@ellipsis-dev/sdk 0.21.0 → 0.22.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-DXHI6EPF.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 SessionExitStatus, N as SessionFrame, O as SessionGit, Q as SessionLiveness, T as SessionMessage, U as SessionMessageResponse, V as SessionMessageStatus, W as SessionPrompting, X as SessionRecord, Y as SessionRecordsListResponse, Z as SessionResponse, _ as SessionSource, $ as SessionState, a0 as SessionStatus, a1 as SessionStreamFrame, a2 as SessionSurface, a3 as SessionsListResponse, a4 as SnapshotFrame, a5 as StreamFrame, a6 as TokensInfo, a7 as paths } from './types-DXHI6EPF.js';
1
+ import { c as components } from './types-BKAbWcLN.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 SessionExitStatus, N as SessionFrame, O as SessionGit, Q as SessionLiveness, T as SessionMessage, U as SessionMessageResponse, V as SessionMessageStatus, W as SessionPrompting, X as SessionRecord, Y as SessionRecordsListResponse, Z as SessionResponse, _ as SessionSource, $ as SessionState, a0 as SessionStatus, a1 as SessionStreamFrame, a2 as SessionSurface, a3 as SessionsListResponse, a4 as SnapshotFrame, a5 as StreamFrame, a6 as TokensInfo, a7 as paths } from './types-BKAbWcLN.js';
3
3
 
4
4
  interface CursorResponse {
5
5
  has_more: boolean;
@@ -553,6 +553,23 @@ declare class EllipsisMemories {
553
553
  prefix?: string | null;
554
554
  }): Promise<S['MemoriesListResponse']>;
555
555
  }
