@carlonicora/nextjs-jsonapi 6.21.0 → 6.23.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.
Files changed (182) hide show
  1. package/dist/{BlockNoteEditor-NXCRWS2O.js → BlockNoteEditor-PPRML5CO.js} +23 -23
  2. package/dist/{BlockNoteEditor-NXCRWS2O.js.map → BlockNoteEditor-PPRML5CO.js.map} +1 -1
  3. package/dist/{BlockNoteEditor-66ZACETR.mjs → BlockNoteEditor-UO4ZRCUM.mjs} +8 -8
  4. package/dist/{BlockNoteViewer-2UDFTXRS.mjs → BlockNoteViewer-2TJZ6JET.mjs} +6 -6
  5. package/dist/{BlockNoteViewer-4OHBRE4Q.js → BlockNoteViewer-K2HBF3IP.js} +7 -7
  6. package/dist/{BlockNoteViewer-4OHBRE4Q.js.map → BlockNoteViewer-K2HBF3IP.js.map} +1 -1
  7. package/dist/{JsonApiRequest-IKKHWCPB.mjs → JsonApiRequest-ADLBJ5RX.mjs} +2 -2
  8. package/dist/JsonApiRequest-KC6DOHKT.js +26 -0
  9. package/dist/{JsonApiRequest-G4J2WTSU.js.map → JsonApiRequest-KC6DOHKT.js.map} +1 -1
  10. package/dist/billing/index.js +495 -495
  11. package/dist/billing/index.mjs +7 -7
  12. package/dist/{chunk-N5ZE2Z6I.js → chunk-53SD4YRF.js} +5 -5
  13. package/dist/{chunk-N5ZE2Z6I.js.map → chunk-53SD4YRF.js.map} +1 -1
  14. package/dist/{chunk-4RA5PRXX.mjs → chunk-7OIWOPM5.mjs} +2 -2
  15. package/dist/{chunk-WCEYT3GG.js → chunk-A5M3MORY.js} +6 -3
  16. package/dist/chunk-A5M3MORY.js.map +1 -0
  17. package/dist/{chunk-AUD6ZLBB.mjs → chunk-BE6UMM5X.mjs} +13 -8
  18. package/dist/chunk-BE6UMM5X.mjs.map +1 -0
  19. package/dist/{chunk-KV4N7DEG.js → chunk-BQ2WAG4K.js} +29 -24
  20. package/dist/chunk-BQ2WAG4K.js.map +1 -0
  21. package/dist/{chunk-OQQ7CZWT.js → chunk-GMMDXINC.js} +12 -12
  22. package/dist/{chunk-OQQ7CZWT.js.map → chunk-GMMDXINC.js.map} +1 -1
  23. package/dist/{chunk-ZB6OYIMB.js → chunk-HN7L6RRW.js} +1296 -1093
  24. package/dist/{chunk-DPXOPLQP.mjs.map → chunk-HN7L6RRW.js.map} +1 -1
  25. package/dist/{chunk-OHHA5BBX.mjs → chunk-HP6DT6K3.mjs} +17 -15
  26. package/dist/chunk-HP6DT6K3.mjs.map +1 -0
  27. package/dist/{chunk-JSHLBRFV.mjs → chunk-N2BFT7KI.mjs} +2 -2
  28. package/dist/chunk-N2BFT7KI.mjs.map +1 -0
  29. package/dist/{chunk-YWLSIIE6.js → chunk-P7L6OFX5.js} +11 -11
  30. package/dist/{chunk-YWLSIIE6.js.map → chunk-P7L6OFX5.js.map} +1 -1
  31. package/dist/{chunk-3CGU6WXY.js → chunk-R5722NLL.js} +926 -924
  32. package/dist/chunk-R5722NLL.js.map +1 -0
  33. package/dist/{chunk-GM4VZTWL.js → chunk-RCOKQ3R4.js} +14 -8
  34. package/dist/chunk-RCOKQ3R4.js.map +1 -0
  35. package/dist/{chunk-M3N7LPHX.mjs → chunk-S7SPAC6X.mjs} +6 -3
  36. package/dist/chunk-S7SPAC6X.mjs.map +1 -0
  37. package/dist/{chunk-54K2CZ2F.js → chunk-SO3YUCL6.js} +4 -4
  38. package/dist/{chunk-54K2CZ2F.js.map → chunk-SO3YUCL6.js.map} +1 -1
  39. package/dist/{chunk-DPXOPLQP.mjs → chunk-T6G2F2BK.mjs} +220 -17
  40. package/dist/chunk-T6G2F2BK.mjs.map +1 -0
  41. package/dist/{chunk-G2UIQSNJ.mjs → chunk-TMV7TL7O.mjs} +4 -4
  42. package/dist/{chunk-BD6ARGGI.js → chunk-TNTCLVUR.js} +15 -15
  43. package/dist/{chunk-BD6ARGGI.js.map → chunk-TNTCLVUR.js.map} +1 -1
  44. package/dist/{chunk-QIEF7HIL.mjs → chunk-VNUT2D27.mjs} +2 -2
  45. package/dist/{chunk-KTGKW72G.mjs → chunk-W4ML6D2X.mjs} +2 -2
  46. package/dist/{chunk-MQ7TXALH.mjs → chunk-YMCL3JXZ.mjs} +14 -8
  47. package/dist/chunk-YMCL3JXZ.mjs.map +1 -0
  48. package/dist/{chunk-QGVVF77L.js → chunk-YSE2Z4RB.js} +11 -11
  49. package/dist/{chunk-QGVVF77L.js.map → chunk-YSE2Z4RB.js.map} +1 -1
  50. package/dist/{chunk-A3RB47X4.mjs → chunk-YTDGYI62.mjs} +3 -3
  51. package/dist/client/JsonApiClient.d.ts +5 -0
  52. package/dist/client/JsonApiClient.d.ts.map +1 -1
  53. package/dist/client/index.js +8 -8
  54. package/dist/client/index.mjs +7 -7
  55. package/dist/client/request.d.ts +5 -0
  56. package/dist/client/request.d.ts.map +1 -1
  57. package/dist/components/index.js +8 -8
  58. package/dist/components/index.mjs +7 -7
  59. package/dist/contexts/index.js +8 -8
  60. package/dist/contexts/index.mjs +7 -7
  61. package/dist/core/abstracts/AbstractService.d.ts +5 -0
  62. package/dist/core/abstracts/AbstractService.d.ts.map +1 -1
  63. package/dist/core/abstracts/ClientAbstractService.d.ts +5 -0
  64. package/dist/core/abstracts/ClientAbstractService.d.ts.map +1 -1
  65. package/dist/core/index.d.ts +2 -0
  66. package/dist/core/index.d.ts.map +1 -1
  67. package/dist/core/index.js +24 -6
  68. package/dist/core/index.js.map +1 -1
  69. package/dist/core/index.mjs +23 -5
  70. package/dist/core/registry/ModuleRegistry.d.ts +3 -0
  71. package/dist/core/registry/ModuleRegistry.d.ts.map +1 -1
  72. package/dist/email-automations/index.js +121 -121
  73. package/dist/email-automations/index.mjs +7 -7
  74. package/dist/features/analytics/index.js +139 -139
  75. package/dist/features/analytics/index.mjs +7 -7
  76. package/dist/features/analytics/server.js +9 -9
  77. package/dist/features/analytics/server.mjs +7 -7
  78. package/dist/features/blog/index.js +154 -154
  79. package/dist/features/blog/index.mjs +7 -7
  80. package/dist/features/blog/server.js +27 -27
  81. package/dist/features/blog/server.mjs +6 -6
  82. package/dist/features/discord-connection/data/discord-connect-confirmation.d.ts +11 -0
  83. package/dist/features/discord-connection/data/discord-connect-confirmation.d.ts.map +1 -0
  84. package/dist/features/discord-connection/data/discord-connect-confirmation.interface.d.ts +14 -0
  85. package/dist/features/discord-connection/data/discord-connect-confirmation.interface.d.ts.map +1 -0
  86. package/dist/features/discord-connection/data/discord-connect-confirmation.service.d.ts +10 -0
  87. package/dist/features/discord-connection/data/discord-connect-confirmation.service.d.ts.map +1 -0
  88. package/dist/features/discord-connection/data/discord-connect-intent.d.ts +11 -0
  89. package/dist/features/discord-connection/data/discord-connect-intent.d.ts.map +1 -0
  90. package/dist/features/discord-connection/data/discord-connect-intent.interface.d.ts +15 -0
  91. package/dist/features/discord-connection/data/discord-connect-intent.interface.d.ts.map +1 -0
  92. package/dist/features/discord-connection/data/discord-connect-intent.service.d.ts +11 -0
  93. package/dist/features/discord-connection/data/discord-connect-intent.service.d.ts.map +1 -0
  94. package/dist/features/discord-connection/data/discord-connection.d.ts +14 -0
  95. package/dist/features/discord-connection/data/discord-connection.d.ts.map +1 -0
  96. package/dist/features/discord-connection/data/discord-connection.interface.d.ts +10 -0
  97. package/dist/features/discord-connection/data/discord-connection.interface.d.ts.map +1 -0
  98. package/dist/features/discord-connection/data/discord-connection.service.d.ts +12 -0
  99. package/dist/features/discord-connection/data/discord-connection.service.d.ts.map +1 -0
  100. package/dist/features/discord-connection/data/index.d.ts +10 -0
  101. package/dist/features/discord-connection/data/index.d.ts.map +1 -0
  102. package/dist/features/discord-connection/discord-connection.module.d.ts +5 -0
  103. package/dist/features/discord-connection/discord-connection.module.d.ts.map +1 -0
  104. package/dist/features/discord-connection/index.d.ts +3 -0
  105. package/dist/features/discord-connection/index.d.ts.map +1 -0
  106. package/dist/features/help/index.js +41 -41
  107. package/dist/features/help/index.mjs +7 -7
  108. package/dist/features/tokenusage/index.js +130 -130
  109. package/dist/features/tokenusage/index.mjs +7 -7
  110. package/dist/features/user/contexts/UserContext.d.ts.map +1 -1
  111. package/dist/index.d.ts +1 -1
  112. package/dist/index.d.ts.map +1 -1
  113. package/dist/index.js +27 -7
  114. package/dist/index.js.map +1 -1
  115. package/dist/index.mjs +26 -6
  116. package/dist/local-transport-MJPOKPTU.js +15 -0
  117. package/dist/{local-transport-4YDJ6FQG.js.map → local-transport-MJPOKPTU.js.map} +1 -1
  118. package/dist/{local-transport-C7YTA4I7.mjs → local-transport-RVD4FZGA.mjs} +5 -5
  119. package/dist/offline/index.js +51 -51
  120. package/dist/offline/index.mjs +6 -6
  121. package/dist/{request-66FGJIHB.mjs → request-4AWGPIGH.mjs} +2 -2
  122. package/dist/{request-6W6UGKJV.js → request-H5FZBZA2.js} +3 -3
  123. package/dist/{request-6W6UGKJV.js.map → request-H5FZBZA2.js.map} +1 -1
  124. package/dist/server/index.js +8 -8
  125. package/dist/server/index.mjs +7 -7
  126. package/dist/unified/JsonApiRequest.d.ts +5 -0
  127. package/dist/unified/JsonApiRequest.d.ts.map +1 -1
  128. package/dist/write-through-7I3LA2WN.mjs +15 -0
  129. package/dist/write-through-HE2QSOVI.js +15 -0
  130. package/dist/{write-through-BAPS24GL.js.map → write-through-HE2QSOVI.js.map} +1 -1
  131. package/package.json +1 -1
  132. package/src/client/JsonApiClient.ts +10 -0
  133. package/src/client/__tests__/request.credentials.spec.ts +103 -0
  134. package/src/client/request.ts +9 -0
  135. package/src/components/forms/EditorSheet.tsx +2 -2
  136. package/src/components/forms/__tests__/EditorSheet.spec.tsx +16 -0
  137. package/src/core/abstracts/AbstractService.ts +10 -0
  138. package/src/core/abstracts/ClientAbstractService.ts +10 -0
  139. package/src/core/index.ts +3 -0
  140. package/src/core/registry/ModuleRegistry.ts +4 -0
  141. package/src/features/discord-connection/data/__tests__/DiscordConnection.spec.ts +114 -0
  142. package/src/features/discord-connection/data/discord-connect-confirmation.interface.ts +16 -0
  143. package/src/features/discord-connection/data/discord-connect-confirmation.service.ts +21 -0
  144. package/src/features/discord-connection/data/discord-connect-confirmation.ts +46 -0
  145. package/src/features/discord-connection/data/discord-connect-intent.interface.ts +16 -0
  146. package/src/features/discord-connection/data/discord-connect-intent.service.ts +20 -0
  147. package/src/features/discord-connection/data/discord-connect-intent.ts +42 -0
  148. package/src/features/discord-connection/data/discord-connection.interface.ts +10 -0
  149. package/src/features/discord-connection/data/discord-connection.service.ts +17 -0
  150. package/src/features/discord-connection/data/discord-connection.ts +41 -0
  151. package/src/features/discord-connection/data/index.ts +9 -0
  152. package/src/features/discord-connection/discord-connection.module.ts +28 -0
  153. package/src/features/discord-connection/index.ts +2 -0
  154. package/src/features/oauth/components/OAuthClientDetail.tsx +1 -1
  155. package/src/features/user/contexts/UserContext.tsx +6 -2
  156. package/src/index.ts +1 -1
  157. package/src/unified/JsonApiRequest.ts +14 -0
  158. package/dist/JsonApiRequest-G4J2WTSU.js +0 -26
  159. package/dist/chunk-3CGU6WXY.js.map +0 -1
  160. package/dist/chunk-AUD6ZLBB.mjs.map +0 -1
  161. package/dist/chunk-GM4VZTWL.js.map +0 -1
  162. package/dist/chunk-JSHLBRFV.mjs.map +0 -1
  163. package/dist/chunk-KV4N7DEG.js.map +0 -1
  164. package/dist/chunk-M3N7LPHX.mjs.map +0 -1
  165. package/dist/chunk-MQ7TXALH.mjs.map +0 -1
  166. package/dist/chunk-OHHA5BBX.mjs.map +0 -1
  167. package/dist/chunk-WCEYT3GG.js.map +0 -1
  168. package/dist/chunk-ZB6OYIMB.js.map +0 -1
  169. package/dist/local-transport-4YDJ6FQG.js +0 -15
  170. package/dist/write-through-BAPS24GL.js +0 -15
  171. package/dist/write-through-IWQKXYHE.mjs +0 -15
  172. /package/dist/{BlockNoteEditor-66ZACETR.mjs.map → BlockNoteEditor-UO4ZRCUM.mjs.map} +0 -0
  173. /package/dist/{BlockNoteViewer-2UDFTXRS.mjs.map → BlockNoteViewer-2TJZ6JET.mjs.map} +0 -0
  174. /package/dist/{JsonApiRequest-IKKHWCPB.mjs.map → JsonApiRequest-ADLBJ5RX.mjs.map} +0 -0
  175. /package/dist/{chunk-4RA5PRXX.mjs.map → chunk-7OIWOPM5.mjs.map} +0 -0
  176. /package/dist/{chunk-G2UIQSNJ.mjs.map → chunk-TMV7TL7O.mjs.map} +0 -0
  177. /package/dist/{chunk-QIEF7HIL.mjs.map → chunk-VNUT2D27.mjs.map} +0 -0
  178. /package/dist/{chunk-KTGKW72G.mjs.map → chunk-W4ML6D2X.mjs.map} +0 -0
  179. /package/dist/{chunk-A3RB47X4.mjs.map → chunk-YTDGYI62.mjs.map} +0 -0
  180. /package/dist/{local-transport-C7YTA4I7.mjs.map → local-transport-RVD4FZGA.mjs.map} +0 -0
  181. /package/dist/{request-66FGJIHB.mjs.map → request-4AWGPIGH.mjs.map} +0 -0
  182. /package/dist/{write-through-IWQKXYHE.mjs.map → write-through-7I3LA2WN.mjs.map} +0 -0
