@ellipsis-dev/sdk 0.17.0 → 0.19.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.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { c as components } from './types--VF0yCc1.js';
2
- export { A as AgentConfigSource, a as AttributionType, B as BudgetSource, C as ClaudeSessionRecord, b as CodexEvent, d as CodexItem, e as CodexSessionRecord, f as CreateReviewRequest, D as DeltaFrame, g as DoneFrame, E as ErrorFrame, F as Finding, G as GithubAccountSnippet, h as GithubAccountType, H as Harness, i as HeartbeatFrame, L as LifecycleSessionRecord, P as ParentKind, j as PromptBlockedReason, R as RecordsAppendFrame, k as ResolvedReviewScope, l as Review, m as ReviewConfiguration, n as ReviewCounters, o as ReviewFinding, p as ReviewRequester, q as ReviewScope, r as ReviewScopeKind, s as ReviewStage, t as ReviewedCommit, u as ReviewsListResponse, S as SdkAssistantRecord, v as SdkContentBlock, w as SdkRateLimitRecord, x as SdkRecord, y as SdkResultRecord, z as SdkSystemRecord, I as SdkUserRecord, J as SendSessionMessageRequest, K as Session, M as SessionExecution, N as SessionExecutionsListResponse, O as SessionExitStatus, Q as SessionFrame, T as SessionGit, U as SessionLiveness, V as SessionMessage, W as SessionMessageResponse, X as SessionMessageStatus, Y as SessionPrompting, Z as SessionRecord, _ as SessionRecordsListResponse, $ as SessionResponse, a0 as SessionSource, a1 as SessionState, a2 as SessionStatus, a3 as SessionStreamFrame, a4 as SessionSurface, a5 as SessionsListResponse, a6 as SnapshotFrame, a7 as StreamFrame, a8 as TokensInfo, a9 as paths } from './types--VF0yCc1.js';
1
+ import { c as components } from './types-D2YZTvgg.js';
2
+ export { A as AgentConfigSource, a as AttributionType, B as BudgetSource, C as ClaudeSessionRecord, b as CodexEvent, d as CodexItem, e as CodexSessionRecord, f as CreateReviewRequest, D as DeltaFrame, g as DoneFrame, E as ErrorFrame, F as Finding, G as GithubAccountSnippet, h as GithubAccountType, H as Harness, i as HeartbeatFrame, L as LifecycleSessionRecord, P as ParentKind, j as PromptBlockedReason, R as RecordsAppendFrame, k as ResolvedReviewScope, l as Review, m as ReviewConfiguration, n as ReviewCounters, o as ReviewFinding, p as ReviewRequester, q as ReviewScope, r as ReviewScopeKind, s as ReviewStage, t as ReviewedCommit, u as ReviewsListResponse, S as SdkAssistantRecord, v as SdkContentBlock, w as SdkRateLimitRecord, x as SdkRecord, y as SdkResultRecord, z as SdkSystemRecord, I as SdkUserRecord, J as SendSessionMessageRequest, K as Session, M as SessionExecution, N as SessionExecutionsListResponse, O as SessionExitStatus, Q as SessionFrame, T as SessionGit, U as SessionLiveness, V as SessionMessage, W as SessionMessageResponse, X as SessionMessageStatus, Y as SessionPrompting, Z as SessionRecord, _ as SessionRecordsListResponse, $ as SessionResponse, a0 as SessionSource, a1 as SessionState, a2 as SessionStatus, a3 as SessionStreamFrame, a4 as SessionSurface, a5 as SessionsListResponse, a6 as SnapshotFrame, a7 as StreamFrame, a8 as TokensInfo, a9 as paths } from './types-D2YZTvgg.js';
3
3
 
