@akai-workflow-builder/cli-sdk 0.1.4 → 0.1.5
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/CHANGELOG.md +37 -0
- package/README.md +29 -2
- package/dist/ctx/build-ctx.d.ts +2 -0
- package/dist/ctx/build-ctx.d.ts.map +1 -1
- package/dist/ctx/build-ctx.js +3 -0
- package/dist/define-connection.d.ts.map +1 -1
- package/dist/define-connection.js +9 -1
- package/dist/errors.d.ts +58 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +52 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/types.d.ts +4 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +2 -1
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to `@akai-workflow-builder/cli-sdk` are documented here.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
|
|
6
|
+
|
|
7
|
+
## [0.1.4]
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- `defineConnection()` — declare a connection umbrella that groups CLIs sharing
|
|
12
|
+
one auth surface (e.g. `google` groups gmail + gsheet). Returns a frozen,
|
|
13
|
+
WeakSet-branded `ConnectionDef`; hand-crafted objects carrying the brand are
|
|
14
|
+
rejected by `isAkaiConnection`.
|
|
15
|
+
- `isAkaiConnection(x)` — type-guard that recognises only defs produced by
|
|
16
|
+
`defineConnection()` (registry-backed, not brand-sniffing).
|
|
17
|
+
- New exported types: `ConnectionSpec`, `ConnectionDef`, `ConnectionOAuthConfig`,
|
|
18
|
+
`OAuthAdminField`, `ConnectionAuthKind`, `TokenEndpointAuthMethod`,
|
|
19
|
+
`RefreshStrategy`.
|
|
20
|
+
- `AkaiConnectionError` — `AkaiSpecError` subclass thrown by `defineConnection()`
|
|
21
|
+
on invalid input; carries `path` + `issues` in `meta` for structured diagnostics.
|
|
22
|
+
- `authorizeUrl`/`tokenUrl` are validated https-only; `http:` and non-http schemes
|
|
23
|
+
(including `javascript:`) are rejected at definition time.
|
|
24
|
+
|
|
25
|
+
## [0.1.3]
|
|
26
|
+
|
|
27
|
+
### Added
|
|
28
|
+
|
|
29
|
+
- `AkaiToolError` — a typed, caller-facing tool failure carrying a stable `kind`
|
|
30
|
+
(`not_found` | `forbidden` | `auth_expired` | `invalid_input` | `conflict` |
|
|
31
|
+
`rate_limited` | `unavailable`), `message`, and optional `meta`. Pins
|
|
32
|
+
`name` to `'AkaiToolError'` so the host runtime can brand-check the
|
|
33
|
+
serialized shape (`{ name, kind, message, meta? }`) with no SDK dependency,
|
|
34
|
+
map `kind` to an HTTP status, and surface the message verbatim.
|
|
35
|
+
- Ergonomic static factories on `AkaiToolError`: `notFound`, `forbidden`,
|
|
36
|
+
`authExpired`, `invalidInput`, `conflict`, `rateLimited`, `unavailable`.
|
|
37
|
+
- Exported the `ToolErrorKind` type from the package entrypoint.
|
package/README.md
CHANGED
|
@@ -119,7 +119,7 @@ A complete runnable example is in [`examples/google`](./examples/google) — `de
|
|
|
119
119
|
|
|
120
120
|
### OAuth connections
|
|
121
121
|
|
|
122
|
-
When `authKind` is `oauth2
|
|
122
|
+
When `authKind` is `oauth2`, declare an `oauth` block. **The manifest declares shape; akai-app owns values:**
|
|
123
123
|
|
|
124
124
|
```ts
|
|
125
125
|
oauth: {
|
|
@@ -414,9 +414,36 @@ Each tool branches on `isJson` and uses the structured logger. The folder includ
|
|
|
414
414
|
| `AkaiSecretError` | A `required: true` secret is missing at invocation time — thrown by `buildCtx` |
|
|
415
415
|
| `AkaiPropertyError`| A `required: true` property is missing at invocation time — thrown by `buildCtx` |
|
|
416
416
|
| `AkaiEgressError` | `ctx.fetch` rejected the target |
|
|
417
|
+
| `AkaiToolError` | A handler threw a typed, caller-facing failure — the host maps `kind` to an HTTP status and surfaces the message verbatim |
|
|
417
418
|
|
|
418
419
|
Every error extends `AkaiError`; the runtime maps each to a structured error envelope.
|
|
419
420
|
|
|
421
|
+
### Typed tool errors
|
|
422
|
+
|
|
423
|
+
Throw `AkaiToolError` from a handler to give an expected failure a stable classification and author-vetted wording. The host runtime brand-checks the thrown value by property access on its shape — `{ name: 'AkaiToolError', kind, message, meta? }` (it reads `message` via property access, not JSON serialization, since `Error.message` is non-enumerable) — with no SDK dependency, maps `kind` to an HTTP status, and returns `message` to the caller **verbatim**. Keep messages secret-free.
|
|
424
|
+
|
|
425
|
+
```ts
|
|
426
|
+
import { AkaiToolError } from '@akai-workflow-builder/cli-sdk';
|
|
427
|
+
|
|
428
|
+
const res = await ctx.fetch(`https://api.example.com/tickets/${id}`);
|
|
429
|
+
if (res.status === 404) throw AkaiToolError.notFound(`No ticket ${id}`, { id });
|
|
430
|
+
if (res.status === 429) throw AkaiToolError.rateLimited('Slow down', { retryAfterMs: 1000 });
|
|
431
|
+
```
|
|
432
|
+
|
|
433
|
+
Factories — each sets the matching `kind`:
|
|
434
|
+
|
|
435
|
+
| Factory | `kind` | Host status |
|
|
436
|
+
|---|---|---|
|
|
437
|
+
| `AkaiToolError.notFound(msg, meta?)` | `not_found` | 404 |
|
|
438
|
+
| `AkaiToolError.forbidden(msg, meta?)` | `forbidden` | 403 |
|
|
439
|
+
| `AkaiToolError.authExpired(msg, meta?)` | `auth_expired` | 401 |
|
|
440
|
+
| `AkaiToolError.invalidInput(msg, meta?)` | `invalid_input` | 422 |
|
|
441
|
+
| `AkaiToolError.conflict(msg, meta?)` | `conflict` | 409 |
|
|
442
|
+
| `AkaiToolError.rateLimited(msg, meta?)` | `rate_limited` | 429 (retryable) |
|
|
443
|
+
| `AkaiToolError.unavailable(msg, meta?)` | `unavailable` | 503 (retryable) |
|
|
444
|
+
|
|
445
|
+
Untyped throws are classified generically (a 500 with a derived message).
|
|
446
|
+
|
|
420
447
|
---
|
|
421
448
|
|
|
422
449
|
## Troubleshooting
|
|
@@ -442,7 +469,7 @@ Every error extends `AkaiError`; the runtime maps each to a structured error env
|
|
|
442
469
|
### Unreleased
|
|
443
470
|
|
|
444
471
|
- Add `defineConnection` — declare a connection's umbrella identity (`slug`, `name`, `vendor`, `blurb`, `longDesc`, `instructions`, `authKind`) plus its `oauth` shape. Returns a frozen, `WeakSet`-branded `ConnectionDef`. Symmetric to `defineCLI`.
|
|
445
|
-
- Add the `oauth` block: `authorizeUrl`, `tokenUrl`, `scopes`, `pkce`, `tokenEndpointAuthMethod`, `extraAuthorizeParams`, `refreshStrategy`, and `adminFields` (the OAuth-app credentials an admin enters; values stay in akai-app). Validated for valid URLs, non-empty `scopes`, env-style admin keys, and `adminFields` presence when `authKind` is `oauth2
|
|
472
|
+
- Add the `oauth` block: `authorizeUrl`, `tokenUrl`, `scopes`, `pkce`, `tokenEndpointAuthMethod`, `extraAuthorizeParams`, `refreshStrategy`, and `adminFields` (the OAuth-app credentials an admin enters; values stay in akai-app). Validated for valid URLs, non-empty `scopes`, env-style admin keys, and `adminFields` presence when `authKind` is `oauth2`.
|
|
446
473
|
- New exports: `defineConnection`, `isAkaiConnection`, `AkaiConnectionError`, and types `ConnectionSpec`, `ConnectionDef`, `ConnectionOAuthConfig`, `OAuthAdminField`, `ConnectionAuthKind`, `RefreshStrategy`, `TokenEndpointAuthMethod`.
|
|
447
474
|
- New runnable example: `examples/google` (a connection grouping `gmail` + `gsheet`).
|
|
448
475
|
|
package/dist/ctx/build-ctx.d.ts
CHANGED
|
@@ -30,6 +30,8 @@ export interface BuildCtxParams {
|
|
|
30
30
|
* throws (no output channel provisioned).
|
|
31
31
|
*/
|
|
32
32
|
readonly outputDir?: string;
|
|
33
|
+
/** Surfaced as `ctx.oauth.accessToken`. */
|
|
34
|
+
readonly oauthAccessToken?: string;
|
|
33
35
|
}
|
|
34
36
|
/**
|
|
35
37
|
* Assemble a frozen {@link ToolCtx} for one tool invocation: resolves
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build-ctx.d.ts","sourceRoot":"","sources":["../../src/ctx/build-ctx.ts"],"names":[],"mappings":"AAGA,OAAO,EAGL,KAAK,cAAc,EACnB,KAAK,YAAY,EAClB,MAAM,cAAc,CAAC;AAGtB,OAAO,KAAK,EAAc,MAAM,EAAiB,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAG1F;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,6GAA6G;IAC7G,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC;IACpC,sGAAsG;IACtG,QAAQ,CAAC,cAAc,CAAC,EAAE,cAAc,CAAC;IACzC,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAC;IAC5B,QAAQ,CAAC,MAAM,EAAE,WAAW,CAAC;IAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B;;;;OAIG;IACH,QAAQ,CAAC,kBAAkB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAChD;;;;;;OAMG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"build-ctx.d.ts","sourceRoot":"","sources":["../../src/ctx/build-ctx.ts"],"names":[],"mappings":"AAGA,OAAO,EAGL,KAAK,cAAc,EACnB,KAAK,YAAY,EAClB,MAAM,cAAc,CAAC;AAGtB,OAAO,KAAK,EAAc,MAAM,EAAiB,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAG1F;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,6GAA6G;IAC7G,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC;IACpC,sGAAsG;IACtG,QAAQ,CAAC,cAAc,CAAC,EAAE,cAAc,CAAC;IACzC,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAC;IAC5B,QAAQ,CAAC,MAAM,EAAE,WAAW,CAAC;IAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B;;;;OAIG;IACH,QAAQ,CAAC,kBAAkB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAChD;;;;;;OAMG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,2CAA2C;IAC3C,QAAQ,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC;CACpC;AA4CD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,QAAQ,CAAC,MAAM,EAAE,cAAc,GAAG,OAAO,CAuDxD"}
|
package/dist/ctx/build-ctx.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"define-connection.d.ts","sourceRoot":"","sources":["../src/define-connection.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,aAAa,EAEb,cAAc,EAEf,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"define-connection.d.ts","sourceRoot":"","sources":["../src/define-connection.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,aAAa,EAEb,cAAc,EAEf,MAAM,YAAY,CAAC;AAsJpB,wBAAgB,gBAAgB,CAAC,CAAC,EAAE,OAAO,GAAG,CAAC,IAAI,aAAa,CAE/D;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,cAAc,GAAG,aAAa,CA4CpE"}
|
|
@@ -14,7 +14,15 @@ const UrlString = z
|
|
|
14
14
|
catch {
|
|
15
15
|
return false;
|
|
16
16
|
}
|
|
17
|
-
}, { error: (issue) => `must be a valid URL (got ${JSON.stringify(issue.input)})` })
|
|
17
|
+
}, { error: (issue) => `must be a valid URL (got ${JSON.stringify(issue.input)})` })
|
|
18
|
+
.refine((val) => {
|
|
19
|
+
try {
|
|
20
|
+
return new URL(val).protocol === 'https:';
|
|
21
|
+
}
|
|
22
|
+
catch {
|
|
23
|
+
return false;
|
|
24
|
+
}
|
|
25
|
+
}, { error: 'authorizeUrl/tokenUrl must be an https URL' });
|
|
18
26
|
const OAuthAdminFieldShape = z.object({
|
|
19
27
|
key: z
|
|
20
28
|
.string({ error: 'key is required' })
|
package/dist/errors.d.ts
CHANGED
|
@@ -28,4 +28,62 @@ export declare class AkaiPropertyError extends AkaiError {
|
|
|
28
28
|
/** `ctx.safePath` rejected a path that resolves outside the allowed roots. */
|
|
29
29
|
export declare class AkaiPathError extends AkaiError {
|
|
30
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Stable, vendor-neutral classification for a caller-facing tool failure.
|
|
33
|
+
*
|
|
34
|
+
* The host runtime maps each `kind` to an HTTP status and surfaces the
|
|
35
|
+
* accompanying `message` to the caller verbatim, so an agent can reason about
|
|
36
|
+
* the failure programmatically (fix the id, ask to be granted access,
|
|
37
|
+
* reconnect, retry) instead of seeing an opaque 500.
|
|
38
|
+
*
|
|
39
|
+
* - `not_found` — host maps to **404**: the entity does not exist or is not
|
|
40
|
+
* visible to this caller. Check the id/URL and that you have access.
|
|
41
|
+
* - `forbidden` — host maps to **403**: the entity exists but the caller lacks
|
|
42
|
+
* permission (not shared, insufficient scope).
|
|
43
|
+
* - `auth_expired` — host maps to **401**: the credential is invalid or expired;
|
|
44
|
+
* reconnect the integration.
|
|
45
|
+
* - `invalid_input` — host maps to **422**: arguments are well-formed but violate
|
|
46
|
+
* a runtime constraint the schema cannot express.
|
|
47
|
+
* - `conflict` — host maps to **409**: the request conflicts with current state
|
|
48
|
+
* (already exists, version mismatch).
|
|
49
|
+
* - `rate_limited` — host maps to **429**: an upstream throttle was hit; retryable.
|
|
50
|
+
* Put a hint in `meta` (e.g. `{ retryAfterMs }`).
|
|
51
|
+
* - `unavailable` — host maps to **503**: upstream is down, timed out, or
|
|
52
|
+
* unreachable; retryable.
|
|
53
|
+
*/
|
|
54
|
+
export type ToolErrorKind = 'not_found' | 'forbidden' | 'auth_expired' | 'invalid_input' | 'conflict' | 'rate_limited' | 'unavailable';
|
|
55
|
+
/**
|
|
56
|
+
* Caller-facing tool failure with a stable, vendor-neutral {@link ToolErrorKind}.
|
|
57
|
+
*
|
|
58
|
+
* Throw this from a tool handler when you want bespoke, author-vetted wording
|
|
59
|
+
* for an expected failure. The host runtime brand-checks the thrown value by
|
|
60
|
+
* property access on its shape — `{ name: 'AkaiToolError', kind, message, meta? }`
|
|
61
|
+
* (note `message` is read via property access, not JSON serialization, since
|
|
62
|
+
* `Error.message` is non-enumerable) — so the `name` is pinned to `'AkaiToolError'`
|
|
63
|
+
* in the constructor and survives across package-boundary `instanceof` gaps. On a
|
|
64
|
+
* match the host maps `kind` to an HTTP
|
|
65
|
+
* status and returns `message` to the caller **verbatim**, so the message must be
|
|
66
|
+
* secret-free and safe to expose. Untyped throws are classified generically.
|
|
67
|
+
*
|
|
68
|
+
* @example
|
|
69
|
+
* throw AkaiToolError.notFound(`No ticket ${id}`, { id });
|
|
70
|
+
*/
|
|
71
|
+
export declare class AkaiToolError extends AkaiError {
|
|
72
|
+
readonly kind: ToolErrorKind;
|
|
73
|
+
constructor(kind: ToolErrorKind, message: string, meta?: Record<string, unknown>);
|
|
74
|
+
/** `invalid_input` → host **422**: args violate a runtime constraint the schema can't express. */
|
|
75
|
+
static invalidInput(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
76
|
+
/** `not_found` → host **404**: the entity doesn't exist or isn't visible to this caller. */
|
|
77
|
+
static notFound(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
78
|
+
/** `forbidden` → host **403**: the entity exists but the caller lacks permission. */
|
|
79
|
+
static forbidden(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
80
|
+
/** `auth_expired` → host **401**: the credential is invalid or expired; reconnect. */
|
|
81
|
+
static authExpired(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
82
|
+
/** `conflict` → host **409**: the request conflicts with current state. */
|
|
83
|
+
static conflict(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
84
|
+
/** `rate_limited` → host **429**: upstream throttle hit; retryable (e.g. `meta.retryAfterMs`). */
|
|
85
|
+
static rateLimited(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
86
|
+
/** `unavailable` → host **503**: upstream down/timed-out/unreachable; retryable. */
|
|
87
|
+
static unavailable(message: string, meta?: Record<string, unknown>): AkaiToolError;
|
|
88
|
+
}
|
|
31
89
|
//# sourceMappingURL=errors.d.ts.map
|
package/dist/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,qBAAa,SAAU,SAAQ,KAAK;IAClC,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;gBAC5B,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;CAK5D;AAED,2EAA2E;AAC3E,qBAAa,aAAc,SAAQ,SAAS;CAAG;AAE/C,2EAA2E;AAC3E,qBAAa,mBAAoB,SAAQ,aAAa;CAAG;AAEzD,+EAA+E;AAC/E,qBAAa,cAAe,SAAQ,SAAS;CAAG;AAEhD,8CAA8C;AAC9C,qBAAa,eAAgB,SAAQ,SAAS;CAAG;AAEjD,sDAAsD;AACtD,qBAAa,eAAgB,SAAQ,SAAS;CAAG;AAEjD,+DAA+D;AAC/D,qBAAa,iBAAkB,SAAQ,SAAS;CAAG;AAGnD,8EAA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,4FAA4F;IAC5F,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;IAI/E,qFAAqF;IACrF,MAAM,CAAC,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;IAIhF,sFAAsF;IACtF,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;IAIlF,2EAA2E;IAC3E,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;IAI/E,kGAAkG;IAClG,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;IAIlF,oFAAoF;IACpF,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,aAAa;CAGnF"}
|
package/dist/errors.js
CHANGED
|
@@ -32,3 +32,55 @@ export class AkaiPropertyError extends AkaiError {
|
|
|
32
32
|
/** `ctx.safePath` rejected a path that resolves outside the allowed roots. */
|
|
33
33
|
export class AkaiPathError extends AkaiError {
|
|
34
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* Caller-facing tool failure with a stable, vendor-neutral {@link ToolErrorKind}.
|
|
37
|
+
*
|
|
38
|
+
* Throw this from a tool handler when you want bespoke, author-vetted wording
|
|
39
|
+
* for an expected failure. The host runtime brand-checks the thrown value by
|
|
40
|
+
* property access on its shape — `{ name: 'AkaiToolError', kind, message, meta? }`
|
|
41
|
+
* (note `message` is read via property access, not JSON serialization, since
|
|
42
|
+
* `Error.message` is non-enumerable) — so the `name` is pinned to `'AkaiToolError'`
|
|
43
|
+
* in the constructor and survives across package-boundary `instanceof` gaps. On a
|
|
44
|
+
* match the host maps `kind` to an HTTP
|
|
45
|
+
* status and returns `message` to the caller **verbatim**, so the message must be
|
|
46
|
+
* secret-free and safe to expose. Untyped throws are classified generically.
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* throw AkaiToolError.notFound(`No ticket ${id}`, { id });
|
|
50
|
+
*/
|
|
51
|
+
export class AkaiToolError extends AkaiError {
|
|
52
|
+
kind;
|
|
53
|
+
constructor(kind, message, meta) {
|
|
54
|
+
super(message, meta);
|
|
55
|
+
this.name = 'AkaiToolError';
|
|
56
|
+
this.kind = kind;
|
|
57
|
+
}
|
|
58
|
+
/** `invalid_input` → host **422**: args violate a runtime constraint the schema can't express. */
|
|
59
|
+
static invalidInput(message, meta) {
|
|
60
|
+
return new AkaiToolError('invalid_input', message, meta);
|
|
61
|
+
}
|
|
62
|
+
/** `not_found` → host **404**: the entity doesn't exist or isn't visible to this caller. */
|
|
63
|
+
static notFound(message, meta) {
|
|
64
|
+
return new AkaiToolError('not_found', message, meta);
|
|
65
|
+
}
|
|
66
|
+
/** `forbidden` → host **403**: the entity exists but the caller lacks permission. */
|
|
67
|
+
static forbidden(message, meta) {
|
|
68
|
+
return new AkaiToolError('forbidden', message, meta);
|
|
69
|
+
}
|
|
70
|
+
/** `auth_expired` → host **401**: the credential is invalid or expired; reconnect. */
|
|
71
|
+
static authExpired(message, meta) {
|
|
72
|
+
return new AkaiToolError('auth_expired', message, meta);
|
|
73
|
+
}
|
|
74
|
+
/** `conflict` → host **409**: the request conflicts with current state. */
|
|
75
|
+
static conflict(message, meta) {
|
|
76
|
+
return new AkaiToolError('conflict', message, meta);
|
|
77
|
+
}
|
|
78
|
+
/** `rate_limited` → host **429**: upstream throttle hit; retryable (e.g. `meta.retryAfterMs`). */
|
|
79
|
+
static rateLimited(message, meta) {
|
|
80
|
+
return new AkaiToolError('rate_limited', message, meta);
|
|
81
|
+
}
|
|
82
|
+
/** `unavailable` → host **503**: upstream down/timed-out/unreachable; retryable. */
|
|
83
|
+
static unavailable(message, meta) {
|
|
84
|
+
return new AkaiToolError('unavailable', message, meta);
|
|
85
|
+
}
|
|
86
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -9,7 +9,8 @@ export type { BuildCtxParams } from './ctx/build-ctx.js';
|
|
|
9
9
|
export type { AnyToolDef, CLIDef, CLISpec, ConnectionAuthKind, ConnectionDef, ConnectionOAuthConfig, ConnectionSpec, DynamicEgress, InputOf, NetworkOptions, OAuthAdminField, OutputOf, PropertiesOf, PropertyDecl, RefreshStrategy, SecretDecl, SecretsOf, TokenEndpointAuthMethod, ToolCtx, ToolDef, ToolLogger, ToolOptions, ToolSpec, } from './types.js';
|
|
10
10
|
export { createSafePath } from './ctx/safe-path.js';
|
|
11
11
|
export type { SafePath } from './ctx/safe-path.js';
|
|
12
|
-
export { AkaiConnectionError, AkaiEgressError, AkaiError, AkaiInputError, AkaiPathError, AkaiPropertyError, AkaiSecretError, AkaiSpecError, } from './errors.js';
|
|
12
|
+
export { AkaiConnectionError, AkaiEgressError, AkaiError, AkaiInputError, AkaiPathError, AkaiPropertyError, AkaiSecretError, AkaiSpecError, AkaiToolError, } from './errors.js';
|
|
13
|
+
export type { ToolErrorKind } from './errors.js';
|
|
13
14
|
export { ConnectionManifestSchema, ManifestJSONSchema, SCHEMA_VERSION, toSchema, validateManifest, } from './manifest/index.js';
|
|
14
15
|
export type { ConnectionManifest, DynamicEgressManifest, HttpToolManifest, ManifestProperty, ManifestSecret, NativeToolManifest, SchemaVersion, ToolManifest, } from './manifest/index.js';
|
|
15
16
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"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EACxB,kBAAkB,EAClB,cAAc,EACd,QAAQ,EACR,gBAAgB,GACjB,MAAM,qBAAqB,CAAC;AAC7B,YAAY,EACV,kBAAkB,EAClB,qBAAqB,EACrB,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,YAAY,GACb,MAAM,qBAAqB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -5,5 +5,5 @@ export { defineConnection, isAkaiConnection } from './define-connection.js';
|
|
|
5
5
|
export { buildScopedSecrets, buildScopedProperties } from './ctx/secrets.js';
|
|
6
6
|
export { buildCtx } from './ctx/build-ctx.js';
|
|
7
7
|
export { createSafePath } from './ctx/safe-path.js';
|
|
8
|
-
export { AkaiConnectionError, AkaiEgressError, AkaiError, AkaiInputError, AkaiPathError, AkaiPropertyError, AkaiSecretError, AkaiSpecError, } from './errors.js';
|
|
8
|
+
export { AkaiConnectionError, AkaiEgressError, AkaiError, AkaiInputError, AkaiPathError, AkaiPropertyError, AkaiSecretError, AkaiSpecError, AkaiToolError, } from './errors.js';
|
|
9
9
|
export { ConnectionManifestSchema, ManifestJSONSchema, SCHEMA_VERSION, toSchema, validateManifest, } from './manifest/index.js';
|
package/dist/types.d.ts
CHANGED
|
@@ -122,6 +122,10 @@ export interface ToolCtx<S extends string = string, P extends string = string> {
|
|
|
122
122
|
* but the host runtime did not supply the output staging dir.
|
|
123
123
|
*/
|
|
124
124
|
writeFile: (name: string, data: Buffer | Uint8Array | string) => Promise<void>;
|
|
125
|
+
/** OAuth access token for this tool's connection, auto-wired by the host. */
|
|
126
|
+
oauth?: {
|
|
127
|
+
accessToken: string;
|
|
128
|
+
};
|
|
125
129
|
}
|
|
126
130
|
/** A built tool. Opaque to consumers, introspectable by the SDK. */
|
|
127
131
|
export interface ToolDef<TInput = unknown, TOutput = unknown, TSecrets extends string = string, TProperties extends string = string> {
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d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
1
|
{
|
|
2
2
|
"name": "@akai-workflow-builder/cli-sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"description": "Authoring SDK for atomic, agent-executable CLIs and tools.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"akai",
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
"files": [
|
|
29
29
|
"bin",
|
|
30
30
|
"dist",
|
|
31
|
+
"CHANGELOG.md",
|
|
31
32
|
"LICENSE",
|
|
32
33
|
"README.md"
|
|
33
34
|
],
|