@dynamic-labs/sdk-api-core 0.0.939 → 0.0.940

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-api-core",
3
- "version": "0.0.939",
3
+ "version": "0.0.940",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -4033,7 +4033,7 @@ class SDKApi extends runtime.BaseAPI {
4033
4033
  await this.getPasskeyRegistrationOptionsOptionsRaw(requestParameters, initOverrides);
4034
4034
  }
4035
4035
  /**
4036
- * Returns a short-lived JWT for subscribing to realtime channels.
4036
+ * 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.
4037
4037
  * Get a realtime auth token
4038
4038
  */
4039
4039
  async getRealtimeAuthTokenRaw(requestParameters, initOverrides) {
@@ -4045,6 +4045,12 @@ class SDKApi extends runtime.BaseAPI {
4045
4045
  queryParameters['capabilities'] = requestParameters.capabilities;
4046
4046
  }
4047
4047
  const headerParameters = {};
4048
+ if (requestParameters.xDynamicCheckoutSessionToken !== undefined && requestParameters.xDynamicCheckoutSessionToken !== null) {
4049
+ headerParameters['X-Dynamic-Checkout-Session-Token'] = String(requestParameters.xDynamicCheckoutSessionToken);
4050
+ }
4051
+ if (requestParameters.xDynamicCheckoutTransactionId !== undefined && requestParameters.xDynamicCheckoutTransactionId !== null) {
4052
+ headerParameters['X-Dynamic-Checkout-Transaction-Id'] = String(requestParameters.xDynamicCheckoutTransactionId);
4053
+ }
4048
4054
  if (this.configuration && this.configuration.accessToken) {
4049
4055
  const token = this.configuration.accessToken;
4050
4056
  const tokenString = await token("bearerAuth", []);
@@ -4061,7 +4067,7 @@ class SDKApi extends runtime.BaseAPI {
4061
4067
  return new runtime.JSONApiResponse(response, (jsonValue) => RealtimeAuthTokenResponse.RealtimeAuthTokenResponseFromJSON(jsonValue));
4062
4068
  }
4063
4069
  /**
4064
- * Returns a short-lived JWT for subscribing to realtime channels.
4070
+ * 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.
4065
4071
  * Get a realtime auth token
4066
4072
  */
4067
4073
  async getRealtimeAuthToken(requestParameters, initOverrides) {
@@ -497,6 +497,8 @@ export interface GetPasskeyRegistrationOptionsOptionsRequest {
497
497
  export interface GetRealtimeAuthTokenRequest {
498
498
  environmentId: string;
499
499
  capabilities?: string;
500
+ xDynamicCheckoutSessionToken?: string;
501
+ xDynamicCheckoutTransactionId?: string;
500
502
  }
501
503
  export interface GetRecoveryCodesRequest {
502
504
  environmentId: string;
@@ -2285,12 +2287,12 @@ export declare class SDKApi extends runtime.BaseAPI {
2285
2287
  */
2286
2288
  getPasskeyRegistrationOptionsOptions(requestParameters: GetPasskeyRegistrationOptionsOptionsRequest, initOverrides?: RequestInit): Promise<void>;
2287
2289
  /**
2288
- * Returns a short-lived JWT for subscribing to realtime channels.
2290
+ * 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.
2289
2291
  * Get a realtime auth token
2290
2292
  */
2291
2293
  getRealtimeAuthTokenRaw(requestParameters: GetRealtimeAuthTokenRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<RealtimeAuthTokenResponse>>;
2292
2294
  /**
2293
- * Returns a short-lived JWT for subscribing to realtime channels.
2295
+ * 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.
2294
2296
  * Get a realtime auth token
2295
2297
  */
2296
2298
  getRealtimeAuthToken(requestParameters: GetRealtimeAuthTokenRequest, initOverrides?: RequestInit): Promise<RealtimeAuthTokenResponse>;
@@ -4029,7 +4029,7 @@ class SDKApi extends BaseAPI {
4029
4029
  await this.getPasskeyRegistrationOptionsOptionsRaw(requestParameters, initOverrides);
4030
4030
  }
4031
4031
  /**
4032
- * Returns a short-lived JWT for subscribing to realtime channels.
4032
+ * 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.
4033
4033
  * Get a realtime auth token
4034
4034
  */
4035
4035
  async getRealtimeAuthTokenRaw(requestParameters, initOverrides) {
@@ -4041,6 +4041,12 @@ class SDKApi extends BaseAPI {
4041
4041
  queryParameters['capabilities'] = requestParameters.capabilities;
4042
4042
  }
4043
4043
  const headerParameters = {};
4044
+ if (requestParameters.xDynamicCheckoutSessionToken !== undefined && requestParameters.xDynamicCheckoutSessionToken !== null) {
4045
+ headerParameters['X-Dynamic-Checkout-Session-Token'] = String(requestParameters.xDynamicCheckoutSessionToken);
4046
+ }
4047
+ if (requestParameters.xDynamicCheckoutTransactionId !== undefined && requestParameters.xDynamicCheckoutTransactionId !== null) {
4048
+ headerParameters['X-Dynamic-Checkout-Transaction-Id'] = String(requestParameters.xDynamicCheckoutTransactionId);
4049
+ }
4044
4050
  if (this.configuration && this.configuration.accessToken) {
4045
4051
  const token = this.configuration.accessToken;
4046
4052
  const tokenString = await token("bearerAuth", []);
@@ -4057,7 +4063,7 @@ class SDKApi extends BaseAPI {
4057
4063
  return new JSONApiResponse(response, (jsonValue) => RealtimeAuthTokenResponseFromJSON(jsonValue));
4058
4064
  }
4059
4065
  /**
4060
- * Returns a short-lived JWT for subscribing to realtime channels.
4066
+ * 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.
4061
4067
  * Get a realtime auth token
4062
4068
  */
4063
4069
  async getRealtimeAuthToken(requestParameters, initOverrides) {