4
4
  interface CursorResponse {
5
5
  has_more: boolean;
@@ -69,152 +69,6 @@ declare class Transport {
69
69
  }
70
70
 
71
71
  type S = components['schemas'];
72
- declare class EllipsisAgentsConfigs {
73
- private readonly transport;
74
- constructor(transport: Transport);
75
- /**
76
- * Create Agent Config
77
- *
78
- * Create an agent config, managed through the API: no file, live
79
- * immediately. To put its definition in a repository instead, create
80
- * it here and then POST /v1/agents/configs/{config_id}/link.
81
- *
82
- * 409 when another live agent already holds the name.
83
- */
84
- create(options: {
85
- config: S['AgentConfig'];
86
- }): Promise<S['AgentConfigResponse']>;
87
- /**
88
- * Delete Agent Config
89
- *
90
- * Delete an agent, by id or by the agent's name.
91
- *
92
- * The agent stops running and its name is freed immediately; its
93
- * past sessions remain readable. Only for agents managed through
94
- * this API — delete the file to remove one defined by a
95
- * repository.
96
- */
97
- delete(config_id: string): Promise<void>;
98
- /**
99
- * Get Agent Config
100
- *
101
- * Return one saved agent config, by id or by the agent's name.
102
- */
103
- get(config_id: string): Promise<S['AgentConfigResponse']>;
104
- /**
105
- * Link Agent Config
106
- *
107
- * Move an agent into a repository, by id or by the agent's name.
108
- *
109
- * Opens a pull request adding the agent's config file. The agent
110
- * keeps running unchanged meanwhile; merging hands it over to the
111
- * file, after which the file is what changes it. Nothing happens
112
- * if the pull request is never merged.
113
- */
114
- link(config_id: string, options: {
115
- path?: string | null;
116
- repository: string;
117
- }): Promise<S['LinkAgentConfigResponse']>;
118
- /**
119
- * List Agent Configs
120
- *
121
- * List saved agent configs.
122
- */
123
- list(): Promise<S['AgentConfigsListResponse']>;
124
- /**
125
- * Unlink Agent Config
126
- *
127
- * Take over an agent from its file, by id or by the agent's name.
128
- *
129
- * The file stops governing the agent immediately and further
130
- * changes go through this API. The file is left in place, inert —
131
- * delete it whenever you like.
132
- */
133
- unlink(config_id: string): Promise<S['AgentConfigResponse']>;
134
- /**
135
- * Update Agent Config
136
- *
137
- * Replace an agent's definition, by id or by the agent's name.
138
- *
139
- * The whole definition is replaced, and the change is live at
140
- * once. Only for agents managed through this API: one defined by a
141
- * repository file is a 409, since the next push to that file would
142
- * revert the change — unlink it first to take ownership.
143
- */
144
- update(config_id: string, options: {
145
- config: S['AgentConfig'];
146
- }): Promise<S['AgentConfigResponse']>;
147
- }
148
- declare class EllipsisAgentsDefaults {
149
- private readonly transport;
150
- constructor(transport: Transport);
151
- /**
152
- * Delete Agent Default
153
- *
154
- * Clear a default agent config.
155
- *
156
- * Addressed by rung: the account rung (repository omitted) or a
157
- * repository rung.
158
- *
159
- * Refused for sandbox tokens.
160
- */
161
- delete(options?: {
162
- repository?: string | null;
163
- }): Promise<void>;
164
- /**
165
- * List Agent Defaults
166
- *
167
- * Get the default agent configs.
168
- *
169
- * The account-wide default and the per-repository defaults, as config
170
- * ids. Repo rungs are keyed "owner/name"; a repository this
171
- * installation can no longer see is omitted.
172
- */
173
- list(): Promise<S['AgentDefaults']>;
174
- /**
175
- * Put Agent Default
176
- *
177
- * Set a default agent config.
178
- *
179
- * Addressed by rung: the account rung (repository omitted) or a
180
- * repository rung ("owner/name"); the config by id or by the
181
- * agent's name. Returns the full resulting ladder.
182
- *
183
- * Refused for sandbox tokens (potentially prompt-injected code
184
- * must not repoint the account's ambient default); an unknown or
185
- * foreign repository is a 404.
186
- */
187
- set(options: {
188
- config_id: string;
189
- repository?: string | null;
190
- }): Promise<S['AgentDefaults']>;
191
- }
192
- declare class EllipsisAgentsTemplates {
193
- private readonly transport;
194
- constructor(transport: Transport);
195
- /**
196
- * Get Agent Template
197
- *
198
- * Return one built-in agent template by slug.
199
- */
200
- get(template_id: string): Promise<S['AgentTemplate']>;
201
- /**
202
- * List Agent Templates
203
- *
204
- * List the built-in starter agent templates.
205
- *
206
- * Behind auth but not account-scoped — the data is static
207
- * product content shared by the dashboard, landing site, and CLI.
208
- */
209
- list(): Promise<S['AgentTemplatesListResponse']>;
210
- }
211
- declare class EllipsisAgents {
212
- private readonly transport;
213
- readonly configs: EllipsisAgentsConfigs;
214
- readonly defaults: EllipsisAgentsDefaults;
215
- readonly templates: EllipsisAgentsTemplates;
216
- constructor(transport: Transport);
217
- }
218
72
  declare class EllipsisAlerts {
219
73
  private readonly transport;
220
74
  constructor(transport: Transport);
@@ -282,15 +136,15 @@ declare class EllipsisAnalytics {
282
136
  * Return pull-request analytics.
283
137
  *
284
138
  * Windowing: pass explicit start/end, or days (default: the last
285
- * 30 days).
139
+ * 30 days). account_type in all|user|bot scopes the authors.
286
140
  */
287
141
  pullRequests(options?: {
288
142
  days?: number | null;
289
143
  start?: string | null;
290
144
  end?: string | null;
291
- account_type?: (string)[] | null;
292
- repository_id?: (number)[] | null;
293
- author_id?: (number)[] | null;
145
+ repo?: (string)[] | null;
146
+ author?: (string)[] | null;
147
+ account_type?: string;
294
148
  status?: (string)[] | null;
295
149
  }): Promise<S['GetAnalyticsPullRequestsResponse']>;
296
150
  /**
@@ -342,46 +196,100 @@ declare class EllipsisAuth {
342
196
  readonly cli: EllipsisAuthCli;
343
197
  constructor(transport: Transport);
344
198
  }
345
- declare class EllipsisEnvironmentsDefaults {
199
+ declare class EllipsisAutomations {
346
200
  private readonly transport;
347
201
  constructor(transport: Transport);
348
202
  /**
349
- * Delete Environment Default
203
+ * Create Automation
350
204
  *
351
- * Clear a default environment.
205
+ * Create an automation, managed through the API: no file, live
206
+ * immediately. To put its definition in a repository instead, create
207
+ * it here and then POST /v1/automations/{automation_id}/link.
352
208
  *
353
- * Addressed by rung: the account rung (repository omitted) or a
354
- * repository rung. Refused for sandbox tokens.
209
+ * 409 when another live automation already holds the name.
355
210
  */
356
- delete(options?: {
357
- repository?: string | null;
358
- }): Promise<void>;
211
+ create(options: {
212
+ automation: S['AgentConfig'];
213
+ }): Promise<S['AutomationResponse']>;
359
214
  /**
360
- * List Environment Defaults
215
+ * Delete Automation
361
216
  *
362
- * Get the default environments.
217
+ * Delete an automation, by id or by name.
363
218
  *
364
- * The account-wide default and the per-repository defaults, as
365
- * environment ids. Repo rungs are keyed "owner/name".
219
+ * It stops running and its name is freed immediately; its past
220
+ * sessions remain readable. Only for automations managed through
221
+ * this API — delete the file to remove one defined by a repository.
366
222
  */
367
- list(): Promise<S['EnvironmentDefaults']>;
223
+ delete(automation_id: string): Promise<void>;
368
224
  /**
369
- * Put Environment Default
225
+ * Get Automation
370
226
  *
371
- * Set a default environment.
227
+ * Return one automation, by id or by name.
228
+ */
229
+ get(automation_id: string): Promise<S['AutomationResponse']>;
230
+ /**
231
+ * Link Automation
372
232
  *
373
- * Addressed by rung: the account rung (repository omitted) or a
374
- * repository rung ("owner/name"); the environment by id or name.
375
- * Returns the full resulting ladder. Refused for sandbox tokens.
233
+ * Move an automation into a repository, by id or by name.
234
+ *
235
+ * Opens a pull request adding its definition file. The automation
236
+ * keeps running unchanged meanwhile; merging hands it over to the
237
+ * file, after which the file is what changes it. Nothing happens
238
+ * if the pull request is never merged.
376
239
  */
377
- set(options: {
378
- environment: string;
379
- repository?: string | null;
380
- }): Promise<S['EnvironmentDefaults']>;
240
+ link(automation_id: string, options: {
241
+ path?: string | null;
242
+ repository: string;
243
+ }): Promise<S['LinkAutomationResponse']>;
244
+ /**
245
+ * List Automations
246
+ *
247
+ * List automations.
248
+ */
249
+ list(): Promise<S['AutomationsListResponse']>;
250
+ /**
251
+ * Start Automation Session
252
+ *
253
+ * Invoke an automation.
254
+ *
255
+ * Runs the automation exactly as defined — its persona, model,
256
+ * environment, permissions, skills, and budget bind — and returns
257
+ * the session it started. The body carries only what a caller may
258
+ * supply: the typed `input` its schema demands, an optional tighter
259
+ * `budget`, and `metadata`. For a different persona or environment,
260
+ * start a raw session with POST /v1/sessions instead.
261
+ */
262
+ run(automation_id: string, options?: {
263
+ budget?: number | null;
264
+ input?: Record<string, unknown> | null;
265
+ metadata?: Record<string, string>;
266
+ }): Promise<S['SessionResponse']>;
267
+ /**
268
+ * Unlink Automation
269
+ *
270
+ * Take over an automation from its file, by id or by name.
271
+ *
272
+ * The file stops governing it immediately and further changes go
273
+ * through this API. The file is left in place, inert — delete it
274
+ * whenever you like.
275
+ */
276
+ unlink(automation_id: string): Promise<S['AutomationResponse']>;
277
+ /**
278
+ * Update Automation
279
+ *
280
+ * Replace an automation's definition, by id or by name.
281
+ *
282
+ * The whole definition is replaced, and the change is live at
283
+ * once. Only for automations managed through this API: one defined
284
+ * by a repository file is a 409, since the next push to that file
285
+ * would revert the change — unlink it first to take ownership.
286
+ */
287
+ update(automation_id: string, options: {
288
+ automation: S['AgentConfig'];
289
+ }): Promise<S['AutomationResponse']>;
381
290
  }
382
291
  declare class EllipsisEnvironments {
383
292
  private readonly transport;
384
- readonly defaults: EllipsisEnvironmentsDefaults;
385
293
  constructor(transport: Transport);
386
294
  /**
387
295
  * Create Environment
@@ -560,13 +468,13 @@ declare class EllipsisIntegrations {
560
468
  readonly slack: EllipsisIntegrationsSlack;
561
469
  constructor(transport: Transport);
562
470
  /**
563
- * Get Integrations
471
+ * List Integrations
564
472
  *
565
473
  * List connected integrations.
566
474
  *
567
475
  * A read-only view, so an agent authoring another agent's
568
476
  * config can learn which repositories, channels, teams, and
569
- * organizations it may name before POST /agents/configs.
477
+ * organizations it may name before POST /automations.
570
478
  *
571
479
  * Available to all credential types including sandbox tokens: the
572
480
  * responses never include OAuth tokens or any other secret.
@@ -741,7 +649,7 @@ declare class EllipsisSecrets {
741
649
  */
742
650
  list(): Promise<S['SecretsListResponse']>;
743
651
  /**
744
- * Put Secrets
652
+ * Set Secrets
745
653
  *
746
654
  * Upsert secrets.
747
655
  *
@@ -767,8 +675,7 @@ declare class EllipsisSessions {
767
675
  * instructions + the config's own instructions).
768
676
  *
769
677
  * Per execution because each cold wake persists its own launch
770
- * config (a config edit or replay override between wakes changes
771
- * it).
678
+ * config (a config edit between wakes changes it).
772
679
  */
773
680
  executions(session_id: string): Promise<S['SessionExecutionsListResponse']>;
774
681
  /**
@@ -818,12 +725,12 @@ declare class EllipsisSessions {
818
725
  *
819
726
  * List cloud agent sessions, newest first.
820
727
  *
821
- * Optionally filtered by config (id or `ellipsis.name`), source, time
728
+ * Optionally filtered by automation (id or name), source, time
822
729
  * window, attributed author, repository, and whether the session is
823
730
  * still going.
824
731
  */
825
732
  list(options?: {
826
- config_id?: string | null;
733
+ automation?: string | null;
827
734
  source?: (S['SessionSource'])[] | null;
828
735
  days?: number | null;
829
736
  start?: string | null;
@@ -862,22 +769,7 @@ declare class EllipsisSessions {
862
769
  limit?: number | null;
863
770
  }): Promise<Page<S['ClaudeSessionRecord'] | S['CodexSessionRecord'] | S['LifecycleSessionRecord'], S['SessionRecordsListResponse']>>;
864
771
  /**
865
- * Replay Agent Session
866
- *
867
- * Replay a session as a new session.
868
- *
869
- * Reuses the original config snapshot unless config_id is given,
870
- * and accepts the same config_override as session start — e.g.
871
- * {"claude": {"model": ...}} to replay the same input on a
872
- * different model.
873
- */
874
- replay(session_id: string, options?: {
875
- config_id?: string | null;
876
- override?: Record<string, unknown> | null;
877
- prompt?: string | null;
878
- }): Promise<S['SessionResponse']>;
879
- /**
880
- * Search Sessions
772
+ * Search Agent Sessions
881
773
  *
882
774
  * Search sessions over steps, recaps, and pull requests.
883
775
  *
@@ -921,25 +813,28 @@ declare class EllipsisSessions {
921
813
  *
922
814
  * Start a cloud agent session.
923
815
  *
924
- * Provide at most one of config_id (an id or an agent name) or
925
- * config; with neither, the account's default-config ladder
926
- * resolves the config. `prompt` is the first message; omit it and
927
- * the session starts idle, waiting for one. 400 when
928
- * interactive=false and there is no prompt or input. 422 when the
929
- * agent declares an input schema and the request's input is absent
930
- * or invalid.
816
+ * The daily driver: a prompt, optionally where to run it
817
+ * (`environment`) and the run's own settings, in the AgentConfig
818
+ * vocabulary. Anything omitted comes from the organization's
819
+ * settings — default model, default environment, budget — so
820
+ * `{"prompt": "..."}` alone is a complete request. `prompt` is the
821
+ * first message; omit it and the session starts idle, waiting for
822
+ * one. 400 when `interactive` is false and there is no prompt, or
823
+ * when `budget` exceeds the organization's per-session ceiling. To
824
+ * run a saved automation, use POST /v1/automations/{automation_id}/sessions.
931
825
  */
932
826
  start(options?: {
933
- config?: S['AgentConfig'] | null;
934
- config_id?: string | null;
935
- environment?: string | null;
827
+ budget?: number | null;
828
+ claude?: S['AgentConfigClaude'] | null;
829
+ codex?: S['AgentConfigCodex'] | null;
830
+ environment?: string | S['AgentConfigEnvironment'] | null;
936
831
  force_rebuild?: boolean;
937
- input?: Record<string, unknown> | null;
938
832
  interactive?: boolean;
939
833
  metadata?: Record<string, string>;
940
- override?: Record<string, unknown> | null;
834
+ output?: S['AgentConfigOutput'] | null;
835
+ permissions?: S['AgentConfigPermissions'] | null;
941
836
  prompt?: string | null;
942
- repository?: string | null;
837
+ skills?: (S['AgentConfigSkill'])[] | null;
943
838
  }): Promise<S['SessionResponse']>;
944
839
  /**
945
840
  * Stop Agent Session
@@ -955,12 +850,67 @@ declare class EllipsisSessions {
955
850
  /** A handle over an existing session. */
956
851
  handle(sessionId: string): Promise<SessionHandle>;
957
852
  }
853
+ declare class EllipsisSettingsOrganization {
854
+ private readonly transport;
855
+ constructor(transport: Transport);
856
+ /**
857
+ * Get Organization Settings
858
+ *
859
+ * Get the organization settings.
860
+ *
861
+ * The default model and default environment every session falls
862
+ * back to when neither its request nor its automation names one,
863
+ * and the per-session budget ceiling no session may exceed.
864
+ */
865
+ get(): Promise<S['OrganizationSettings']>;
866
+ /**
867
+ * Set Organization Settings
868
+ *
869
+ * Set the organization settings.
870
+ *
871
+ * Replaces all three: `default_model` accepts an alias or canonical
872
+ * id and is stored canonical; `default_environment` accepts a name
873
+ * or `env_` id and is stored as the id; `budget_ceiling.session` is
874
+ * in US dollars, at most the platform ceiling. Null clears each.
875
+ * Refused for sandbox tokens (potentially prompt-injected code must
876
+ * not repoint the organization's defaults).
877
+ */
878
+ set(options?: {
879
+ budget_ceiling?: S['BudgetCeiling'];
880
+ default_environment?: string | null;
881
+ default_model?: string | null;
882
+ }): Promise<S['OrganizationSettings']>;
883
+ }
884
+ declare class EllipsisSettings {
885
+ private readonly transport;
886
+ readonly organization: EllipsisSettingsOrganization;
887
+ constructor(transport: Transport);
888
+ }
889
+ declare class EllipsisTemplates {
890
+ private readonly transport;
891
+ constructor(transport: Transport);
892
+ /**
893
+ * Get Agent Template
894
+ *
895
+ * Return one built-in agent template by slug.
896
+ */
897
+ get(template_id: string): Promise<S['AgentTemplate']>;
898
+ /**
899
+ * List Agent Templates
900
+ *
901
+ * List the built-in starter agent templates.
902
+ *
903
+ * Behind auth but not account-scoped — the data is static
904
+ * product content shared by the dashboard, landing site, and CLI.
905
+ */
906
+ list(): Promise<S['AgentTemplatesListResponse']>;
907
+ }
958
908
  declare class Ellipsis {
959
909
  private readonly transport;
960
- readonly agents: EllipsisAgents;
961
910
  readonly alerts: EllipsisAlerts;
962
911
  readonly analytics: EllipsisAnalytics;
963
912
  readonly auth: EllipsisAuth;
913
+ readonly automations: EllipsisAutomations;
964
914
  readonly environments: EllipsisEnvironments;
965
915
  readonly files: EllipsisFiles;
966
916
  readonly integrations: EllipsisIntegrations;
@@ -969,6 +919,8 @@ declare class Ellipsis {
969
919
  readonly reviews: EllipsisReviews;
970
920
  readonly secrets: EllipsisSecrets;
971
921
  readonly sessions: EllipsisSessions;
922
+ readonly settings: EllipsisSettings;
923
+ readonly templates: EllipsisTemplates;
972
924
  constructor(options: TransportOptions);
973
925
  /**
974
926
  * Get Budget
@@ -977,13 +929,13 @@ declare class Ellipsis {
977
929
  */
978
930
  budget(): Promise<S['BudgetSummary']>;
979
931
  /**
980
- * Whoami
932
+ * Current Identity
981
933
  *
982
934
  * Return the identity behind the caller's credential.
983
935
  */
984
936
  me(): Promise<S['WhoAmIResponse']>;
985
937
  /**
986
- * Get Usage Endpoint
938
+ * Get Usage
987
939
  *
988
940
  * Return the caller's usage dashboard data.
989
941
  */