@base44-preview/sdk 0.7.2-pr.30.51b5464 → 0.7.3-pr.30.2bc2a1c

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/dist/client.d.ts CHANGED
@@ -19,6 +19,7 @@ export declare function createClient(config: {
19
19
  serviceToken?: string;
20
20
  requiresAuth?: boolean;
21
21
  functionsVersion?: string;
22
+ headers?: Record<string, string>;
22
23
  options?: CreateClientOptions;
23
24
  onRedirectToLogin?: () => void;
24
25
  }): {
package/dist/client.js CHANGED
@@ -18,7 +18,7 @@ import { RoomsSocket } from "./utils/socket-utils.js";
18
18
  * @returns {Object} Base44 client instance
19
19
  */
20
20
  export function createClient(config) {
21
- const { serverUrl = "https://base44.app", appId, token, serviceToken, requiresAuth = false, options, functionsVersion, onRedirectToLogin, } = config;
21
+ const { serverUrl = "https://base44.app", appId, token, serviceToken, requiresAuth = false, options, functionsVersion, onRedirectToLogin, headers: optionalHeaders, } = config;
22
22
  const socketConfig = {
23
23
  serverUrl,
24
24
  mountPath: "/ws-user-apps/socket.io/",
@@ -30,6 +30,7 @@ export function createClient(config) {
30
30
  config: socketConfig,
31
31
  });
32
32
  const headers = {
33
+ ...optionalHeaders,
33
34
  "X-App-Id": String(appId),
34
35
  };
35
36
  const functionHeaders = functionsVersion
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@base44-preview/sdk",
3
- "version": "0.7.2-pr.30.51b5464",
3
+ "version": "0.7.3-pr.30.2bc2a1c",
4
4
  "description": "JavaScript SDK for Base44 API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",