@@ -0,0 +1,41 @@
1
+ import { AbstractApiData, JsonApiHydratedDataInterface, Modules } from "../../../core";
2
+ import { DiscordConnectionInterface } from "./discord-connection.interface";
3
+
4
+ export class DiscordConnection extends AbstractApiData implements DiscordConnectionInterface {
5
+ private _connected: boolean = false;
6
+ private _discordName?: string;
7
+
8
+ get connected(): boolean {
9
+ return this._connected;
10
+ }
11
+
12
+ get discordName(): string | undefined {
13
+ return this._discordName;
14
+ }
15
+
16
+ rehydrate(data: JsonApiHydratedDataInterface): this {
17
+ super.rehydrate(data);
18
+
19
+ const attributes = data.jsonApi.attributes ?? {};
20
+
21
+ this._connected = attributes.connected === true;
22
+ this._discordName = attributes.discordName ?? undefined;
23
+
24
+ return this;
25
+ }
26
+
27
+ /** Read-only resource: the body only identifies the user. */
28
+ createJsonApi(data: { id: string }) {
29
+ const response: any = {
30
+ data: {
31
+ type: Modules.DiscordConnection.name,
32
+ id: data.id,
33
+ attributes: {},
34
+ relationships: {},
35
+ },
36
+ included: [],
37
+ };
38
+
39
+ return response;
40
+ }
41
+ }
@@ -0,0 +1,9 @@
1
+ export * from "./discord-connection.interface";
2
+ export * from "./discord-connection";
3
+ export * from "./discord-connection.service";
4
+ export * from "./discord-connect-intent.interface";
5
+ export * from "./discord-connect-intent";
6
+ export * from "./discord-connect-intent.service";
7
+ export * from "./discord-connect-confirmation.interface";
8
+ export * from "./discord-connect-confirmation";
9
+ export * from "./discord-connect-confirmation.service";
@@ -0,0 +1,28 @@
1
+ import { ModuleFactory } from "../../permissions";
2
+ import { DiscordConnectConfirmation } from "./data/discord-connect-confirmation";
3
+ import { DiscordConnectIntent } from "./data/discord-connect-intent";
4
+ import { DiscordConnection } from "./data/discord-connection";
5
+
6
+ // Bootstrapper key: `DiscordConnection: DiscordConnectionModule(moduleFactory)`.
7
+ export const DiscordConnectionModule = (factory: ModuleFactory) =>
8
+ factory({
9
+ name: "discord-connections",
10
+ pageUrl: "/settings",
11
+ model: DiscordConnection,
12
+ });
13
+
14
+ // Bootstrapper key: `DiscordConnectIntent: DiscordConnectIntentModule(moduleFactory)`.
15
+ export const DiscordConnectIntentModule = (factory: ModuleFactory) =>
16
+ factory({
17
+ name: "discord-connect-intents",
18
+ pageUrl: "/settings",
19
+ model: DiscordConnectIntent,
20
+ });
21
+
22
+ // Bootstrapper key: `DiscordConnectConfirmation: DiscordConnectConfirmationModule(moduleFactory)`.
23
+ export const DiscordConnectConfirmationModule = (factory: ModuleFactory) =>
24
+ factory({
25
+ name: "discord-connect-confirmations",
26
+ pageUrl: "/settings",
27
+ model: DiscordConnectConfirmation,
28
+ });
@@ -0,0 +1,2 @@
1
+ export * from "./discord-connection.module";
2
+ export * from "./data";
@@ -201,7 +201,7 @@ export function OAuthClientDetail({
201
201
  {/* Actions */}
202
202
  <div className="flex gap-3 pt-4">
203
203
  {onEdit && (
204
- <Button variant="outline" onClick={onEdit} disabled={isLoading}>
204
+ <Button onClick={onEdit} disabled={isLoading}>
205
205
  <Pencil className="h-4 w-4 me-2" />
206
206
  {t("ui.buttons.edit")}
207
207
  </Button>
@@ -76,6 +76,7 @@ export const UserProvider = ({ children, dehydratedUser }: UserProviderProps) =>
76
76
  };
77
77
 
78
78
  const functions: ReactNode[] = [];
79
+ const actionBar: ReactNode[] = [];
79
80
 
80
81
  if (user) {
81
82
  response.element = `${user.name}${user.isDeleted ? ` (${t(`user.deleted`)})` : ""}`;
@@ -86,17 +87,20 @@ export const UserProvider = ({ children, dehydratedUser }: UserProviderProps) =>
86
87
  if (!user.isActivated)
87
88
  functions.push(<UserResentInvitationEmail key={`UserResentInvitationEmail`} user={user} />);
88
89
 
89
- functions.push(<UserDeleter key={`UserDeleter`} user={user} />);
90
+ actionBar.push(<UserDeleter key={`UserDeleter`} user={user} />);
90
91
 
91
92
  // Opt-in: only apps that registered AccountDeletionModule, platform administrators only.
92
93
  if (hasRole(getRoleId().Administrator) && isAccountDeletionEnabled())
93
94
  functions.push(<AccountDeletionAdminTrigger key={`AccountDeletionAdminTrigger`} user={user} />);
94
95
  }
95
96
 
96
- functions.push(<UserEditor key={`UserEditor`} user={user} propagateChanges={setUser} />);
97
+ // Delete and Edit live in the secondary header (action bar), where they
98
+ // render as labelled buttons, like every other entity page.
99
+ actionBar.push(<UserEditor key={`UserEditor`} user={user} propagateChanges={setUser} />);
97
100
  }
98
101
 
99
102
  if (functions.length > 0) response.functions = functions;
103
+ if (actionBar.length > 0) response.actionBar = actionBar;
100
104
 
101
105
  return response;
102
106
  };
package/src/index.ts CHANGED
@@ -23,7 +23,7 @@ export { configureI18n } from "./i18n";
23
23
  export type { I18nConfig } from "./i18n";
24
24
 
25
25
  // Login configuration (multi-provider auth)
26
- export { configureLogin } from "./login";
26
+ export { configureLogin, isDiscordAuthEnabled } from "./login";
27
27
  export type { LoginConfig } from "./login";
28
28
 
29
29
  // Roles configuration
@@ -17,6 +17,7 @@ type DirectFetchFn = (params: {
17
17
  companyId?: string;
18
18
  language: string;
19
19
  additionalHeaders?: Record<string, string>;
20
+ credentials?: RequestCredentials;
20
21
  }) => Promise<ApiData>;
21
22
 
22
23
  type ServerRequestFn = (params: {
@@ -95,6 +96,8 @@ async function makeRequest(params: {
95
96
  companyId?: string;
96
97
  language: string;
97
98
  additionalHeaders?: Record<string, string>;
99
+ /** Client-side only: forwarded to the browser `fetch`. Ignored on the server. */
100
+ credentials?: RequestCredentials;
98
101
  }): Promise<ApiData> {
99
102
  if (typeof window !== "undefined") {
100
103
  // Client-side: use direct fetch
@@ -111,6 +114,7 @@ async function makeRequest(params: {
111
114
  companyId: params.companyId,
112
115
  language: params.language,
113
116
  additionalHeaders: params.additionalHeaders,
117
+ credentials: params.credentials,
114
118
  });
115
119
  } else {
116
120
  // Server-side: use server request with caching
@@ -188,6 +192,7 @@ export async function JsonApiGet(params: {
188
192
  language: string;
189
193
  token?: string;
190
194
  baseUrl?: string;
195
+ credentials?: RequestCredentials;
191
196
  }): Promise<ApiResponseInterface> {
192
197
  runBootstrapper();
193
198
  // A cached server GET never sends the token, so it must not read the cookie either:
@@ -203,6 +208,7 @@ export async function JsonApiGet(params: {
203
208
  companyId: params.companyId,
204
209
  language: params.language,
205
210
  additionalHeaders: _staticConfig?.additionalHeaders,
211
+ credentials: params.credentials,
206
212
  });
207
213
 
208
214
  return translateResponse({
@@ -233,6 +239,7 @@ export async function JsonApiPost(params: {
233
239
  responseType?: ApiRequestDataTypeInterface;
234
240
  token?: string;
235
241
  baseUrl?: string;
242
+ credentials?: RequestCredentials;
236
243
  }): Promise<ApiResponseInterface> {
237
244
  runBootstrapper();
238
245
  const token = params.token ?? (await getToken());
@@ -253,6 +260,7 @@ export async function JsonApiPost(params: {
253
260
  companyId: params.companyId,
254
261
  language: params.language,
255
262
  additionalHeaders: _staticConfig?.additionalHeaders,
263
+ credentials: params.credentials,
256
264
  });
257
265
 
258
266
  return translateResponse({
@@ -273,6 +281,7 @@ export async function JsonApiPut(params: {
273
281
  responseType?: ApiRequestDataTypeInterface;
274
282
  token?: string;
275
283
  baseUrl?: string;
284
+ credentials?: RequestCredentials;
276
285
  }): Promise<ApiResponseInterface> {
277
286
  runBootstrapper();
278
287
  const token = params.token ?? (await getToken());
@@ -293,6 +302,7 @@ export async function JsonApiPut(params: {
293
302
  companyId: params.companyId,
294
303
  language: params.language,
295
304
  additionalHeaders: _staticConfig?.additionalHeaders,
305
+ credentials: params.credentials,
296
306
  });
297
307
 
298
308
  return translateResponse({
@@ -314,6 +324,7 @@ export async function JsonApiPatch(params: {
314
324
  language: string;
315
325
  token?: string;
316
326
  baseUrl?: string;
327
+ credentials?: RequestCredentials;
317
328
  }): Promise<ApiResponseInterface> {
318
329
  runBootstrapper();
319
330
  const token = params.token ?? (await getToken());
@@ -334,6 +345,7 @@ export async function JsonApiPatch(params: {
334
345
  companyId: params.companyId,
335
346
  language: params.language,
336
347
  additionalHeaders: _staticConfig?.additionalHeaders,
348
+ credentials: params.credentials,
337
349
  });
338
350
 
339
351
  return translateResponse({
@@ -352,6 +364,7 @@ export async function JsonApiDelete(params: {
352
364
  responseType?: ApiRequestDataTypeInterface;
353
365
  token?: string;
354
366
  baseUrl?: string;
367
+ credentials?: RequestCredentials;
355
368
  }): Promise<ApiResponseInterface> {
356
369
  runBootstrapper();
357
370
  const token = params.token ?? (await getToken());
@@ -363,6 +376,7 @@ export async function JsonApiDelete(params: {
363
376
  companyId: params.companyId,
364
377
  language: params.language,
365
378
  additionalHeaders: _staticConfig?.additionalHeaders,
379
+ credentials: params.credentials,
366
380
  });
367
381
 
368
382
  return translateResponse({
@@ -1,26 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
-
4
-
5
-
6
-
7
-
8
-
9
-
10
-
11
-
12
- var _chunkGM4VZTWLjs = require('./chunk-GM4VZTWL.js');
13
- require('./chunk-7QVYU63E.js');
14
-
15
-
16
-
17
-
18
-
19
-
20
-
21
-
22
-
23
-
24
-
25
- exports.JsonApiDelete = _chunkGM4VZTWLjs.JsonApiDelete; exports.JsonApiGet = _chunkGM4VZTWLjs.JsonApiGet; exports.JsonApiPatch = _chunkGM4VZTWLjs.JsonApiPatch; exports.JsonApiPost = _chunkGM4VZTWLjs.JsonApiPost; exports.JsonApiPut = _chunkGM4VZTWLjs.JsonApiPut; exports.buildUrl = _chunkGM4VZTWLjs.buildUrl; exports.configureJsonApi = _chunkGM4VZTWLjs.configureJsonApi; exports.getApiUrl = _chunkGM4VZTWLjs.getApiUrl; exports.getAppUrl = _chunkGM4VZTWLjs.getAppUrl; exports.getTrackablePages = _chunkGM4VZTWLjs.getTrackablePages;
26
- //# sourceMappingURL=JsonApiRequest-G4J2WTSU.js.map