@sesamy/sesamy-js 1.113.2 → 1.115.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.
@@ -89,6 +89,18 @@ declare interface AuthConfig {
89
89
  * @default false
90
90
  */
91
91
  useHttpCookies?: boolean;
92
+ /**
93
+ * Server-injected id-token for SSR. When set, sesamy-js treats the user as
94
+ * authenticated immediately without calling `/auth/userinfo`.
95
+ *
96
+ * The server typically reads the HttpOnly auth cookie, validates it, and
97
+ * injects the id-token into the page for the client.
98
+ *
99
+ * Alternatively, include a `<script type="application/json"
100
+ * id="sesamy-server-state">{"idToken":"eyJ..."}</script>` element — the
101
+ * cookie-auth plugin reads it automatically.
102
+ */
103
+ idToken?: string;
92
104
  }
93
105
 
94
106
  export declare interface AuthPlugin {
@@ -191,6 +203,8 @@ export declare interface CapsulePlugin {
191
203
 
192
204
  declare interface CapsulePluginDeps {
193
205
  getToken: (throwOnUnauthorized?: boolean) => Promise<string | null>;
206
+ /** API base URL from `config.api.endpoint`, used to rewrite DCA unlock URLs. */
207
+ apiEndpoint?: string;
194
208
  }
195
209
 
196
210
  export { Checkout }