MOBILE-258: Allow path prefix for operaionsDomain#740
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Enables operationsDomain to include an optional path prefix (e.g. domain.com/api/v2) so operation endpoints are appended after that prefix, while keeping strict validation (no query/fragment/empty path segments).
Changes:
- Added
SdkValidation.isValidOperationsDomain()(host + optional path prefix) and switched configuration/policy validation to use it. - Updated
toBaseUrl/gateway URL-building test coverage to ensure path prefixes are preserved and no double slashes occur. - Documented the new
operationsDomainbehavior inMindboxConfiguration.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| sdk/src/test/java/cloud/mindbox/mobile_sdk/SdkValidationDomainTest.kt | Adds tests for toBaseUrl path-prefix behavior and new operations-domain validation cases. |
| sdk/src/test/java/cloud/mindbox/mobile_sdk/managers/GatewayManagerTest.kt | Verifies operations URLs append endpoints after a configured path prefix (and avoid //). |
| sdk/src/test/java/cloud/mindbox/mobile_sdk/inapp/data/repositories/OperationsDomainConfigPolicyTest.kt | Updates mocks/tests to validate and store operations domains that may include a path prefix. |
| sdk/src/main/java/cloud/mindbox/mobile_sdk/SdkValidation.kt | Introduces isValidOperationsDomain() and uses it in configuration validation. |
| sdk/src/main/java/cloud/mindbox/mobile_sdk/MindboxConfiguration.kt | Updates operationsDomain builder documentation to explicitly allow a path prefix. |
| sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/data/repositories/OperationsDomainConfigPolicy.kt | Switches policy validation from isValidDomain to isValidOperationsDomain. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
sergeysozinov
approved these changes
Jul 22, 2026
enotniy
force-pushed
the
feature/MOBILE-258
branch
from
July 23, 2026 11:50
b40a824 to
29a93c1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://tracker.yandex.ru/MOBILE-258