556
+ declare class EllipsisModels {
557
+ private readonly transport;
558
+ constructor(transport: Transport);
559
+ /**
560
+ * List Supported Models
561
+ *
562
+ * List selectable agent models.
563
+ *
564
+ * Most expensive first, with the platform default flagged.
565
+ *
566
+ * Reads the same registry as the dashboard's rate table, so a
567
+ * client's model picker can never drift from what's offered.
568
+ * Behind auth but not account-scoped — the selectable set is
569
+ * global.
570
+ */
571
+ list(): Promise<S['ModelsListResponse']>;
572
+ }
556
573
  declare class EllipsisReviews {
557
574
  private readonly transport;
558
575
  constructor(transport: Transport);
@@ -859,6 +876,7 @@ declare class Ellipsis {
859
876
  readonly files: EllipsisFiles;
860
877
  readonly integrations: EllipsisIntegrations;
861
878
  readonly memories: EllipsisMemories;
879
+ readonly models: EllipsisModels;
862
880
  readonly reviews: EllipsisReviews;
863
881
  readonly secrets: EllipsisSecrets;
864
882
  readonly sessions: EllipsisSessions;
package/dist/index.js CHANGED
@@ -828,6 +828,28 @@ var EllipsisMemories = class {
828
828
  return await this.transport.request("GET", path, { query });
829
829
  }
830
830
  };
831
+ var EllipsisModels = class {
832
+ constructor(transport) {
833
+ this.transport = transport;
834
+ }
835
+ transport;
836
+ /**
837
+ * List Supported Models
838
+ *
839
+ * List selectable agent models.
840
+ *
841
+ * Most expensive first, with the platform default flagged.
842
+ *
843
+ * Reads the same registry as the dashboard's rate table, so a
844
+ * client's model picker can never drift from what's offered.
845
+ * Behind auth but not account-scoped — the selectable set is
846
+ * global.
847
+ */
848
+ async list() {
849
+ const path = "/v1/models";
850
+ return await this.transport.request("GET", path);
851
+ }
852
+ };
831
853
  var EllipsisReviews = class {
832
854
  constructor(transport) {
833
855
  this.transport = transport;
@@ -1184,6 +1206,7 @@ var Ellipsis = class {
1184
1206
  files;
1185
1207
  integrations;
1186
1208
  memories;
1209
+ models;
1187
1210
  reviews;
1188
1211
  secrets;
1189
1212
  sessions;
@@ -1199,6 +1222,7 @@ var Ellipsis = class {
1199
1222
  this.files = new EllipsisFiles(this.transport);
1200
1223
  this.integrations = new EllipsisIntegrations(this.transport);
1201
1224
  this.memories = new EllipsisMemories(this.transport);
1225
+ this.models = new EllipsisModels(this.transport);
1202
1226
  this.reviews = new EllipsisReviews(this.transport);
1203
1227
  this.secrets = new EllipsisSecrets(this.transport);
1204
1228
  this.sessions = new EllipsisSessions(this.transport);
@@ -1,4 +1,4 @@
1
- import { X as SessionRecord, a8 as CodexFileChangeItem, b as CodexEvent, a9 as CodexMcpToolCallItem, x as SdkRecord, K as Session, T as SessionMessage, a5 as StreamFrame } from '../types-DXHI6EPF.js';
1
+ import { X as SessionRecord, a8 as CodexFileChangeItem, b as CodexEvent, a9 as CodexMcpToolCallItem, x as SdkRecord, K as Session, T as SessionMessage, a5 as StreamFrame } from '../types-BKAbWcLN.js';
2
2
 
3
3
  interface ChatToolNode {
4
4
  key: string;
@@ -1,4 +1,4 @@
1
- import { a5 as StreamFrame, K as Session } from '../types-DXHI6EPF.js';
1
+ import { a5 as StreamFrame, K as Session } from '../types-BKAbWcLN.js';
2
2
 
3
3
  declare const SESSION_STREAM_PROTOCOL_VERSION = 3;
4
4
  declare const WS_CLOSE_NORMAL = 1000;
@@ -742,6 +742,33 @@ interface paths {
742
742
  patch?: never;
743
743
  trace?: never;
744
744
  };
745
+ '/v1/models': {
746
+ parameters: {
747
+ query?: never;
748
+ header?: never;
749
+ path?: never;
750
+ cookie?: never;
751
+ };
752
+ /**
753
+ * List Supported Models
754
+ * @description List selectable agent models.
755
+ *
756
+ * Most expensive first, with the platform default flagged.
757
+ *
758
+ * Reads the same registry as the dashboard's rate table, so a
759
+ * client's model picker can never drift from what's offered.
760
+ * Behind auth but not account-scoped — the selectable set is
761
+ * global.
762
+ */
763
+ get: operations['list_supported_models'];
764
+ put?: never;
765
+ post?: never;
766
+ delete?: never;
767
+ options?: never;
768
+ head?: never;
769
+ patch?: never;
770
+ trace?: never;
771
+ };
745
772
  '/v1/reviews': {
746
773
  parameters: {
747
774
  query?: never;
@@ -4179,6 +4206,50 @@ interface components {
4179
4206
  /** @description The credential that last wrote the memory. */
4180
4207
  updated_by: components['schemas']['MemoryActor'];
4181
4208
  };
4209
+ /** Model */
4210
+ Model: {
4211
+ /** Display Name */
4212
+ display_name: string;
4213
+ /** Id */
4214
+ id: string;
4215
+ /** Is Default Agent Model */
4216
+ is_default_agent_model: boolean;
4217
+ manufacturer: components['schemas']['ModelManufacturer'];
4218
+ rate_card: components['schemas']['ModelRateCardApi'];
4219
+ };
4220
+ /**
4221
+ * ModelManufacturer
4222
+ * @description Who BUILT a model. Never who serves it.
4223
+ *
4224
+ * Serving path is irrelevant here. Anthropic built every Claude model, so all of
4225
+ * them are ANTHROPIC even though OpenRouter is what actually serves them.
4226
+ * Likewise the `gpt-5.6-*` rows are OPENAI (OpenAI's models, resold to us by
4227
+ * OpenRouter), and GLM is ZAI (Z.ai's model, served by DeepInfra via
4228
+ * OpenRouter).
4229
+ *
4230
+ * So this is deliberately NOT derived from `EgressRoute.provider`: routing is an
4231
+ * infrastructure fact that changes when we move a model between providers, while
4232
+ * the manufacturer is a property of the model itself and never changes.
4233
+ *
4234
+ * The frontend renders a vendor logo per model, which is why it needs the maker.
4235
+ * Keying that UI off the egress provider would put an AWS logo on a GPT model and
4236
+ * an OpenAI logo on GLM.
4237
+ * @enum {string}
4238
+ */
4239
+ ModelManufacturer: 'anthropic' | 'openai' | 'zai' | 'minimax' | 'moonshot';
4240
+ /** ModelRateCardApi */
4241
+ ModelRateCardApi: {
4242
+ /** Cache Read Millicents Per 1M Tokens */
4243
+ cache_read_millicents_per_1m_tokens: number;
4244
+ /** Cache Write 1H Millicents Per 1M Tokens */
4245
+ cache_write_1h_millicents_per_1m_tokens: number;
4246
+ /** Cache Write 5M Millicents Per 1M Tokens */
4247
+ cache_write_5m_millicents_per_1m_tokens: number;
4248
+ /** Input Millicents Per 1M Tokens */
4249
+ input_millicents_per_1m_tokens: number;
4250
+ /** Output Millicents Per 1M Tokens */
4251
+ output_millicents_per_1m_tokens: number;
4252
+ };
4182
4253
  /**
4183
4254
  * ModelUsageBreakdown
4184
4255
  * @description Usage and cost for one model over the whole period, split into the four
@@ -4216,6 +4287,11 @@ interface components {
4216
4287
  */
4217
4288
  tokens: number;
4218
4289
  };
4290
+ /** ModelsListResponse */
4291
+ ModelsListResponse: {
4292
+ /** Models */
4293
+ models: components['schemas']['Model'][];
4294
+ };
4219
4295
  /**
4220
4296
  * OrganizationRole
4221
4297
  * @enum {string}
@@ -9413,6 +9489,55 @@ interface operations {
9413
9489
  };
9414
9490
  };
9415
9491
  };
9492
+ list_supported_models: {
9493
+ parameters: {
9494
+ query?: never;
9495
+ header?: {
9496
+ 'user-agent'?: string | null;
9497
+ };
9498
+ path?: never;
9499
+ cookie?: never;
9500
+ };
9501
+ requestBody?: never;
9502
+ responses: {
9503
+ /** @description Successful Response */
9504
+ 200: {
9505
+ headers: {
9506
+ [name: string]: unknown;
9507
+ };
9508
+ content: {
9509
+ 'application/json': components['schemas']['ModelsListResponse'];
9510
+ };
9511
+ };
9512
+ /** @description The bearer token is missing, invalid, or revoked. */
9513
+ 401: {
9514
+ headers: {
9515
+ [name: string]: unknown;
9516
+ };
9517
+ content: {
9518
+ 'application/json': components['schemas']['ErrorResponse'];
9519
+ };
9520
+ };
9521
+ /** @description The credential may not perform this action, or the account is blocked. */
9522
+ 403: {
9523
+ headers: {
9524
+ [name: string]: unknown;
9525
+ };
9526
+ content: {
9527
+ 'application/json': components['schemas']['ErrorResponse'];
9528
+ };
9529
+ };
9530
+ /** @description Validation Error */
9531
+ 422: {
9532
+ headers: {
9533
+ [name: string]: unknown;
9534
+ };
9535
+ content: {
9536
+ 'application/json': components['schemas']['HTTPValidationError'];
9537
+ };
9538
+ };
9539
+ };
9540
+ };
9416
9541
  list_reviews: {
9417
9542
  parameters: {
9418
9543
  query?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ellipsis-dev/sdk",
3
- "version": "0.21.0",
3
+ "version": "0.22.0",
4
4
  "description": "TypeScript SDK for the Ellipsis agents platform: /v1 REST types + client, the session stream WebSocket client, and the session transcript store.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -5417,6 +5417,82 @@
5417
5417
  "title": "MemorySummary",
5418
5418
  "type": "object"
5419
5419
  },
5420
+ "Model": {
5421
+ "properties": {
5422
+ "display_name": {
5423
+ "title": "Display Name",
5424
+ "type": "string"
5425
+ },
5426
+ "id": {
5427
+ "title": "Id",
5428
+ "type": "string"
5429
+ },
5430
+ "is_default_agent_model": {
5431
+ "title": "Is Default Agent Model",
5432
+ "type": "boolean"
5433
+ },
5434
+ "manufacturer": {
5435
+ "$ref": "#/components/schemas/ModelManufacturer"
5436
+ },
5437
+ "rate_card": {
5438
+ "$ref": "#/components/schemas/ModelRateCardApi"
5439
+ }
5440
+ },
5441
+ "required": [
5442
+ "id",
5443
+ "display_name",
5444
+ "manufacturer",
5445
+ "is_default_agent_model",
5446
+ "rate_card"
5447
+ ],
5448
+ "title": "Model",
5449
+ "type": "object"
5450
+ },
5451
+ "ModelManufacturer": {
5452
+ "description": "Who BUILT a model. Never who serves it.\n\nServing path is irrelevant here. Anthropic built every Claude model, so all of\nthem are ANTHROPIC even though OpenRouter is what actually serves them.\nLikewise the `gpt-5.6-*` rows are OPENAI (OpenAI's models, resold to us by\nOpenRouter), and GLM is ZAI (Z.ai's model, served by DeepInfra via\nOpenRouter).\n\nSo this is deliberately NOT derived from `EgressRoute.provider`: routing is an\ninfrastructure fact that changes when we move a model between providers, while\nthe manufacturer is a property of the model itself and never changes.\n\nThe frontend renders a vendor logo per model, which is why it needs the maker.\nKeying that UI off the egress provider would put an AWS logo on a GPT model and\nan OpenAI logo on GLM.",
5453
+ "enum": [
5454
+ "anthropic",
5455
+ "openai",
5456
+ "zai",
5457
+ "minimax",
5458
+ "moonshot"
5459
+ ],
5460
+ "title": "ModelManufacturer",
5461
+ "type": "string"
5462
+ },
5463
+ "ModelRateCardApi": {
5464
+ "properties": {
5465
+ "cache_read_millicents_per_1m_tokens": {
5466
+ "title": "Cache Read Millicents Per 1M Tokens",
5467
+ "type": "integer"
5468
+ },
5469
+ "cache_write_1h_millicents_per_1m_tokens": {
5470
+ "title": "Cache Write 1H Millicents Per 1M Tokens",
5471
+ "type": "integer"
5472
+ },
5473
+ "cache_write_5m_millicents_per_1m_tokens": {
5474
+ "title": "Cache Write 5M Millicents Per 1M Tokens",
5475
+ "type": "integer"
5476
+ },
5477
+ "input_millicents_per_1m_tokens": {
5478
+ "title": "Input Millicents Per 1M Tokens",
5479
+ "type": "integer"
5480
+ },
5481
+ "output_millicents_per_1m_tokens": {
5482
+ "title": "Output Millicents Per 1M Tokens",
5483
+ "type": "integer"
5484
+ }
5485
+ },
5486
+ "required": [
5487
+ "input_millicents_per_1m_tokens",
5488
+ "cache_write_5m_millicents_per_1m_tokens",
5489
+ "cache_write_1h_millicents_per_1m_tokens",
5490
+ "cache_read_millicents_per_1m_tokens",
5491
+ "output_millicents_per_1m_tokens"
5492
+ ],
5493
+ "title": "ModelRateCardApi",
5494
+ "type": "object"
5495
+ },
5420
5496
  "ModelUsageBreakdown": {
5421
5497
  "description": "Usage and cost for one model over the whole period, split into the four\nbilled categories.",
5422
5498
  "properties": {
@@ -5462,6 +5538,22 @@
5462
5538
  "title": "ModelUsageBreakdown",
5463
5539
  "type": "object"
5464
5540
  },
5541
+ "ModelsListResponse": {
5542
+ "properties": {
5543
+ "models": {
5544
+ "items": {
5545
+ "$ref": "#/components/schemas/Model"
5546
+ },
5547
+ "title": "Models",
5548
+ "type": "array"
5549
+ }
5550
+ },
5551
+ "required": [
5552
+ "models"
5553
+ ],
5554
+ "title": "ModelsListResponse",
5555
+ "type": "object"
5556
+ },
5465
5557
  "OrganizationRole": {
5466
5558
  "enum": [
5467
5559
  "admin",
@@ -14427,6 +14519,82 @@
14427
14519
  "x-ellipsis-undocumented": true
14428
14520
  }
14429
14521
  },
14522
+ "/v1/models": {
14523
+ "get": {
14524
+ "description": "List selectable agent models.\n\nMost expensive first, with the platform default flagged.\n\nReads the same registry as the dashboard's rate table, so a\nclient's model picker can never drift from what's offered.\nBehind auth but not account-scoped \u2014 the selectable set is\nglobal.",
14525
+ "operationId": "list_supported_models",
14526
+ "parameters": [
14527
+ {
14528
+ "in": "header",
14529
+ "name": "user-agent",
14530
+ "required": false,
14531
+ "schema": {
14532
+ "anyOf": [
14533
+ {
14534
+ "type": "string"
14535
+ },
14536
+ {
14537
+ "type": "null"
14538
+ }
14539
+ ],
14540
+ "title": "User-Agent"
14541
+ }
14542
+ }
14543
+ ],
14544
+ "responses": {
14545
+ "200": {
14546
+ "content": {
14547
+ "application/json": {
14548
+ "schema": {
14549
+ "$ref": "#/components/schemas/ModelsListResponse"
14550
+ }
14551
+ }
14552
+ },
14553
+ "description": "Successful Response"
14554
+ },
14555
+ "401": {
14556
+ "content": {
14557
+ "application/json": {
14558
+ "schema": {
14559
+ "$ref": "#/components/schemas/ErrorResponse"
14560
+ }
14561
+ }
14562
+ },
14563
+ "description": "The bearer token is missing, invalid, or revoked."
14564
+ },
14565
+ "403": {
14566
+ "content": {
14567
+ "application/json": {
14568
+ "schema": {
14569
+ "$ref": "#/components/schemas/ErrorResponse"
14570
+ }
14571
+ }
14572
+ },
14573
+ "description": "The credential may not perform this action, or the account is blocked."
14574
+ },
14575
+ "422": {
14576
+ "content": {
14577
+ "application/json": {
14578
+ "schema": {
14579
+ "$ref": "#/components/schemas/HTTPValidationError"
14580
+ }
14581
+ }
14582
+ },
14583
+ "description": "Validation Error"
14584
+ }
14585
+ },
14586
+ "security": [
14587
+ {
14588
+ "HTTPBearer": []
14589
+ }
14590
+ ],
14591
+ "summary": "List Supported Models",
14592
+ "tags": [
14593
+ "v1"
14594
+ ],
14595
+ "x-ellipsis-sdk-method": "models.list"
14596
+ }
14597
+ },
14430
14598
  "/v1/reviews": {
14431
14599
  "get": {
14432
14600
  "description": "List code reviews, newest first.\n\n`findings` is omitted (counters only).\n\nWebhook-created reviews appear here too, so this answers \"show\nme every review on this PR\".",