@geins/core 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -21,9 +21,17 @@ export declare abstract class BaseApiService {
|
|
|
21
21
|
destroy(): void;
|
|
22
22
|
/**
|
|
23
23
|
* Merges caller-provided variables with default languageId, marketId, and channelId from settings.
|
|
24
|
-
*
|
|
24
|
+
*
|
|
25
|
+
* Per-request overrides: if `vars` already contains `languageId`, `marketId`, or `channelId`
|
|
26
|
+
* those values are used as-is and the SDK-level settings are ignored for that field.
|
|
27
|
+
* This mirrors the shape of {@link RequestContext} and allows callers to pass a
|
|
28
|
+
* `RequestContext` object directly as part of `vars` to override locale/market on a
|
|
29
|
+
* per-request basis without reinitialising the SDK.
|
|
30
|
+
*
|
|
31
|
+
* @param vars - Variables to enrich with defaults. Pre-existing `languageId`, `marketId`,
|
|
32
|
+
* or `channelId` fields take precedence over the SDK-level settings.
|
|
25
33
|
* @returns The enriched variables object.
|
|
26
|
-
* @throws {GeinsError} If locale or market is missing
|
|
34
|
+
* @throws {GeinsError} If locale or market is missing from both `vars` and the SDK settings.
|
|
27
35
|
*/
|
|
28
36
|
protected createVariables(vars: Record<string, unknown>): Record<string, unknown>;
|
|
29
37
|
/**
|