@salesforce/lds-runtime-one-app 1.463.0 → 1.464.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.
@@ -2636,7 +2636,7 @@ function buildServiceDescriptor$d(luvio) {
2636
2636
  },
2637
2637
  };
2638
2638
  }
2639
- // version: 1.463.0-ea9ecd17fc
2639
+ // version: 1.464.0-e54c238397
2640
2640
 
2641
2641
  class AuraGraphQLNormalizedCacheControlCommand extends AuraNormalizedCacheControlCommand {
2642
2642
  constructor(config, documentRootType, services) {
@@ -2975,7 +2975,7 @@ function buildServiceDescriptor$9(notifyRecordUpdateAvailable, getNormalizedLuvi
2975
2975
  },
2976
2976
  };
2977
2977
  }
2978
- // version: 1.463.0-ea9ecd17fc
2978
+ // version: 1.464.0-e54c238397
2979
2979
 
2980
2980
  class RetryService {
2981
2981
  constructor(defaultRetryPolicy) {
@@ -4447,7 +4447,12 @@ function buildServiceDescriptor$2(interceptors = {
4447
4447
  }
4448
4448
  const fetchArgs = cleanInit === void 0 ? [input] : [input, cleanInit];
4449
4449
  const baseContext = interceptors.createContext?.();
4450
- const context = contextSeed === void 0 ? baseContext : { ...baseContext, ...contextSeed };
4450
+ const onestore = cleanInit?.onestore;
4451
+ const context = contextSeed === void 0 && onestore === void 0 ? baseContext : {
4452
+ ...baseContext,
4453
+ ...contextSeed,
4454
+ ...onestore !== void 0 && { onestore }
4455
+ };
4451
4456
  const {
4452
4457
  request: requestInterceptors = [],
4453
4458
  retry: retryInterceptor = void 0,
@@ -5901,7 +5906,7 @@ function getEnvironmentSetting(name) {
5901
5906
  }
5902
5907
  return undefined;
5903
5908
  }
5904
- // version: 1.463.0-8515018faf
5909
+ // version: 1.464.0-b35c0e7723
5905
5910
 
5906
5911
  /**
5907
5912
  * Helpers for reaching the Aura framework from the LDS Aura runtime.
@@ -6316,7 +6321,13 @@ function getOrGenerateErrorId(responseBody, status, statusText) {
6316
6321
  return generateErrorId(context);
6317
6322
  }
6318
6323
  function buildLexRuntime5xxStatusResponseInterceptor(logger) {
6319
- return async (response) => {
6324
+ return async (response, context) => {
6325
+ // The caller opted in (`onestore.handleServerError`, exposed by the fetch service as
6326
+ // `context.onestore`) to receive the 5xx itself, so skip the gack and the throw and
6327
+ // let the response flow to the command's error handling.
6328
+ if (context?.onestore?.handleServerError === true) {
6329
+ return response;
6330
+ }
6320
6331
  if (response.status >= 500 && response.status < 600) {
6321
6332
  const internalLogMessage = `LEX runtime 5xx: ${response.status} ${response.statusText || ''}`.trim();
6322
6333
  logger.warn(internalLogMessage);
@@ -7631,15 +7642,21 @@ function buildFetchRetryInterceptor() {
7631
7642
  }
7632
7643
 
7633
7644
  /**
7634
- * The context-seed key under which a custom command forwards its JWT mint
7645
+ * Legacy context-seed key under which a custom command forwards its JWT mint
7635
7646
  * parameters. The framework's `buildServiceDescriptor` merges the request init's
7636
7647
  * `__contextSeed` onto the per-request interceptor context, so this interceptor
7637
- * reads the params off `context[JWT_MINT_PARAMS_SEED_KEY]`.
7648
+ * can read the params off `context[JWT_MINT_PARAMS_SEED_KEY]`.
7649
+ *
7650
+ * **Transitional.** The first-class channel is now the typed
7651
+ * `init.onestore.mintParams` field (onestore 3.29.0), which this interceptor
7652
+ * prefers. This seed key remains only as a fallback while the core
7653
+ * `onestore-custom-adapters` producers still write `__contextSeed`; it — together
7654
+ * with the `context` fallback and the interceptor's `context` parameter — is
7655
+ * removed once those producers emit `onestore.mintParams`. That removal is the
7656
+ * follow-up PR #8314 (tracked under W-24472492).
7638
7657
  *
7639
- * This is a cross-team contract: the custom command writes this key, this
7640
- * interceptor reads it. It is intentionally an opaque key — OneStore does not
7641
- * define it and never inspects the param shape; the typed shape lives in the
7642
- * resolver.
7658
+ * It is intentionally an opaque key — OneStore does not define it and never
7659
+ * inspects the param shape; the typed shape lives in the resolver.
7643
7660
  */
7644
7661
  const JWT_MINT_PARAMS_SEED_KEY = 'jwtMintParams';
7645
7662
  /**
@@ -7670,15 +7687,17 @@ function hasAuthorizationHeader([resource, options]) {
7670
7687
  * Builds the request interceptor that bridges the per-request context seed to the
7671
7688
  * dispatching SFAP JwtManager for the **parameterized** mint path.
7672
7689
  *
7673
- * For a parameterized SFAP command, the context carries `jwtMintParams`. This
7674
- * interceptor reads them, calls `jwtManager.getJwt(params)` (which the dispatching
7675
- * resolver routes to the parameterized resolver), attaches the `Authorization`
7676
- * header, and rewrites the request URL via the minted `baseUri`. The presence of
7677
- * that `Authorization` header is the signal the descriptor's guarded legacy
7678
- * interceptor uses to skip — so the legacy path does not mint a second time.
7690
+ * For a parameterized SFAP command, the mint params arrive on the typed
7691
+ * `init.onestore.mintParams` field (preferred) or, transitionally, under the
7692
+ * legacy `context[jwtMintParams]` seed. This interceptor reads them (onestore
7693
+ * first), calls `jwtManager.getJwt(params)` (which the dispatching resolver routes
7694
+ * to the parameterized resolver), attaches the `Authorization` header, and
7695
+ * rewrites the request URL via the minted `baseUri`. The presence of that
7696
+ * `Authorization` header is the signal the descriptor's guarded legacy interceptor
7697
+ * uses to skip — so the legacy path does not mint a second time.
7679
7698
  *
7680
- * For a legacy parameterless command the context carries no `jwtMintParams`, so
7681
- * this interceptor **early-returns on its first line** and the request flows
7699
+ * For a legacy parameterless command neither channel carries mint params, so this
7700
+ * interceptor **early-returns on its first statement** and the request flows
7682
7701
  * unchanged to the legacy `buildJwtRequestHeaderInterceptor` — guaranteeing zero
7683
7702
  * behavior change for non-opted-in adapters.
7684
7703
  *
@@ -7692,8 +7711,11 @@ function hasAuthorizationHeader([resource, options]) {
7692
7711
  */
7693
7712
  function buildJwtParameterizationInterceptor(jwtManager, jwtRequestModifier = (_extraInfo, fetchArgs) => fetchArgs) {
7694
7713
  return (fetchArgs, context) => {
7695
- const jwtContext = context;
7696
- const mintParams = jwtContext?.[JWT_MINT_PARAMS_SEED_KEY];
7714
+ // Prefer the typed `init.onestore.mintParams`; fall back to the legacy
7715
+ // `context[JWT_MINT_PARAMS_SEED_KEY]` seed while the core producers still
7716
+ // write it (transitional dual-read — see JWT_MINT_PARAMS_SEED_KEY).
7717
+ const mintParams = fetchArgs[1]?.onestore?.mintParams ??
7718
+ context?.[JWT_MINT_PARAMS_SEED_KEY];
7697
7719
  // No mint params → not a parameterized request. Do nothing; the legacy
7698
7720
  // interceptor handles it. This MUST be the first statement so non-opted-in
7699
7721
  // SFAP commands observe no work at all.
@@ -7788,7 +7810,8 @@ function buildJwtAuthorizedSfapFetchServiceDescriptor(logger) {
7788
7810
  *
7789
7811
  * It reuses the module's `sfapJwtManager`: `cdp_url` is emitted on the same
7790
7812
  * `SFAP_API`-scope JWT, so the Data360 command mints the same kind of token — it
7791
- * just forwards the data-cloud scopes via the context-seed `jwtMintParams`.
7813
+ * just forwards the data-cloud scopes via `onestore.mintParams` (or, transitionally,
7814
+ * the legacy context-seed `jwtMintParams`).
7792
7815
  *
7793
7816
  * Gated behind its own `data_360_cdp_url_rewrite` auth-scope tag so it binds ONLY to
7794
7817
  * the Data360 command — the SFAP fleet never flows past this interceptor.
@@ -7919,10 +7942,11 @@ function buildJwtRequestInterceptor(logger) {
7919
7942
  * (`cdp_url`), and modifiers only receive `extraInfo`. So — like the copilot
7920
7943
  * interceptor that reads `decodedInfo.iss` — it holds the token directly:
7921
7944
  *
7922
- * 1. Read the command's `jwtMintParams` off the per-request context seed and
7923
- * mint (via the parameterized SFAP resolver, routed by the dispatching
7924
- * resolver inside `sfapJwtManager`). Without mint params there is no token
7925
- * to authorize with, so leave the request untouched.
7945
+ * 1. Read the command's mint params from `init.onestore.mintParams` (preferred)
7946
+ * or the legacy per-request context seed, and mint (via the parameterized
7947
+ * SFAP resolver, routed by the dispatching resolver inside `sfapJwtManager`).
7948
+ * Without mint params there is no token to authorize with, so leave the
7949
+ * request untouched.
7926
7950
  * 2. Decode `cdp_url` from the JWT and resolve the tenant-specific endpoint
7927
7951
  * (TSE). `cdp_url` is a bare host, so a scheme is prepended before parsing
7928
7952
  * and the protocol is forced to `https:`.
@@ -7941,7 +7965,11 @@ function buildJwtRequestInterceptor(logger) {
7941
7965
  */
7942
7966
  function buildData360HostRewriteInterceptor(logger) {
7943
7967
  return (fetchArgs, context) => {
7944
- const mintParams = context?.[JWT_MINT_PARAMS_SEED_KEY];
7968
+ // Prefer the typed `init.onestore.mintParams`; fall back to the legacy
7969
+ // `context[JWT_MINT_PARAMS_SEED_KEY]` seed while the core producers still
7970
+ // write it (transitional dual-read — see JWT_MINT_PARAMS_SEED_KEY).
7971
+ const mintParams = fetchArgs[1]?.onestore?.mintParams ??
7972
+ context?.[JWT_MINT_PARAMS_SEED_KEY];
7945
7973
  // No mint params → not a parameterized Data360 request. Nothing to do.
7946
7974
  if (mintParams === undefined) {
7947
7975
  return resolvedPromiseLike$2(fetchArgs);
@@ -10656,6 +10684,10 @@ function getLexRuntimeDefaultInterceptorConfig(logger) {
10656
10684
  buildCsrfTokenInterceptor(),
10657
10685
  buildEntityEncodingInterceptor(),
10658
10686
  buildFirstPartyHeaderInterceptor(),
10687
+ // Per-request gzip: compresses only operations that opt in via
10688
+ // `init.onestore.compression`; a pass-through no-op otherwise. Last in
10689
+ // the chain so it compresses the final body, after body-modifying interceptors.
10690
+ buildCompressionInterceptor(),
10659
10691
  ],
10660
10692
  retry: buildFetchRetryInterceptor(),
10661
10693
  response: [
@@ -11559,4 +11591,4 @@ function ldsEngineCreator() {
11559
11591
  }
11560
11592
 
11561
11593
  export { LexRequestStrategy, PDL_ENGINE_REGISTRATION_ID, PdlPrefetcherEventType, PdlRequestPriority, buildPredictorForContext, configService, ldsEngineCreator as default, initializeLDS, initializeOneStore, notifyUpdateAvailableFactory, registerRequestStrategy, saveRequestAsPrediction, subscribeToPrefetcherEvents, unregisterRequestStrategy, whenPredictionsReady };
11562
- // version: 1.463.0-ea9ecd17fc
11594
+ // version: 1.464.0-e54c238397
@@ -20,7 +20,8 @@ export declare function buildJwtAuthorizedSfapFetchServiceDescriptor(logger: Log
20
20
  *
21
21
  * It reuses the module's `sfapJwtManager`: `cdp_url` is emitted on the same
22
22
  * `SFAP_API`-scope JWT, so the Data360 command mints the same kind of token — it
23
- * just forwards the data-cloud scopes via the context-seed `jwtMintParams`.
23
+ * just forwards the data-cloud scopes via `onestore.mintParams` (or, transitionally,
24
+ * the legacy context-seed `jwtMintParams`).
24
25
  *
25
26
  * Gated behind its own `data_360_cdp_url_rewrite` auth-scope tag so it binds ONLY to
26
27
  * the Data360 command — the SFAP fleet never flows past this interceptor.
@@ -3,15 +3,21 @@ import { type JwtRequestModifier } from '@conduit-client/service-fetch-network/v
3
3
  import type { JwtManager } from '@conduit-client/jwt-manager';
4
4
  import type { ExtraInfo } from '../network-sfap';
5
5
  /**
6
- * The context-seed key under which a custom command forwards its JWT mint
6
+ * Legacy context-seed key under which a custom command forwards its JWT mint
7
7
  * parameters. The framework's `buildServiceDescriptor` merges the request init's
8
8
  * `__contextSeed` onto the per-request interceptor context, so this interceptor
9
- * reads the params off `context[JWT_MINT_PARAMS_SEED_KEY]`.
9
+ * can read the params off `context[JWT_MINT_PARAMS_SEED_KEY]`.
10
10
  *
11
- * This is a cross-team contract: the custom command writes this key, this
12
- * interceptor reads it. It is intentionally an opaque key — OneStore does not
13
- * define it and never inspects the param shape; the typed shape lives in the
14
- * resolver.
11
+ * **Transitional.** The first-class channel is now the typed
12
+ * `init.onestore.mintParams` field (onestore 3.29.0), which this interceptor
13
+ * prefers. This seed key remains only as a fallback while the core
14
+ * `onestore-custom-adapters` producers still write `__contextSeed`; it — together
15
+ * with the `context` fallback and the interceptor's `context` parameter — is
16
+ * removed once those producers emit `onestore.mintParams`. That removal is the
17
+ * follow-up PR #8314 (tracked under W-24472492).
18
+ *
19
+ * It is intentionally an opaque key — OneStore does not define it and never
20
+ * inspects the param shape; the typed shape lives in the resolver.
15
21
  */
16
22
  export declare const JWT_MINT_PARAMS_SEED_KEY = "jwtMintParams";
17
23
  /**
@@ -27,15 +33,17 @@ export declare function hasAuthorizationHeader([resource, options]: FetchParamet
27
33
  * Builds the request interceptor that bridges the per-request context seed to the
28
34
  * dispatching SFAP JwtManager for the **parameterized** mint path.
29
35
  *
30
- * For a parameterized SFAP command, the context carries `jwtMintParams`. This
31
- * interceptor reads them, calls `jwtManager.getJwt(params)` (which the dispatching
32
- * resolver routes to the parameterized resolver), attaches the `Authorization`
33
- * header, and rewrites the request URL via the minted `baseUri`. The presence of
34
- * that `Authorization` header is the signal the descriptor's guarded legacy
35
- * interceptor uses to skip — so the legacy path does not mint a second time.
36
+ * For a parameterized SFAP command, the mint params arrive on the typed
37
+ * `init.onestore.mintParams` field (preferred) or, transitionally, under the
38
+ * legacy `context[jwtMintParams]` seed. This interceptor reads them (onestore
39
+ * first), calls `jwtManager.getJwt(params)` (which the dispatching resolver routes
40
+ * to the parameterized resolver), attaches the `Authorization` header, and
41
+ * rewrites the request URL via the minted `baseUri`. The presence of that
42
+ * `Authorization` header is the signal the descriptor's guarded legacy interceptor
43
+ * uses to skip — so the legacy path does not mint a second time.
36
44
  *
37
- * For a legacy parameterless command the context carries no `jwtMintParams`, so
38
- * this interceptor **early-returns on its first line** and the request flows
45
+ * For a legacy parameterless command neither channel carries mint params, so this
46
+ * interceptor **early-returns on its first statement** and the request flows
39
47
  * unchanged to the legacy `buildJwtRequestHeaderInterceptor` — guaranteeing zero
40
48
  * behavior change for non-opted-in adapters.
41
49
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/lds-runtime-one-app",
3
- "version": "1.463.0",
3
+ "version": "1.464.0",
4
4
  "license": "SEE LICENSE IN LICENSE.txt",
5
5
  "description": "LDS engine for the one.app (LEX) runtime.",
6
6
  "main": "dist/oneAppLdsEngineCreator.js",
@@ -34,53 +34,53 @@
34
34
  "release:corejar": "yarn build && ../core-build/scripts/core.js --name=lds-runtime-one-app"
35
35
  },
36
36
  "devDependencies": {
37
- "@conduit-client/service-provisioner": "3.30.0",
38
- "@conduit-client/tools-core": "3.30.0",
39
- "@salesforce/lds-adapters-apex": "^1.463.0",
40
- "@salesforce/lds-adapters-uiapi": "^1.463.0",
41
- "@salesforce/lds-ads-bridge": "^1.463.0",
42
- "@salesforce/lds-aura-storage": "^1.463.0",
43
- "@salesforce/lds-bindings": "^1.463.0",
44
- "@salesforce/lds-instrumentation": "^1.463.0",
45
- "@salesforce/lds-network-adapter": "^1.463.0",
46
- "@salesforce/lds-network-aura": "^1.463.0",
47
- "@salesforce/lds-network-fetch": "^1.463.0",
37
+ "@conduit-client/service-provisioner": "3.32.0",
38
+ "@conduit-client/tools-core": "3.32.0",
39
+ "@salesforce/lds-adapters-apex": "^1.464.0",
40
+ "@salesforce/lds-adapters-uiapi": "^1.464.0",
41
+ "@salesforce/lds-ads-bridge": "^1.464.0",
42
+ "@salesforce/lds-aura-storage": "^1.464.0",
43
+ "@salesforce/lds-bindings": "^1.464.0",
44
+ "@salesforce/lds-instrumentation": "^1.464.0",
45
+ "@salesforce/lds-network-adapter": "^1.464.0",
46
+ "@salesforce/lds-network-aura": "^1.464.0",
47
+ "@salesforce/lds-network-fetch": "^1.464.0",
48
48
  "jwt-encode": "1.0.1"
49
49
  },
50
50
  "dependencies": {
51
- "@conduit-client/command-aura-graphql-normalized-cache-control": "3.30.0",
52
- "@conduit-client/command-aura-network": "3.30.0",
53
- "@conduit-client/command-aura-normalized-cache-control": "3.30.0",
54
- "@conduit-client/command-fetch-network": "3.30.0",
55
- "@conduit-client/command-http-graphql-normalized-cache-control": "3.30.0",
56
- "@conduit-client/command-http-normalized-cache-control": "3.30.0",
57
- "@conduit-client/command-ndjson": "3.30.0",
58
- "@conduit-client/command-network": "3.30.0",
59
- "@conduit-client/command-sse": "3.30.0",
60
- "@conduit-client/command-streaming": "3.30.0",
61
- "@conduit-client/jwt-manager": "3.30.0",
62
- "@conduit-client/service-aura-network": "3.30.0",
63
- "@conduit-client/service-bindings-imperative": "3.30.0",
64
- "@conduit-client/service-bindings-lwc": "3.30.0",
65
- "@conduit-client/service-cache": "3.30.0",
66
- "@conduit-client/service-cache-control": "3.30.0",
67
- "@conduit-client/service-cache-inclusion-policy": "3.30.0",
68
- "@conduit-client/service-config": "3.30.0",
69
- "@conduit-client/service-feature-flags": "3.30.0",
70
- "@conduit-client/service-fetch-network": "3.30.0",
71
- "@conduit-client/service-instrument-command": "3.30.0",
72
- "@conduit-client/service-pubsub": "3.30.0",
73
- "@conduit-client/service-renewable-resource-manager": "3.30.0",
74
- "@conduit-client/service-store": "3.30.0",
75
- "@conduit-client/utils": "3.30.0",
51
+ "@conduit-client/command-aura-graphql-normalized-cache-control": "3.32.0",
52
+ "@conduit-client/command-aura-network": "3.32.0",
53
+ "@conduit-client/command-aura-normalized-cache-control": "3.32.0",
54
+ "@conduit-client/command-fetch-network": "3.32.0",
55
+ "@conduit-client/command-http-graphql-normalized-cache-control": "3.32.0",
56
+ "@conduit-client/command-http-normalized-cache-control": "3.32.0",
57
+ "@conduit-client/command-ndjson": "3.32.0",
58
+ "@conduit-client/command-network": "3.32.0",
59
+ "@conduit-client/command-sse": "3.32.0",
60
+ "@conduit-client/command-streaming": "3.32.0",
61
+ "@conduit-client/jwt-manager": "3.32.0",
62
+ "@conduit-client/service-aura-network": "3.32.0",
63
+ "@conduit-client/service-bindings-imperative": "3.32.0",
64
+ "@conduit-client/service-bindings-lwc": "3.32.0",
65
+ "@conduit-client/service-cache": "3.32.0",
66
+ "@conduit-client/service-cache-control": "3.32.0",
67
+ "@conduit-client/service-cache-inclusion-policy": "3.32.0",
68
+ "@conduit-client/service-config": "3.32.0",
69
+ "@conduit-client/service-feature-flags": "3.32.0",
70
+ "@conduit-client/service-fetch-network": "3.32.0",
71
+ "@conduit-client/service-instrument-command": "3.32.0",
72
+ "@conduit-client/service-pubsub": "3.32.0",
73
+ "@conduit-client/service-renewable-resource-manager": "3.32.0",
74
+ "@conduit-client/service-store": "3.32.0",
75
+ "@conduit-client/utils": "3.32.0",
76
76
  "@luvio/network-adapter-composable": "0.161.2",
77
77
  "@luvio/network-adapter-fetch": "0.161.2",
78
78
  "@lwc/state": "^0.29.0",
79
- "@salesforce/lds-adapters-onestore-graphql": "^1.463.0",
79
+ "@salesforce/lds-adapters-onestore-graphql": "^1.464.0",
80
80
  "@salesforce/lds-adapters-uiapi-lex": "^1.415.0",
81
- "@salesforce/lds-durable-storage": "^1.463.0",
82
- "@salesforce/lds-luvio-service": "^1.463.0",
83
- "@salesforce/lds-luvio-uiapi-records-service": "^1.463.0"
81
+ "@salesforce/lds-durable-storage": "^1.464.0",
82
+ "@salesforce/lds-luvio-service": "^1.464.0",
83
+ "@salesforce/lds-luvio-uiapi-records-service": "^1.464.0"
84
84
  },
85
85
  "luvioBundlesize": [
86
86
  {