EnvironmentInterceptor
Interceptor that attaches the X-Target-Environment header to every request, sourced once from configuration (io.rekast.sdk.utils.ApiConfig.environment) rather than being threaded through every service method as a parameter.
The header is required by all product endpoints and by the OAuth2 (oauth2/token, bc-authorize) endpoints, but not by the API-user provisioning and access-token bootstrap endpoints (createApiUser, getApiUser, createApiKey, getAccessToken), which are therefore skipped:
any path containing an
apiusersegment (create/get API user, create API key), andthe plain access-token endpoint
/{productType}/token/(identified by a finaltokensegment with nooauth2segment — the OAuth2 token endpoint/{productType}/oauth2/token/still receives it).
Parameters
The target environment (e.g., "sandbox" or "production").