@runtypelabs/sdk 10.14.2 → 10.15.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
@@ -173,7 +173,8 @@ function createFlowEventTranslator() {
173
173
  failedSteps: data.failedSteps,
174
174
  executionTime: data.durationMs,
175
175
  finalOutput: data.finalOutput,
176
- completedAt: data.completedAt
176
+ completedAt: data.completedAt,
177
+ outcome: data.outcome
177
178
  })];
178
179
  case "execution_error": return [compact({
179
180
  type: "flow_error",
@@ -182,7 +183,8 @@ function createFlowEventTranslator() {
182
183
  error: data.error,
183
184
  code: data.code,
184
185
  upgradeUrl: data.upgradeUrl,
185
- blockReason: data.blockReason
186
+ blockReason: data.blockReason,
187
+ outcome: data.outcome
186
188
  })];
187
189
  case "await":
188
190
  if (data.awaitReason === "detached") return [];
@@ -438,7 +440,8 @@ function createAgentEventTranslator() {
438
440
  totalTokens: data.totalTokens,
439
441
  finalOutput: data.finalOutput,
440
442
  duration: data.durationMs,
441
- externalAgent: data.externalAgent
443
+ externalAgent: data.externalAgent,
444
+ outcome: data.outcome
442
445
  })];
443
446
  case "execution_error":
444
447
  if (data.kind !== "agent") return [];
@@ -450,7 +453,8 @@ function createAgentEventTranslator() {
450
453
  success: false,
451
454
  stopReason: data.stopReason ?? "error",
452
455
  error: errorMessage(data.error),
453
- completedAt: data.completedAt
456
+ completedAt: data.completedAt,
457
+ outcome: data.outcome
454
458
  })];
