@dynamic-labs/sdk-api-core 0.31.0 → 0.33.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.
- package/package.json +1 -1
- package/src/apis/SDKApi.cjs +8 -2
- package/src/apis/SDKApi.cjs.map +1 -1
- package/src/apis/SDKApi.d.ts +4 -2
- package/src/apis/SDKApi.js +8 -2
- package/src/apis/SDKApi.js.map +1 -1
package/src/apis/SDKApi.d.ts
CHANGED
|
@@ -615,6 +615,8 @@ export interface GetRealtimeAuthTokenRequest {
|
|
|
615
615
|
capabilities?: string;
|
|
616
616
|
xDynamicFlowSessionToken?: string;
|
|
617
617
|
xDynamicFlowId?: string;
|
|
618
|
+
xDynamicCheckoutSessionToken?: string;
|
|
619
|
+
xDynamicCheckoutTransactionId?: string;
|
|
618
620
|
}
|
|
619
621
|
export interface GetRecoveryCodesRequest {
|
|
620
622
|
environmentId: string;
|
|
@@ -2935,12 +2937,12 @@ export declare class SDKApi extends runtime.BaseAPI {
|
|
|
2935
2937
|
*/
|
|
2936
2938
|
getPasskeyRegistrationOptionsOptions(requestParameters: GetPasskeyRegistrationOptionsOptionsRequest, initOverrides?: RequestInit): Promise<void>;
|
|
2937
2939
|
/**
|
|
2938
|
-
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows.
|
|
2940
|
+
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows. The token is always scoped to the channels of the resources the caller is entitled to: session tokens are scoped to their own transaction or flow, while JWT callers must name the flow and/or checkout transaction to follow via the X-Dynamic-Flow-Id and X-Dynamic-Checkout-Transaction-Id headers.
|
|
2939
2941
|
* Get a realtime auth token
|
|
2940
2942
|
*/
|
|
2941
2943
|
getRealtimeAuthTokenRaw(requestParameters: GetRealtimeAuthTokenRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<RealtimeAuthTokenResponse>>;
|
|
2942
2944
|
/**
|
|
2943
|
-
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows.
|
|
2945
|
+
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows. The token is always scoped to the channels of the resources the caller is entitled to: session tokens are scoped to their own transaction or flow, while JWT callers must name the flow and/or checkout transaction to follow via the X-Dynamic-Flow-Id and X-Dynamic-Checkout-Transaction-Id headers.
|
|
2944
2946
|
* Get a realtime auth token
|
|
2945
2947
|
*/
|
|
2946
2948
|
getRealtimeAuthToken(requestParameters: GetRealtimeAuthTokenRequest, initOverrides?: RequestInit): Promise<RealtimeAuthTokenResponse>;
|
package/src/apis/SDKApi.js
CHANGED
|
@@ -4933,7 +4933,7 @@ class SDKApi extends BaseAPI {
|
|
|
4933
4933
|
await this.getPasskeyRegistrationOptionsOptionsRaw(requestParameters, initOverrides);
|
|
4934
4934
|
}
|
|
4935
4935
|
/**
|
|
4936
|
-
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows.
|
|
4936
|
+
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows. The token is always scoped to the channels of the resources the caller is entitled to: session tokens are scoped to their own transaction or flow, while JWT callers must name the flow and/or checkout transaction to follow via the X-Dynamic-Flow-Id and X-Dynamic-Checkout-Transaction-Id headers.
|
|
4937
4937
|
* Get a realtime auth token
|
|
4938
4938
|
*/
|
|
4939
4939
|
async getRealtimeAuthTokenRaw(requestParameters, initOverrides) {
|
|
@@ -4951,6 +4951,12 @@ class SDKApi extends BaseAPI {
|
|
|
4951
4951
|
if (requestParameters.xDynamicFlowId !== undefined && requestParameters.xDynamicFlowId !== null) {
|
|
4952
4952
|
headerParameters['X-Dynamic-Flow-Id'] = String(requestParameters.xDynamicFlowId);
|
|
4953
4953
|
}
|
|
4954
|
+
if (requestParameters.xDynamicCheckoutSessionToken !== undefined && requestParameters.xDynamicCheckoutSessionToken !== null) {
|
|
4955
|
+
headerParameters['X-Dynamic-Checkout-Session-Token'] = String(requestParameters.xDynamicCheckoutSessionToken);
|
|
4956
|
+
}
|
|
4957
|
+
if (requestParameters.xDynamicCheckoutTransactionId !== undefined && requestParameters.xDynamicCheckoutTransactionId !== null) {
|
|
4958
|
+
headerParameters['X-Dynamic-Checkout-Transaction-Id'] = String(requestParameters.xDynamicCheckoutTransactionId);
|
|
4959
|
+
}
|
|
4954
4960
|
if (this.configuration && this.configuration.accessToken) {
|
|
4955
4961
|
const token = this.configuration.accessToken;
|
|
4956
4962
|
const tokenString = await token("bearerAuth", []);
|
|
@@ -4967,7 +4973,7 @@ class SDKApi extends BaseAPI {
|
|
|
4967
4973
|
return new JSONApiResponse(response, (jsonValue) => RealtimeAuthTokenResponseFromJSON(jsonValue));
|
|
4968
4974
|
}
|
|
4969
4975
|
/**
|
|
4970
|
-
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows.
|
|
4976
|
+
* Returns a short-lived JWT for subscribing to realtime channels. Accepts either a JWT (via Authorization header) or a checkout session token with transaction ID for unauthenticated checkout flows. The token is always scoped to the channels of the resources the caller is entitled to: session tokens are scoped to their own transaction or flow, while JWT callers must name the flow and/or checkout transaction to follow via the X-Dynamic-Flow-Id and X-Dynamic-Checkout-Transaction-Id headers.
|
|
4971
4977
|
* Get a realtime auth token
|
|
4972
4978
|
*/
|
|
4973
4979
|
async getRealtimeAuthToken(requestParameters, initOverrides) {
|