@naturali/sdk 0.134.0 → 0.136.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.
package/dist/index.cjs CHANGED
@@ -1472,7 +1472,7 @@ var ApiKeys = class {
1472
1472
  * Create an API key
1473
1473
  *
1474
1474
  * Creates an API key. When `project_id` is set the key is scoped to that project (the default and recommended stance); omit it for an account-scoped key. `capabilities` narrows what the key may do; when omitted the key inherits the creator's capabilities. The raw `key` (nat_sk_…) is returned only in this response.
1475
- * A project-scoped key requires the `admin` role in that project: the key is a standing credential for everything the project can do, so handing one out is an administrative act rather than something a read-only `member` can do for themselves. An account-scoped key requires a credential that is not itself confined to one project.
1475
+ * A project-scoped key requires membership of that project. The key carries no role of its own — every request it makes resolves its holder's membership again — so it can never reach past what its minter already had. An account-scoped key requires a credential that is not itself confined to one project.
1476
1476
  * A connected app cannot create keys at all: a grant is revocable and a key is not, so a key minted under a grant would still work after the app was disconnected. Reading and revoking keys stay available.
1477
1477
  *
1478
1478
  */
@@ -3726,7 +3726,7 @@ var Projects = class {
3726
3726
  * Update a project
3727
3727
  *
3728
3728
  * Rename or archive a project, and/or change its content-retention settings (`trace_content_retention_days`, `trace_content_mode`), its execution ceilings (`max_concurrent_runs`, `max_chain_generations`, `max_orchestration_run_depth`) and its priced-model gate (`require_priced_model`). Archiving is reversible; resources are retained.
3729
- * Requires the `admin` role in the project (an `owner` has it too).
3729
+ * Requires the `admin` role in the project (an `owner` has it too). These are the terms every member works under, which is why setting them sits above the role that works under them.
3730
3730
  * The ceilings and the priced-model gate are uncapped by plan: each one only ever narrows what the project may spend, so setting one takes on a restriction rather than claiming an entitlement. On the three ceilings `null` clears the project's own bound and omission leaves it alone — they are different instructions.
3731
3731
  * The two retention controls answer different questions. The window bounds how long content *stays* — a daily sweep purges anything past it, leaving auditable skeletons behind. `trace_content_mode: none` means content is never *written*, which is the stronger guarantee: it cannot be missed by a sweep or survive in a backup.
3732
3732
  *
@@ -3746,7 +3746,7 @@ var Projects = class {
3746
3746
  /**
3747
3747
  * List project members
3748
3748
  *
3749
- * Lists who may act in the project, and with what role. Readable by every member, including a read-only `member`: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
3749
+ * Lists who may act in the project, and with what role. Readable by every member, whatever their role: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
3750
3750
  * Somebody invited who has never signed in is listed too, with status `pending` — the invitation is already a grant, so hiding it until they arrive would hide access that exists.
3751
3751
  *
3752
3752
  */
@@ -3783,7 +3783,7 @@ var Projects = class {
3783
3783
  *
3784
3784
  * Removes a member, or leaves the project yourself.
3785
3785
  *
3786
- * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a read-only `member` and not another `admin`.
3786
+ * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a `member` and not another `admin`.
3787
3787
  *
3788
3788
  * The owner's own row is refused: a project with no owner is unreachable, and the row names who pays.
3789
3789
  *
package/dist/index.d.cts CHANGED
@@ -438,7 +438,7 @@ type Address = {
438
438
  /**
439
439
  * This address's own decision, when it has one — beats every route.
440
440
  */
441
- action: 'agent' | 'message' | 'silence' | null;
441
+ action: 'agent' | 'oneshot' | 'message' | 'silence' | null;
442
442
  agent_id: string | null;
443
443
  text: string | null;
444
444
  /**
@@ -448,6 +448,14 @@ type Address = {
448
448
  after_seconds: number;
449
449
  };
450
450
  language: string | null;
451
+ /**
452
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
453
+ *
454
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
455
+ *
456
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
457
+ *
458
+ */
451
459
  config: {
452
460
  [key: string]: unknown;
453
461
  } | null;
@@ -459,13 +467,29 @@ type Address = {
459
467
  *
460
468
  */
461
469
  type AddressActionSet = {
462
- action: 'agent' | 'message' | 'silence' | null;
470
+ /**
471
+ * What an inbound message becomes.
472
+ *
473
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
474
+ *
475
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
476
+ *
477
+ */
478
+ action: 'agent' | 'oneshot' | 'message' | 'silence' | null;
463
479
  agent_id?: string;
464
480
  text?: string;
465
481
  repeat?: 'every' | 'once' | {
466
482
  after_seconds: number;
467
483
  };
468
484
  language?: string;
485
+ /**
486
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
487
+ *
488
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
489
+ *
490
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
491
+ *
492
+ */
469
493
  config?: {
470
494
  [key: string]: unknown;
471
495
  };
@@ -2088,7 +2112,15 @@ type ChannelRoute = {
2088
2112
  * Tiebreak only, after specificity and `surface`.
2089
2113
  */
2090
2114
  priority: number;
2091
- action: 'agent' | 'message' | 'silence';
2115
+ /**
2116
+ * What an inbound message becomes.
2117
+ *
2118
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2119
+ *
2120
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2121
+ *
2122
+ */
2123
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2092
2124
  agent_id: string | null;
2093
2125
  text: string | null;
2094
2126
  /**
@@ -2098,6 +2130,14 @@ type ChannelRoute = {
2098
2130
  after_seconds: number;
2099
2131
  };
2100
2132
  language: string | null;
2133
+ /**
2134
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2135
+ *
2136
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2137
+ *
2138
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2139
+ *
2140
+ */
2101
2141
  config: {
2102
2142
  [key: string]: unknown;
2103
2143
  } | null;
@@ -2111,13 +2151,29 @@ type ChannelRouteWrite = {
2111
2151
  [key: string]: unknown;
2112
2152
  };
2113
2153
  priority?: number;
2114
- action: 'agent' | 'message' | 'silence';
2154
+ /**
2155
+ * What an inbound message becomes.
2156
+ *
2157
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2158
+ *
2159
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2160
+ *
2161
+ */
2162
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2115
2163
  agent_id?: string;
2116
2164
  text?: string;
2117
2165
  repeat?: 'every' | 'once' | {
2118
2166
  after_seconds: number;
2119
2167
  };
2120
2168
  language?: string;
2169
+ /**
2170
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2171
+ *
2172
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2173
+ *
2174
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2175
+ *
2176
+ */
2121
2177
  config?: {
2122
2178
  [key: string]: unknown;
2123
2179
  };
@@ -2268,9 +2324,17 @@ type ChannelList = {
2268
2324
  *
2269
2325
  */
2270
2326
  type ChannelDefaultAction = {
2271
- action: 'agent' | 'message' | 'silence';
2272
2327
  /**
2273
- * The agent that answers, when `action` is `agent`.
2328
+ * What an inbound message becomes.
2329
+ *
2330
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2331
+ *
2332
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2333
+ *
2334
+ */
2335
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2336
+ /**
2337
+ * The agent that answers, when `action` is `agent` or `oneshot`.
2274
2338
  */
2275
2339
  agent_id: string | null;
2276
2340
  /**
@@ -2289,7 +2353,12 @@ type ChannelDefaultAction = {
2289
2353
  */
2290
2354
  language: string | null;
2291
2355
  /**
2292
- * Conversation config bag — media handling, persona overrides, the Discord allowlist.
2356
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2357
+ *
2358
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2359
+ *
2360
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2361
+ *
2293
2362
  */
2294
2363
  config: {
2295
2364
  [key: string]: unknown;
@@ -2300,7 +2369,15 @@ type ChannelDefaultAction = {
2300
2369
  *
2301
2370
  */
2302
2371
  type ChannelDefaultActionInput = {
2303
- action: 'agent' | 'message' | 'silence';
2372
+ /**
2373
+ * What an inbound message becomes.
2374
+ *
2375
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2376
+ *
2377
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2378
+ *
2379
+ */
2380
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2304
2381
  agent_id?: string;
2305
2382
  text?: string;
2306
2383
  repeat?: 'every' | 'once' | {
@@ -5871,7 +5948,7 @@ type Project = {
5871
5948
  updated_at: Date;
5872
5949
  };
5873
5950
  /**
5874
- * What the member may do in this project. `owner` — everything, including deleting it and paying for it; exactly one per project. `admin` — every read and write inside it, including minting project API keys, but not deleting the project. `member` — reads only.
5951
+ * What the member may do in this project. `owner` — everything, including deleting it and paying for it; exactly one per project. `admin` — everything a `member` may do, plus managing who else is in the project and how the project itself is configured. `member` — every read and write on the project's own resources, including minting project API keys.
5875
5952
  * When returned on a `Project`, this is *your* role, not a property of the project: it is what lets a client hide an action the request would refuse.
5876
5953
  *
5877
5954
  */
@@ -17828,7 +17905,7 @@ type AddProjectMemberErrors = {
17828
17905
  */
17829
17906
  401: ErrorResponse;
17830
17907
  /**
17831
- * The caller is a read-only `member`, an `admin` granting `admin`, or a project-scoped credential.
17908
+ * The caller is a `member`, an `admin` granting `admin`, or a project-scoped credential.
17832
17909
  *
17833
17910
  */
17834
17911
  403: ErrorResponse;
@@ -18256,7 +18333,7 @@ type CreateProjectUsageThresholdErrors = {
18256
18333
  */
18257
18334
  401: ErrorResponse;
18258
18335
  /**
18259
- * The caller is a read-only member.
18336
+ * The caller is a `member`; an alerting rule needs `admin`.
18260
18337
  */
18261
18338
  403: ErrorResponse;
18262
18339
  /**
@@ -18290,7 +18367,7 @@ type DeleteProjectUsageThresholdErrors = {
18290
18367
  */
18291
18368
  401: ErrorResponse;
18292
18369
  /**
18293
- * The caller is a read-only member.
18370
+ * The caller is a `member`; an alerting rule needs `admin`.
18294
18371
  */
18295
18372
  403: ErrorResponse;
18296
18373
  /**
@@ -21662,7 +21739,7 @@ export declare class ApiKeys {
21662
21739
  * Create an API key
21663
21740
  *
21664
21741
  * Creates an API key. When `project_id` is set the key is scoped to that project (the default and recommended stance); omit it for an account-scoped key. `capabilities` narrows what the key may do; when omitted the key inherits the creator's capabilities. The raw `key` (nat_sk_…) is returned only in this response.
21665
- * A project-scoped key requires the `admin` role in that project: the key is a standing credential for everything the project can do, so handing one out is an administrative act rather than something a read-only `member` can do for themselves. An account-scoped key requires a credential that is not itself confined to one project.
21742
+ * A project-scoped key requires membership of that project. The key carries no role of its own — every request it makes resolves its holder's membership again — so it can never reach past what its minter already had. An account-scoped key requires a credential that is not itself confined to one project.
21666
21743
  * A connected app cannot create keys at all: a grant is revocable and a key is not, so a key minted under a grant would still work after the app was disconnected. Reading and revoking keys stay available.
21667
21744
  *
21668
21745
  */
@@ -22825,7 +22902,7 @@ export declare class Projects {
22825
22902
  * Update a project
22826
22903
  *
22827
22904
  * Rename or archive a project, and/or change its content-retention settings (`trace_content_retention_days`, `trace_content_mode`), its execution ceilings (`max_concurrent_runs`, `max_chain_generations`, `max_orchestration_run_depth`) and its priced-model gate (`require_priced_model`). Archiving is reversible; resources are retained.
22828
- * Requires the `admin` role in the project (an `owner` has it too).
22905
+ * Requires the `admin` role in the project (an `owner` has it too). These are the terms every member works under, which is why setting them sits above the role that works under them.
22829
22906
  * The ceilings and the priced-model gate are uncapped by plan: each one only ever narrows what the project may spend, so setting one takes on a restriction rather than claiming an entitlement. On the three ceilings `null` clears the project's own bound and omission leaves it alone — they are different instructions.
22830
22907
  * The two retention controls answer different questions. The window bounds how long content *stays* — a daily sweep purges anything past it, leaving auditable skeletons behind. `trace_content_mode: none` means content is never *written*, which is the stronger guarantee: it cannot be missed by a sweep or survive in a backup.
22831
22908
  *
@@ -22836,7 +22913,7 @@ export declare class Projects {
22836
22913
  /**
22837
22914
  * List project members
22838
22915
  *
22839
- * Lists who may act in the project, and with what role. Readable by every member, including a read-only `member`: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
22916
+ * Lists who may act in the project, and with what role. Readable by every member, whatever their role: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
22840
22917
  * Somebody invited who has never signed in is listed too, with status `pending` — the invitation is already a grant, so hiding it until they arrive would hide access that exists.
22841
22918
  *
22842
22919
  */
@@ -22859,7 +22936,7 @@ export declare class Projects {
22859
22936
  *
22860
22937
  * Removes a member, or leaves the project yourself.
22861
22938
  *
22862
- * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a read-only `member` and not another `admin`.
22939
+ * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a `member` and not another `admin`.
22863
22940
  *
22864
22941
  * The owner's own row is refused: a project with no owner is unreachable, and the row names who pays.
22865
22942
  *
package/dist/index.d.mts CHANGED
@@ -438,7 +438,7 @@ type Address = {
438
438
  /**
439
439
  * This address's own decision, when it has one — beats every route.
440
440
  */
441
- action: 'agent' | 'message' | 'silence' | null;
441
+ action: 'agent' | 'oneshot' | 'message' | 'silence' | null;
442
442
  agent_id: string | null;
443
443
  text: string | null;
444
444
  /**
@@ -448,6 +448,14 @@ type Address = {
448
448
  after_seconds: number;
449
449
  };
450
450
  language: string | null;
451
+ /**
452
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
453
+ *
454
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
455
+ *
456
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
457
+ *
458
+ */
451
459
  config: {
452
460
  [key: string]: unknown;
453
461
  } | null;
@@ -459,13 +467,29 @@ type Address = {
459
467
  *
460
468
  */
461
469
  type AddressActionSet = {
462
- action: 'agent' | 'message' | 'silence' | null;
470
+ /**
471
+ * What an inbound message becomes.
472
+ *
473
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
474
+ *
475
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
476
+ *
477
+ */
478
+ action: 'agent' | 'oneshot' | 'message' | 'silence' | null;
463
479
  agent_id?: string;
464
480
  text?: string;
465
481
  repeat?: 'every' | 'once' | {
466
482
  after_seconds: number;
467
483
  };
468
484
  language?: string;
485
+ /**
486
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
487
+ *
488
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
489
+ *
490
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
491
+ *
492
+ */
469
493
  config?: {
470
494
  [key: string]: unknown;
471
495
  };
@@ -2088,7 +2112,15 @@ type ChannelRoute = {
2088
2112
  * Tiebreak only, after specificity and `surface`.
2089
2113
  */
2090
2114
  priority: number;
2091
- action: 'agent' | 'message' | 'silence';
2115
+ /**
2116
+ * What an inbound message becomes.
2117
+ *
2118
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2119
+ *
2120
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2121
+ *
2122
+ */
2123
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2092
2124
  agent_id: string | null;
2093
2125
  text: string | null;
2094
2126
  /**
@@ -2098,6 +2130,14 @@ type ChannelRoute = {
2098
2130
  after_seconds: number;
2099
2131
  };
2100
2132
  language: string | null;
2133
+ /**
2134
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2135
+ *
2136
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2137
+ *
2138
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2139
+ *
2140
+ */
2101
2141
  config: {
2102
2142
  [key: string]: unknown;
2103
2143
  } | null;
@@ -2111,13 +2151,29 @@ type ChannelRouteWrite = {
2111
2151
  [key: string]: unknown;
2112
2152
  };
2113
2153
  priority?: number;
2114
- action: 'agent' | 'message' | 'silence';
2154
+ /**
2155
+ * What an inbound message becomes.
2156
+ *
2157
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2158
+ *
2159
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2160
+ *
2161
+ */
2162
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2115
2163
  agent_id?: string;
2116
2164
  text?: string;
2117
2165
  repeat?: 'every' | 'once' | {
2118
2166
  after_seconds: number;
2119
2167
  };
2120
2168
  language?: string;
2169
+ /**
2170
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2171
+ *
2172
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2173
+ *
2174
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2175
+ *
2176
+ */
2121
2177
  config?: {
2122
2178
  [key: string]: unknown;
2123
2179
  };
@@ -2268,9 +2324,17 @@ type ChannelList = {
2268
2324
  *
2269
2325
  */
2270
2326
  type ChannelDefaultAction = {
2271
- action: 'agent' | 'message' | 'silence';
2272
2327
  /**
2273
- * The agent that answers, when `action` is `agent`.
2328
+ * What an inbound message becomes.
2329
+ *
2330
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2331
+ *
2332
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2333
+ *
2334
+ */
2335
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2336
+ /**
2337
+ * The agent that answers, when `action` is `agent` or `oneshot`.
2274
2338
  */
2275
2339
  agent_id: string | null;
2276
2340
  /**
@@ -2289,7 +2353,12 @@ type ChannelDefaultAction = {
2289
2353
  */
2290
2354
  language: string | null;
2291
2355
  /**
2292
- * Conversation config bag — media handling, persona overrides, the Discord allowlist.
2356
+ * Conversation config bag — media handling, persona overrides, the Discord allowlist, and how a `oneshot` answers.
2357
+ *
2358
+ * `discord.reply` picks the delivery: `react` (the default) adds `discord.reaction` — `✅` unless named — to the message that triggered the run, `mention` answers beside it addressing whoever asked, `thread` opens a thread and answers inside it, and `none` delivers nothing at all. A run that fails delivers nothing in every mode, so a reaction always means the work was done; there is no failure marker.
2359
+ *
2360
+ * Read only for `oneshot`. A conversational `agent` in a guild *is* its thread — that is what its session is keyed on — so it always opens one.
2361
+ *
2293
2362
  */
2294
2363
  config: {
2295
2364
  [key: string]: unknown;
@@ -2300,7 +2369,15 @@ type ChannelDefaultAction = {
2300
2369
  *
2301
2370
  */
2302
2371
  type ChannelDefaultActionInput = {
2303
- action: 'agent' | 'message' | 'silence';
2372
+ /**
2373
+ * What an inbound message becomes.
2374
+ *
2375
+ * `agent` is a dialogue: the identity behind the message gets a session, and every later message on it continues the same one. `oneshot` runs the agent once and keeps nothing — no address, no actor, no session, no conversation — so each message is answered on its own. Choose it for work that is filed rather than discussed; choose `agent` when the answer depends on what came before.
2376
+ *
2377
+ * `message` delivers fixed text without running an agent, and `silence` answers nothing.
2378
+ *
2379
+ */
2380
+ action: 'agent' | 'oneshot' | 'message' | 'silence';
2304
2381
  agent_id?: string;
2305
2382
  text?: string;
2306
2383
  repeat?: 'every' | 'once' | {
@@ -5871,7 +5948,7 @@ type Project = {
5871
5948
  updated_at: Date;
5872
5949
  };
5873
5950
  /**
5874
- * What the member may do in this project. `owner` — everything, including deleting it and paying for it; exactly one per project. `admin` — every read and write inside it, including minting project API keys, but not deleting the project. `member` — reads only.
5951
+ * What the member may do in this project. `owner` — everything, including deleting it and paying for it; exactly one per project. `admin` — everything a `member` may do, plus managing who else is in the project and how the project itself is configured. `member` — every read and write on the project's own resources, including minting project API keys.
5875
5952
  * When returned on a `Project`, this is *your* role, not a property of the project: it is what lets a client hide an action the request would refuse.
5876
5953
  *
5877
5954
  */
@@ -17828,7 +17905,7 @@ type AddProjectMemberErrors = {
17828
17905
  */
17829
17906
  401: ErrorResponse;
17830
17907
  /**
17831
- * The caller is a read-only `member`, an `admin` granting `admin`, or a project-scoped credential.
17908
+ * The caller is a `member`, an `admin` granting `admin`, or a project-scoped credential.
17832
17909
  *
17833
17910
  */
17834
17911
  403: ErrorResponse;
@@ -18256,7 +18333,7 @@ type CreateProjectUsageThresholdErrors = {
18256
18333
  */
18257
18334
  401: ErrorResponse;
18258
18335
  /**
18259
- * The caller is a read-only member.
18336
+ * The caller is a `member`; an alerting rule needs `admin`.
18260
18337
  */
18261
18338
  403: ErrorResponse;
18262
18339
  /**
@@ -18290,7 +18367,7 @@ type DeleteProjectUsageThresholdErrors = {
18290
18367
  */
18291
18368
  401: ErrorResponse;
18292
18369
  /**
18293
- * The caller is a read-only member.
18370
+ * The caller is a `member`; an alerting rule needs `admin`.
18294
18371
  */
18295
18372
  403: ErrorResponse;
18296
18373
  /**
@@ -21662,7 +21739,7 @@ export declare class ApiKeys {
21662
21739
  * Create an API key
21663
21740
  *
21664
21741
  * Creates an API key. When `project_id` is set the key is scoped to that project (the default and recommended stance); omit it for an account-scoped key. `capabilities` narrows what the key may do; when omitted the key inherits the creator's capabilities. The raw `key` (nat_sk_…) is returned only in this response.
21665
- * A project-scoped key requires the `admin` role in that project: the key is a standing credential for everything the project can do, so handing one out is an administrative act rather than something a read-only `member` can do for themselves. An account-scoped key requires a credential that is not itself confined to one project.
21742
+ * A project-scoped key requires membership of that project. The key carries no role of its own — every request it makes resolves its holder's membership again — so it can never reach past what its minter already had. An account-scoped key requires a credential that is not itself confined to one project.
21666
21743
  * A connected app cannot create keys at all: a grant is revocable and a key is not, so a key minted under a grant would still work after the app was disconnected. Reading and revoking keys stay available.
21667
21744
  *
21668
21745
  */
@@ -22825,7 +22902,7 @@ export declare class Projects {
22825
22902
  * Update a project
22826
22903
  *
22827
22904
  * Rename or archive a project, and/or change its content-retention settings (`trace_content_retention_days`, `trace_content_mode`), its execution ceilings (`max_concurrent_runs`, `max_chain_generations`, `max_orchestration_run_depth`) and its priced-model gate (`require_priced_model`). Archiving is reversible; resources are retained.
22828
- * Requires the `admin` role in the project (an `owner` has it too).
22905
+ * Requires the `admin` role in the project (an `owner` has it too). These are the terms every member works under, which is why setting them sits above the role that works under them.
22829
22906
  * The ceilings and the priced-model gate are uncapped by plan: each one only ever narrows what the project may spend, so setting one takes on a restriction rather than claiming an entitlement. On the three ceilings `null` clears the project's own bound and omission leaves it alone — they are different instructions.
22830
22907
  * The two retention controls answer different questions. The window bounds how long content *stays* — a daily sweep purges anything past it, leaving auditable skeletons behind. `trace_content_mode: none` means content is never *written*, which is the stronger guarantee: it cannot be missed by a sweep or survive in a backup.
22831
22908
  *
@@ -22836,7 +22913,7 @@ export declare class Projects {
22836
22913
  /**
22837
22914
  * List project members
22838
22915
  *
22839
- * Lists who may act in the project, and with what role. Readable by every member, including a read-only `member`: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
22916
+ * Lists who may act in the project, and with what role. Readable by every member, whatever their role: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
22840
22917
  * Somebody invited who has never signed in is listed too, with status `pending` — the invitation is already a grant, so hiding it until they arrive would hide access that exists.
22841
22918
  *
22842
22919
  */
@@ -22859,7 +22936,7 @@ export declare class Projects {
22859
22936
  *
22860
22937
  * Removes a member, or leaves the project yourself.
22861
22938
  *
22862
- * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a read-only `member` and not another `admin`.
22939
+ * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a `member` and not another `admin`.
22863
22940
  *
22864
22941
  * The owner's own row is refused: a project with no owner is unreachable, and the row names who pays.
22865
22942
  *
package/dist/index.mjs CHANGED
@@ -1471,7 +1471,7 @@ var ApiKeys = class {
1471
1471
  * Create an API key
1472
1472
  *
1473
1473
  * Creates an API key. When `project_id` is set the key is scoped to that project (the default and recommended stance); omit it for an account-scoped key. `capabilities` narrows what the key may do; when omitted the key inherits the creator's capabilities. The raw `key` (nat_sk_…) is returned only in this response.
1474
- * A project-scoped key requires the `admin` role in that project: the key is a standing credential for everything the project can do, so handing one out is an administrative act rather than something a read-only `member` can do for themselves. An account-scoped key requires a credential that is not itself confined to one project.
1474
+ * A project-scoped key requires membership of that project. The key carries no role of its own — every request it makes resolves its holder's membership again — so it can never reach past what its minter already had. An account-scoped key requires a credential that is not itself confined to one project.
1475
1475
  * A connected app cannot create keys at all: a grant is revocable and a key is not, so a key minted under a grant would still work after the app was disconnected. Reading and revoking keys stay available.
1476
1476
  *
1477
1477
  */
@@ -3725,7 +3725,7 @@ var Projects = class {
3725
3725
  * Update a project
3726
3726
  *
3727
3727
  * Rename or archive a project, and/or change its content-retention settings (`trace_content_retention_days`, `trace_content_mode`), its execution ceilings (`max_concurrent_runs`, `max_chain_generations`, `max_orchestration_run_depth`) and its priced-model gate (`require_priced_model`). Archiving is reversible; resources are retained.
3728
- * Requires the `admin` role in the project (an `owner` has it too).
3728
+ * Requires the `admin` role in the project (an `owner` has it too). These are the terms every member works under, which is why setting them sits above the role that works under them.
3729
3729
  * The ceilings and the priced-model gate are uncapped by plan: each one only ever narrows what the project may spend, so setting one takes on a restriction rather than claiming an entitlement. On the three ceilings `null` clears the project's own bound and omission leaves it alone — they are different instructions.
3730
3730
  * The two retention controls answer different questions. The window bounds how long content *stays* — a daily sweep purges anything past it, leaving auditable skeletons behind. `trace_content_mode: none` means content is never *written*, which is the stronger guarantee: it cannot be missed by a sweep or survive in a backup.
3731
3731
  *
@@ -3745,7 +3745,7 @@ var Projects = class {
3745
3745
  /**
3746
3746
  * List project members
3747
3747
  *
3748
- * Lists who may act in the project, and with what role. Readable by every member, including a read-only `member`: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
3748
+ * Lists who may act in the project, and with what role. Readable by every member, whatever their role: who else is in the project is not a privileged fact, and hiding it makes "why can that person see my agents?" unanswerable.
3749
3749
  * Somebody invited who has never signed in is listed too, with status `pending` — the invitation is already a grant, so hiding it until they arrive would hide access that exists.
3750
3750
  *
3751
3751
  */
@@ -3782,7 +3782,7 @@ var Projects = class {
3782
3782
  *
3783
3783
  * Removes a member, or leaves the project yourself.
3784
3784
  *
3785
- * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a read-only `member` and not another `admin`.
3785
+ * **Anyone may remove themselves**, whatever their role: a colleague who no longer wants access should not have to ask for it, and leaving takes nothing from anybody else. Removing *somebody else* needs authority — an `owner` may remove anyone, an `admin` may remove a `member` and not another `admin`.
3786
3786
  *
3787
3787
  * The owner's own row is refused: a project with no owner is unreachable, and the row names who pays.
3788
3788
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@naturali/sdk",
3
- "version": "0.134.0",
3
+ "version": "0.136.0",
4
4
  "description": "TypeScript SDK for the naturali.ai API, generated from its OpenAPI specs",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "devDependencies": {
33
33
  "@hey-api/openapi-ts": "^0.99.0",
34
- "@naturali/api": "0.134.0",
34
+ "@naturali/api": "0.136.0",
35
35
  "@ttoss/openapi-codegen": "^0.3.1",
36
36
  "@types/node": "^26.5.1",
37
37
  "tsdown": "^0.23.0",