@sylphx/sdk 0.3.3 → 0.3.4
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/index.d.cts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/dist/nextjs/index.d.cts +14 -11
- package/dist/nextjs/index.d.ts +14 -11
- package/dist/nextjs/index.js +43 -15
- package/dist/nextjs/index.js.map +1 -1
- package/dist/nextjs/index.mjs +43 -15
- package/dist/nextjs/index.mjs.map +1 -1
- package/dist/react/index.d.cts +3 -3
- package/dist/react/index.d.ts +3 -3
- package/dist/react/index.js +2 -2
- package/dist/react/index.js.map +1 -1
- package/dist/react/index.mjs +2 -2
- package/dist/react/index.mjs.map +1 -1
- package/dist/server/index.d.cts +14 -11
- package/dist/server/index.d.ts +14 -11
- package/dist/server/index.js +43 -15
- package/dist/server/index.js.map +1 -1
- package/dist/server/index.mjs +43 -15
- package/dist/server/index.mjs.map +1 -1
- package/dist/web-analytics.js.map +1 -1
- package/dist/web-analytics.mjs.map +1 -1
- package/package.json +1 -1
package/dist/react/index.d.cts
CHANGED
|
@@ -735,7 +735,7 @@ interface SylphxConfig {
|
|
|
735
735
|
*/
|
|
736
736
|
readonly secretKey?: string;
|
|
737
737
|
/**
|
|
738
|
-
* Project ref — short
|
|
738
|
+
* Project ref — short 12-char lowercase alphanumeric string (e.g. "abc123def456").
|
|
739
739
|
*
|
|
740
740
|
* The SDK targets: https://{ref}.api.sylphx.com/v1
|
|
741
741
|
*
|
|
@@ -5337,7 +5337,7 @@ interface components {
|
|
|
5337
5337
|
OrgInvitation: {
|
|
5338
5338
|
/**
|
|
5339
5339
|
* @description Invitation ID
|
|
5340
|
-
* @example
|
|
5340
|
+
* @example inv_3Zb83qVQxkHMJPZ8VrJfQ2
|
|
5341
5341
|
*/
|
|
5342
5342
|
id: string
|
|
5343
5343
|
/**
|
|
@@ -5407,7 +5407,7 @@ interface components {
|
|
|
5407
5407
|
/**
|
|
5408
5408
|
* Format: uuid
|
|
5409
5409
|
* @description Invitation token (ID)
|
|
5410
|
-
* @example
|
|
5410
|
+
* @example inv_3Zb83qVQxkHMJPZ8VrJfQ2
|
|
5411
5411
|
*/
|
|
5412
5412
|
token: string
|
|
5413
5413
|
}
|
package/dist/react/index.d.ts
CHANGED
|
@@ -735,7 +735,7 @@ interface SylphxConfig {
|
|
|
735
735
|
*/
|
|
736
736
|
readonly secretKey?: string;
|
|
737
737
|
/**
|
|
738
|
-
* Project ref — short
|
|
738
|
+
* Project ref — short 12-char lowercase alphanumeric string (e.g. "abc123def456").
|
|
739
739
|
*
|
|
740
740
|
* The SDK targets: https://{ref}.api.sylphx.com/v1
|
|
741
741
|
*
|
|
@@ -5337,7 +5337,7 @@ interface components {
|
|
|
5337
5337
|
OrgInvitation: {
|
|
5338
5338
|
/**
|
|
5339
5339
|
* @description Invitation ID
|
|
5340
|
-
* @example
|
|
5340
|
+
* @example inv_3Zb83qVQxkHMJPZ8VrJfQ2
|
|
5341
5341
|
*/
|
|
5342
5342
|
id: string
|
|
5343
5343
|
/**
|
|
@@ -5407,7 +5407,7 @@ interface components {
|
|
|
5407
5407
|
/**
|
|
5408
5408
|
* Format: uuid
|
|
5409
5409
|
* @description Invitation token (ID)
|
|
5410
|
-
* @example
|
|
5410
|
+
* @example inv_3Zb83qVQxkHMJPZ8VrJfQ2
|
|
5411
5411
|
*/
|
|
5412
5412
|
token: string
|
|
5413
5413
|
}
|
package/dist/react/index.js
CHANGED
|
@@ -43519,7 +43519,7 @@ function httpStatusToErrorCode(status) {
|
|
|
43519
43519
|
return status >= 500 ? "INTERNAL_SERVER_ERROR" : "BAD_REQUEST";
|
|
43520
43520
|
}
|
|
43521
43521
|
}
|
|
43522
|
-
var REF_PATTERN = /^[a-z0-9]{
|
|
43522
|
+
var REF_PATTERN = /^[a-z0-9]{12}$/;
|
|
43523
43523
|
function createConfig(input) {
|
|
43524
43524
|
let secretKey;
|
|
43525
43525
|
if (input.secretKey) {
|
|
@@ -43538,7 +43538,7 @@ function createConfig(input) {
|
|
|
43538
43538
|
const trimmedRef = input.ref.trim();
|
|
43539
43539
|
if (!REF_PATTERN.test(trimmedRef)) {
|
|
43540
43540
|
throw new SylphxError(
|
|
43541
|
-
`[Sylphx] Invalid project ref format: "${input.ref}". Expected a
|
|
43541
|
+
`[Sylphx] Invalid project ref format: "${input.ref}". Expected a 12-character lowercase alphanumeric string (e.g. "abc123def456"). Get your ref from Platform Console \u2192 Projects \u2192 Your Project \u2192 Overview.`,
|
|
43542
43542
|
{ code: "BAD_REQUEST" }
|
|
43543
43543
|
);
|
|
43544
43544
|
}
|