455
459
  case "error": return [compact({
456
460
  type: "agent_error",
@@ -8739,6 +8743,13 @@ var LogsEndpoint = class {
8739
8743
  return this.client.get(`/logs/trace/execution/${executionId}`);
8740
8744
  }
8741
8745
  /**
8746
+ * Explain one execution from its retained trace, with each claim citing trace entry ids.
8747
+ * Runs a metered, tool-free analysis in the caller's account and never changes the run.
8748
+ */
8749
+ async explainRun(executionId) {
8750
+ return this.client.post(`/logs/trace/execution/${encodeURIComponent(executionId)}/explain`, void 0, void 0, { timeoutMs: 6e4 });
8751
+ }
8752
+ /**
8742
8753
  * Get the trace tree for a conversation (all executions within it).
8743
8754
  */
8744
8755
  async traceConversation(conversationId) {
@@ -14445,7 +14456,7 @@ function transformQueryParams(params) {
14445
14456
  }
14446
14457
  //#endregion
14447
14458
  //#region src/version.ts
14448
- const SDK_VERSION = "10.14.2";
14459
+ const SDK_VERSION = "10.15.0";
14449
14460
  /**
14450
14461
  * Canonical client identity the API uses for attribution
14451
14462
  * (`detectActorSource` in apps/api/src/lib/audit-log.ts keys `'sdk'` off the
@@ -14750,7 +14761,7 @@ var RuntypeClient = class {
14750
14761
  /**
14751
14762
  * Generic POST request
14752
14763
  */
14753
- async post(path, data, extraHeaders) {
14764
+ async post(path, data, extraHeaders, options) {
14754
14765
  const url = this.buildUrl(path);
14755
14766
  return await this.makeRequest(url, {
14756
14767
  method: "POST",
@@ -14759,7 +14770,7 @@ var RuntypeClient = class {
14759
14770
  ...extraHeaders
14760
14771
  },
14761
14772
  body: data ? JSON.stringify(data) : void 0
14762
- });
14773
+ }, options?.timeoutMs);
14763
14774
  }
14764
14775
  /**
14765
14776
  * POST request with FormData support for file uploads
@@ -14868,9 +14879,9 @@ var RuntypeClient = class {
14868
14879
  * `makeRawRequest` keeps its own variant: it additionally composes a
14869
14880
  * caller-supplied `signal` (user-initiated stream aborts) with the timeout.
14870
14881
  */
14871
- async fetchWithTimeout(url, options) {
14872
- const controller = this.timeout === null ? null : new AbortController();
14873
- const timeoutId = controller && this.timeout !== null ? setTimeout(() => controller.abort(), this.timeout) : null;
14882
+ async fetchWithTimeout(url, options, timeoutMs = this.timeout) {
14883
+ const controller = timeoutMs === null ? null : new AbortController();
14884
+ const timeoutId = controller && timeoutMs !== null ? setTimeout(() => controller.abort(), timeoutMs) : null;
14874
14885
  try {
14875
14886
  const response = await fetch(url, {
14876
14887
  ...options,
@@ -14880,12 +14891,12 @@ var RuntypeClient = class {
14880
14891
  return response;
14881
14892
  } catch (error) {
14882
14893
  if (timeoutId) clearTimeout(timeoutId);
14883
- if (timeoutId && error instanceof Error && error.name === "AbortError") throw new Error(`Request timeout after ${this.timeout}ms`, { cause: error });
14894
+ if (timeoutId && error instanceof Error && error.name === "AbortError") throw new Error(`Request timeout after ${timeoutMs}ms`, { cause: error });
14884
14895
  throw error;
14885
14896
  }
14886
14897
  }
14887
- async makeRequest(url, options) {
14888
- const response = await this.fetchWithTimeout(url, options);
14898
+ async makeRequest(url, options, timeoutMs = this.timeout) {
14899
+ const response = await this.fetchWithTimeout(url, options, timeoutMs);
14889
14900
  if (!response.ok) throw await this.createApiError(response);
14890
14901
  if (response.status === 204) return null;
14891
14902
  if (response.headers.get("content-type")?.includes("application/json")) return response.json();
package/dist/index.d.cts CHANGED
@@ -1204,6 +1204,7 @@ interface paths {
1204
1204
  };
1205
1205
  enabled?: boolean;
1206
1206
  id: string;
1207
+ identityAudiences?: string[];
1207
1208
  name?: string;
1208
1209
  timeout?: number;
1209
1210
  /** @enum {string} */
@@ -1740,6 +1741,7 @@ interface paths {
1740
1741
  };
1741
1742
  enabled?: boolean;
1742
1743
  id: string;
1744
+ identityAudiences?: string[];
1743
1745
  name?: string;
1744
1746
  timeout?: number;
1745
1747
  /** @enum {string} */
@@ -2565,6 +2567,7 @@ interface paths {
2565
2567
  };
2566
2568
  enabled?: boolean;
2567
2569
  id: string;
2570
+ identityAudiences?: string[];
2568
2571
  name?: string;
2569
2572
  timeout?: number;
2570
2573
  /** @enum {string} */
@@ -3192,6 +3195,8 @@ interface paths {
3192
3195
  };
3193
3196
  content: {
3194
3197
  "application/json": {
3198
+ /** @description Non-blocking advisories, e.g. SCHEDULE_AGENT_CONFIG_UNSUPPORTED when moving `live` makes active schedules unrunnable. */
3199
+ _warnings?: string[];
3195
3200
  alias: string;
3196
3201
  /** @description Per-alias secret binding names in force after this activation. Names only, never values. */
3197
3202
  bindingNames: string[];
@@ -3801,6 +3806,8 @@ interface paths {
3801
3806
  };
3802
3807
  content: {
3803
3808
  "application/json": {
3809
+ /** @description Non-blocking advisories, e.g. SCHEDULE_AGENT_CONFIG_UNSUPPORTED when moving `live` makes active schedules unrunnable. */
3810
+ _warnings?: string[];
3804
3811
  alias: string;
3805
3812
  /** @description Per-alias secret binding names in force after this activation. Names only, never values. */
3806
3813
  bindingNames: string[];
@@ -5878,6 +5885,7 @@ interface paths {
5878
5885
  };
5879
5886
  content: {
5880
5887
  "application/json": {
5888
+ _warnings?: string[];
5881
5889
  message: string;
5882
5890
  publishedVersionId: string;
5883
5891
  success: boolean;
@@ -27611,6 +27619,160 @@ interface paths {
27611
27619
  patch?: never;
27612
27620
  trace?: never;
27613
27621
  };
27622
+ "/v1/logs/trace/execution/{executionId}/explain": {
27623
+ parameters: {
27624
+ query?: never;
27625
+ header?: never;
27626
+ path?: never;
27627
+ cookie?: never;
27628
+ };
27629
+ get?: never;
27630
+ put?: never;
27631
+ /**
27632
+ * Explain a run using retained trace evidence
27633
+ * @description Runs a bounded, tool-free analysis in the caller account. Model usage is metered. Requires ANALYTICS:READ and FLOWS:EXECUTE for API keys. Does not assess business quality or modify the source run.
27634
+ */
27635
+ post: {
27636
+ parameters: {
27637
+ query?: never;
27638
+ header?: never;
27639
+ path: {
27640
+ executionId: string;
27641
+ };
27642
+ cookie?: never;
27643
+ };
27644
+ requestBody?: never;
27645
+ responses: {
27646
+ /** @description Evidence-linked run explanation */
27647
+ 200: {
27648
+ headers: {
27649
+ [name: string]: unknown;
27650
+ };
27651
+ content: {
27652
+ "application/json": {
27653
+ data: {
27654
+ analysis: {
27655
+ hypotheses: {
27656
+ eventIds: string[];
27657
+ text: string;
27658
+ }[];
27659
+ limitations: string[];
27660
+ nextSteps: {
27661
+ eventIds: string[];
27662
+ text: string;
27663
+ }[];
27664
+ observations: {
27665
+ eventIds: string[];
27666
+ text: string;
27667
+ }[];
27668
+ overview: {
27669
+ eventIds: string[];
27670
+ text: string;
27671
+ };
27672
+ };
27673
+ analysisExecutionId: string;
27674
+ analyzerVersion: number;
27675
+ coverageWarnings: string[];
27676
+ evidenceCount: number;
27677
+ executionId: string;
27678
+ generatedAt: string;
27679
+ /** @enum {string} */
27680
+ qualityAssessment: "not_assessed";
27681
+ };
27682
+ /** @enum {boolean} */
27683
+ success: true;
27684
+ };
27685
+ };
27686
+ };
27687
+ /** @description Invalid execution ID */
27688
+ 400: {
27689
+ headers: {
27690
+ [name: string]: unknown;
27691
+ };
27692
+ content: {
27693
+ "application/json": components["schemas"]["Error"];
27694
+ };
27695
+ };
27696
+ /** @description Unauthorized */
27697
+ 401: {
27698
+ headers: {
27699
+ [name: string]: unknown;
27700
+ };
27701
+ content: {
27702
+ "application/json": components["schemas"]["Error"];
27703
+ };
27704
+ };
27705
+ /** @description Execution spend limit reached */
27706
+ 402: {
27707
+ headers: {
27708
+ [name: string]: unknown;
27709
+ };
27710
+ content: {
27711
+ "application/json": components["schemas"]["Error"];
27712
+ };
27713
+ };
27714
+ /** @description Required permission or account verification missing */
27715
+ 403: {
27716
+ headers: {
27717
+ [name: string]: unknown;
27718
+ };
27719
+ content: {
27720
+ "application/json": components["schemas"]["Error"];
27721
+ };
27722
+ };
27723
+ /** @description No retained trace evidence */
27724
+ 404: {
27725
+ headers: {
27726
+ [name: string]: unknown;
27727
+ };
27728
+ content: {
27729
+ "application/json": components["schemas"]["Error"];
27730
+ };
27731
+ };
27732
+ /** @description Request cancelled */
27733
+ 408: {
27734
+ headers: {
27735
+ [name: string]: unknown;
27736
+ };
27737
+ content: {
27738
+ "application/json": components["schemas"]["Error"];
27739
+ };
27740
+ };
27741
+ /** @description Execution rate limit reached */
27742
+ 429: {
27743
+ headers: {
27744
+ [name: string]: unknown;
27745
+ };
27746
+ content: {
27747
+ "application/json": components["schemas"]["Error"];
27748
+ };
27749
+ };
27750
+ /** @description Analysis failed or invalid evidence citations */
27751
+ 502: {
27752
+ headers: {
27753
+ [name: string]: unknown;
27754
+ };
27755
+ content: {
27756
+ "application/json": components["schemas"]["Error"];
27757
+ };
27758
+ };
27759
+ /** @description Trace service unavailable */
27760
+ 503: {
27761
+ headers: {
27762
+ [name: string]: unknown;
27763
+ };
27764
+ content: {
27765
+ "application/json": components["schemas"]["Error"];
27766
+ };
27767
+ };
27768
+ };
27769
+ };
27770
+ delete?: never;
27771
+ options?: never;
27772
+ head?: never;
27773
+ patch?: never;
27774
+ trace?: never;
27775
+ };
27614
27776
  "/v1/messaging/conversations": {
27615
27777
  parameters: {
27616
27778
  query?: never;
@@ -38895,7 +39057,7 @@ interface paths {
38895
39057
  name: string;
38896
39058
  /** @enum {string} */
38897
39059
  provider: "openai" | "anthropic" | "google" | "xai" | "mixlayer" | "vertex" | "vertex-anthropic" | "bedrock" | "weaviate" | "vectorize" | "browser-rendering" | "tinfoil" | "vercel" | "generic-openai" | "braintrust";
38898
- /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the OpenAI-compatible endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39060
+ /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the custom inference endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
38899
39061
  settings?: {
38900
39062
  [key: string]: unknown;
38901
39063
  };
@@ -39394,7 +39556,7 @@ interface paths {
39394
39556
  isActive?: boolean;
39395
39557
  isDefault?: boolean;
39396
39558
  name?: string;
39397
- /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the OpenAI-compatible endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39559
+ /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the custom inference endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39398
39560
  settings?: {
39399
39561
  [key: string]: unknown;
39400
39562
  };
@@ -46384,13 +46546,13 @@ interface paths {
46384
46546
  };
46385
46547
  };
46386
46548
  };
46387
- /** @description Invalid ID format */
46549
+ /** @description Invalid ID format, or SCHEDULE_AGENT_CONFIG_UNSUPPORTED for an agent a schedule cannot run */
46388
46550
  400: {
46389
46551
  headers: {
46390
46552
  [name: string]: unknown;
46391
46553
  };
46392
46554
  content: {
46393
- "application/json": components["schemas"]["Error"];
46555
+ "application/json": components["schemas"]["ScheduleValidationError"];
46394
46556
  };
46395
46557
  };
46396
46558
  /** @description Unauthorized */
@@ -52750,6 +52912,7 @@ interface components {
52750
52912
  };
52751
52913
  enabled?: boolean;
52752
52914
  id: string;
52915
+ identityAudiences?: string[];
52753
52916
  name?: string;
52754
52917
  timeout?: number;
52755
52918
  /** @enum {string} */
@@ -52950,7 +53113,7 @@ interface components {
52950
53113
  reasons: string[];
52951
53114
  };
52952
53115
  BuiltinToolExecuteResult: {
52953
- /** @description Execution metadata for the caller, never part of a model-facing tool result. builtin:typesafe_judge sets metadata.judgment: requestedModel, resolvedModelId, keySource, questionSetId and questionSetVersion (configured mode), usage { inputTokens, outputTokens, reported }, and estimatedCostUsd (provider rates, before margin). */
53116
+ /** @description Execution metadata for the caller, never part of a model-facing tool result. builtin:typesafe_judge sets metadata.judgment: requestedModel, resolvedModelId (null when not reported), calibrationId (null when absent), keySource, questionSetId and questionSetVersion (configured mode), usage { inputTokens, outputTokens, reported }, and estimatedCostUsd (provider rates, before margin). */
52954
53117
  metadata?: {
52955
53118
  [key: string]: unknown;
52956
53119
  };
@@ -53543,6 +53706,7 @@ interface components {
53543
53706
  };
53544
53707
  enabled?: boolean;
53545
53708
  id: string;
53709
+ identityAudiences?: string[];
53546
53710
  name?: string;
53547
53711
  timeout?: number;
53548
53712
  /** @enum {string} */
@@ -54451,6 +54615,11 @@ interface components {
54451
54615
  iterations?: number;
54452
54616
  /** @enum {string} */
54453
54617
  kind: "agent" | "flow";
54618
+ /**
54619
+ * @description How the execution ended: `completed`, `error`, or `aborted` (cancelled, interrupted, or superseded by the caller or host). Absent on frames from older producers: treat `execution_error` as `error` and `execution_complete` as `completed`, or `error` when `success` is false.
54620
+ * @enum {string}
54621
+ */
54622
+ outcome?: "completed" | "error" | "aborted";
54454
54623
  seq: number;
54455
54624
  stepErrorCount?: number;
54456
54625
  stopReason?: string;
@@ -54480,6 +54649,11 @@ interface components {
54480
54649
  finalOutput?: string;
54481
54650
  /** @enum {string} */
54482
54651
  kind: "agent" | "flow";
54652
+ /**
54653
+ * @description How the execution ended: `completed`, `error`, or `aborted` (cancelled, interrupted, or superseded by the caller or host). Absent on frames from older producers: treat `execution_error` as `error` and `execution_complete` as `completed`, or `error` when `success` is false.
54654
+ * @enum {string}
54655
+ */
54656
+ outcome?: "completed" | "error" | "aborted";
54483
54657
  seq: number;
54484
54658
  stopReason?: string;
54485
54659
  /** @enum {string} */
@@ -56699,6 +56873,10 @@ type ExecutionStreamEvent = components['schemas']['ExecutionStreamEvent'];
56699
56873
  * @deprecated Alias of {@link ExecutionStreamEvent}. Prefer `ExecutionStreamEvent`.
56700
56874
  */
56701
56875
  type DispatchEvent = components['schemas']['ExecutionStreamEvent'];
56876
+ /** How an execution ended, read off the terminal `execution_complete` / `execution_error` frame. */
56877
+ type ExecutionTerminalOutcome = NonNullable<Extract<ExecutionStreamEvent, {
56878
+ type: 'execution_complete';
56879
+ }>['outcome']>;
56702
56880
  /**
56703
56881
  * SDK presentation shape for FlowBuilder callbacks.
56704
56882
  *
@@ -56729,6 +56907,7 @@ type FlowStreamEvent = (LegacyFlowEventBase & {
56729
56907
  success?: boolean;
56730
56908
  finalOutput?: unknown;
56731
56909
  completedAt?: string;
56910
+ outcome?: ExecutionTerminalOutcome;
56732
56911
  }) | (LegacyFlowEventBase & {
56733
56912
  type: 'flow_error';
56734
56913
  flowId?: string;
@@ -56736,6 +56915,7 @@ type FlowStreamEvent = (LegacyFlowEventBase & {
56736
56915
  error?: string | Record<string, unknown> | null;
56737
56916
  code?: string;
56738
56917
  timestamp?: string;
56918
+ outcome?: ExecutionTerminalOutcome;
56739
56919
  }) | (LegacyFlowEventBase & {
56740
56920
  type: 'flow_await';
56741
56921
  flowId?: string;
@@ -59049,6 +59229,8 @@ export interface CustomMCPServer {
59049
59229
  timeout?: number;
59050
59230
  transport?: 'streamable_http' | 'rest';
59051
59231
  enabled?: boolean;
59232
+ /** Hosts a `{{_identity.token}}` may be minted for; hostnames or one-label `*.` wildcards, at most 20. */
59233
+ identityAudiences?: string[];
59052
59234
  }
59053
59235
  export interface ToolsConfig {
59054
59236
  toolIds?: string[];
@@ -65609,7 +65791,9 @@ export interface ApiClient {
65609
65791
  get<T>(path: string, params?: {
65610
65792
  [key: string]: any;
65611
65793
  }): Promise<T>;
65612
- post<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
65794
+ post<T>(path: string, data?: any, headers?: Record<string, string>, options?: {
65795
+ timeoutMs?: number | null;
65796
+ }): Promise<T>;
65613
65797
  put<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
65614
65798
  patch<T>(path: string, data?: any): Promise<T>;
65615
65799
  delete<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
@@ -67035,6 +67219,8 @@ export interface AgentCompleteEvent extends BaseAgentEvent {
67035
67219
  * `sse-parser.ts`.
67036
67220
  */
67037
67221
  externalAgent?: ExternalAgentContext;
67222
+ /** How the run ended: `completed`, `error`, or `aborted`. Absent when an older server omitted it. */
67223
+ outcome?: ExecutionTerminalOutcome;
67038
67224
  }
67039
67225
  /**
67040
67226
  * Agent error event
@@ -68390,6 +68576,11 @@ export declare class LogsEndpoint {
68390
68576
  * Get the trace tree for a single execution.
68391
68577
  */
68392
68578
  traceExecution(executionId: string): Promise<Record<string, unknown>>;
68579
+ /**
68580
+ * Explain one execution from its retained trace, with each claim citing trace entry ids.
68581
+ * Runs a metered, tool-free analysis in the caller's account and never changes the run.
68582
+ */
68583
+ explainRun(executionId: string): Promise<Record<string, unknown>>;
68393
68584
  /**
68394
68585
  * Get the trace tree for a conversation (all executions within it).
68395
68586
  */
@@ -68750,7 +68941,9 @@ export declare class RuntypeClient implements ApiClient {
68750
68941
  /**
68751
68942
  * Generic POST request
68752
68943
  */
68753
- post<T>(path: string, data?: unknown, extraHeaders?: Record<string, string>): Promise<T>;
68944
+ post<T>(path: string, data?: unknown, extraHeaders?: Record<string, string>, options?: {
68945
+ timeoutMs?: number | null;
68946
+ }): Promise<T>;
68754
68947
  /**
68755
68948
  * POST request with FormData support for file uploads
68756
68949
  */
@@ -70182,5 +70375,5 @@ export declare function getLikelySupportingCandidatePaths(bestCandidatePath: str
70182
70375
  export declare function getDefaultPlanPath(taskName: string): string;
70183
70376
  export declare function sanitizeTaskSlug(taskName: string): string;
70184
70377
  //#endregion
70185
- export type { A2AHandlerOptions, A2ARunInput, A2ATextMessage, AIGrader, ActivateAgentAliasInput, ActivateAgentPromotionInput, AgentAlias, AgentAliasActivation, AgentAliasArchiveFailure, AgentAliasArchived, AgentAliasList, AgentAliasTransport, AgentCapabilityChange, AgentCapabilityDeclaration, AgentDefinition, AgentDefinitionConfig, AgentDeploymentList, AgentDeploymentPromotion, AgentDeploymentReceipt, AgentPromotionManifest, AgentPromotionTransport, AgentPromotionValidation, AgentPullResult, AgentSkillBinding, AgentSkillBindingChange, AgentStreamEvent, ApiKeyRequest, ApiKeyRequestDelivery, ApiKeyRequestEnvironment, ApiKeyRequestHandoff, ApiKeyRequestListParams, ApiKeyRequestRequester, ApiKeyRequestStatus, ApplyGeneratedProposalOptions, ApplyGeneratedProposalResult, ArchiveAgentAliasEverywhereResult, ArchiveAgentAliasInput, AttachRuntimeToolsOptions, BatchClient, BatchListParams, BatchOptions, BatchRequest, BatchResult, BatchScheduleConfig, BatchStatus, BindSkillInput, BuiltInGraderId, CaseExpected, CheckGrader, ClaimApiKeyRequestInput, ClaimApiKeyRequestResponse, ClientConversation, ClientToken, ClientTokenConfig, ClientTokenDefinition, ClientTokenEnvironment, ClientTokenVersionPin, ClientWidgetTheme, CollectionPullResult, CollectionSchemaChange, ConditionalGetResult, ConditionalStepConfig, ContextErrorHandling, ContextFallback, CreateApiKeyRequestInput, CreateApiKeyRequestResponse, CreateClientTokenRequest, CreateClientTokenResponse, CreateEvalSuiteInput, CreatePromptData, DecomposeCriteriaResult, DefineAgentInput, DefineEvalCaseInput, DefineEvalInput, DefineFlowInput, DefineProductInput, DefineScheduleInput, DefineSkillInput, DefineSurfaceInput, DefineToolInput, DetachedReattach, DetachedReconnectOptions, DispatchClient, DispatchEvent, DispatchOptions, EnsureAgentConverged, EnsureAgentOptions, EnsureAgentPlan, EnsureAgentResult, EnsureClientTokenConverged, EnsureClientTokenOptions, EnsureClientTokenPlan, EnsureClientTokenResult, EnsureCollectionConverged, EnsureCollectionOptions, EnsureCollectionPlan, EnsureCollectionResult, EnsureEvalApplyOptions, EnsureEvalOptions, EnsureEvalPlan, EnsureEvalResult, EnsureFlowConverged, EnsureFlowOptions, EnsureFlowPlan, EnsureFlowResult, EnsureFpoOptions, EnsureFpoResult, EnsureProductConverged, EnsureProductOptions, EnsureProductPlan, EnsureProductResult, EnsureQuestionSetConverged, EnsureQuestionSetOptions, EnsureQuestionSetPlan, EnsureQuestionSetResult, EnsureScheduleConverged, EnsureScheduleOptions, EnsureSchedulePlan, EnsureScheduleResult, EnsureSkillConverged, EnsureSkillOptions, EnsureSkillPlan, EnsureSkillResult, EnsureSurfaceConverged, EnsureSurfaceOptions, EnsureSurfacePlan, EnsureSurfaceResult, EnsureToolConverged, EnsureToolOptions, EnsureToolPlan, EnsureToolResult, ErrorHandlingMode, EvalAgentSelector, EvalAgentTargetResolution, EvalCaseDefinition, EvalCaseInput, EvalCaseProposal, EvalCaseProposalAccepted, EvalCaseProposalListResult, EvalCasesGenerated, EvalClient, EvalDefinition, EvalListParams, EvalMessage, EvalOptions, EvalProposalSource, EvalProposalStatus, EvalProposedCase, EvalPullResult, EvalRecord, EvalRequest, EvalResult, EvalRunCaseScores, EvalRunConfig, EvalRunEvidence, EvalRunScores, EvalStatus, EvalSuiteCase, EvalSuiteCaseInput, EvalSuiteCoverage, EvalSuiteDetail, EvalSuiteLatestRun, EvalSuiteListResult, EvalSuiteRunQueued, EvalSuiteRunResult, EvalSuiteSummary, EvalTarget, ExecutionStreamEvent, FallbackFailEvent, FallbackStartEvent, FallbackSuccessEvent, FallbackTrigger, FallbackTriggerType, FallbacksExhaustedEvent, FallbacksInitiatedEvent, FetchUrlStepConfig, FieldFormat, FlowCompleteEvent, FlowConfig, FlowDefinition, FlowDefinitionStep, FlowErrorEvent, FlowFallback, FlowInlineEvalInput, FlowPausedEvent, FlowPullResult, FlowStartEvent, FlowStreamEvent, FlowSummary, FlowValidationClient, FlowValidationIssue, FlowValidationResult, FpoEntityOutcome, FpoInput, GenerateEmbeddingStepConfig, GenerateEvalCasesInput, GeneratedRuntimeToolGateDecision, GeneratedRuntimeToolGateOptions, GetApiKeyRequestResponse, GetRecordStepConfig, Gradeable, GraderConfig, GraderOutcome, GraderSeverity, HumanVerdict, ListAgentAliasesOptions, ListAgentDeploymentsOptions, ListConversationsResponse, ListRecordsStepConfig, LoopStepConfig, Message, MessageFallback, ModelFallback, ModelOverride, OrganizationAgentAlias, OrganizationAgentAliasList, PersistedGraderOutcome, PrepareAgentPromotionInput, ProductDefinition, ProductPullResult, PromoteAgentInput, PromoteAgentResult, PromptErrorHandling, PromptFallback, PromptListParams, PromptStepConfig, PullFpoResult, QuestionSetDefinition, QuestionSetPullResult, RecordCollectionDefinition, RecordCollectionValidationMode, RecordConfig, RecordFilter, RecordFilterCondition, RecordFilterGroup, RecordFilterOperator, RetrieveRecordStepConfig, RetryFallback, RollbackAgentAliasInput, RunEvalCaseResult, RunEvalInput, RunEvalResult, RunListParams, RunListResponse, RunListRow, AgentSkillBinding$1 as RuntypeAgentSkillBinding, ConditionalStepConfig$1 as RuntypeConditionalStepConfig, RuntypeConfig, FetchUrlStepConfig$1 as RuntypeFetchUrlStepConfig, FlowConfig$1 as RuntypeFlowConfig, GenerateEmbeddingStepConfig$1 as RuntypeGenerateEmbeddingStepConfig, GetRecordStepConfig$1 as RuntypeGetRecordStepConfig, ListRecordsStepConfig$1 as RuntypeListRecordsStepConfig, LoopStepConfig$1 as RuntypeLoopStepConfig, Message$1 as RuntypeMessage, ModelOverride$1 as RuntypeModelOverride, Prompt$1 as RuntypePrompt, PromptStepConfig$1 as RuntypePromptStepConfig, RecordConfig$1 as RuntypeRecordConfig, RetrieveRecordStepConfig$1 as RuntypeRetrieveRecordStepConfig, SearchStepConfig as RuntypeSearchStepConfig, SendEmailStepConfig as RuntypeSendEmailStepConfig, SendEventStepConfig as RuntypeSendEventStepConfig, SendStreamStepConfig as RuntypeSendStreamStepConfig, SetVariableStepConfig as RuntypeSetVariableStepConfig, Skill as RuntypeSkill, SkillBindingWithAgent as RuntypeSkillBindingWithAgent, SkillCapabilities as RuntypeSkillCapabilities, SkillFrontmatter as RuntypeSkillFrontmatter, SkillManifest as RuntypeSkillManifest, SkillProposal as RuntypeSkillProposal, SkillRuntypeExtensions as RuntypeSkillRuntypeExtensions, SkillVersion as RuntypeSkillVersion, TransformDataStepConfig as RuntypeTransformDataStepConfig, UpsertFlowConfig as RuntypeUpsertFlowConfig, UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, VectorSearchStepConfig as RuntypeVectorSearchStepConfig, WaitUntilStepConfig as RuntypeWaitUntilStepConfig, ScheduleDefinition, ScheduleDefinitionMessage, ScheduleEnsureTransport, SchedulePullResult, SearchStepConfig$1 as SearchStepConfig, SendEmailStepConfig$1 as SendEmailStepConfig, SendEventStepConfig$1 as SendEventStepConfig, SendStreamStepConfig$1 as SendStreamStepConfig, SetVariableStepConfig$1 as SetVariableStepConfig, SkillDefinition, SkillListPage, SkillListPagination, SkillListParams, SkillManifestInput, SkillMarkdownInput, SkillOrigin, SkillProposalStatus, SkillPullResult, SkillStatus, SkillTrustLevel, SkillVersionStatus, SkillWithVersion, SkillWriteInput, StepCompleteEvent, StepDeltaEvent, StepFallback, StepFieldMeta, StepStartEvent, StepWaitingLocalEvent, StreamCallbacks, StreamConsumeOptions, StreamEvent, StreamEventOf, SurfaceDefinition, SurfaceDefinitionStatus, SurfaceDefinitionType, SurfacePullResult, ToolDefinition, ToolDefinitionType, ToolPullResult, TransformDataStepConfig$1 as TransformDataStepConfig, UpdateClientTokenRequest, UpdateEvalCaseInput, UpdateEvalSuiteInput, UpdatePromptData, UpsertFlowConfig$1 as UpsertFlowConfig, UpsertRecordStepConfig$1 as UpsertRecordStepConfig, ValidateAgentPromotionInput, VectorSearchStepConfig$1 as VectorSearchStepConfig, WaitUntilStepConfig$1 as WaitUntilStepConfig, WorkflowCompileDeps, WorkflowCompletionCriteriaConfig, WorkflowConfig, WorkflowConfigFactory, WorkflowHookEntry, WorkflowHookKind, WorkflowHookRef, WorkflowHookSignatures, WorkflowMilestoneConfig, WorkflowPolicyConfig, WorkflowRecoveryConfig, WorkflowSlot };
70378
+ export type { A2AHandlerOptions, A2ARunInput, A2ATextMessage, AIGrader, ActivateAgentAliasInput, ActivateAgentPromotionInput, AgentAlias, AgentAliasActivation, AgentAliasArchiveFailure, AgentAliasArchived, AgentAliasList, AgentAliasTransport, AgentCapabilityChange, AgentCapabilityDeclaration, AgentDefinition, AgentDefinitionConfig, AgentDeploymentList, AgentDeploymentPromotion, AgentDeploymentReceipt, AgentPromotionManifest, AgentPromotionTransport, AgentPromotionValidation, AgentPullResult, AgentSkillBinding, AgentSkillBindingChange, AgentStreamEvent, ApiKeyRequest, ApiKeyRequestDelivery, ApiKeyRequestEnvironment, ApiKeyRequestHandoff, ApiKeyRequestListParams, ApiKeyRequestRequester, ApiKeyRequestStatus, ApplyGeneratedProposalOptions, ApplyGeneratedProposalResult, ArchiveAgentAliasEverywhereResult, ArchiveAgentAliasInput, AttachRuntimeToolsOptions, BatchClient, BatchListParams, BatchOptions, BatchRequest, BatchResult, BatchScheduleConfig, BatchStatus, BindSkillInput, BuiltInGraderId, CaseExpected, CheckGrader, ClaimApiKeyRequestInput, ClaimApiKeyRequestResponse, ClientConversation, ClientToken, ClientTokenConfig, ClientTokenDefinition, ClientTokenEnvironment, ClientTokenVersionPin, ClientWidgetTheme, CollectionPullResult, CollectionSchemaChange, ConditionalGetResult, ConditionalStepConfig, ContextErrorHandling, ContextFallback, CreateApiKeyRequestInput, CreateApiKeyRequestResponse, CreateClientTokenRequest, CreateClientTokenResponse, CreateEvalSuiteInput, CreatePromptData, DecomposeCriteriaResult, DefineAgentInput, DefineEvalCaseInput, DefineEvalInput, DefineFlowInput, DefineProductInput, DefineScheduleInput, DefineSkillInput, DefineSurfaceInput, DefineToolInput, DetachedReattach, DetachedReconnectOptions, DispatchClient, DispatchEvent, DispatchOptions, EnsureAgentConverged, EnsureAgentOptions, EnsureAgentPlan, EnsureAgentResult, EnsureClientTokenConverged, EnsureClientTokenOptions, EnsureClientTokenPlan, EnsureClientTokenResult, EnsureCollectionConverged, EnsureCollectionOptions, EnsureCollectionPlan, EnsureCollectionResult, EnsureEvalApplyOptions, EnsureEvalOptions, EnsureEvalPlan, EnsureEvalResult, EnsureFlowConverged, EnsureFlowOptions, EnsureFlowPlan, EnsureFlowResult, EnsureFpoOptions, EnsureFpoResult, EnsureProductConverged, EnsureProductOptions, EnsureProductPlan, EnsureProductResult, EnsureQuestionSetConverged, EnsureQuestionSetOptions, EnsureQuestionSetPlan, EnsureQuestionSetResult, EnsureScheduleConverged, EnsureScheduleOptions, EnsureSchedulePlan, EnsureScheduleResult, EnsureSkillConverged, EnsureSkillOptions, EnsureSkillPlan, EnsureSkillResult, EnsureSurfaceConverged, EnsureSurfaceOptions, EnsureSurfacePlan, EnsureSurfaceResult, EnsureToolConverged, EnsureToolOptions, EnsureToolPlan, EnsureToolResult, ErrorHandlingMode, EvalAgentSelector, EvalAgentTargetResolution, EvalCaseDefinition, EvalCaseInput, EvalCaseProposal, EvalCaseProposalAccepted, EvalCaseProposalListResult, EvalCasesGenerated, EvalClient, EvalDefinition, EvalListParams, EvalMessage, EvalOptions, EvalProposalSource, EvalProposalStatus, EvalProposedCase, EvalPullResult, EvalRecord, EvalRequest, EvalResult, EvalRunCaseScores, EvalRunConfig, EvalRunEvidence, EvalRunScores, EvalStatus, EvalSuiteCase, EvalSuiteCaseInput, EvalSuiteCoverage, EvalSuiteDetail, EvalSuiteLatestRun, EvalSuiteListResult, EvalSuiteRunQueued, EvalSuiteRunResult, EvalSuiteSummary, EvalTarget, ExecutionStreamEvent, ExecutionTerminalOutcome, FallbackFailEvent, FallbackStartEvent, FallbackSuccessEvent, FallbackTrigger, FallbackTriggerType, FallbacksExhaustedEvent, FallbacksInitiatedEvent, FetchUrlStepConfig, FieldFormat, FlowCompleteEvent, FlowConfig, FlowDefinition, FlowDefinitionStep, FlowErrorEvent, FlowFallback, FlowInlineEvalInput, FlowPausedEvent, FlowPullResult, FlowStartEvent, FlowStreamEvent, FlowSummary, FlowValidationClient, FlowValidationIssue, FlowValidationResult, FpoEntityOutcome, FpoInput, GenerateEmbeddingStepConfig, GenerateEvalCasesInput, GeneratedRuntimeToolGateDecision, GeneratedRuntimeToolGateOptions, GetApiKeyRequestResponse, GetRecordStepConfig, Gradeable, GraderConfig, GraderOutcome, GraderSeverity, HumanVerdict, ListAgentAliasesOptions, ListAgentDeploymentsOptions, ListConversationsResponse, ListRecordsStepConfig, LoopStepConfig, Message, MessageFallback, ModelFallback, ModelOverride, OrganizationAgentAlias, OrganizationAgentAliasList, PersistedGraderOutcome, PrepareAgentPromotionInput, ProductDefinition, ProductPullResult, PromoteAgentInput, PromoteAgentResult, PromptErrorHandling, PromptFallback, PromptListParams, PromptStepConfig, PullFpoResult, QuestionSetDefinition, QuestionSetPullResult, RecordCollectionDefinition, RecordCollectionValidationMode, RecordConfig, RecordFilter, RecordFilterCondition, RecordFilterGroup, RecordFilterOperator, RetrieveRecordStepConfig, RetryFallback, RollbackAgentAliasInput, RunEvalCaseResult, RunEvalInput, RunEvalResult, RunListParams, RunListResponse, RunListRow, AgentSkillBinding$1 as RuntypeAgentSkillBinding, ConditionalStepConfig$1 as RuntypeConditionalStepConfig, RuntypeConfig, FetchUrlStepConfig$1 as RuntypeFetchUrlStepConfig, FlowConfig$1 as RuntypeFlowConfig, GenerateEmbeddingStepConfig$1 as RuntypeGenerateEmbeddingStepConfig, GetRecordStepConfig$1 as RuntypeGetRecordStepConfig, ListRecordsStepConfig$1 as RuntypeListRecordsStepConfig, LoopStepConfig$1 as RuntypeLoopStepConfig, Message$1 as RuntypeMessage, ModelOverride$1 as RuntypeModelOverride, Prompt$1 as RuntypePrompt, PromptStepConfig$1 as RuntypePromptStepConfig, RecordConfig$1 as RuntypeRecordConfig, RetrieveRecordStepConfig$1 as RuntypeRetrieveRecordStepConfig, SearchStepConfig as RuntypeSearchStepConfig, SendEmailStepConfig as RuntypeSendEmailStepConfig, SendEventStepConfig as RuntypeSendEventStepConfig, SendStreamStepConfig as RuntypeSendStreamStepConfig, SetVariableStepConfig as RuntypeSetVariableStepConfig, Skill as RuntypeSkill, SkillBindingWithAgent as RuntypeSkillBindingWithAgent, SkillCapabilities as RuntypeSkillCapabilities, SkillFrontmatter as RuntypeSkillFrontmatter, SkillManifest as RuntypeSkillManifest, SkillProposal as RuntypeSkillProposal, SkillRuntypeExtensions as RuntypeSkillRuntypeExtensions, SkillVersion as RuntypeSkillVersion, TransformDataStepConfig as RuntypeTransformDataStepConfig, UpsertFlowConfig as RuntypeUpsertFlowConfig, UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, VectorSearchStepConfig as RuntypeVectorSearchStepConfig, WaitUntilStepConfig as RuntypeWaitUntilStepConfig, ScheduleDefinition, ScheduleDefinitionMessage, ScheduleEnsureTransport, SchedulePullResult, SearchStepConfig$1 as SearchStepConfig, SendEmailStepConfig$1 as SendEmailStepConfig, SendEventStepConfig$1 as SendEventStepConfig, SendStreamStepConfig$1 as SendStreamStepConfig, SetVariableStepConfig$1 as SetVariableStepConfig, SkillDefinition, SkillListPage, SkillListPagination, SkillListParams, SkillManifestInput, SkillMarkdownInput, SkillOrigin, SkillProposalStatus, SkillPullResult, SkillStatus, SkillTrustLevel, SkillVersionStatus, SkillWithVersion, SkillWriteInput, StepCompleteEvent, StepDeltaEvent, StepFallback, StepFieldMeta, StepStartEvent, StepWaitingLocalEvent, StreamCallbacks, StreamConsumeOptions, StreamEvent, StreamEventOf, SurfaceDefinition, SurfaceDefinitionStatus, SurfaceDefinitionType, SurfacePullResult, ToolDefinition, ToolDefinitionType, ToolPullResult, TransformDataStepConfig$1 as TransformDataStepConfig, UpdateClientTokenRequest, UpdateEvalCaseInput, UpdateEvalSuiteInput, UpdatePromptData, UpsertFlowConfig$1 as UpsertFlowConfig, UpsertRecordStepConfig$1 as UpsertRecordStepConfig, ValidateAgentPromotionInput, VectorSearchStepConfig$1 as VectorSearchStepConfig, WaitUntilStepConfig$1 as WaitUntilStepConfig, WorkflowCompileDeps, WorkflowCompletionCriteriaConfig, WorkflowConfig, WorkflowConfigFactory, WorkflowHookEntry, WorkflowHookKind, WorkflowHookRef, WorkflowHookSignatures, WorkflowMilestoneConfig, WorkflowPolicyConfig, WorkflowRecoveryConfig, WorkflowSlot };
70186
70379
  export {}
package/dist/index.d.ts CHANGED
@@ -1204,6 +1204,7 @@ interface paths {
1204
1204
  };
1205
1205
  enabled?: boolean;
1206
1206
  id: string;
1207
+ identityAudiences?: string[];
1207
1208
  name?: string;
1208
1209
  timeout?: number;
1209
1210
  /** @enum {string} */
@@ -1740,6 +1741,7 @@ interface paths {
1740
1741
  };
1741
1742
  enabled?: boolean;
1742
1743
  id: string;
1744
+ identityAudiences?: string[];
1743
1745
  name?: string;
1744
1746
  timeout?: number;
1745
1747
  /** @enum {string} */
@@ -2565,6 +2567,7 @@ interface paths {
2565
2567
  };
2566
2568
  enabled?: boolean;
2567
2569
  id: string;
2570
+ identityAudiences?: string[];
2568
2571
  name?: string;
2569
2572
  timeout?: number;
2570
2573
  /** @enum {string} */
@@ -3192,6 +3195,8 @@ interface paths {
3192
3195
  };
3193
3196
  content: {
3194
3197
  "application/json": {
3198
+ /** @description Non-blocking advisories, e.g. SCHEDULE_AGENT_CONFIG_UNSUPPORTED when moving `live` makes active schedules unrunnable. */
3199
+ _warnings?: string[];
3195
3200
  alias: string;
3196
3201
  /** @description Per-alias secret binding names in force after this activation. Names only, never values. */
3197
3202
  bindingNames: string[];
@@ -3801,6 +3806,8 @@ interface paths {
3801
3806
  };
3802
3807
  content: {
3803
3808
  "application/json": {
3809
+ /** @description Non-blocking advisories, e.g. SCHEDULE_AGENT_CONFIG_UNSUPPORTED when moving `live` makes active schedules unrunnable. */
3810
+ _warnings?: string[];
3804
3811
  alias: string;
3805
3812
  /** @description Per-alias secret binding names in force after this activation. Names only, never values. */
3806
3813
  bindingNames: string[];
@@ -5878,6 +5885,7 @@ interface paths {
5878
5885
  };
5879
5886
  content: {
5880
5887
  "application/json": {
5888
+ _warnings?: string[];
5881
5889
  message: string;
5882
5890
  publishedVersionId: string;
5883
5891
  success: boolean;
@@ -27611,6 +27619,160 @@ interface paths {
27611
27619
  patch?: never;
27612
27620
  trace?: never;
27613
27621
  };
27622
+ "/v1/logs/trace/execution/{executionId}/explain": {
27623
+ parameters: {
27624
+ query?: never;
27625
+ header?: never;
27626
+ path?: never;
27627
+ cookie?: never;
27628
+ };
27629
+ get?: never;
27630
+ put?: never;
27631
+ /**
27632
+ * Explain a run using retained trace evidence
27633
+ * @description Runs a bounded, tool-free analysis in the caller account. Model usage is metered. Requires ANALYTICS:READ and FLOWS:EXECUTE for API keys. Does not assess business quality or modify the source run.
27634
+ */
27635
+ post: {
27636
+ parameters: {
27637
+ query?: never;
27638
+ header?: never;
27639
+ path: {
27640
+ executionId: string;
27641
+ };
27642
+ cookie?: never;
27643
+ };
27644
+ requestBody?: never;
27645
+ responses: {
27646
+ /** @description Evidence-linked run explanation */
27647
+ 200: {
27648
+ headers: {
27649
+ [name: string]: unknown;
27650
+ };
27651
+ content: {
27652
+ "application/json": {
27653
+ data: {
27654
+ analysis: {
27655
+ hypotheses: {
27656
+ eventIds: string[];
27657
+ text: string;
27658
+ }[];
27659
+ limitations: string[];
27660
+ nextSteps: {
27661
+ eventIds: string[];
27662
+ text: string;
27663
+ }[];
27664
+ observations: {
27665
+ eventIds: string[];
27666
+ text: string;
27667
+ }[];
27668
+ overview: {
27669
+ eventIds: string[];
27670
+ text: string;
27671
+ };
27672
+ };
27673
+ analysisExecutionId: string;
27674
+ analyzerVersion: number;
27675
+ coverageWarnings: string[];
27676
+ evidenceCount: number;
27677
+ executionId: string;
27678
+ generatedAt: string;
27679
+ /** @enum {string} */
27680
+ qualityAssessment: "not_assessed";
27681
+ };
27682
+ /** @enum {boolean} */
27683
+ success: true;
27684
+ };
27685
+ };
27686
+ };
27687
+ /** @description Invalid execution ID */
27688
+ 400: {
27689
+ headers: {
27690
+ [name: string]: unknown;
27691
+ };
27692
+ content: {
27693
+ "application/json": components["schemas"]["Error"];
27694
+ };
27695
+ };
27696
+ /** @description Unauthorized */
27697
+ 401: {
27698
+ headers: {
27699
+ [name: string]: unknown;
27700
+ };
27701
+ content: {
27702
+ "application/json": components["schemas"]["Error"];
27703
+ };
27704
+ };
27705
+ /** @description Execution spend limit reached */
27706
+ 402: {
27707
+ headers: {
27708
+ [name: string]: unknown;
27709
+ };
27710
+ content: {
27711
+ "application/json": components["schemas"]["Error"];
27712
+ };
27713
+ };
27714
+ /** @description Required permission or account verification missing */
27715
+ 403: {
27716
+ headers: {
27717
+ [name: string]: unknown;
27718
+ };
27719
+ content: {
27720
+ "application/json": components["schemas"]["Error"];
27721
+ };
27722
+ };
27723
+ /** @description No retained trace evidence */
27724
+ 404: {
27725
+ headers: {
27726
+ [name: string]: unknown;
27727
+ };
27728
+ content: {
27729
+ "application/json": components["schemas"]["Error"];
27730
+ };
27731
+ };
27732
+ /** @description Request cancelled */
27733
+ 408: {
27734
+ headers: {
27735
+ [name: string]: unknown;
27736
+ };
27737
+ content: {
27738
+ "application/json": components["schemas"]["Error"];
27739
+ };
27740
+ };
27741
+ /** @description Execution rate limit reached */
27742
+ 429: {
27743
+ headers: {
27744
+ [name: string]: unknown;
27745
+ };
27746
+ content: {
27747
+ "application/json": components["schemas"]["Error"];
27748
+ };
27749
+ };
27750
+ /** @description Analysis failed or invalid evidence citations */
27751
+ 502: {
27752
+ headers: {
27753
+ [name: string]: unknown;
27754
+ };
27755
+ content: {
27756
+ "application/json": components["schemas"]["Error"];
27757
+ };
27758
+ };
27759
+ /** @description Trace service unavailable */
27760
+ 503: {
27761
+ headers: {
27762
+ [name: string]: unknown;
27763
+ };
27764
+ content: {
27765
+ "application/json": components["schemas"]["Error"];
27766
+ };
27767
+ };
27768
+ };
27769
+ };
27770
+ delete?: never;
27771
+ options?: never;
27772
+ head?: never;
27773
+ patch?: never;
27774
+ trace?: never;
27775
+ };
27614
27776
  "/v1/messaging/conversations": {
27615
27777
  parameters: {
27616
27778
  query?: never;
@@ -38895,7 +39057,7 @@ interface paths {
38895
39057
  name: string;
38896
39058
  /** @enum {string} */
38897
39059
  provider: "openai" | "anthropic" | "google" | "xai" | "mixlayer" | "vertex" | "vertex-anthropic" | "bedrock" | "weaviate" | "vectorize" | "browser-rendering" | "tinfoil" | "vercel" | "generic-openai" | "braintrust";
38898
- /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the OpenAI-compatible endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39060
+ /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the custom inference endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
38899
39061
  settings?: {
38900
39062
  [key: string]: unknown;
38901
39063
  };
@@ -39394,7 +39556,7 @@ interface paths {
39394
39556
  isActive?: boolean;
39395
39557
  isDefault?: boolean;
39396
39558
  name?: string;
39397
- /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the OpenAI-compatible endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39559
+ /** @description Provider-specific settings. For generic-openai: baseUrl, and apiFormat. Wire format of the custom inference endpoint: "chat-completions" (default) posts to {baseUrl}/chat/completions, "responses" posts to {baseUrl}/responses. */
39398
39560
  settings?: {
39399
39561
  [key: string]: unknown;
39400
39562
  };
@@ -46384,13 +46546,13 @@ interface paths {
46384
46546
  };
46385
46547
  };
46386
46548
  };
46387
- /** @description Invalid ID format */
46549
+ /** @description Invalid ID format, or SCHEDULE_AGENT_CONFIG_UNSUPPORTED for an agent a schedule cannot run */
46388
46550
  400: {
46389
46551
  headers: {
46390
46552
  [name: string]: unknown;
46391
46553
  };
46392
46554
  content: {
46393
- "application/json": components["schemas"]["Error"];
46555
+ "application/json": components["schemas"]["ScheduleValidationError"];
46394
46556
  };
46395
46557
  };
46396
46558
  /** @description Unauthorized */
@@ -52750,6 +52912,7 @@ interface components {
52750
52912
  };
52751
52913
  enabled?: boolean;
52752
52914
  id: string;
52915
+ identityAudiences?: string[];
52753
52916
  name?: string;
52754
52917
  timeout?: number;
52755
52918
  /** @enum {string} */
@@ -52950,7 +53113,7 @@ interface components {
52950
53113
  reasons: string[];
52951
53114
  };
52952
53115
  BuiltinToolExecuteResult: {
52953
- /** @description Execution metadata for the caller, never part of a model-facing tool result. builtin:typesafe_judge sets metadata.judgment: requestedModel, resolvedModelId, keySource, questionSetId and questionSetVersion (configured mode), usage { inputTokens, outputTokens, reported }, and estimatedCostUsd (provider rates, before margin). */
53116
+ /** @description Execution metadata for the caller, never part of a model-facing tool result. builtin:typesafe_judge sets metadata.judgment: requestedModel, resolvedModelId (null when not reported), calibrationId (null when absent), keySource, questionSetId and questionSetVersion (configured mode), usage { inputTokens, outputTokens, reported }, and estimatedCostUsd (provider rates, before margin). */
52954
53117
  metadata?: {
52955
53118
  [key: string]: unknown;
52956
53119
  };
@@ -53543,6 +53706,7 @@ interface components {
53543
53706
  };
53544
53707
  enabled?: boolean;
53545
53708
  id: string;
53709
+ identityAudiences?: string[];
53546
53710
  name?: string;
53547
53711
  timeout?: number;
53548
53712
  /** @enum {string} */
@@ -54451,6 +54615,11 @@ interface components {
54451
54615
  iterations?: number;
54452
54616
  /** @enum {string} */
54453
54617
  kind: "agent" | "flow";
54618
+ /**
54619
+ * @description How the execution ended: `completed`, `error`, or `aborted` (cancelled, interrupted, or superseded by the caller or host). Absent on frames from older producers: treat `execution_error` as `error` and `execution_complete` as `completed`, or `error` when `success` is false.
54620
+ * @enum {string}
54621
+ */
54622
+ outcome?: "completed" | "error" | "aborted";
54454
54623
  seq: number;
54455
54624
  stepErrorCount?: number;
54456
54625
  stopReason?: string;
@@ -54480,6 +54649,11 @@ interface components {
54480
54649
  finalOutput?: string;
54481
54650
  /** @enum {string} */
54482
54651
  kind: "agent" | "flow";
54652
+ /**
54653
+ * @description How the execution ended: `completed`, `error`, or `aborted` (cancelled, interrupted, or superseded by the caller or host). Absent on frames from older producers: treat `execution_error` as `error` and `execution_complete` as `completed`, or `error` when `success` is false.
54654
+ * @enum {string}
54655
+ */
54656
+ outcome?: "completed" | "error" | "aborted";
54483
54657
  seq: number;
54484
54658
  stopReason?: string;
54485
54659
  /** @enum {string} */
@@ -56699,6 +56873,10 @@ type ExecutionStreamEvent = components['schemas']['ExecutionStreamEvent'];
56699
56873
  * @deprecated Alias of {@link ExecutionStreamEvent}. Prefer `ExecutionStreamEvent`.
56700
56874
  */
56701
56875
  type DispatchEvent = components['schemas']['ExecutionStreamEvent'];
56876
+ /** How an execution ended, read off the terminal `execution_complete` / `execution_error` frame. */
56877
+ type ExecutionTerminalOutcome = NonNullable<Extract<ExecutionStreamEvent, {
56878
+ type: 'execution_complete';
56879
+ }>['outcome']>;
56702
56880
  /**
56703
56881
  * SDK presentation shape for FlowBuilder callbacks.
56704
56882
  *
@@ -56729,6 +56907,7 @@ type FlowStreamEvent = (LegacyFlowEventBase & {
56729
56907
  success?: boolean;
56730
56908
  finalOutput?: unknown;
56731
56909
  completedAt?: string;
56910
+ outcome?: ExecutionTerminalOutcome;
56732
56911
  }) | (LegacyFlowEventBase & {
56733
56912
  type: 'flow_error';
56734
56913
  flowId?: string;
@@ -56736,6 +56915,7 @@ type FlowStreamEvent = (LegacyFlowEventBase & {
56736
56915
  error?: string | Record<string, unknown> | null;
56737
56916
  code?: string;
56738
56917
  timestamp?: string;
56918
+ outcome?: ExecutionTerminalOutcome;
56739
56919
  }) | (LegacyFlowEventBase & {
56740
56920
  type: 'flow_await';
56741
56921
  flowId?: string;
@@ -59049,6 +59229,8 @@ export interface CustomMCPServer {
59049
59229
  timeout?: number;
59050
59230
  transport?: 'streamable_http' | 'rest';
59051
59231
  enabled?: boolean;
59232
+ /** Hosts a `{{_identity.token}}` may be minted for; hostnames or one-label `*.` wildcards, at most 20. */
59233
+ identityAudiences?: string[];
59052
59234
  }
59053
59235
  export interface ToolsConfig {
59054
59236
  toolIds?: string[];
@@ -65609,7 +65791,9 @@ export interface ApiClient {
65609
65791
  get<T>(path: string, params?: {
65610
65792
  [key: string]: any;
65611
65793
  }): Promise<T>;
65612
- post<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
65794
+ post<T>(path: string, data?: any, headers?: Record<string, string>, options?: {
65795
+ timeoutMs?: number | null;
65796
+ }): Promise<T>;
65613
65797
  put<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
65614
65798
  patch<T>(path: string, data?: any): Promise<T>;
65615
65799
  delete<T>(path: string, data?: any, headers?: Record<string, string>): Promise<T>;
@@ -67035,6 +67219,8 @@ export interface AgentCompleteEvent extends BaseAgentEvent {
67035
67219
  * `sse-parser.ts`.
67036
67220
  */
67037
67221
  externalAgent?: ExternalAgentContext;
67222
+ /** How the run ended: `completed`, `error`, or `aborted`. Absent when an older server omitted it. */
67223
+ outcome?: ExecutionTerminalOutcome;
67038
67224
  }
67039
67225
  /**
67040
67226
  * Agent error event
@@ -68390,6 +68576,11 @@ export declare class LogsEndpoint {
68390
68576
  * Get the trace tree for a single execution.
68391
68577
  */
68392
68578
  traceExecution(executionId: string): Promise<Record<string, unknown>>;
68579
+ /**
68580
+ * Explain one execution from its retained trace, with each claim citing trace entry ids.
68581
+ * Runs a metered, tool-free analysis in the caller's account and never changes the run.
68582
+ */
68583
+ explainRun(executionId: string): Promise<Record<string, unknown>>;
68393
68584
  /**
68394
68585
  * Get the trace tree for a conversation (all executions within it).
68395
68586
  */
@@ -68750,7 +68941,9 @@ export declare class RuntypeClient implements ApiClient {
68750
68941
  /**
68751
68942
  * Generic POST request
68752
68943
  */
68753
- post<T>(path: string, data?: unknown, extraHeaders?: Record<string, string>): Promise<T>;
68944
+ post<T>(path: string, data?: unknown, extraHeaders?: Record<string, string>, options?: {
68945
+ timeoutMs?: number | null;
68946
+ }): Promise<T>;
68754
68947
  /**
68755
68948
  * POST request with FormData support for file uploads
68756
68949
  */
@@ -70182,5 +70375,5 @@ export declare function getLikelySupportingCandidatePaths(bestCandidatePath: str
70182
70375
  export declare function getDefaultPlanPath(taskName: string): string;
70183
70376
  export declare function sanitizeTaskSlug(taskName: string): string;
70184
70377
  //#endregion
70185
- export type { A2AHandlerOptions, A2ARunInput, A2ATextMessage, AIGrader, ActivateAgentAliasInput, ActivateAgentPromotionInput, AgentAlias, AgentAliasActivation, AgentAliasArchiveFailure, AgentAliasArchived, AgentAliasList, AgentAliasTransport, AgentCapabilityChange, AgentCapabilityDeclaration, AgentDefinition, AgentDefinitionConfig, AgentDeploymentList, AgentDeploymentPromotion, AgentDeploymentReceipt, AgentPromotionManifest, AgentPromotionTransport, AgentPromotionValidation, AgentPullResult, AgentSkillBinding, AgentSkillBindingChange, AgentStreamEvent, ApiKeyRequest, ApiKeyRequestDelivery, ApiKeyRequestEnvironment, ApiKeyRequestHandoff, ApiKeyRequestListParams, ApiKeyRequestRequester, ApiKeyRequestStatus, ApplyGeneratedProposalOptions, ApplyGeneratedProposalResult, ArchiveAgentAliasEverywhereResult, ArchiveAgentAliasInput, AttachRuntimeToolsOptions, BatchClient, BatchListParams, BatchOptions, BatchRequest, BatchResult, BatchScheduleConfig, BatchStatus, BindSkillInput, BuiltInGraderId, CaseExpected, CheckGrader, ClaimApiKeyRequestInput, ClaimApiKeyRequestResponse, ClientConversation, ClientToken, ClientTokenConfig, ClientTokenDefinition, ClientTokenEnvironment, ClientTokenVersionPin, ClientWidgetTheme, CollectionPullResult, CollectionSchemaChange, ConditionalGetResult, ConditionalStepConfig, ContextErrorHandling, ContextFallback, CreateApiKeyRequestInput, CreateApiKeyRequestResponse, CreateClientTokenRequest, CreateClientTokenResponse, CreateEvalSuiteInput, CreatePromptData, DecomposeCriteriaResult, DefineAgentInput, DefineEvalCaseInput, DefineEvalInput, DefineFlowInput, DefineProductInput, DefineScheduleInput, DefineSkillInput, DefineSurfaceInput, DefineToolInput, DetachedReattach, DetachedReconnectOptions, DispatchClient, DispatchEvent, DispatchOptions, EnsureAgentConverged, EnsureAgentOptions, EnsureAgentPlan, EnsureAgentResult, EnsureClientTokenConverged, EnsureClientTokenOptions, EnsureClientTokenPlan, EnsureClientTokenResult, EnsureCollectionConverged, EnsureCollectionOptions, EnsureCollectionPlan, EnsureCollectionResult, EnsureEvalApplyOptions, EnsureEvalOptions, EnsureEvalPlan, EnsureEvalResult, EnsureFlowConverged, EnsureFlowOptions, EnsureFlowPlan, EnsureFlowResult, EnsureFpoOptions, EnsureFpoResult, EnsureProductConverged, EnsureProductOptions, EnsureProductPlan, EnsureProductResult, EnsureQuestionSetConverged, EnsureQuestionSetOptions, EnsureQuestionSetPlan, EnsureQuestionSetResult, EnsureScheduleConverged, EnsureScheduleOptions, EnsureSchedulePlan, EnsureScheduleResult, EnsureSkillConverged, EnsureSkillOptions, EnsureSkillPlan, EnsureSkillResult, EnsureSurfaceConverged, EnsureSurfaceOptions, EnsureSurfacePlan, EnsureSurfaceResult, EnsureToolConverged, EnsureToolOptions, EnsureToolPlan, EnsureToolResult, ErrorHandlingMode, EvalAgentSelector, EvalAgentTargetResolution, EvalCaseDefinition, EvalCaseInput, EvalCaseProposal, EvalCaseProposalAccepted, EvalCaseProposalListResult, EvalCasesGenerated, EvalClient, EvalDefinition, EvalListParams, EvalMessage, EvalOptions, EvalProposalSource, EvalProposalStatus, EvalProposedCase, EvalPullResult, EvalRecord, EvalRequest, EvalResult, EvalRunCaseScores, EvalRunConfig, EvalRunEvidence, EvalRunScores, EvalStatus, EvalSuiteCase, EvalSuiteCaseInput, EvalSuiteCoverage, EvalSuiteDetail, EvalSuiteLatestRun, EvalSuiteListResult, EvalSuiteRunQueued, EvalSuiteRunResult, EvalSuiteSummary, EvalTarget, ExecutionStreamEvent, FallbackFailEvent, FallbackStartEvent, FallbackSuccessEvent, FallbackTrigger, FallbackTriggerType, FallbacksExhaustedEvent, FallbacksInitiatedEvent, FetchUrlStepConfig, FieldFormat, FlowCompleteEvent, FlowConfig, FlowDefinition, FlowDefinitionStep, FlowErrorEvent, FlowFallback, FlowInlineEvalInput, FlowPausedEvent, FlowPullResult, FlowStartEvent, FlowStreamEvent, FlowSummary, FlowValidationClient, FlowValidationIssue, FlowValidationResult, FpoEntityOutcome, FpoInput, GenerateEmbeddingStepConfig, GenerateEvalCasesInput, GeneratedRuntimeToolGateDecision, GeneratedRuntimeToolGateOptions, GetApiKeyRequestResponse, GetRecordStepConfig, Gradeable, GraderConfig, GraderOutcome, GraderSeverity, HumanVerdict, ListAgentAliasesOptions, ListAgentDeploymentsOptions, ListConversationsResponse, ListRecordsStepConfig, LoopStepConfig, Message, MessageFallback, ModelFallback, ModelOverride, OrganizationAgentAlias, OrganizationAgentAliasList, PersistedGraderOutcome, PrepareAgentPromotionInput, ProductDefinition, ProductPullResult, PromoteAgentInput, PromoteAgentResult, PromptErrorHandling, PromptFallback, PromptListParams, PromptStepConfig, PullFpoResult, QuestionSetDefinition, QuestionSetPullResult, RecordCollectionDefinition, RecordCollectionValidationMode, RecordConfig, RecordFilter, RecordFilterCondition, RecordFilterGroup, RecordFilterOperator, RetrieveRecordStepConfig, RetryFallback, RollbackAgentAliasInput, RunEvalCaseResult, RunEvalInput, RunEvalResult, RunListParams, RunListResponse, RunListRow, AgentSkillBinding$1 as RuntypeAgentSkillBinding, ConditionalStepConfig$1 as RuntypeConditionalStepConfig, RuntypeConfig, FetchUrlStepConfig$1 as RuntypeFetchUrlStepConfig, FlowConfig$1 as RuntypeFlowConfig, GenerateEmbeddingStepConfig$1 as RuntypeGenerateEmbeddingStepConfig, GetRecordStepConfig$1 as RuntypeGetRecordStepConfig, ListRecordsStepConfig$1 as RuntypeListRecordsStepConfig, LoopStepConfig$1 as RuntypeLoopStepConfig, Message$1 as RuntypeMessage, ModelOverride$1 as RuntypeModelOverride, Prompt$1 as RuntypePrompt, PromptStepConfig$1 as RuntypePromptStepConfig, RecordConfig$1 as RuntypeRecordConfig, RetrieveRecordStepConfig$1 as RuntypeRetrieveRecordStepConfig, SearchStepConfig as RuntypeSearchStepConfig, SendEmailStepConfig as RuntypeSendEmailStepConfig, SendEventStepConfig as RuntypeSendEventStepConfig, SendStreamStepConfig as RuntypeSendStreamStepConfig, SetVariableStepConfig as RuntypeSetVariableStepConfig, Skill as RuntypeSkill, SkillBindingWithAgent as RuntypeSkillBindingWithAgent, SkillCapabilities as RuntypeSkillCapabilities, SkillFrontmatter as RuntypeSkillFrontmatter, SkillManifest as RuntypeSkillManifest, SkillProposal as RuntypeSkillProposal, SkillRuntypeExtensions as RuntypeSkillRuntypeExtensions, SkillVersion as RuntypeSkillVersion, TransformDataStepConfig as RuntypeTransformDataStepConfig, UpsertFlowConfig as RuntypeUpsertFlowConfig, UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, VectorSearchStepConfig as RuntypeVectorSearchStepConfig, WaitUntilStepConfig as RuntypeWaitUntilStepConfig, ScheduleDefinition, ScheduleDefinitionMessage, ScheduleEnsureTransport, SchedulePullResult, SearchStepConfig$1 as SearchStepConfig, SendEmailStepConfig$1 as SendEmailStepConfig, SendEventStepConfig$1 as SendEventStepConfig, SendStreamStepConfig$1 as SendStreamStepConfig, SetVariableStepConfig$1 as SetVariableStepConfig, SkillDefinition, SkillListPage, SkillListPagination, SkillListParams, SkillManifestInput, SkillMarkdownInput, SkillOrigin, SkillProposalStatus, SkillPullResult, SkillStatus, SkillTrustLevel, SkillVersionStatus, SkillWithVersion, SkillWriteInput, StepCompleteEvent, StepDeltaEvent, StepFallback, StepFieldMeta, StepStartEvent, StepWaitingLocalEvent, StreamCallbacks, StreamConsumeOptions, StreamEvent, StreamEventOf, SurfaceDefinition, SurfaceDefinitionStatus, SurfaceDefinitionType, SurfacePullResult, ToolDefinition, ToolDefinitionType, ToolPullResult, TransformDataStepConfig$1 as TransformDataStepConfig, UpdateClientTokenRequest, UpdateEvalCaseInput, UpdateEvalSuiteInput, UpdatePromptData, UpsertFlowConfig$1 as UpsertFlowConfig, UpsertRecordStepConfig$1 as UpsertRecordStepConfig, ValidateAgentPromotionInput, VectorSearchStepConfig$1 as VectorSearchStepConfig, WaitUntilStepConfig$1 as WaitUntilStepConfig, WorkflowCompileDeps, WorkflowCompletionCriteriaConfig, WorkflowConfig, WorkflowConfigFactory, WorkflowHookEntry, WorkflowHookKind, WorkflowHookRef, WorkflowHookSignatures, WorkflowMilestoneConfig, WorkflowPolicyConfig, WorkflowRecoveryConfig, WorkflowSlot };
70378
+ export type { A2AHandlerOptions, A2ARunInput, A2ATextMessage, AIGrader, ActivateAgentAliasInput, ActivateAgentPromotionInput, AgentAlias, AgentAliasActivation, AgentAliasArchiveFailure, AgentAliasArchived, AgentAliasList, AgentAliasTransport, AgentCapabilityChange, AgentCapabilityDeclaration, AgentDefinition, AgentDefinitionConfig, AgentDeploymentList, AgentDeploymentPromotion, AgentDeploymentReceipt, AgentPromotionManifest, AgentPromotionTransport, AgentPromotionValidation, AgentPullResult, AgentSkillBinding, AgentSkillBindingChange, AgentStreamEvent, ApiKeyRequest, ApiKeyRequestDelivery, ApiKeyRequestEnvironment, ApiKeyRequestHandoff, ApiKeyRequestListParams, ApiKeyRequestRequester, ApiKeyRequestStatus, ApplyGeneratedProposalOptions, ApplyGeneratedProposalResult, ArchiveAgentAliasEverywhereResult, ArchiveAgentAliasInput, AttachRuntimeToolsOptions, BatchClient, BatchListParams, BatchOptions, BatchRequest, BatchResult, BatchScheduleConfig, BatchStatus, BindSkillInput, BuiltInGraderId, CaseExpected, CheckGrader, ClaimApiKeyRequestInput, ClaimApiKeyRequestResponse, ClientConversation, ClientToken, ClientTokenConfig, ClientTokenDefinition, ClientTokenEnvironment, ClientTokenVersionPin, ClientWidgetTheme, CollectionPullResult, CollectionSchemaChange, ConditionalGetResult, ConditionalStepConfig, ContextErrorHandling, ContextFallback, CreateApiKeyRequestInput, CreateApiKeyRequestResponse, CreateClientTokenRequest, CreateClientTokenResponse, CreateEvalSuiteInput, CreatePromptData, DecomposeCriteriaResult, DefineAgentInput, DefineEvalCaseInput, DefineEvalInput, DefineFlowInput, DefineProductInput, DefineScheduleInput, DefineSkillInput, DefineSurfaceInput, DefineToolInput, DetachedReattach, DetachedReconnectOptions, DispatchClient, DispatchEvent, DispatchOptions, EnsureAgentConverged, EnsureAgentOptions, EnsureAgentPlan, EnsureAgentResult, EnsureClientTokenConverged, EnsureClientTokenOptions, EnsureClientTokenPlan, EnsureClientTokenResult, EnsureCollectionConverged, EnsureCollectionOptions, EnsureCollectionPlan, EnsureCollectionResult, EnsureEvalApplyOptions, EnsureEvalOptions, EnsureEvalPlan, EnsureEvalResult, EnsureFlowConverged, EnsureFlowOptions, EnsureFlowPlan, EnsureFlowResult, EnsureFpoOptions, EnsureFpoResult, EnsureProductConverged, EnsureProductOptions, EnsureProductPlan, EnsureProductResult, EnsureQuestionSetConverged, EnsureQuestionSetOptions, EnsureQuestionSetPlan, EnsureQuestionSetResult, EnsureScheduleConverged, EnsureScheduleOptions, EnsureSchedulePlan, EnsureScheduleResult, EnsureSkillConverged, EnsureSkillOptions, EnsureSkillPlan, EnsureSkillResult, EnsureSurfaceConverged, EnsureSurfaceOptions, EnsureSurfacePlan, EnsureSurfaceResult, EnsureToolConverged, EnsureToolOptions, EnsureToolPlan, EnsureToolResult, ErrorHandlingMode, EvalAgentSelector, EvalAgentTargetResolution, EvalCaseDefinition, EvalCaseInput, EvalCaseProposal, EvalCaseProposalAccepted, EvalCaseProposalListResult, EvalCasesGenerated, EvalClient, EvalDefinition, EvalListParams, EvalMessage, EvalOptions, EvalProposalSource, EvalProposalStatus, EvalProposedCase, EvalPullResult, EvalRecord, EvalRequest, EvalResult, EvalRunCaseScores, EvalRunConfig, EvalRunEvidence, EvalRunScores, EvalStatus, EvalSuiteCase, EvalSuiteCaseInput, EvalSuiteCoverage, EvalSuiteDetail, EvalSuiteLatestRun, EvalSuiteListResult, EvalSuiteRunQueued, EvalSuiteRunResult, EvalSuiteSummary, EvalTarget, ExecutionStreamEvent, ExecutionTerminalOutcome, FallbackFailEvent, FallbackStartEvent, FallbackSuccessEvent, FallbackTrigger, FallbackTriggerType, FallbacksExhaustedEvent, FallbacksInitiatedEvent, FetchUrlStepConfig, FieldFormat, FlowCompleteEvent, FlowConfig, FlowDefinition, FlowDefinitionStep, FlowErrorEvent, FlowFallback, FlowInlineEvalInput, FlowPausedEvent, FlowPullResult, FlowStartEvent, FlowStreamEvent, FlowSummary, FlowValidationClient, FlowValidationIssue, FlowValidationResult, FpoEntityOutcome, FpoInput, GenerateEmbeddingStepConfig, GenerateEvalCasesInput, GeneratedRuntimeToolGateDecision, GeneratedRuntimeToolGateOptions, GetApiKeyRequestResponse, GetRecordStepConfig, Gradeable, GraderConfig, GraderOutcome, GraderSeverity, HumanVerdict, ListAgentAliasesOptions, ListAgentDeploymentsOptions, ListConversationsResponse, ListRecordsStepConfig, LoopStepConfig, Message, MessageFallback, ModelFallback, ModelOverride, OrganizationAgentAlias, OrganizationAgentAliasList, PersistedGraderOutcome, PrepareAgentPromotionInput, ProductDefinition, ProductPullResult, PromoteAgentInput, PromoteAgentResult, PromptErrorHandling, PromptFallback, PromptListParams, PromptStepConfig, PullFpoResult, QuestionSetDefinition, QuestionSetPullResult, RecordCollectionDefinition, RecordCollectionValidationMode, RecordConfig, RecordFilter, RecordFilterCondition, RecordFilterGroup, RecordFilterOperator, RetrieveRecordStepConfig, RetryFallback, RollbackAgentAliasInput, RunEvalCaseResult, RunEvalInput, RunEvalResult, RunListParams, RunListResponse, RunListRow, AgentSkillBinding$1 as RuntypeAgentSkillBinding, ConditionalStepConfig$1 as RuntypeConditionalStepConfig, RuntypeConfig, FetchUrlStepConfig$1 as RuntypeFetchUrlStepConfig, FlowConfig$1 as RuntypeFlowConfig, GenerateEmbeddingStepConfig$1 as RuntypeGenerateEmbeddingStepConfig, GetRecordStepConfig$1 as RuntypeGetRecordStepConfig, ListRecordsStepConfig$1 as RuntypeListRecordsStepConfig, LoopStepConfig$1 as RuntypeLoopStepConfig, Message$1 as RuntypeMessage, ModelOverride$1 as RuntypeModelOverride, Prompt$1 as RuntypePrompt, PromptStepConfig$1 as RuntypePromptStepConfig, RecordConfig$1 as RuntypeRecordConfig, RetrieveRecordStepConfig$1 as RuntypeRetrieveRecordStepConfig, SearchStepConfig as RuntypeSearchStepConfig, SendEmailStepConfig as RuntypeSendEmailStepConfig, SendEventStepConfig as RuntypeSendEventStepConfig, SendStreamStepConfig as RuntypeSendStreamStepConfig, SetVariableStepConfig as RuntypeSetVariableStepConfig, Skill as RuntypeSkill, SkillBindingWithAgent as RuntypeSkillBindingWithAgent, SkillCapabilities as RuntypeSkillCapabilities, SkillFrontmatter as RuntypeSkillFrontmatter, SkillManifest as RuntypeSkillManifest, SkillProposal as RuntypeSkillProposal, SkillRuntypeExtensions as RuntypeSkillRuntypeExtensions, SkillVersion as RuntypeSkillVersion, TransformDataStepConfig as RuntypeTransformDataStepConfig, UpsertFlowConfig as RuntypeUpsertFlowConfig, UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, VectorSearchStepConfig as RuntypeVectorSearchStepConfig, WaitUntilStepConfig as RuntypeWaitUntilStepConfig, ScheduleDefinition, ScheduleDefinitionMessage, ScheduleEnsureTransport, SchedulePullResult, SearchStepConfig$1 as SearchStepConfig, SendEmailStepConfig$1 as SendEmailStepConfig, SendEventStepConfig$1 as SendEventStepConfig, SendStreamStepConfig$1 as SendStreamStepConfig, SetVariableStepConfig$1 as SetVariableStepConfig, SkillDefinition, SkillListPage, SkillListPagination, SkillListParams, SkillManifestInput, SkillMarkdownInput, SkillOrigin, SkillProposalStatus, SkillPullResult, SkillStatus, SkillTrustLevel, SkillVersionStatus, SkillWithVersion, SkillWriteInput, StepCompleteEvent, StepDeltaEvent, StepFallback, StepFieldMeta, StepStartEvent, StepWaitingLocalEvent, StreamCallbacks, StreamConsumeOptions, StreamEvent, StreamEventOf, SurfaceDefinition, SurfaceDefinitionStatus, SurfaceDefinitionType, SurfacePullResult, ToolDefinition, ToolDefinitionType, ToolPullResult, TransformDataStepConfig$1 as TransformDataStepConfig, UpdateClientTokenRequest, UpdateEvalCaseInput, UpdateEvalSuiteInput, UpdatePromptData, UpsertFlowConfig$1 as UpsertFlowConfig, UpsertRecordStepConfig$1 as UpsertRecordStepConfig, ValidateAgentPromotionInput, VectorSearchStepConfig$1 as VectorSearchStepConfig, WaitUntilStepConfig$1 as WaitUntilStepConfig, WorkflowCompileDeps, WorkflowCompletionCriteriaConfig, WorkflowConfig, WorkflowConfigFactory, WorkflowHookEntry, WorkflowHookKind, WorkflowHookRef, WorkflowHookSignatures, WorkflowMilestoneConfig, WorkflowPolicyConfig, WorkflowRecoveryConfig, WorkflowSlot };
70186
70379
  export {}
package/dist/index.mjs CHANGED
@@ -172,7 +172,8 @@ function createFlowEventTranslator() {
172
172
  failedSteps: data.failedSteps,
173
173
  executionTime: data.durationMs,
174
174
  finalOutput: data.finalOutput,
175
- completedAt: data.completedAt
175
+ completedAt: data.completedAt,
176
+ outcome: data.outcome
176
177
  })];
177
178
  case "execution_error": return [compact({
178
179
  type: "flow_error",
@@ -181,7 +182,8 @@ function createFlowEventTranslator() {
181
182
  error: data.error,
182
183
  code: data.code,
183
184
  upgradeUrl: data.upgradeUrl,
184
- blockReason: data.blockReason
185
+ blockReason: data.blockReason,
186
+ outcome: data.outcome
185
187
  })];
186
188
  case "await":
187
189
  if (data.awaitReason === "detached") return [];
@@ -437,7 +439,8 @@ function createAgentEventTranslator() {
437
439
  totalTokens: data.totalTokens,
438
440
  finalOutput: data.finalOutput,
439
441
  duration: data.durationMs,
440
- externalAgent: data.externalAgent
442
+ externalAgent: data.externalAgent,
443
+ outcome: data.outcome
441
444
  })];
442
445
  case "execution_error":
443
446
  if (data.kind !== "agent") return [];
@@ -449,7 +452,8 @@ function createAgentEventTranslator() {
449
452
  success: false,
450
453
  stopReason: data.stopReason ?? "error",
451
454
  error: errorMessage(data.error),
452
- completedAt: data.completedAt
455
+ completedAt: data.completedAt,
456
+ outcome: data.outcome
453
457
  })];
454
458
  case "error": return [compact({
455
459
  type: "agent_error",
@@ -8738,6 +8742,13 @@ var LogsEndpoint = class {
8738
8742
  return this.client.get(`/logs/trace/execution/${executionId}`);
8739
8743
  }
8740
8744
  /**
8745
+ * Explain one execution from its retained trace, with each claim citing trace entry ids.
8746
+ * Runs a metered, tool-free analysis in the caller's account and never changes the run.
8747
+ */
8748
+ async explainRun(executionId) {
8749
+ return this.client.post(`/logs/trace/execution/${encodeURIComponent(executionId)}/explain`, void 0, void 0, { timeoutMs: 6e4 });
8750
+ }
8751
+ /**
8741
8752
  * Get the trace tree for a conversation (all executions within it).
8742
8753
  */
8743
8754
  async traceConversation(conversationId) {
@@ -14444,7 +14455,7 @@ function transformQueryParams(params) {
14444
14455
  }
14445
14456
  //#endregion
14446
14457
  //#region src/version.ts
14447
- const SDK_VERSION = "10.14.2";
14458
+ const SDK_VERSION = "10.15.0";
14448
14459
  /**
14449
14460
  * Canonical client identity the API uses for attribution
14450
14461
  * (`detectActorSource` in apps/api/src/lib/audit-log.ts keys `'sdk'` off the
@@ -14749,7 +14760,7 @@ var RuntypeClient = class {
14749
14760
  /**
14750
14761
  * Generic POST request
14751
14762
  */
14752
- async post(path, data, extraHeaders) {
14763
+ async post(path, data, extraHeaders, options) {
14753
14764
  const url = this.buildUrl(path);
14754
14765
  return await this.makeRequest(url, {
14755
14766
  method: "POST",
@@ -14758,7 +14769,7 @@ var RuntypeClient = class {
14758
14769
  ...extraHeaders
14759
14770
  },
14760
14771
  body: data ? JSON.stringify(data) : void 0
14761
- });
14772
+ }, options?.timeoutMs);
14762
14773
  }
14763
14774
  /**
14764
14775
  * POST request with FormData support for file uploads
@@ -14867,9 +14878,9 @@ var RuntypeClient = class {
14867
14878
  * `makeRawRequest` keeps its own variant: it additionally composes a
14868
14879
  * caller-supplied `signal` (user-initiated stream aborts) with the timeout.
14869
14880
  */
14870
- async fetchWithTimeout(url, options) {
14871
- const controller = this.timeout === null ? null : new AbortController();
14872
- const timeoutId = controller && this.timeout !== null ? setTimeout(() => controller.abort(), this.timeout) : null;
14881
+ async fetchWithTimeout(url, options, timeoutMs = this.timeout) {
14882
+ const controller = timeoutMs === null ? null : new AbortController();
14883
+ const timeoutId = controller && timeoutMs !== null ? setTimeout(() => controller.abort(), timeoutMs) : null;
14873
14884
  try {
14874
14885
  const response = await fetch(url, {
14875
14886
  ...options,
@@ -14879,12 +14890,12 @@ var RuntypeClient = class {
14879
14890
  return response;
14880
14891
  } catch (error) {
14881
14892
  if (timeoutId) clearTimeout(timeoutId);
14882
- if (timeoutId && error instanceof Error && error.name === "AbortError") throw new Error(`Request timeout after ${this.timeout}ms`, { cause: error });
14893
+ if (timeoutId && error instanceof Error && error.name === "AbortError") throw new Error(`Request timeout after ${timeoutMs}ms`, { cause: error });
14883
14894
  throw error;
14884
14895
  }
14885
14896
  }
14886
- async makeRequest(url, options) {
14887
- const response = await this.fetchWithTimeout(url, options);
14897
+ async makeRequest(url, options, timeoutMs = this.timeout) {
14898
+ const response = await this.fetchWithTimeout(url, options, timeoutMs);
14888
14899
  if (!response.ok) throw await this.createApiError(response);
14889
14900
  if (response.status === 204) return null;
14890
14901
  if (response.headers.get("content-type")?.includes("application/json")) return response.json();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@runtypelabs/sdk",
3
- "version": "10.14.2",
3
+ "version": "10.15.0",
4
4
  "type": "module",
5
5
  "description": "TypeScript SDK for the Runtype API with fluent methods. Use it to quickly realize AI products, agents, and workflows.",
6
6
  "main": "dist/index.cjs",
@@ -24,7 +24,7 @@
24
24
  ],
25
25
  "dependencies": {},
26
26
  "devDependencies": {
27
- "@runtypelabs/shared": "3.80.0",
27
+ "@runtypelabs/shared": "3.81.0",
28
28
  "openapi-typescript": "^7.13.0",
29
29
  "tsdown": "^0.23.0",
30
30
  "typescript": "^6.0.3",