@animaapp/anima-sdk 0.6.7 → 0.6.9
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.cjs.map +1 -1
- package/dist/index.d.ts +14 -2
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -63,7 +63,7 @@ export declare class CodegenError extends Error {
|
|
|
63
63
|
detail?: unknown;
|
|
64
64
|
constructor({ name, reason, status, detail, }: {
|
|
65
65
|
name: string;
|
|
66
|
-
reason: CodegenErrorReason | CodegenRouteErrorReason | SDKErrorReason;
|
|
66
|
+
reason: CodegenErrorReason | CodegenRouteErrorReason | SDKErrorReason | GetCodeFromWebsiteErrorReason;
|
|
67
67
|
status?: number;
|
|
68
68
|
detail?: unknown;
|
|
69
69
|
});
|
|
@@ -224,6 +224,11 @@ export declare type GeneratingCodePayload = {
|
|
|
224
224
|
files: AnimaFiles;
|
|
225
225
|
};
|
|
226
226
|
|
|
227
|
+
/**
|
|
228
|
+
* Errors from the Website To Code Flow
|
|
229
|
+
*/
|
|
230
|
+
export declare type GetCodeFromWebsiteErrorReason = "Scraping is blocked" | "Unknown";
|
|
231
|
+
|
|
227
232
|
export declare type GetCodeFromWebsiteHandler = ((message: SSEGetCodeFromWebsiteMessage) => void) | {
|
|
228
233
|
onQueueing?: () => void;
|
|
229
234
|
onStart?: ({ sessionId }: {
|
|
@@ -566,7 +571,7 @@ export declare type SSEGetCodeFromWebsiteMessage = {
|
|
|
566
571
|
type: 'aborted';
|
|
567
572
|
} | {
|
|
568
573
|
type: 'error';
|
|
569
|
-
payload:
|
|
574
|
+
payload: SSEGetCodeFromWebsiteMessageErrorPayload;
|
|
570
575
|
} | {
|
|
571
576
|
type: 'done';
|
|
572
577
|
payload: {
|
|
@@ -575,6 +580,13 @@ export declare type SSEGetCodeFromWebsiteMessage = {
|
|
|
575
580
|
};
|
|
576
581
|
};
|
|
577
582
|
|
|
583
|
+
export declare type SSEGetCodeFromWebsiteMessageErrorPayload = {
|
|
584
|
+
errorName: string;
|
|
585
|
+
task?: string;
|
|
586
|
+
reason: GetCodeFromWebsiteErrorReason;
|
|
587
|
+
sentryTraceId?: string;
|
|
588
|
+
};
|
|
589
|
+
|
|
578
590
|
/**
|
|
579
591
|
* @deprecated This type is deprecated and will be removed soon.
|
|
580
592
|
*/
|