@runtypelabs/sdk 1.24.1 → 2.0.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
@@ -3737,7 +3737,10 @@ var RecordsEndpoint = class {
3737
3737
  return this.client.delete(`/records/${id}/results`, { resultId });
3738
3738
  }
3739
3739
  /**
3740
- * Upload CSV file to create multiple records
3740
+ * Upload CSV file to create multiple records.
3741
+ * Provide either `typeColumn` (read each row's type from a column) or
3742
+ * `typeValue` (assign the same constant type to every row). `typeValue`
3743
+ * takes precedence when both are supplied.
3741
3744
  */
3742
3745
  async uploadCsv(file, params) {
3743
3746
  const formData = new FormData();
@@ -3748,6 +3751,9 @@ var RecordsEndpoint = class {
3748
3751
  if (params?.nameColumn) {
3749
3752
  formData.append("nameColumn", params.nameColumn);
3750
3753
  }
3754
+ if (params?.typeValue) {
3755
+ formData.append("typeValue", params.typeValue);
3756
+ }
3751
3757
  return this.client.postFormData("/records/upload-csv", formData);
3752
3758
  }
3753
3759
  /**
@@ -4315,7 +4321,12 @@ var EvalEndpoint = class {
4315
4321
  }
4316
4322
  /**
4317
4323
  * Run virtual eval with streaming response
4318
- * Executes multiple eval configs simultaneously and streams results via multiplexed SSE
4324
+ * Executes multiple eval configs simultaneously and streams results via multiplexed SSE.
4325
+ *
4326
+ * Targets are mutually exclusive — provide exactly one of `flowId`,
4327
+ * `flowDefinition`, or `agentId`. The `agentId` form targets a
4328
+ * `claude_managed` agent; combine with per-config `claudeManagedOverride`
4329
+ * to vary model / system prompt / tool permissions across configs.
4319
4330
  */
4320
4331
  async runVirtualEval(data) {
4321
4332
  return this.client.requestStream("/eval/stream", {
package/dist/index.d.cts CHANGED
@@ -1142,7 +1142,6 @@ interface Flow {
1142
1142
  id: string;
1143
1143
  name: string;
1144
1144
  description?: string | null;
1145
- status: 'draft' | 'active' | 'paused' | 'failed';
1146
1145
  config?: JsonObject;
1147
1146
  userId: string;
1148
1147
  organizationId: string | null;
@@ -1262,6 +1261,12 @@ interface CreateFlowRequest {
1262
1261
  name: string;
1263
1262
  description?: string;
1264
1263
  flowSteps?: Array<{
1264
+ /**
1265
+ * Stable step identifier. When provided, the server preserves it across
1266
+ * saves so references in `flow_step_results` and dashboard state remain
1267
+ * valid. When omitted, the server mints one on first save.
1268
+ */
1269
+ id?: string;
1265
1270
  type: 'prompt' | 'context' | 'condition' | 'output' | 'email';
1266
1271
  name: string;
1267
1272
  order?: number;
@@ -1378,6 +1383,8 @@ interface DispatchRequest {
1378
1383
  id?: number | string;
1379
1384
  name?: string;
1380
1385
  type?: string;
1386
+ /** First-class owner; stored as `metadata.ownerId` (overrides any value in `metadata`). */
1387
+ ownerId?: string;
1381
1388
  metadata?: Metadata;
1382
1389
  };
1383
1390
  flow: {
@@ -3280,11 +3287,15 @@ declare class RecordsEndpoint {
3280
3287
  */
3281
3288
  deleteResult(id: string, resultId: string): Promise<void>;
3282
3289
  /**
3283
- * Upload CSV file to create multiple records
3290
+ * Upload CSV file to create multiple records.
3291
+ * Provide either `typeColumn` (read each row's type from a column) or
3292
+ * `typeValue` (assign the same constant type to every row). `typeValue`
3293
+ * takes precedence when both are supplied.
3284
3294
  */
3285
3295
  uploadCsv(file: File, params?: {
3286
3296
  typeColumn?: string;
3287
3297
  nameColumn?: string;
3298
+ typeValue?: string;
3288
3299
  }): Promise<any>;
3289
3300
  /**
3290
3301
  * Get record types (distinct values)
@@ -3716,7 +3727,12 @@ declare class EvalEndpoint {
3716
3727
  constructor(client: ApiClient);
3717
3728
  /**
3718
3729
  * Run virtual eval with streaming response
3719
- * Executes multiple eval configs simultaneously and streams results via multiplexed SSE
3730
+ * Executes multiple eval configs simultaneously and streams results via multiplexed SSE.
3731
+ *
3732
+ * Targets are mutually exclusive — provide exactly one of `flowId`,
3733
+ * `flowDefinition`, or `agentId`. The `agentId` form targets a
3734
+ * `claude_managed` agent; combine with per-config `claudeManagedOverride`
3735
+ * to vary model / system prompt / tool permissions across configs.
3720
3736
  */
3721
3737
  runVirtualEval(data: {
3722
3738
  record?: {
@@ -3730,10 +3746,36 @@ declare class EvalEndpoint {
3730
3746
  }>;
3731
3747
  flowId?: string;
3732
3748
  flowDefinition?: any;
3749
+ /**
3750
+ * Target a `claude_managed` agent rather than a flow. Mutually exclusive
3751
+ * with `flowId` and `flowDefinition`.
3752
+ */
3753
+ agentId?: string;
3733
3754
  evalConfigs: Array<{
3734
3755
  evalConfigId?: string;
3735
3756
  evalName?: string;
3736
3757
  stepOverrides?: Record<string, any>;
3758
+ /**
3759
+ * Per-config override applied when the eval target is a
3760
+ * `claude_managed` agent. Mirrors `ClaudeManagedEvalOverride` from
3761
+ * `@runtypelabs/shared` — defined inline here to keep the SDK
3762
+ * dependency-free.
3763
+ */
3764
+ claudeManagedOverride?: {
3765
+ targetType?: 'claude_managed';
3766
+ model?: string;
3767
+ systemPrompt?: string;
3768
+ toolPermissions?: {
3769
+ bash?: boolean;
3770
+ read?: boolean;
3771
+ write?: boolean;
3772
+ edit?: boolean;
3773
+ glob?: boolean;
3774
+ grep?: boolean;
3775
+ webFetch?: boolean;
3776
+ webSearch?: boolean;
3777
+ };
3778
+ };
3737
3779
  }>;
3738
3780
  evalGroupId?: string;
3739
3781
  }): Promise<Response>;
@@ -3953,6 +3995,20 @@ interface AgentMediaEvent extends BaseAgentEvent {
3953
3995
  };
3954
3996
  }>;
3955
3997
  }
3998
+ /**
3999
+ * A2A 0.3.0 conversation handle surfaced on `agent_complete` and
4000
+ * `agent_approval_start` events for external-mode agents.
4001
+ *
4002
+ * Local SDK copy of `ExternalAgentContext` from `@runtypelabs/shared`'s
4003
+ * `sse-parser.ts`. The SDK has zero production dependencies and
4004
+ * re-derives wire types by design (Phase 9 — see
4005
+ * `docs/features/shipped/2026-02-25-user-cloud-deployment.md`). Keep
4006
+ * the shape identical to `@runtypelabs/shared`'s `ExternalAgentContext`.
4007
+ */
4008
+ interface ExternalAgentContext {
4009
+ contextId?: string;
4010
+ taskId?: string;
4011
+ }
3956
4012
  /**
3957
4013
  * Agent approval start event — execution paused waiting for user approval.
3958
4014
  */
@@ -3967,6 +4023,13 @@ interface AgentApprovalStartEvent extends BaseAgentEvent {
3967
4023
  parameters?: Record<string, unknown>;
3968
4024
  timeout: number;
3969
4025
  startedAt: string;
4026
+ /**
4027
+ * Populated when an external A2A agent paused (`input-required` /
4028
+ * `auth-required`) and the upstream returned a conversation handle.
4029
+ * Mirrors `AgentApprovalStartEvent.externalAgent` in
4030
+ * `@runtypelabs/shared`'s `sse-parser.ts`.
4031
+ */
4032
+ externalAgent?: ExternalAgentContext;
3970
4033
  }
3971
4034
  /**
3972
4035
  * Agent approval complete event — user or system resolved the approval.
@@ -4021,6 +4084,16 @@ interface AgentCompleteEvent extends BaseAgentEvent {
4021
4084
  finalOutput?: string;
4022
4085
  duration?: number;
4023
4086
  error?: string;
4087
+ /**
4088
+ * Populated only by external-mode (`agentType: 'external'`) executions
4089
+ * when the upstream A2A 0.3.0 server returns a conversation handle.
4090
+ * Callers persist `contextId` and pass it back via the runtime's
4091
+ * `ExecuteAgentOptions.externalAgent.contextId` on the next call to
4092
+ * resume the same conversation. Mirrors
4093
+ * `AgentCompleteEvent.externalAgent` in `@runtypelabs/shared`'s
4094
+ * `sse-parser.ts`.
4095
+ */
4096
+ externalAgent?: ExternalAgentContext;
4024
4097
  }
4025
4098
  /**
4026
4099
  * Agent error event
@@ -5451,4 +5524,4 @@ declare function getLikelySupportingCandidatePaths(bestCandidatePath: string | u
5451
5524
  declare function getDefaultPlanPath(taskName: string): string;
5452
5525
  declare function sanitizeTaskSlug(taskName: string): string;
5453
5526
 
5454
- export { type Agent, type AgentApprovalCompleteEvent, type AgentApprovalStartEvent, type AgentCompleteEvent, type AgentErrorEvent, type AgentEvent, type AgentEventType, type AgentExecuteRequest, type AgentExecuteResponse, type AgentIterationCompleteEvent, type AgentIterationStartEvent, type AgentMediaEvent, type AgentMessage, type AgentPausedEvent, type AgentPingEvent, type AgentReflectionEvent, type AgentRuntimeToolDefinition, type AgentStartEvent, type AgentStreamCallbacks, type AgentSubagentConfig, type AgentToolCompleteEvent, type AgentToolDeltaEvent, type AgentToolInputCompleteEvent, type AgentToolInputDeltaEvent, type AgentToolStartEvent, type AgentTurnCompleteEvent, type AgentTurnDeltaEvent, type AgentTurnStartEvent, AgentsEndpoint, AnalyticsEndpoint, type ApiClient, type ApiKey, ApiKeysEndpoint, type ApiResponse, type ApplyGeneratedProposalOptions, type ApplyGeneratedProposalResult, type AttachRuntimeToolsOptions, type BaseAgentEvent, BatchBuilder, type BatchClient, type BatchListParams, type BatchOptions, type BatchRequest, type BatchResult, type BatchScheduleConfig, type BatchStatus, BatchesNamespace, type BuiltInTool, type BulkEditCondition, type BulkEditRequest, type BulkEditResponse, type BulkEditResult, ChatEndpoint, ClientBatchBuilder, type ClientConfig, type ClientConversation, ClientEvalBuilder, ClientFlowBuilder, type ClientToken, type ClientTokenConfig, type ClientTokenEnvironment, type ClientTokenVersionPin, ClientTokensEndpoint, type ClientWidgetTheme, type ConditionalStepConfig$1 as ConditionalStepConfig, type ContextErrorHandling, type ContextFallback, ContextTemplatesEndpoint, type CreateApiKeyRequest, type CreateClientTokenRequest, type CreateClientTokenResponse, type CreateFlowRequest, type CreateModelConfigRequest, type CreatePromptData, type CreatePromptRequest, type CreateProviderKeyRequest, type CreateRecordRequest, type CreateToolRequest, type CustomMCPServer, type CustomMCPServerAuth, type CustomToolConfig, type DeployCfSandboxRequest, type DeployCfSandboxResponse, type DeploySandboxRequest, type DeploySandboxResponse, type DispatchClient, DispatchEndpoint, type DispatchEnvironment, type DispatchOptions$1 as DispatchOptions, type DispatchRequest, type ErrorHandlingMode, EvalBuilder, type EvalClient, EvalEndpoint, type EvalListParams, type EvalOptions, type EvalRecord, type EvalRequest, type EvalResult, type EvalRunConfig, EvalRunner, type EvalStatus, EvalsNamespace, type ExecuteToolRequest, type ExecuteToolResponse, type ExternalToolConfig, type FallbackFailEvent, type FallbackStartEvent, type FallbackSuccessEvent, type FallbacksExhaustedEvent, type FallbacksInitiatedEvent, type FetchGitHubStepConfig$1 as FetchGitHubStepConfig, type FetchUrlStepConfig$1 as FetchUrlStepConfig, type FieldFormat, type FileContentPart, type Flow, type FlowAttachment, FlowBuilder, type FlowCompleteEvent, type FlowConfig$1 as FlowConfig, type FlowErrorEvent, type FlowFallback, type FlowPausedEvent, FlowResult, type FlowStartEvent, type FlowStep, FlowStepsEndpoint, type FlowSummary, type FlowToolConfig, FlowsEndpoint, FlowsNamespace, type GenerateEmbeddingStepConfig$1 as GenerateEmbeddingStepConfig, type GeneratedRuntimeToolGateDecision, type GeneratedRuntimeToolGateOptions, type ImageContentPart, type JSONSchema, type JsonArray, type JsonObject, type JsonPrimitive, type JsonValue, type ListConversationsResponse, type ListParams, type LocalToolConfig, type LocalToolDefinition, type LocalToolExecutionCompleteEvent, type LocalToolExecutionLoopSnapshotSlice, type LocalToolExecutionStartEvent, type Message$1 as Message, type MessageContent, type Metadata, type ModelConfig, ModelConfigsEndpoint, type ModelFallback, type ModelOverride, type ModelUsageDetail, type ModelUsageQueryParams, type ModelUsageResponse, type ModelUsageSummary, type ModelUsageTimeSeries, type PaginationResponse, type Prompt$1 as Prompt, type PromptErrorHandling, type PromptFallback, type PromptListParams, type PromptRunOptions, PromptRunner, type PromptStepConfig$1 as PromptStepConfig, PromptsEndpoint, PromptsNamespace, type ProviderApiKey, type ReasoningConfig, type ReasoningValue, type RecordConfig$1 as RecordConfig, type RecordFilter, type RecordFilterCondition, type RecordFilterGroup, type RecordFilterOperator, type RecordListParams, RecordsEndpoint, type RetrieveRecordStepConfig$1 as RetrieveRecordStepConfig, type RetryFallback, type RunTaskContextBudgetBreakdown, type RunTaskContextCompactionEvent, type RunTaskContextCompactionStrategy, type RunTaskContextNoticeEvent, type RunTaskContinuation, type RunTaskOnContextCompaction, type RunTaskOnContextNotice, type RunTaskOnSession, type RunTaskOptions, type RunTaskResult, type RunTaskResumeState, type RunTaskSessionSummary, type RunTaskState, type RunTaskStateSlice, type RunTaskStatus, type RunTaskToolTraceSlice, type RuntimeCustomToolConfig, type RuntimeExternalToolConfig, type RuntimeFlowToolConfig, type RuntimeLocalToolConfig, type RuntimeSubagentToolConfig, type RuntimeTool, type RuntimeToolConfig, Runtype, RuntypeApiError, RuntypeClient, type ConditionalStepConfig as RuntypeConditionalStepConfig, type RuntypeConfig, type FetchGitHubStepConfig as RuntypeFetchGitHubStepConfig, type FetchUrlStepConfig as RuntypeFetchUrlStepConfig, RuntypeFlowBuilder, type FlowConfig as RuntypeFlowConfig, type GenerateEmbeddingStepConfig as RuntypeGenerateEmbeddingStepConfig, type Message as RuntypeMessage, type ModelOverride$1 as RuntypeModelOverride, type Prompt as RuntypePrompt, type PromptStepConfig as RuntypePromptStepConfig, type RuntypeRecord, type RecordConfig as RuntypeRecordConfig, type RetrieveRecordStepConfig as RuntypeRetrieveRecordStepConfig, type SearchStepConfig as RuntypeSearchStepConfig, type SendEmailStepConfig as RuntypeSendEmailStepConfig, type SendEventStepConfig as RuntypeSendEventStepConfig, type SendStreamStepConfig as RuntypeSendStreamStepConfig, type SendTextStepConfig as RuntypeSendTextStepConfig, type SetVariableStepConfig as RuntypeSetVariableStepConfig, type TransformDataStepConfig as RuntypeTransformDataStepConfig, type UpsertFlowConfig as RuntypeUpsertFlowConfig, type UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, type VectorSearchStepConfig as RuntypeVectorSearchStepConfig, type WaitUntilStepConfig as RuntypeWaitUntilStepConfig, STEP_FIELD_REGISTRY, STEP_TYPE_TO_METHOD, type SearchStepConfig$1 as SearchStepConfig, type SendEmailStepConfig$1 as SendEmailStepConfig, type SendEventStepConfig$1 as SendEventStepConfig, type SendStreamStepConfig$1 as SendStreamStepConfig, type SendTextStepConfig$1 as SendTextStepConfig, type SetVariableStepConfig$1 as SetVariableStepConfig, type StepCompleteEvent, type StepDeltaEvent, type StepFallback, type StepFieldMeta, type StepStartEvent, type StepWaitingLocalEvent, type StreamCallbacks, type StreamEvent, type SubagentToolConfig, type TextContentPart, type Tool, type ToolConfig, type ToolExecution, type ToolsConfig, ToolsEndpoint, type TransformDataStepConfig$1 as TransformDataStepConfig, type UpdateClientTokenRequest, type UpdatePromptData, type UpdateProviderKeyRequest, type UpdateToolRequest, type UpsertFlowConfig$1 as UpsertFlowConfig, type UpsertOptions, type UpsertRecordStepConfig$1 as UpsertRecordStepConfig, type UserProfile, UsersEndpoint, type VectorSearchStepConfig$1 as VectorSearchStepConfig, type WaitUntilStepConfig$1 as WaitUntilStepConfig, type WorkflowContext, type WorkflowDefinition, type WorkflowPhase, applyGeneratedRuntimeToolProposalToDispatchRequest, attachRuntimeToolsToDispatchRequest, buildGeneratedRuntimeToolGateOutput, createClient, createExternalTool, defaultWorkflow, deployWorkflow, evaluateGeneratedRuntimeToolProposal, gameWorkflow, getDefaultPlanPath, getLikelySupportingCandidatePaths, isDiscoveryToolName, isMarathonArtifactPath, isPreservationSensitiveTask, normalizeCandidatePath, parseFinalBuffer, parseSSEChunk, processStream, sanitizeTaskSlug, streamEvents };
5527
+ export { type Agent, type AgentApprovalCompleteEvent, type AgentApprovalStartEvent, type AgentCompleteEvent, type AgentErrorEvent, type AgentEvent, type AgentEventType, type AgentExecuteRequest, type AgentExecuteResponse, type AgentIterationCompleteEvent, type AgentIterationStartEvent, type AgentMediaEvent, type AgentMessage, type AgentPausedEvent, type AgentPingEvent, type AgentReflectionEvent, type AgentRuntimeToolDefinition, type AgentStartEvent, type AgentStreamCallbacks, type AgentSubagentConfig, type AgentToolCompleteEvent, type AgentToolDeltaEvent, type AgentToolInputCompleteEvent, type AgentToolInputDeltaEvent, type AgentToolStartEvent, type AgentTurnCompleteEvent, type AgentTurnDeltaEvent, type AgentTurnStartEvent, AgentsEndpoint, AnalyticsEndpoint, type ApiClient, type ApiKey, ApiKeysEndpoint, type ApiResponse, type ApplyGeneratedProposalOptions, type ApplyGeneratedProposalResult, type AttachRuntimeToolsOptions, type BaseAgentEvent, BatchBuilder, type BatchClient, type BatchListParams, type BatchOptions, type BatchRequest, type BatchResult, type BatchScheduleConfig, type BatchStatus, BatchesNamespace, type BuiltInTool, type BulkEditCondition, type BulkEditRequest, type BulkEditResponse, type BulkEditResult, ChatEndpoint, ClientBatchBuilder, type ClientConfig, type ClientConversation, ClientEvalBuilder, ClientFlowBuilder, type ClientToken, type ClientTokenConfig, type ClientTokenEnvironment, type ClientTokenVersionPin, ClientTokensEndpoint, type ClientWidgetTheme, type ConditionalStepConfig$1 as ConditionalStepConfig, type ContextErrorHandling, type ContextFallback, ContextTemplatesEndpoint, type CreateApiKeyRequest, type CreateClientTokenRequest, type CreateClientTokenResponse, type CreateFlowRequest, type CreateModelConfigRequest, type CreatePromptData, type CreatePromptRequest, type CreateProviderKeyRequest, type CreateRecordRequest, type CreateToolRequest, type CustomMCPServer, type CustomMCPServerAuth, type CustomToolConfig, type DeployCfSandboxRequest, type DeployCfSandboxResponse, type DeploySandboxRequest, type DeploySandboxResponse, type DispatchClient, DispatchEndpoint, type DispatchEnvironment, type DispatchOptions$1 as DispatchOptions, type DispatchRequest, type ErrorHandlingMode, EvalBuilder, type EvalClient, EvalEndpoint, type EvalListParams, type EvalOptions, type EvalRecord, type EvalRequest, type EvalResult, type EvalRunConfig, EvalRunner, type EvalStatus, EvalsNamespace, type ExecuteToolRequest, type ExecuteToolResponse, type ExternalAgentContext, type ExternalToolConfig, type FallbackFailEvent, type FallbackStartEvent, type FallbackSuccessEvent, type FallbacksExhaustedEvent, type FallbacksInitiatedEvent, type FetchGitHubStepConfig$1 as FetchGitHubStepConfig, type FetchUrlStepConfig$1 as FetchUrlStepConfig, type FieldFormat, type FileContentPart, type Flow, type FlowAttachment, FlowBuilder, type FlowCompleteEvent, type FlowConfig$1 as FlowConfig, type FlowErrorEvent, type FlowFallback, type FlowPausedEvent, FlowResult, type FlowStartEvent, type FlowStep, FlowStepsEndpoint, type FlowSummary, type FlowToolConfig, FlowsEndpoint, FlowsNamespace, type GenerateEmbeddingStepConfig$1 as GenerateEmbeddingStepConfig, type GeneratedRuntimeToolGateDecision, type GeneratedRuntimeToolGateOptions, type ImageContentPart, type JSONSchema, type JsonArray, type JsonObject, type JsonPrimitive, type JsonValue, type ListConversationsResponse, type ListParams, type LocalToolConfig, type LocalToolDefinition, type LocalToolExecutionCompleteEvent, type LocalToolExecutionLoopSnapshotSlice, type LocalToolExecutionStartEvent, type Message$1 as Message, type MessageContent, type Metadata, type ModelConfig, ModelConfigsEndpoint, type ModelFallback, type ModelOverride, type ModelUsageDetail, type ModelUsageQueryParams, type ModelUsageResponse, type ModelUsageSummary, type ModelUsageTimeSeries, type PaginationResponse, type Prompt$1 as Prompt, type PromptErrorHandling, type PromptFallback, type PromptListParams, type PromptRunOptions, PromptRunner, type PromptStepConfig$1 as PromptStepConfig, PromptsEndpoint, PromptsNamespace, type ProviderApiKey, type ReasoningConfig, type ReasoningValue, type RecordConfig$1 as RecordConfig, type RecordFilter, type RecordFilterCondition, type RecordFilterGroup, type RecordFilterOperator, type RecordListParams, RecordsEndpoint, type RetrieveRecordStepConfig$1 as RetrieveRecordStepConfig, type RetryFallback, type RunTaskContextBudgetBreakdown, type RunTaskContextCompactionEvent, type RunTaskContextCompactionStrategy, type RunTaskContextNoticeEvent, type RunTaskContinuation, type RunTaskOnContextCompaction, type RunTaskOnContextNotice, type RunTaskOnSession, type RunTaskOptions, type RunTaskResult, type RunTaskResumeState, type RunTaskSessionSummary, type RunTaskState, type RunTaskStateSlice, type RunTaskStatus, type RunTaskToolTraceSlice, type RuntimeCustomToolConfig, type RuntimeExternalToolConfig, type RuntimeFlowToolConfig, type RuntimeLocalToolConfig, type RuntimeSubagentToolConfig, type RuntimeTool, type RuntimeToolConfig, Runtype, RuntypeApiError, RuntypeClient, type ConditionalStepConfig as RuntypeConditionalStepConfig, type RuntypeConfig, type FetchGitHubStepConfig as RuntypeFetchGitHubStepConfig, type FetchUrlStepConfig as RuntypeFetchUrlStepConfig, RuntypeFlowBuilder, type FlowConfig as RuntypeFlowConfig, type GenerateEmbeddingStepConfig as RuntypeGenerateEmbeddingStepConfig, type Message as RuntypeMessage, type ModelOverride$1 as RuntypeModelOverride, type Prompt as RuntypePrompt, type PromptStepConfig as RuntypePromptStepConfig, type RuntypeRecord, type RecordConfig as RuntypeRecordConfig, type RetrieveRecordStepConfig as RuntypeRetrieveRecordStepConfig, type SearchStepConfig as RuntypeSearchStepConfig, type SendEmailStepConfig as RuntypeSendEmailStepConfig, type SendEventStepConfig as RuntypeSendEventStepConfig, type SendStreamStepConfig as RuntypeSendStreamStepConfig, type SendTextStepConfig as RuntypeSendTextStepConfig, type SetVariableStepConfig as RuntypeSetVariableStepConfig, type TransformDataStepConfig as RuntypeTransformDataStepConfig, type UpsertFlowConfig as RuntypeUpsertFlowConfig, type UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, type VectorSearchStepConfig as RuntypeVectorSearchStepConfig, type WaitUntilStepConfig as RuntypeWaitUntilStepConfig, STEP_FIELD_REGISTRY, STEP_TYPE_TO_METHOD, type SearchStepConfig$1 as SearchStepConfig, type SendEmailStepConfig$1 as SendEmailStepConfig, type SendEventStepConfig$1 as SendEventStepConfig, type SendStreamStepConfig$1 as SendStreamStepConfig, type SendTextStepConfig$1 as SendTextStepConfig, type SetVariableStepConfig$1 as SetVariableStepConfig, type StepCompleteEvent, type StepDeltaEvent, type StepFallback, type StepFieldMeta, type StepStartEvent, type StepWaitingLocalEvent, type StreamCallbacks, type StreamEvent, type SubagentToolConfig, type TextContentPart, type Tool, type ToolConfig, type ToolExecution, type ToolsConfig, ToolsEndpoint, type TransformDataStepConfig$1 as TransformDataStepConfig, type UpdateClientTokenRequest, type UpdatePromptData, type UpdateProviderKeyRequest, type UpdateToolRequest, type UpsertFlowConfig$1 as UpsertFlowConfig, type UpsertOptions, type UpsertRecordStepConfig$1 as UpsertRecordStepConfig, type UserProfile, UsersEndpoint, type VectorSearchStepConfig$1 as VectorSearchStepConfig, type WaitUntilStepConfig$1 as WaitUntilStepConfig, type WorkflowContext, type WorkflowDefinition, type WorkflowPhase, applyGeneratedRuntimeToolProposalToDispatchRequest, attachRuntimeToolsToDispatchRequest, buildGeneratedRuntimeToolGateOutput, createClient, createExternalTool, defaultWorkflow, deployWorkflow, evaluateGeneratedRuntimeToolProposal, gameWorkflow, getDefaultPlanPath, getLikelySupportingCandidatePaths, isDiscoveryToolName, isMarathonArtifactPath, isPreservationSensitiveTask, normalizeCandidatePath, parseFinalBuffer, parseSSEChunk, processStream, sanitizeTaskSlug, streamEvents };
package/dist/index.d.ts CHANGED
@@ -1142,7 +1142,6 @@ interface Flow {
1142
1142
  id: string;
1143
1143
  name: string;
1144
1144
  description?: string | null;
1145
- status: 'draft' | 'active' | 'paused' | 'failed';
1146
1145
  config?: JsonObject;
1147
1146
  userId: string;
1148
1147
  organizationId: string | null;
@@ -1262,6 +1261,12 @@ interface CreateFlowRequest {
1262
1261
  name: string;
1263
1262
  description?: string;
1264
1263
  flowSteps?: Array<{
1264
+ /**
1265
+ * Stable step identifier. When provided, the server preserves it across
1266
+ * saves so references in `flow_step_results` and dashboard state remain
1267
+ * valid. When omitted, the server mints one on first save.
1268
+ */
1269
+ id?: string;
1265
1270
  type: 'prompt' | 'context' | 'condition' | 'output' | 'email';
1266
1271
  name: string;
1267
1272
  order?: number;
@@ -1378,6 +1383,8 @@ interface DispatchRequest {
1378
1383
  id?: number | string;
1379
1384
  name?: string;
1380
1385
  type?: string;
1386
+ /** First-class owner; stored as `metadata.ownerId` (overrides any value in `metadata`). */
1387
+ ownerId?: string;
1381
1388
  metadata?: Metadata;
1382
1389
  };
1383
1390
  flow: {
@@ -3280,11 +3287,15 @@ declare class RecordsEndpoint {
3280
3287
  */
3281
3288
  deleteResult(id: string, resultId: string): Promise<void>;
3282
3289
  /**
3283
- * Upload CSV file to create multiple records
3290
+ * Upload CSV file to create multiple records.
3291
+ * Provide either `typeColumn` (read each row's type from a column) or
3292
+ * `typeValue` (assign the same constant type to every row). `typeValue`
3293
+ * takes precedence when both are supplied.
3284
3294
  */
3285
3295
  uploadCsv(file: File, params?: {
3286
3296
  typeColumn?: string;
3287
3297
  nameColumn?: string;
3298
+ typeValue?: string;
3288
3299
  }): Promise<any>;
3289
3300
  /**
3290
3301
  * Get record types (distinct values)
@@ -3716,7 +3727,12 @@ declare class EvalEndpoint {
3716
3727
  constructor(client: ApiClient);
3717
3728
  /**
3718
3729
  * Run virtual eval with streaming response
3719
- * Executes multiple eval configs simultaneously and streams results via multiplexed SSE
3730
+ * Executes multiple eval configs simultaneously and streams results via multiplexed SSE.
3731
+ *
3732
+ * Targets are mutually exclusive — provide exactly one of `flowId`,
3733
+ * `flowDefinition`, or `agentId`. The `agentId` form targets a
3734
+ * `claude_managed` agent; combine with per-config `claudeManagedOverride`
3735
+ * to vary model / system prompt / tool permissions across configs.
3720
3736
  */
3721
3737
  runVirtualEval(data: {
3722
3738
  record?: {
@@ -3730,10 +3746,36 @@ declare class EvalEndpoint {
3730
3746
  }>;
3731
3747
  flowId?: string;
3732
3748
  flowDefinition?: any;
3749
+ /**
3750
+ * Target a `claude_managed` agent rather than a flow. Mutually exclusive
3751
+ * with `flowId` and `flowDefinition`.
3752
+ */
3753
+ agentId?: string;
3733
3754
  evalConfigs: Array<{
3734
3755
  evalConfigId?: string;
3735
3756
  evalName?: string;
3736
3757
  stepOverrides?: Record<string, any>;
3758
+ /**
3759
+ * Per-config override applied when the eval target is a
3760
+ * `claude_managed` agent. Mirrors `ClaudeManagedEvalOverride` from
3761
+ * `@runtypelabs/shared` — defined inline here to keep the SDK
3762
+ * dependency-free.
3763
+ */
3764
+ claudeManagedOverride?: {
3765
+ targetType?: 'claude_managed';
3766
+ model?: string;
3767
+ systemPrompt?: string;
3768
+ toolPermissions?: {
3769
+ bash?: boolean;
3770
+ read?: boolean;
3771
+ write?: boolean;
3772
+ edit?: boolean;
3773
+ glob?: boolean;
3774
+ grep?: boolean;
3775
+ webFetch?: boolean;
3776
+ webSearch?: boolean;
3777
+ };
3778
+ };
3737
3779
  }>;
3738
3780
  evalGroupId?: string;
3739
3781
  }): Promise<Response>;
@@ -3953,6 +3995,20 @@ interface AgentMediaEvent extends BaseAgentEvent {
3953
3995
  };
3954
3996
  }>;
3955
3997
  }
3998
+ /**
3999
+ * A2A 0.3.0 conversation handle surfaced on `agent_complete` and
4000
+ * `agent_approval_start` events for external-mode agents.
4001
+ *
4002
+ * Local SDK copy of `ExternalAgentContext` from `@runtypelabs/shared`'s
4003
+ * `sse-parser.ts`. The SDK has zero production dependencies and
4004
+ * re-derives wire types by design (Phase 9 — see
4005
+ * `docs/features/shipped/2026-02-25-user-cloud-deployment.md`). Keep
4006
+ * the shape identical to `@runtypelabs/shared`'s `ExternalAgentContext`.
4007
+ */
4008
+ interface ExternalAgentContext {
4009
+ contextId?: string;
4010
+ taskId?: string;
4011
+ }
3956
4012
  /**
3957
4013
  * Agent approval start event — execution paused waiting for user approval.
3958
4014
  */
@@ -3967,6 +4023,13 @@ interface AgentApprovalStartEvent extends BaseAgentEvent {
3967
4023
  parameters?: Record<string, unknown>;
3968
4024
  timeout: number;
3969
4025
  startedAt: string;
4026
+ /**
4027
+ * Populated when an external A2A agent paused (`input-required` /
4028
+ * `auth-required`) and the upstream returned a conversation handle.
4029
+ * Mirrors `AgentApprovalStartEvent.externalAgent` in
4030
+ * `@runtypelabs/shared`'s `sse-parser.ts`.
4031
+ */
4032
+ externalAgent?: ExternalAgentContext;
3970
4033
  }
3971
4034
  /**
3972
4035
  * Agent approval complete event — user or system resolved the approval.
@@ -4021,6 +4084,16 @@ interface AgentCompleteEvent extends BaseAgentEvent {
4021
4084
  finalOutput?: string;
4022
4085
  duration?: number;
4023
4086
  error?: string;
4087
+ /**
4088
+ * Populated only by external-mode (`agentType: 'external'`) executions
4089
+ * when the upstream A2A 0.3.0 server returns a conversation handle.
4090
+ * Callers persist `contextId` and pass it back via the runtime's
4091
+ * `ExecuteAgentOptions.externalAgent.contextId` on the next call to
4092
+ * resume the same conversation. Mirrors
4093
+ * `AgentCompleteEvent.externalAgent` in `@runtypelabs/shared`'s
4094
+ * `sse-parser.ts`.
4095
+ */
4096
+ externalAgent?: ExternalAgentContext;
4024
4097
  }
4025
4098
  /**
4026
4099
  * Agent error event
@@ -5451,4 +5524,4 @@ declare function getLikelySupportingCandidatePaths(bestCandidatePath: string | u
5451
5524
  declare function getDefaultPlanPath(taskName: string): string;
5452
5525
  declare function sanitizeTaskSlug(taskName: string): string;
5453
5526
 
5454
- export { type Agent, type AgentApprovalCompleteEvent, type AgentApprovalStartEvent, type AgentCompleteEvent, type AgentErrorEvent, type AgentEvent, type AgentEventType, type AgentExecuteRequest, type AgentExecuteResponse, type AgentIterationCompleteEvent, type AgentIterationStartEvent, type AgentMediaEvent, type AgentMessage, type AgentPausedEvent, type AgentPingEvent, type AgentReflectionEvent, type AgentRuntimeToolDefinition, type AgentStartEvent, type AgentStreamCallbacks, type AgentSubagentConfig, type AgentToolCompleteEvent, type AgentToolDeltaEvent, type AgentToolInputCompleteEvent, type AgentToolInputDeltaEvent, type AgentToolStartEvent, type AgentTurnCompleteEvent, type AgentTurnDeltaEvent, type AgentTurnStartEvent, AgentsEndpoint, AnalyticsEndpoint, type ApiClient, type ApiKey, ApiKeysEndpoint, type ApiResponse, type ApplyGeneratedProposalOptions, type ApplyGeneratedProposalResult, type AttachRuntimeToolsOptions, type BaseAgentEvent, BatchBuilder, type BatchClient, type BatchListParams, type BatchOptions, type BatchRequest, type BatchResult, type BatchScheduleConfig, type BatchStatus, BatchesNamespace, type BuiltInTool, type BulkEditCondition, type BulkEditRequest, type BulkEditResponse, type BulkEditResult, ChatEndpoint, ClientBatchBuilder, type ClientConfig, type ClientConversation, ClientEvalBuilder, ClientFlowBuilder, type ClientToken, type ClientTokenConfig, type ClientTokenEnvironment, type ClientTokenVersionPin, ClientTokensEndpoint, type ClientWidgetTheme, type ConditionalStepConfig$1 as ConditionalStepConfig, type ContextErrorHandling, type ContextFallback, ContextTemplatesEndpoint, type CreateApiKeyRequest, type CreateClientTokenRequest, type CreateClientTokenResponse, type CreateFlowRequest, type CreateModelConfigRequest, type CreatePromptData, type CreatePromptRequest, type CreateProviderKeyRequest, type CreateRecordRequest, type CreateToolRequest, type CustomMCPServer, type CustomMCPServerAuth, type CustomToolConfig, type DeployCfSandboxRequest, type DeployCfSandboxResponse, type DeploySandboxRequest, type DeploySandboxResponse, type DispatchClient, DispatchEndpoint, type DispatchEnvironment, type DispatchOptions$1 as DispatchOptions, type DispatchRequest, type ErrorHandlingMode, EvalBuilder, type EvalClient, EvalEndpoint, type EvalListParams, type EvalOptions, type EvalRecord, type EvalRequest, type EvalResult, type EvalRunConfig, EvalRunner, type EvalStatus, EvalsNamespace, type ExecuteToolRequest, type ExecuteToolResponse, type ExternalToolConfig, type FallbackFailEvent, type FallbackStartEvent, type FallbackSuccessEvent, type FallbacksExhaustedEvent, type FallbacksInitiatedEvent, type FetchGitHubStepConfig$1 as FetchGitHubStepConfig, type FetchUrlStepConfig$1 as FetchUrlStepConfig, type FieldFormat, type FileContentPart, type Flow, type FlowAttachment, FlowBuilder, type FlowCompleteEvent, type FlowConfig$1 as FlowConfig, type FlowErrorEvent, type FlowFallback, type FlowPausedEvent, FlowResult, type FlowStartEvent, type FlowStep, FlowStepsEndpoint, type FlowSummary, type FlowToolConfig, FlowsEndpoint, FlowsNamespace, type GenerateEmbeddingStepConfig$1 as GenerateEmbeddingStepConfig, type GeneratedRuntimeToolGateDecision, type GeneratedRuntimeToolGateOptions, type ImageContentPart, type JSONSchema, type JsonArray, type JsonObject, type JsonPrimitive, type JsonValue, type ListConversationsResponse, type ListParams, type LocalToolConfig, type LocalToolDefinition, type LocalToolExecutionCompleteEvent, type LocalToolExecutionLoopSnapshotSlice, type LocalToolExecutionStartEvent, type Message$1 as Message, type MessageContent, type Metadata, type ModelConfig, ModelConfigsEndpoint, type ModelFallback, type ModelOverride, type ModelUsageDetail, type ModelUsageQueryParams, type ModelUsageResponse, type ModelUsageSummary, type ModelUsageTimeSeries, type PaginationResponse, type Prompt$1 as Prompt, type PromptErrorHandling, type PromptFallback, type PromptListParams, type PromptRunOptions, PromptRunner, type PromptStepConfig$1 as PromptStepConfig, PromptsEndpoint, PromptsNamespace, type ProviderApiKey, type ReasoningConfig, type ReasoningValue, type RecordConfig$1 as RecordConfig, type RecordFilter, type RecordFilterCondition, type RecordFilterGroup, type RecordFilterOperator, type RecordListParams, RecordsEndpoint, type RetrieveRecordStepConfig$1 as RetrieveRecordStepConfig, type RetryFallback, type RunTaskContextBudgetBreakdown, type RunTaskContextCompactionEvent, type RunTaskContextCompactionStrategy, type RunTaskContextNoticeEvent, type RunTaskContinuation, type RunTaskOnContextCompaction, type RunTaskOnContextNotice, type RunTaskOnSession, type RunTaskOptions, type RunTaskResult, type RunTaskResumeState, type RunTaskSessionSummary, type RunTaskState, type RunTaskStateSlice, type RunTaskStatus, type RunTaskToolTraceSlice, type RuntimeCustomToolConfig, type RuntimeExternalToolConfig, type RuntimeFlowToolConfig, type RuntimeLocalToolConfig, type RuntimeSubagentToolConfig, type RuntimeTool, type RuntimeToolConfig, Runtype, RuntypeApiError, RuntypeClient, type ConditionalStepConfig as RuntypeConditionalStepConfig, type RuntypeConfig, type FetchGitHubStepConfig as RuntypeFetchGitHubStepConfig, type FetchUrlStepConfig as RuntypeFetchUrlStepConfig, RuntypeFlowBuilder, type FlowConfig as RuntypeFlowConfig, type GenerateEmbeddingStepConfig as RuntypeGenerateEmbeddingStepConfig, type Message as RuntypeMessage, type ModelOverride$1 as RuntypeModelOverride, type Prompt as RuntypePrompt, type PromptStepConfig as RuntypePromptStepConfig, type RuntypeRecord, type RecordConfig as RuntypeRecordConfig, type RetrieveRecordStepConfig as RuntypeRetrieveRecordStepConfig, type SearchStepConfig as RuntypeSearchStepConfig, type SendEmailStepConfig as RuntypeSendEmailStepConfig, type SendEventStepConfig as RuntypeSendEventStepConfig, type SendStreamStepConfig as RuntypeSendStreamStepConfig, type SendTextStepConfig as RuntypeSendTextStepConfig, type SetVariableStepConfig as RuntypeSetVariableStepConfig, type TransformDataStepConfig as RuntypeTransformDataStepConfig, type UpsertFlowConfig as RuntypeUpsertFlowConfig, type UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, type VectorSearchStepConfig as RuntypeVectorSearchStepConfig, type WaitUntilStepConfig as RuntypeWaitUntilStepConfig, STEP_FIELD_REGISTRY, STEP_TYPE_TO_METHOD, type SearchStepConfig$1 as SearchStepConfig, type SendEmailStepConfig$1 as SendEmailStepConfig, type SendEventStepConfig$1 as SendEventStepConfig, type SendStreamStepConfig$1 as SendStreamStepConfig, type SendTextStepConfig$1 as SendTextStepConfig, type SetVariableStepConfig$1 as SetVariableStepConfig, type StepCompleteEvent, type StepDeltaEvent, type StepFallback, type StepFieldMeta, type StepStartEvent, type StepWaitingLocalEvent, type StreamCallbacks, type StreamEvent, type SubagentToolConfig, type TextContentPart, type Tool, type ToolConfig, type ToolExecution, type ToolsConfig, ToolsEndpoint, type TransformDataStepConfig$1 as TransformDataStepConfig, type UpdateClientTokenRequest, type UpdatePromptData, type UpdateProviderKeyRequest, type UpdateToolRequest, type UpsertFlowConfig$1 as UpsertFlowConfig, type UpsertOptions, type UpsertRecordStepConfig$1 as UpsertRecordStepConfig, type UserProfile, UsersEndpoint, type VectorSearchStepConfig$1 as VectorSearchStepConfig, type WaitUntilStepConfig$1 as WaitUntilStepConfig, type WorkflowContext, type WorkflowDefinition, type WorkflowPhase, applyGeneratedRuntimeToolProposalToDispatchRequest, attachRuntimeToolsToDispatchRequest, buildGeneratedRuntimeToolGateOutput, createClient, createExternalTool, defaultWorkflow, deployWorkflow, evaluateGeneratedRuntimeToolProposal, gameWorkflow, getDefaultPlanPath, getLikelySupportingCandidatePaths, isDiscoveryToolName, isMarathonArtifactPath, isPreservationSensitiveTask, normalizeCandidatePath, parseFinalBuffer, parseSSEChunk, processStream, sanitizeTaskSlug, streamEvents };
5527
+ export { type Agent, type AgentApprovalCompleteEvent, type AgentApprovalStartEvent, type AgentCompleteEvent, type AgentErrorEvent, type AgentEvent, type AgentEventType, type AgentExecuteRequest, type AgentExecuteResponse, type AgentIterationCompleteEvent, type AgentIterationStartEvent, type AgentMediaEvent, type AgentMessage, type AgentPausedEvent, type AgentPingEvent, type AgentReflectionEvent, type AgentRuntimeToolDefinition, type AgentStartEvent, type AgentStreamCallbacks, type AgentSubagentConfig, type AgentToolCompleteEvent, type AgentToolDeltaEvent, type AgentToolInputCompleteEvent, type AgentToolInputDeltaEvent, type AgentToolStartEvent, type AgentTurnCompleteEvent, type AgentTurnDeltaEvent, type AgentTurnStartEvent, AgentsEndpoint, AnalyticsEndpoint, type ApiClient, type ApiKey, ApiKeysEndpoint, type ApiResponse, type ApplyGeneratedProposalOptions, type ApplyGeneratedProposalResult, type AttachRuntimeToolsOptions, type BaseAgentEvent, BatchBuilder, type BatchClient, type BatchListParams, type BatchOptions, type BatchRequest, type BatchResult, type BatchScheduleConfig, type BatchStatus, BatchesNamespace, type BuiltInTool, type BulkEditCondition, type BulkEditRequest, type BulkEditResponse, type BulkEditResult, ChatEndpoint, ClientBatchBuilder, type ClientConfig, type ClientConversation, ClientEvalBuilder, ClientFlowBuilder, type ClientToken, type ClientTokenConfig, type ClientTokenEnvironment, type ClientTokenVersionPin, ClientTokensEndpoint, type ClientWidgetTheme, type ConditionalStepConfig$1 as ConditionalStepConfig, type ContextErrorHandling, type ContextFallback, ContextTemplatesEndpoint, type CreateApiKeyRequest, type CreateClientTokenRequest, type CreateClientTokenResponse, type CreateFlowRequest, type CreateModelConfigRequest, type CreatePromptData, type CreatePromptRequest, type CreateProviderKeyRequest, type CreateRecordRequest, type CreateToolRequest, type CustomMCPServer, type CustomMCPServerAuth, type CustomToolConfig, type DeployCfSandboxRequest, type DeployCfSandboxResponse, type DeploySandboxRequest, type DeploySandboxResponse, type DispatchClient, DispatchEndpoint, type DispatchEnvironment, type DispatchOptions$1 as DispatchOptions, type DispatchRequest, type ErrorHandlingMode, EvalBuilder, type EvalClient, EvalEndpoint, type EvalListParams, type EvalOptions, type EvalRecord, type EvalRequest, type EvalResult, type EvalRunConfig, EvalRunner, type EvalStatus, EvalsNamespace, type ExecuteToolRequest, type ExecuteToolResponse, type ExternalAgentContext, type ExternalToolConfig, type FallbackFailEvent, type FallbackStartEvent, type FallbackSuccessEvent, type FallbacksExhaustedEvent, type FallbacksInitiatedEvent, type FetchGitHubStepConfig$1 as FetchGitHubStepConfig, type FetchUrlStepConfig$1 as FetchUrlStepConfig, type FieldFormat, type FileContentPart, type Flow, type FlowAttachment, FlowBuilder, type FlowCompleteEvent, type FlowConfig$1 as FlowConfig, type FlowErrorEvent, type FlowFallback, type FlowPausedEvent, FlowResult, type FlowStartEvent, type FlowStep, FlowStepsEndpoint, type FlowSummary, type FlowToolConfig, FlowsEndpoint, FlowsNamespace, type GenerateEmbeddingStepConfig$1 as GenerateEmbeddingStepConfig, type GeneratedRuntimeToolGateDecision, type GeneratedRuntimeToolGateOptions, type ImageContentPart, type JSONSchema, type JsonArray, type JsonObject, type JsonPrimitive, type JsonValue, type ListConversationsResponse, type ListParams, type LocalToolConfig, type LocalToolDefinition, type LocalToolExecutionCompleteEvent, type LocalToolExecutionLoopSnapshotSlice, type LocalToolExecutionStartEvent, type Message$1 as Message, type MessageContent, type Metadata, type ModelConfig, ModelConfigsEndpoint, type ModelFallback, type ModelOverride, type ModelUsageDetail, type ModelUsageQueryParams, type ModelUsageResponse, type ModelUsageSummary, type ModelUsageTimeSeries, type PaginationResponse, type Prompt$1 as Prompt, type PromptErrorHandling, type PromptFallback, type PromptListParams, type PromptRunOptions, PromptRunner, type PromptStepConfig$1 as PromptStepConfig, PromptsEndpoint, PromptsNamespace, type ProviderApiKey, type ReasoningConfig, type ReasoningValue, type RecordConfig$1 as RecordConfig, type RecordFilter, type RecordFilterCondition, type RecordFilterGroup, type RecordFilterOperator, type RecordListParams, RecordsEndpoint, type RetrieveRecordStepConfig$1 as RetrieveRecordStepConfig, type RetryFallback, type RunTaskContextBudgetBreakdown, type RunTaskContextCompactionEvent, type RunTaskContextCompactionStrategy, type RunTaskContextNoticeEvent, type RunTaskContinuation, type RunTaskOnContextCompaction, type RunTaskOnContextNotice, type RunTaskOnSession, type RunTaskOptions, type RunTaskResult, type RunTaskResumeState, type RunTaskSessionSummary, type RunTaskState, type RunTaskStateSlice, type RunTaskStatus, type RunTaskToolTraceSlice, type RuntimeCustomToolConfig, type RuntimeExternalToolConfig, type RuntimeFlowToolConfig, type RuntimeLocalToolConfig, type RuntimeSubagentToolConfig, type RuntimeTool, type RuntimeToolConfig, Runtype, RuntypeApiError, RuntypeClient, type ConditionalStepConfig as RuntypeConditionalStepConfig, type RuntypeConfig, type FetchGitHubStepConfig as RuntypeFetchGitHubStepConfig, type FetchUrlStepConfig as RuntypeFetchUrlStepConfig, RuntypeFlowBuilder, type FlowConfig as RuntypeFlowConfig, type GenerateEmbeddingStepConfig as RuntypeGenerateEmbeddingStepConfig, type Message as RuntypeMessage, type ModelOverride$1 as RuntypeModelOverride, type Prompt as RuntypePrompt, type PromptStepConfig as RuntypePromptStepConfig, type RuntypeRecord, type RecordConfig as RuntypeRecordConfig, type RetrieveRecordStepConfig as RuntypeRetrieveRecordStepConfig, type SearchStepConfig as RuntypeSearchStepConfig, type SendEmailStepConfig as RuntypeSendEmailStepConfig, type SendEventStepConfig as RuntypeSendEventStepConfig, type SendStreamStepConfig as RuntypeSendStreamStepConfig, type SendTextStepConfig as RuntypeSendTextStepConfig, type SetVariableStepConfig as RuntypeSetVariableStepConfig, type TransformDataStepConfig as RuntypeTransformDataStepConfig, type UpsertFlowConfig as RuntypeUpsertFlowConfig, type UpsertRecordStepConfig as RuntypeUpsertRecordStepConfig, type VectorSearchStepConfig as RuntypeVectorSearchStepConfig, type WaitUntilStepConfig as RuntypeWaitUntilStepConfig, STEP_FIELD_REGISTRY, STEP_TYPE_TO_METHOD, type SearchStepConfig$1 as SearchStepConfig, type SendEmailStepConfig$1 as SendEmailStepConfig, type SendEventStepConfig$1 as SendEventStepConfig, type SendStreamStepConfig$1 as SendStreamStepConfig, type SendTextStepConfig$1 as SendTextStepConfig, type SetVariableStepConfig$1 as SetVariableStepConfig, type StepCompleteEvent, type StepDeltaEvent, type StepFallback, type StepFieldMeta, type StepStartEvent, type StepWaitingLocalEvent, type StreamCallbacks, type StreamEvent, type SubagentToolConfig, type TextContentPart, type Tool, type ToolConfig, type ToolExecution, type ToolsConfig, ToolsEndpoint, type TransformDataStepConfig$1 as TransformDataStepConfig, type UpdateClientTokenRequest, type UpdatePromptData, type UpdateProviderKeyRequest, type UpdateToolRequest, type UpsertFlowConfig$1 as UpsertFlowConfig, type UpsertOptions, type UpsertRecordStepConfig$1 as UpsertRecordStepConfig, type UserProfile, UsersEndpoint, type VectorSearchStepConfig$1 as VectorSearchStepConfig, type WaitUntilStepConfig$1 as WaitUntilStepConfig, type WorkflowContext, type WorkflowDefinition, type WorkflowPhase, applyGeneratedRuntimeToolProposalToDispatchRequest, attachRuntimeToolsToDispatchRequest, buildGeneratedRuntimeToolGateOutput, createClient, createExternalTool, defaultWorkflow, deployWorkflow, evaluateGeneratedRuntimeToolProposal, gameWorkflow, getDefaultPlanPath, getLikelySupportingCandidatePaths, isDiscoveryToolName, isMarathonArtifactPath, isPreservationSensitiveTask, normalizeCandidatePath, parseFinalBuffer, parseSSEChunk, processStream, sanitizeTaskSlug, streamEvents };
package/dist/index.mjs CHANGED
@@ -3665,7 +3665,10 @@ var RecordsEndpoint = class {
3665
3665
  return this.client.delete(`/records/${id}/results`, { resultId });
3666
3666
  }
3667
3667
  /**
3668
- * Upload CSV file to create multiple records
3668
+ * Upload CSV file to create multiple records.
3669
+ * Provide either `typeColumn` (read each row's type from a column) or
3670
+ * `typeValue` (assign the same constant type to every row). `typeValue`
3671
+ * takes precedence when both are supplied.
3669
3672
  */
3670
3673
  async uploadCsv(file, params) {
3671
3674
  const formData = new FormData();
@@ -3676,6 +3679,9 @@ var RecordsEndpoint = class {
3676
3679
  if (params?.nameColumn) {
3677
3680
  formData.append("nameColumn", params.nameColumn);
3678
3681
  }
3682
+ if (params?.typeValue) {
3683
+ formData.append("typeValue", params.typeValue);
3684
+ }
3679
3685
  return this.client.postFormData("/records/upload-csv", formData);
3680
3686
  }
3681
3687
  /**
@@ -4243,7 +4249,12 @@ var EvalEndpoint = class {
4243
4249
  }
4244
4250
  /**
4245
4251
  * Run virtual eval with streaming response
4246
- * Executes multiple eval configs simultaneously and streams results via multiplexed SSE
4252
+ * Executes multiple eval configs simultaneously and streams results via multiplexed SSE.
4253
+ *
4254
+ * Targets are mutually exclusive — provide exactly one of `flowId`,
4255
+ * `flowDefinition`, or `agentId`. The `agentId` form targets a
4256
+ * `claude_managed` agent; combine with per-config `claudeManagedOverride`
4257
+ * to vary model / system prompt / tool permissions across configs.
4247
4258
  */
4248
4259
  async runVirtualEval(data) {
4249
4260
  return this.client.requestStream("/eval/stream", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@runtypelabs/sdk",
3
- "version": "1.24.1",
3
+ "version": "2.0.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",