@darqlabs/curator-sdk 0.2.0 → 0.3.1
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/cjs/client.js +6 -0
- package/dist/cjs/client.js.map +1 -1
- package/dist/cjs/errors.d.ts +96 -5
- package/dist/cjs/errors.d.ts.map +1 -1
- package/dist/cjs/errors.js +181 -15
- package/dist/cjs/errors.js.map +1 -1
- package/dist/cjs/http.d.ts.map +1 -1
- package/dist/cjs/http.js +65 -13
- package/dist/cjs/http.js.map +1 -1
- package/dist/cjs/index.d.ts +2 -1
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/index.js +5 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types.d.ts +12 -0
- package/dist/cjs/types.d.ts.map +1 -1
- package/dist/esm/client.js +6 -0
- package/dist/esm/client.js.map +1 -1
- package/dist/esm/errors.d.ts +96 -5
- package/dist/esm/errors.d.ts.map +1 -1
- package/dist/esm/errors.js +176 -14
- package/dist/esm/errors.js.map +1 -1
- package/dist/esm/http.d.ts.map +1 -1
- package/dist/esm/http.js +66 -14
- package/dist/esm/http.js.map +1 -1
- package/dist/esm/index.d.ts +2 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types.d.ts +12 -0
- package/dist/esm/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/cjs/client.js
CHANGED
|
@@ -429,6 +429,12 @@ function adaptHistoryMessage(m) {
|
|
|
429
429
|
content: m.content,
|
|
430
430
|
sequence: m.sequence,
|
|
431
431
|
createdAt: m.created_at,
|
|
432
|
+
// Passed through as-is: the server already uses these exact camelCase keys.
|
|
433
|
+
// Omitted rather than set to [] when absent, so `attachments` being present
|
|
434
|
+
// means the server actually reported some.
|
|
435
|
+
...(Array.isArray(m.attachments) && m.attachments.length > 0
|
|
436
|
+
? { attachments: m.attachments }
|
|
437
|
+
: {}),
|
|
432
438
|
};
|
|
433
439
|
}
|
|
434
440
|
function toServerFile(f) {
|
package/dist/cjs/client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/client.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,2CAMoB;AACpB,yCAAkC;AAClC,uDAAgD;AAChD,uCAAqF;AACrF,qCAAyC;AACzC,+DAA0D;AAE1D,uDAAyD;AAsFzD,MAAM,gBAAgB,GAAG,yBAAyB,CAAA;AAClD,MAAM,kBAAkB,GAAG,OAAO,CAAA;AAElC,MAAa,OAAO;IACD,IAAI,CAAY;IAChB,cAAc,CAAS;IACvB,kBAAkB,CAAa;IAC/B,gBAAgB,CAAQ;IACzC,+CAA+C;IACtC,KAAK,CAAO;IACrB,uEAAuE;IAC9D,YAAY,CAAc;IAEnC,YAAY,IAAoB;QAC9B,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,IAAI,gBAAgB,CAAA;QAChD,kEAAkE;QAClE,qEAAqE;QACrE,0EAA0E;QAC1E,MAAM,WAAW,GAAG,UAAU,CAAC,KAAK,CAAA;QACpC,MAAM,SAAS,GACb,IAAI,CAAC,KAAK,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAE,SAAqC,CAAC,CAAA;QACrG,IAAI,CAAC,IAAI,GAAG,IAAI,oBAAU,CAAC;YACzB,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,OAAO;YACP,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,UAAU,EAAE,IAAI,CAAC,UAAU;SAC5B,CAAC,CAAA;QACF,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,OAAO,CAAA;QAClC,IAAI,CAAC,kBAAkB,GAAG,IAAI,CAAC,WAAW,IAAI,YAAY,CAAA;Q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
11
|
import type { AssistantMessage, ApprovalDetails, AuthorizationDetails, AgentFailureClass } from "./types.js";
|
|
12
12
|
export declare class CuratorError extends Error {
|
|
13
|
+
/**
|
|
14
|
+
* What an END USER may be shown.
|
|
15
|
+
*
|
|
16
|
+
* `message` is for developers — it can name the request, the status, and the
|
|
17
|
+
* server's own wording. That is the wrong text to put in a chat bubble, and
|
|
18
|
+
* shipping it there is not a hypothetical: a 500 rendered as
|
|
19
|
+
* `HTTP 500 from https://api.../agents/<slug>/conversations: …`, exposing the
|
|
20
|
+
* deployment's URL to whoever was chatting, and an end-user token failure
|
|
21
|
+
* rendered as "End-user JWT could not be verified", which tells the person
|
|
22
|
+
* nothing they can act on and leaks the auth mechanism.
|
|
23
|
+
*
|
|
24
|
+
* Every subclass sets this to something safe and actionable. `renderError` in
|
|
25
|
+
* the React bindings prefers it and never falls back to `message`, so a new
|
|
26
|
+
* error type is safe-by-default rather than leaky-by-default.
|
|
27
|
+
*/
|
|
28
|
+
readonly userMessage: string;
|
|
29
|
+
/** HTTP status, when this came from a response. */
|
|
30
|
+
readonly status: number | null;
|
|
31
|
+
/** Server error code (`error.code`), when present. */
|
|
32
|
+
readonly code: string | null;
|
|
33
|
+
/**
|
|
34
|
+
* Correlation id from `x-request-id` / `correlationId`. The one detail worth
|
|
35
|
+
* showing a user on an unexpected failure — it is what support can trace,
|
|
36
|
+
* and it says nothing about the system's shape.
|
|
37
|
+
*/
|
|
38
|
+
readonly requestId: string | null;
|
|
39
|
+
/**
|
|
40
|
+
* Request URL, as a PROPERTY rather than part of `message`. Available for
|
|
41
|
+
* logs and bug reports without riding along into anything user-visible.
|
|
42
|
+
*/
|
|
43
|
+
readonly url: string | null;
|
|
13
44
|
constructor(message: string, options?: {
|
|
14
45
|
cause?: unknown;
|
|
46
|
+
userMessage?: string;
|
|
47
|
+
status?: number | null;
|
|
48
|
+
code?: string | null;
|
|
49
|
+
requestId?: string | null;
|
|
50
|
+
url?: string | null;
|
|
15
51
|
});
|
|
16
52
|
}
|
|
53
|
+
/** Last-resort user-facing text. Deliberately says nothing about the system. */
|
|
54
|
+
export declare const DEFAULT_USER_MESSAGE = "Something went wrong. Please try again.";
|
|
55
|
+
/** Appends a correlation id when there is one, so support has a handle. */
|
|
56
|
+
export declare function withRequestId(text: string, requestId: string | null): string;
|
|
57
|
+
type HttpContext = {
|
|
58
|
+
status?: number | null;
|
|
59
|
+
code?: string | null;
|
|
60
|
+
requestId?: string | null;
|
|
61
|
+
url?: string | null;
|
|
62
|
+
};
|
|
17
63
|
/** HTTP 401 from the API — your API key is missing, invalid, or revoked. */
|
|
18
64
|
export declare class CuratorAuthError extends CuratorError {
|
|
19
|
-
constructor(message?: string);
|
|
65
|
+
constructor(message?: string, ctx?: HttpContext);
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* HTTP 401 specifically because the END-USER token was missing, expired, or
|
|
69
|
+
* unverifiable — distinct from `CuratorAuthError`, which is about the
|
|
70
|
+
* integrator's API key.
|
|
71
|
+
*
|
|
72
|
+
* Separate because the remediation is completely different: an API-key failure
|
|
73
|
+
* needs a developer, whereas this one is usually a stale session the user fixes
|
|
74
|
+
* by signing in again. Collapsing them produced "Authentication failed. Check
|
|
75
|
+
* your API key." in response to an expired user token, which sends the reader
|
|
76
|
+
* after the wrong thing entirely.
|
|
77
|
+
*/
|
|
78
|
+
export declare class CuratorEndUserAuthError extends CuratorError {
|
|
79
|
+
constructor(message?: string, ctx?: HttpContext);
|
|
20
80
|
}
|
|
21
81
|
/** HTTP 403 from the API — your API key doesn't have permission for this action. */
|
|
22
82
|
export declare class CuratorForbiddenError extends CuratorError {
|
|
23
|
-
constructor(message?: string);
|
|
83
|
+
constructor(message?: string, ctx?: HttpContext);
|
|
24
84
|
}
|
|
25
85
|
/** HTTP 404 from the API — the deployment slug or conversation id wasn't found. */
|
|
26
86
|
export declare class CuratorNotFoundError extends CuratorError {
|
|
27
|
-
constructor(message?: string);
|
|
87
|
+
constructor(message?: string, ctx?: HttpContext);
|
|
28
88
|
}
|
|
29
89
|
/** HTTP 410 from the API — the deployment was retired. */
|
|
30
90
|
export declare class CuratorDeploymentRetiredError extends CuratorError {
|
|
31
91
|
readonly retiredAt: string | null;
|
|
32
|
-
constructor(message: string, retiredAt: string | null);
|
|
92
|
+
constructor(message: string, retiredAt: string | null, ctx?: HttpContext);
|
|
33
93
|
}
|
|
34
94
|
/** HTTP 429 from the API — back off. */
|
|
35
95
|
export declare class CuratorRateLimitError extends CuratorError {
|
|
36
96
|
readonly retryAfterSeconds: number | null;
|
|
37
|
-
constructor(message?: string, retryAfterSeconds?: number | null);
|
|
97
|
+
constructor(message?: string, retryAfterSeconds?: number | null, ctx?: HttpContext);
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* HTTP 5xx. The server already returns a generic body plus a `correlationId`
|
|
101
|
+
* for unexpected failures, so the useful thing to surface is that id — not the
|
|
102
|
+
* status line and URL the SDK used to build into `message`.
|
|
103
|
+
*/
|
|
104
|
+
export declare class CuratorServerError extends CuratorError {
|
|
105
|
+
constructor(message: string, ctx?: HttpContext);
|
|
38
106
|
}
|
|
39
107
|
/**
|
|
40
108
|
* Run paused waiting for human approval. Approval resolution is not
|
|
@@ -69,6 +137,22 @@ export declare class CuratorAuthorizationRequiredError extends CuratorError {
|
|
|
69
137
|
runId: string;
|
|
70
138
|
});
|
|
71
139
|
}
|
|
140
|
+
/**
|
|
141
|
+
* Delegated-identity failure codes, mirroring the server's taxonomy in
|
|
142
|
+
* `delegationFailure.ts`. Four outcomes because each implies a DIFFERENT next
|
|
143
|
+
* action, and collapsing them is what makes "why did this fail only after the
|
|
144
|
+
* approval?" unanswerable.
|
|
145
|
+
*
|
|
146
|
+
* `AgentFailureClass` has no delegated variant, and the errored payload carries
|
|
147
|
+
* no structured code — the server prefixes the failure MESSAGE with the code
|
|
148
|
+
* instead. So this is recovered by parsing that prefix, which is a real
|
|
149
|
+
* coupling: if the server stops prefixing, `delegationCode` silently goes null
|
|
150
|
+
* and the user gets the generic agent-error text. The durable fix is a
|
|
151
|
+
* first-class field on the errored event; until then the prefix is the contract.
|
|
152
|
+
*/
|
|
153
|
+
export type DelegationFailureCode = "DELEGATED_IDENTITY_EXPIRED" | "DELEGATED_IDENTITY_REVOKED" | "DELEGATED_TOKEN_EXCHANGE_FAILED" | "DOWNSTREAM_AUTH_REJECTED" | "DELEGATED_AUTH_NOT_CONFIGURED";
|
|
154
|
+
/** Recover the delegated-failure code from a server message prefix. */
|
|
155
|
+
export declare function parseDelegationFailureCode(message: string | undefined): DelegationFailureCode | null;
|
|
72
156
|
/**
|
|
73
157
|
* The agent run reached a terminal error state (LLM quota, auth, 5xx
|
|
74
158
|
* exhausted retries, etc.). `failureClass` and `isPermanent` mirror the
|
|
@@ -80,6 +164,12 @@ export declare class CuratorAgentError extends CuratorError {
|
|
|
80
164
|
readonly conversationId: string;
|
|
81
165
|
readonly runId: string;
|
|
82
166
|
readonly stepId: string | null;
|
|
167
|
+
/**
|
|
168
|
+
* Set when the run failed on delegated identity. Distinct from
|
|
169
|
+
* `failureClass`, which has no delegated variant — see
|
|
170
|
+
* {@link DelegationFailureCode}.
|
|
171
|
+
*/
|
|
172
|
+
readonly delegationCode: DelegationFailureCode | null;
|
|
83
173
|
constructor(args: {
|
|
84
174
|
message: string;
|
|
85
175
|
failureClass: AgentFailureClass;
|
|
@@ -104,4 +194,5 @@ export declare class CuratorTimeoutError extends CuratorError {
|
|
|
104
194
|
continueWaiting: (timeoutMs?: number) => Promise<AssistantMessage>;
|
|
105
195
|
});
|
|
106
196
|
}
|
|
197
|
+
export {};
|
|
107
198
|
//# sourceMappingURL=errors.d.ts.map
|
package/dist/cjs/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EACV,gBAAgB,EAChB,eAAe,EACf,oBAAoB,EACpB,iBA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GAAG,IAAI,CAAA;KACvB;CAuBF;AAED;;;;GAIG;AACH,qBAAa,mBAAoB,SAAQ,YAAY;IACnD,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAA;IAC/B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,eAAe,EAAE,CAAC,SAAS,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC,gBAAgB,CAAC,CAAA;gBAE/D,IAAI,EAAE;QAChB,cAAc,EAAE,MAAM,CAAA;QACtB,KAAK,EAAE,MAAM,CAAA;QACb,eAAe,EAAE,CAAC,SAAS,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC,gBAAgB,CAAC,CAAA;KACnE;CAUF"}
|
package/dist/cjs/errors.js
CHANGED
|
@@ -10,11 +10,49 @@
|
|
|
10
10
|
* backstop.
|
|
11
11
|
*/
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.CuratorTimeoutError = exports.CuratorAgentError = exports.CuratorAuthorizationRequiredError = exports.CuratorApprovalRequiredError = exports.CuratorRateLimitError = exports.CuratorDeploymentRetiredError = exports.CuratorNotFoundError = exports.CuratorForbiddenError = exports.CuratorAuthError = exports.CuratorError = void 0;
|
|
13
|
+
exports.CuratorTimeoutError = exports.CuratorAgentError = exports.CuratorAuthorizationRequiredError = exports.CuratorApprovalRequiredError = exports.CuratorServerError = exports.CuratorRateLimitError = exports.CuratorDeploymentRetiredError = exports.CuratorNotFoundError = exports.CuratorForbiddenError = exports.CuratorEndUserAuthError = exports.CuratorAuthError = exports.DEFAULT_USER_MESSAGE = exports.CuratorError = void 0;
|
|
14
|
+
exports.withRequestId = withRequestId;
|
|
15
|
+
exports.parseDelegationFailureCode = parseDelegationFailureCode;
|
|
14
16
|
class CuratorError extends Error {
|
|
17
|
+
/**
|
|
18
|
+
* What an END USER may be shown.
|
|
19
|
+
*
|
|
20
|
+
* `message` is for developers — it can name the request, the status, and the
|
|
21
|
+
* server's own wording. That is the wrong text to put in a chat bubble, and
|
|
22
|
+
* shipping it there is not a hypothetical: a 500 rendered as
|
|
23
|
+
* `HTTP 500 from https://api.../agents/<slug>/conversations: …`, exposing the
|
|
24
|
+
* deployment's URL to whoever was chatting, and an end-user token failure
|
|
25
|
+
* rendered as "End-user JWT could not be verified", which tells the person
|
|
26
|
+
* nothing they can act on and leaks the auth mechanism.
|
|
27
|
+
*
|
|
28
|
+
* Every subclass sets this to something safe and actionable. `renderError` in
|
|
29
|
+
* the React bindings prefers it and never falls back to `message`, so a new
|
|
30
|
+
* error type is safe-by-default rather than leaky-by-default.
|
|
31
|
+
*/
|
|
32
|
+
userMessage;
|
|
33
|
+
/** HTTP status, when this came from a response. */
|
|
34
|
+
status;
|
|
35
|
+
/** Server error code (`error.code`), when present. */
|
|
36
|
+
code;
|
|
37
|
+
/**
|
|
38
|
+
* Correlation id from `x-request-id` / `correlationId`. The one detail worth
|
|
39
|
+
* showing a user on an unexpected failure — it is what support can trace,
|
|
40
|
+
* and it says nothing about the system's shape.
|
|
41
|
+
*/
|
|
42
|
+
requestId;
|
|
43
|
+
/**
|
|
44
|
+
* Request URL, as a PROPERTY rather than part of `message`. Available for
|
|
45
|
+
* logs and bug reports without riding along into anything user-visible.
|
|
46
|
+
*/
|
|
47
|
+
url;
|
|
15
48
|
constructor(message, options) {
|
|
16
49
|
super(message);
|
|
17
50
|
this.name = "CuratorError";
|
|
51
|
+
this.userMessage = options?.userMessage ?? exports.DEFAULT_USER_MESSAGE;
|
|
52
|
+
this.status = options?.status ?? null;
|
|
53
|
+
this.code = options?.code ?? null;
|
|
54
|
+
this.requestId = options?.requestId ?? null;
|
|
55
|
+
this.url = options?.url ?? null;
|
|
18
56
|
// Preserve the underlying error if the runtime supports it.
|
|
19
57
|
if (options?.cause !== undefined) {
|
|
20
58
|
;
|
|
@@ -23,26 +61,57 @@ class CuratorError extends Error {
|
|
|
23
61
|
}
|
|
24
62
|
}
|
|
25
63
|
exports.CuratorError = CuratorError;
|
|
64
|
+
/** Last-resort user-facing text. Deliberately says nothing about the system. */
|
|
65
|
+
exports.DEFAULT_USER_MESSAGE = "Something went wrong. Please try again.";
|
|
66
|
+
/** Appends a correlation id when there is one, so support has a handle. */
|
|
67
|
+
function withRequestId(text, requestId) {
|
|
68
|
+
return requestId ? `${text} (reference: ${requestId})` : text;
|
|
69
|
+
}
|
|
26
70
|
/** HTTP 401 from the API — your API key is missing, invalid, or revoked. */
|
|
27
71
|
class CuratorAuthError extends CuratorError {
|
|
28
|
-
constructor(message = "Invalid or revoked API key") {
|
|
29
|
-
|
|
72
|
+
constructor(message = "Invalid or revoked API key", ctx = {}) {
|
|
73
|
+
// The API key is the INTEGRATOR's credential. An end user can do nothing
|
|
74
|
+
// about it and should not be told which credential failed.
|
|
75
|
+
super(message, { ...ctx, userMessage: "This chat isn't available right now. Please try again later." });
|
|
30
76
|
this.name = "CuratorAuthError";
|
|
31
77
|
}
|
|
32
78
|
}
|
|
33
79
|
exports.CuratorAuthError = CuratorAuthError;
|
|
80
|
+
/**
|
|
81
|
+
* HTTP 401 specifically because the END-USER token was missing, expired, or
|
|
82
|
+
* unverifiable — distinct from `CuratorAuthError`, which is about the
|
|
83
|
+
* integrator's API key.
|
|
84
|
+
*
|
|
85
|
+
* Separate because the remediation is completely different: an API-key failure
|
|
86
|
+
* needs a developer, whereas this one is usually a stale session the user fixes
|
|
87
|
+
* by signing in again. Collapsing them produced "Authentication failed. Check
|
|
88
|
+
* your API key." in response to an expired user token, which sends the reader
|
|
89
|
+
* after the wrong thing entirely.
|
|
90
|
+
*/
|
|
91
|
+
class CuratorEndUserAuthError extends CuratorError {
|
|
92
|
+
constructor(message = "End-user token could not be verified", ctx = {}) {
|
|
93
|
+
super(message, {
|
|
94
|
+
...ctx,
|
|
95
|
+
userMessage: "Your session has expired. Please sign in again to continue.",
|
|
96
|
+
});
|
|
97
|
+
this.name = "CuratorEndUserAuthError";
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
exports.CuratorEndUserAuthError = CuratorEndUserAuthError;
|
|
34
101
|
/** HTTP 403 from the API — your API key doesn't have permission for this action. */
|
|
35
102
|
class CuratorForbiddenError extends CuratorError {
|
|
36
|
-
constructor(message = "Permission denied") {
|
|
37
|
-
super(message);
|
|
103
|
+
constructor(message = "Permission denied", ctx = {}) {
|
|
104
|
+
super(message, { ...ctx, userMessage: "You don't have access to this." });
|
|
38
105
|
this.name = "CuratorForbiddenError";
|
|
39
106
|
}
|
|
40
107
|
}
|
|
41
108
|
exports.CuratorForbiddenError = CuratorForbiddenError;
|
|
42
109
|
/** HTTP 404 from the API — the deployment slug or conversation id wasn't found. */
|
|
43
110
|
class CuratorNotFoundError extends CuratorError {
|
|
44
|
-
constructor(message = "Resource not found") {
|
|
45
|
-
|
|
111
|
+
constructor(message = "Resource not found", ctx = {}) {
|
|
112
|
+
// Says nothing about WHICH resource: on a 404 the slug is often the thing
|
|
113
|
+
// that is wrong, and echoing it back tells a prober they guessed close.
|
|
114
|
+
super(message, { ...ctx, userMessage: "This chat isn't available." });
|
|
46
115
|
this.name = "CuratorNotFoundError";
|
|
47
116
|
}
|
|
48
117
|
}
|
|
@@ -50,8 +119,11 @@ exports.CuratorNotFoundError = CuratorNotFoundError;
|
|
|
50
119
|
/** HTTP 410 from the API — the deployment was retired. */
|
|
51
120
|
class CuratorDeploymentRetiredError extends CuratorError {
|
|
52
121
|
retiredAt;
|
|
53
|
-
constructor(message, retiredAt) {
|
|
54
|
-
super(message
|
|
122
|
+
constructor(message, retiredAt, ctx = {}) {
|
|
123
|
+
super(message, {
|
|
124
|
+
...ctx,
|
|
125
|
+
userMessage: "This assistant is no longer available.",
|
|
126
|
+
});
|
|
55
127
|
this.name = "CuratorDeploymentRetiredError";
|
|
56
128
|
this.retiredAt = retiredAt;
|
|
57
129
|
}
|
|
@@ -60,13 +132,33 @@ exports.CuratorDeploymentRetiredError = CuratorDeploymentRetiredError;
|
|
|
60
132
|
/** HTTP 429 from the API — back off. */
|
|
61
133
|
class CuratorRateLimitError extends CuratorError {
|
|
62
134
|
retryAfterSeconds;
|
|
63
|
-
constructor(message = "Rate limit exceeded", retryAfterSeconds = null) {
|
|
64
|
-
super(message
|
|
135
|
+
constructor(message = "Rate limit exceeded", retryAfterSeconds = null, ctx = {}) {
|
|
136
|
+
super(message, {
|
|
137
|
+
...ctx,
|
|
138
|
+
userMessage: retryAfterSeconds
|
|
139
|
+
? `Too many messages. Please wait ${retryAfterSeconds} seconds and try again.`
|
|
140
|
+
: "Too many messages. Please wait a moment and try again.",
|
|
141
|
+
});
|
|
65
142
|
this.name = "CuratorRateLimitError";
|
|
66
143
|
this.retryAfterSeconds = retryAfterSeconds;
|
|
67
144
|
}
|
|
68
145
|
}
|
|
69
146
|
exports.CuratorRateLimitError = CuratorRateLimitError;
|
|
147
|
+
/**
|
|
148
|
+
* HTTP 5xx. The server already returns a generic body plus a `correlationId`
|
|
149
|
+
* for unexpected failures, so the useful thing to surface is that id — not the
|
|
150
|
+
* status line and URL the SDK used to build into `message`.
|
|
151
|
+
*/
|
|
152
|
+
class CuratorServerError extends CuratorError {
|
|
153
|
+
constructor(message, ctx = {}) {
|
|
154
|
+
super(message, {
|
|
155
|
+
...ctx,
|
|
156
|
+
userMessage: withRequestId("Something went wrong on our end. Please try again.", ctx.requestId ?? null),
|
|
157
|
+
});
|
|
158
|
+
this.name = "CuratorServerError";
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
exports.CuratorServerError = CuratorServerError;
|
|
70
162
|
/**
|
|
71
163
|
* Run paused waiting for human approval. Approval resolution is not
|
|
72
164
|
* exposed to API consumers — pauses are routed through the dashboard
|
|
@@ -80,7 +172,10 @@ class CuratorApprovalRequiredError extends CuratorError {
|
|
|
80
172
|
runId;
|
|
81
173
|
constructor(args) {
|
|
82
174
|
super(`Run paused for approval — the '${args.approval.tool_name}' tool needs an administrator to review it. ` +
|
|
83
|
-
"Contact your administrator to resolve this in the Curator dashboard."
|
|
175
|
+
"Contact your administrator to resolve this in the Curator dashboard.", {
|
|
176
|
+
userMessage: `That action needs administrator approval. Someone has been asked to review the ` +
|
|
177
|
+
`"${args.approval.tool_name}" request.`,
|
|
178
|
+
});
|
|
84
179
|
this.name = "CuratorApprovalRequiredError";
|
|
85
180
|
this.approval = args.approval;
|
|
86
181
|
this.conversationId = args.conversationId;
|
|
@@ -102,7 +197,11 @@ class CuratorAuthorizationRequiredError extends CuratorError {
|
|
|
102
197
|
super(`Run paused for authorization — connect ${args.authorization.provider} to continue. ` +
|
|
103
198
|
(args.authorization.connect_url
|
|
104
199
|
? `Connect at ${args.authorization.connect_url}, then resume the conversation.`
|
|
105
|
-
: "Connect the provider, then resume the conversation.")
|
|
200
|
+
: "Connect the provider, then resume the conversation."), {
|
|
201
|
+
// `reason` is authored for the end user by the integration; prefer it.
|
|
202
|
+
userMessage: args.authorization.reason ||
|
|
203
|
+
`Connect your ${args.authorization.provider} account to continue.`,
|
|
204
|
+
});
|
|
106
205
|
this.name = "CuratorAuthorizationRequiredError";
|
|
107
206
|
this.authorization = args.authorization;
|
|
108
207
|
this.conversationId = args.conversationId;
|
|
@@ -110,6 +209,51 @@ class CuratorAuthorizationRequiredError extends CuratorError {
|
|
|
110
209
|
}
|
|
111
210
|
}
|
|
112
211
|
exports.CuratorAuthorizationRequiredError = CuratorAuthorizationRequiredError;
|
|
212
|
+
const DELEGATION_CODES = [
|
|
213
|
+
"DELEGATED_IDENTITY_EXPIRED",
|
|
214
|
+
"DELEGATED_IDENTITY_REVOKED",
|
|
215
|
+
"DELEGATED_TOKEN_EXCHANGE_FAILED",
|
|
216
|
+
"DOWNSTREAM_AUTH_REJECTED",
|
|
217
|
+
"DELEGATED_AUTH_NOT_CONFIGURED",
|
|
218
|
+
];
|
|
219
|
+
/** Recover the delegated-failure code from a server message prefix. */
|
|
220
|
+
function parseDelegationFailureCode(message) {
|
|
221
|
+
if (!message)
|
|
222
|
+
return null;
|
|
223
|
+
for (const code of DELEGATION_CODES) {
|
|
224
|
+
if (message.startsWith(`${code}:`))
|
|
225
|
+
return code;
|
|
226
|
+
}
|
|
227
|
+
return null;
|
|
228
|
+
}
|
|
229
|
+
/**
|
|
230
|
+
* End-user text per delegated-failure code. The split that matters is WHO can
|
|
231
|
+
* fix it: expiry is the user's to resolve by re-authenticating, revocation and
|
|
232
|
+
* scope gaps need an administrator, and the exchange/config failures are ours
|
|
233
|
+
* and must not be phrased as the user's fault.
|
|
234
|
+
*/
|
|
235
|
+
function delegationUserMessage(code) {
|
|
236
|
+
switch (code) {
|
|
237
|
+
case "DELEGATED_IDENTITY_EXPIRED":
|
|
238
|
+
// The common one: a run paused past the assertion's lifetime. Retrying
|
|
239
|
+
// the same request is futile, so the text must ask for a NEW session
|
|
240
|
+
// rather than inviting another attempt.
|
|
241
|
+
return "Your session expired before that could finish. Please sign in again and retry.";
|
|
242
|
+
case "DELEGATED_IDENTITY_REVOKED":
|
|
243
|
+
// Server-side this pages someone — it means a context was crossed or
|
|
244
|
+
// probed. Never hint at the mechanism; the user just lacks authority.
|
|
245
|
+
return "You don't have permission to complete that action. Please contact your administrator.";
|
|
246
|
+
case "DOWNSTREAM_AUTH_REJECTED":
|
|
247
|
+
// Exchange worked; the resource server said no. A scope/permission gap on
|
|
248
|
+
// the customer's side, so an administrator is the right destination.
|
|
249
|
+
return "Your account doesn't have access to what that action needed. Please contact your administrator.";
|
|
250
|
+
case "DELEGATED_TOKEN_EXCHANGE_FAILED":
|
|
251
|
+
case "DELEGATED_AUTH_NOT_CONFIGURED":
|
|
252
|
+
// Ours to fix. Do not tell the user to sign in — it will not help, and it
|
|
253
|
+
// sends them chasing a problem they cannot see.
|
|
254
|
+
return "That action isn't available right now. Please try again later.";
|
|
255
|
+
}
|
|
256
|
+
}
|
|
113
257
|
/**
|
|
114
258
|
* The agent run reached a terminal error state (LLM quota, auth, 5xx
|
|
115
259
|
* exhausted retries, etc.). `failureClass` and `isPermanent` mirror the
|
|
@@ -121,9 +265,29 @@ class CuratorAgentError extends CuratorError {
|
|
|
121
265
|
conversationId;
|
|
122
266
|
runId;
|
|
123
267
|
stepId;
|
|
268
|
+
/**
|
|
269
|
+
* Set when the run failed on delegated identity. Distinct from
|
|
270
|
+
* `failureClass`, which has no delegated variant — see
|
|
271
|
+
* {@link DelegationFailureCode}.
|
|
272
|
+
*/
|
|
273
|
+
delegationCode;
|
|
124
274
|
constructor(args) {
|
|
125
|
-
|
|
275
|
+
const delegationCode = parseDelegationFailureCode(args.message);
|
|
276
|
+
super(args.message, {
|
|
277
|
+
// NOT `args.message`: the run's failure text is written for an operator
|
|
278
|
+
// and can name providers, quotas, or step ids. A delegated failure gets
|
|
279
|
+
// its own text because the server already told us who can fix it —
|
|
280
|
+
// throwing that away and falling back to `isPermanent` is how an expired
|
|
281
|
+
// session became "couldn't complete that request", which is true and
|
|
282
|
+
// useless when "sign in again" was the answer.
|
|
283
|
+
userMessage: delegationCode
|
|
284
|
+
? delegationUserMessage(delegationCode)
|
|
285
|
+
: args.isPermanent
|
|
286
|
+
? "The assistant couldn't complete that request. Please try rephrasing, or contact support."
|
|
287
|
+
: "The assistant hit a temporary problem. Please try again.",
|
|
288
|
+
});
|
|
126
289
|
this.name = "CuratorAgentError";
|
|
290
|
+
this.delegationCode = delegationCode;
|
|
127
291
|
this.failureClass = args.failureClass;
|
|
128
292
|
this.isPermanent = args.isPermanent;
|
|
129
293
|
this.conversationId = args.conversationId;
|
|
@@ -142,7 +306,9 @@ class CuratorTimeoutError extends CuratorError {
|
|
|
142
306
|
runId;
|
|
143
307
|
continueWaiting;
|
|
144
308
|
constructor(args) {
|
|
145
|
-
super("Timed out waiting for the agent to reply — the run is still in progress."
|
|
309
|
+
super("Timed out waiting for the agent to reply — the run is still in progress.", {
|
|
310
|
+
userMessage: "This is taking longer than usual. It may still finish — check back in a moment.",
|
|
311
|
+
});
|
|
146
312
|
this.name = "CuratorTimeoutError";
|
|
147
313
|
this.conversationId = args.conversationId;
|
|
148
314
|
this.runId = args.runId;
|
package/dist/cjs/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/errors.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/errors.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;AAwEH,sCAEC;AA6MD,gEAQC;AAtRD,MAAa,YAAa,SAAQ,KAAK;IACrC;;;;;;;;;;;;;;OAcG;IACM,WAAW,CAAQ;IAC5B,mDAAmD;IAC1C,MAAM,CAAe;IAC9B,sDAAsD;IAC7C,IAAI,CAAe;IAC5B;;;;OAIG;IACM,SAAS,CAAe;IACjC;;;OAGG;IACM,GAAG,CAAe;IAE3B,YACE,OAAe,EACf,OAOC;QAED,KAAK,CAAC,OAAO,CAAC,CAAA;QACd,IAAI,CAAC,IAAI,GAAG,cAAc,CAAA;QAC1B,IAAI,CAAC,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,4BAAoB,CAAA;QAC/D,IAAI,CAAC,MAAM,GAAG,OAAO,EAAE,MAAM,IAAI,IAAI,CAAA;QACrC,IAAI,CAAC,IAAI,GAAG,OAAO,EAAE,IAAI,IAAI,IAAI,CAAA;QACjC,IAAI,CAAC,SAAS,GAAG,OAAO,EAAE,SAAS,IAAI,IAAI,CAAA;QAC3C,IAAI,CAAC,GAAG,GAAG,OAAO,EAAE,GAAG,IAAI,IAAI,CAAA;QAC/B,4DAA4D;QAC5D,IAAI,OAAO,EAAE,KAAK,KAAK,SAAS,EAAE,CAAC;YACjC,CAAC;YAAC,IAA4B,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,CAAA;QACtD,CAAC;IACH,CAAC;CACF;AAxDD,oCAwDC;AAED,gFAAgF;AACnE,QAAA,oBAAoB,GAC/B,yCAAyC,CAAA;AAE3C,2EAA2E;AAC3E,SAAgB,aAAa,CAAC,IAAY,EAAE,SAAwB;IAClE,OAAO,SAAS,CAAC,CAAC,CAAC,GAA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AAC,CAAA;QACF,IAAI,CAAC,IAAI,GAAG,mBAAmB,CAAA;QAC/B,IAAI,CAAC,cAAc,GAAG,cAAc,CAAA;QACpC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,YAAY,CAAA;QACrC,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAA;QACnC,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,cAAc,CAAA;QACzC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,IAAI,IAAI,CAAA;IACnC,CAAC;CACF;AA3CD,8CA2CC;AAED;;;;GAIG;AACH,MAAa,mBAAoB,SAAQ,YAAY;IAC1C,cAAc,CAAQ;IACtB,KAAK,CAAQ;IACb,eAAe,CAAmD;IAE3E,YAAY,IAIX;QACC,KAAK,CAAC,0EAA0E,EAAE;YAChF,WAAW,EACT,iFAAiF;SACpF,CAAC,CAAA;QACF,IAAI,CAAC,IAAI,GAAG,qBAAqB,CAAA;QACjC,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,cAAc,CAAA;QACzC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAA;QACvB,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC,eAAe,CAAA;IAC7C,CAAC;CACF;AAnBD,kDAmBC"}
|
package/dist/cjs/http.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/http.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;
|
|
1
|
+
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/http.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAYH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAE7C;;;;;GAKG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,SAAS,GAAG,QAA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