@agents24/node 0.5.25 → 0.5.27

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.
@@ -471,6 +471,8 @@ declare class DelegationsNamespace {
471
471
  act(runId: string, handle: string, request: DelegationActionRequest, options?: RequestOptions): Promise<Record<string, unknown>>;
472
472
  }
473
473
 
474
+ type ModelRuntimeKind = "chat" | "embedding" | "speech_to_text" | "image_generation" | "rerank" | "ocr";
475
+ type ModelPricingDimension = "audio_input_second" | "audio_input_token" | "audio_output_token" | "cached_input_token" | "image_output" | "input_token" | "ocr_page" | "output_token" | "reasoning_token" | "request" | "search_request";
474
476
  type ModelCapabilityFeatures = {
475
477
  tool_calling: boolean;
476
478
  structured_output: boolean;
@@ -500,6 +502,8 @@ type ModelRequirements = {
500
502
  input_modalities?: Array<ModelInputModality>;
501
503
  output_modalities?: Array<ModelOutputModality>;
502
504
  required_features?: Array<"tool_calling" | "structured_output" | "reasoning" | "segment_timestamps" | "word_timestamps">;
505
+ providers?: Array<string>;
506
+ runtime_kinds?: Array<"chat" | "embedding" | "speech_to_text" | "image_generation" | "rerank" | "ocr">;
503
507
  };
504
508
 
505
509
  type Agents24NodeOptions = {
@@ -1096,7 +1100,7 @@ type ResourcePackageDependency = {
1096
1100
  required: boolean;
1097
1101
  bundled: boolean;
1098
1102
  included?: boolean;
1099
- required_capability?: "chat" | "embedding" | "speech_to_text" | "rerank";
1103
+ required_capability?: "chat" | "embedding" | "speech_to_text" | "rerank" | "ocr";
1100
1104
  status?: "bundled" | "mapped" | "unresolved";
1101
1105
  mapped_id?: string | null;
1102
1106
  suggested_mapping?: {
@@ -1118,7 +1122,7 @@ type ResourcePackageExportPlan = {
1118
1122
  kind: string;
1119
1123
  name?: string | null;
1120
1124
  required: boolean;
1121
- required_capability?: "chat" | "embedding" | "speech_to_text" | "rerank";
1125
+ required_capability?: "chat" | "embedding" | "speech_to_text" | "rerank" | "ocr";
1122
1126
  }>;
1123
1127
  warnings: string[];
1124
1128
  blockers: Array<{
@@ -1185,7 +1189,7 @@ type ResourcePackageCandidateOptions = {
1185
1189
  query?: string;
1186
1190
  limit?: number;
1187
1191
  offset?: number;
1188
- requiredCapability?: "chat" | "embedding" | "speech_to_text" | "rerank";
1192
+ requiredCapability?: "chat" | "embedding" | "speech_to_text" | "rerank" | "ocr";
1189
1193
  };
1190
1194
  type ResourceInstallationBinding = {
1191
1195
  resource_key: string;
@@ -1887,6 +1891,9 @@ type IngestionJob = {
1887
1891
  completed_at?: string | null;
1888
1892
  knowledge_namespaces?: Record<string, string>;
1889
1893
  job_kind?: "pipeline" | "indexed_cleanup";
1894
+ retention?: RagRetention;
1895
+ input_params?: Record<string, unknown>;
1896
+ input_availability?: PayloadAvailability;
1890
1897
  };
1891
1898
  type IngestionJobPage = {
1892
1899
  items: Array<IngestionJob>;
@@ -2022,7 +2029,7 @@ type FileAssetReference = {
2022
2029
  source: SourceDescriptor;
2023
2030
  };
2024
2031
  type EvidenceLocation = {
2025
- kind: "pdf" | "docx" | "media" | "text" | "record";
2032
+ kind: "pdf" | "docx" | "media" | "text" | "record" | "image";
2026
2033
  page_number?: number | null;
2027
2034
  total_pages?: number | null;
2028
2035
  bbox?: Array<number> | null;
@@ -2151,6 +2158,204 @@ type SourceOutcome = {
2151
2158
  language?: string | null;
2152
2159
  duration_ms?: number | null;
2153
2160
  };
2161
+ type RagRetention = {
2162
+ version?: number;
2163
+ pipeline_type?: string;
2164
+ inspection_days?: 0 | 1 | 7 | 30 | 90;
2165
+ capture_reason?: string;
2166
+ attempt?: number;
2167
+ inspection_expires_at?: string | null;
2168
+ inspection_status?: "disabled" | "available" | "expired" | "partial";
2169
+ };
2170
+ type JobStep = {
2171
+ id?: string;
2172
+ job_id?: string;
2173
+ step_id: string;
2174
+ operator_id: string;
2175
+ status: string;
2176
+ metadata?: Record<string, unknown>;
2177
+ failure?: FailureView | null;
2178
+ execution_order?: number;
2179
+ started_at?: string | null;
2180
+ completed_at?: string | null;
2181
+ has_input_data?: boolean;
2182
+ has_output_data?: boolean;
2183
+ input_availability?: PayloadAvailability;
2184
+ output_availability?: PayloadAvailability;
2185
+ };
2186
+ type JobSteps = {
2187
+ steps: Array<JobStep>;
2188
+ };
2189
+ type JobStepData = {
2190
+ availability?: "available" | "unavailable";
2191
+ reason?: string;
2192
+ data: unknown;
2193
+ total?: number;
2194
+ page?: number;
2195
+ pages?: number;
2196
+ is_list?: boolean;
2197
+ truncated_fields?: Record<string, unknown>;
2198
+ };
2199
+ type JobFieldData = {
2200
+ availability?: "available" | "unavailable";
2201
+ reason?: string;
2202
+ data?: unknown;
2203
+ content?: string;
2204
+ is_string?: boolean;
2205
+ offset?: number;
2206
+ limit?: number;
2207
+ total_size?: number;
2208
+ has_more?: boolean;
2209
+ };
2210
+ type JobPayloadDownload = {
2211
+ availability: "available" | "unavailable" | "expired";
2212
+ reason?: string;
2213
+ data?: unknown;
2214
+ url?: string;
2215
+ encoding?: "gzip" | "json";
2216
+ path?: string | null;
2217
+ expires_in?: number;
2218
+ };
2219
+ type JobResult = {
2220
+ data: unknown;
2221
+ retention: RagRetention;
2222
+ };
2223
+ type JobStepDataOptions = {
2224
+ type: "input" | "output";
2225
+ page?: number;
2226
+ limit?: number;
2227
+ reference_id?: string;
2228
+ };
2229
+ type JobStepFieldOptions = {
2230
+ type: "input" | "output";
2231
+ path: string;
2232
+ offset?: number;
2233
+ limit?: number;
2234
+ reference_id?: string;
2235
+ };
2236
+ type JobStepDownloadOptions = {
2237
+ type: "input" | "output";
2238
+ reference_id?: string;
2239
+ };
2240
+ type ProcessedContentOptions = {
2241
+ reference: string;
2242
+ };
2243
+ type NamespaceInput = {
2244
+ namespace: string;
2245
+ };
2246
+ type RawVectorRecord = {
2247
+ id: string;
2248
+ values: Array<number>;
2249
+ metadata?: Record<string, unknown>;
2250
+ };
2251
+ type RecordUpsertRequest = {
2252
+ namespace: string;
2253
+ records: Array<RawVectorRecord>;
2254
+ };
2255
+ type RecordFetchRequest = {
2256
+ namespace: string;
2257
+ ids: Array<string>;
2258
+ };
2259
+ type RecordListRequest = {
2260
+ namespace: string;
2261
+ prefix?: string | null;
2262
+ limit?: number;
2263
+ cursor?: string | null;
2264
+ };
2265
+ type RecordQueryRequest = {
2266
+ namespace: string;
2267
+ vector?: Array<number> | null;
2268
+ id?: string | null;
2269
+ top_k?: number;
2270
+ filter?: Record<string, unknown> | null;
2271
+ include_values?: boolean;
2272
+ };
2273
+ type RecordUpdateRequest = {
2274
+ namespace: string;
2275
+ id: string;
2276
+ values?: Array<number> | null;
2277
+ metadata?: Record<string, unknown> | null;
2278
+ };
2279
+ type RecordDeleteRequest = {
2280
+ namespace: string;
2281
+ ids?: Array<string> | null;
2282
+ filter?: Record<string, unknown> | null;
2283
+ all?: boolean;
2284
+ };
2285
+ type RawVectorMatch = {
2286
+ id: string;
2287
+ score: number;
2288
+ metadata: Record<string, unknown>;
2289
+ values?: Array<number> | null;
2290
+ };
2291
+ type RecordMutationAck = {
2292
+ acknowledged?: boolean;
2293
+ acknowledged_ids?: Array<string> | null;
2294
+ };
2295
+ type RecordFetchResult = {
2296
+ records: Record<string, RawVectorRecord>;
2297
+ missing_ids: Array<string>;
2298
+ };
2299
+ type RecordPage = {
2300
+ ids: Array<string>;
2301
+ next_cursor: string | null;
2302
+ };
2303
+ type RecordQueryResult = {
2304
+ matches: Array<RawVectorMatch>;
2305
+ metric: string;
2306
+ };
2307
+ type NamespaceSummary = {
2308
+ name: string;
2309
+ record_count: number;
2310
+ };
2311
+ type NamespacePage = {
2312
+ namespaces: Array<NamespaceSummary>;
2313
+ next_cursor: string | null;
2314
+ };
2315
+ type RecordCapabilities = {
2316
+ record_listing: boolean;
2317
+ prefix_listing: boolean;
2318
+ namespace_listing: boolean;
2319
+ max_records: number;
2320
+ max_ids: number;
2321
+ max_page_size: number;
2322
+ max_top_k: number;
2323
+ max_request_bytes: number;
2324
+ };
2325
+ type NamespaceDataStats = {
2326
+ record_count: number;
2327
+ dimension: number;
2328
+ metric: string;
2329
+ observed_at: string;
2330
+ capabilities: RecordCapabilities;
2331
+ };
2332
+ type NamespaceListOptions = {
2333
+ limit?: number;
2334
+ cursor?: string | null;
2335
+ };
2336
+ type RecordBatchResult = {
2337
+ acknowledged_ids: Array<string>;
2338
+ failed_ids: Array<string>;
2339
+ unknown_ids: Array<string>;
2340
+ failure?: FailureView;
2341
+ };
2342
+ type PayloadAvailability = {
2343
+ availability: "available" | "unavailable";
2344
+ reason?: string;
2345
+ expires_at?: string;
2346
+ };
2347
+ type OCROptions = {
2348
+ model_id: string;
2349
+ language_hints?: Array<string>;
2350
+ };
2351
+ type IndexedRecordIdPage = {
2352
+ ids: Array<string>;
2353
+ next_cursor: string | null;
2354
+ };
2355
+ type IndexedRecordIdListOptions = {
2356
+ cursor?: string;
2357
+ limit?: number;
2358
+ };
2154
2359
 
2155
2360
  declare class PipelinesNamespace {
2156
2361
  protected readonly http: Agents24HttpClient;
@@ -2176,6 +2381,12 @@ declare class IngestionJobsNamespace {
2176
2381
  putUploadPart(sessionId: string, partNumber: string, data: Blob): Promise<UploadPartAck>;
2177
2382
  completeUpload(sessionId: string, options?: RequestOptions): Promise<UploadSession>;
2178
2383
  abortUpload(sessionId: string, options?: RequestOptions): Promise<UploadSession>;
2384
+ listSteps(jobId: string): Promise<JobSteps>;
2385
+ getStepData(jobId: string, stepId: string, options: JobStepDataOptions): Promise<JobStepData>;
2386
+ getStepField(jobId: string, stepId: string, options: JobStepFieldOptions): Promise<JobFieldData>;
2387
+ downloadStepData(jobId: string, stepId: string, options: JobStepDownloadOptions): Promise<JobPayloadDownload>;
2388
+ getResult(jobId: string): Promise<JobResult>;
2389
+ getProcessedContent(jobId: string, options: ProcessedContentOptions): Promise<JobResult>;
2179
2390
  }
2180
2391
 
2181
2392
  declare class KnowledgeStoresNamespace {
@@ -2189,10 +2400,24 @@ declare class KnowledgeStoresNamespace {
2189
2400
  archive(storeId: string): Promise<void>;
2190
2401
  listIndexedContent(storeId: string, options: IndexedContentListOptions): Promise<IndexedContentPage>;
2191
2402
  getIndexedContent(storeId: string, indexedId: string): Promise<IndexedContent>;
2403
+ listIndexedRecordIds(storeId: string, indexedId: string, options: IndexedRecordIdListOptions): Promise<IndexedRecordIdPage>;
2192
2404
  deleteIndexedContent(storeId: string, indexedId: string, options?: RequestOptions): Promise<IndexedCleanupAck>;
2193
2405
  getCleanupJob(storeId: string, jobId: string): Promise<IngestionJob>;
2194
2406
  resumeCleanupJob(storeId: string, jobId: string, options?: RequestOptions): Promise<IngestionJob>;
2195
2407
  cancelCleanupJob(storeId: string, jobId: string, options?: RequestOptions): Promise<IngestionJob>;
2408
+ upsertRecords(storeId: string, request: RecordUpsertRequest): Promise<RecordMutationAck>;
2409
+ fetchRecords(storeId: string, request: RecordFetchRequest): Promise<RecordFetchResult>;
2410
+ listRecords(storeId: string, request: RecordListRequest): Promise<RecordPage>;
2411
+ queryRecords(storeId: string, request: RecordQueryRequest): Promise<RecordQueryResult>;
2412
+ updateRecord(storeId: string, request: RecordUpdateRequest): Promise<RecordMutationAck>;
2413
+ deleteRecords(storeId: string, request: RecordDeleteRequest): Promise<RecordMutationAck>;
2414
+ listNamespaces(storeId: string, options?: NamespaceListOptions): Promise<NamespacePage>;
2415
+ namespaceStats(storeId: string, request: NamespaceInput): Promise<NamespaceDataStats>;
2416
+ listRecordPages(storeId: string, request: RecordListRequest): AsyncGenerator<RecordPage>;
2417
+ upsertRecordsBatched(storeId: string, request: RecordUpsertRequest, limits?: {
2418
+ maxRecords?: number;
2419
+ maxBytes?: number;
2420
+ }): Promise<RecordBatchResult>;
2196
2421
  }
2197
2422
 
2198
2423
  declare class GeneratedIntegrationNamespaces {
@@ -2220,4 +2445,4 @@ declare class Agents24 extends GeneratedIntegrationNamespaces {
2220
2445
  graph(): GraphBuilder;
2221
2446
  }
2222
2447
 
2223
- export { type CustomerResourcePolicyAssignment as $, Agents24 as A, type BackendSessionRequestOptions as B, type ClearCustomerResourcePolicyAssignmentResult as C, type ClientDeploymentListQuery as D, type ClientDeploymentListResponse as E, type ClientNativeProfile as F, type ClientRuntimeNativeProfileInput as G, type ClientRuntimeOidcConfig as H, type ClientRuntimePolicyInput as I, type ClientSessionCredentials as J, type ContentChunk as K, type ContentSegment as L, type ControlPlaneAgentRunRequest as M, type ControlPlaneRunEventsResponse as N, type ConversationRunRequest as O, type ConversationRunResult as P, type ConversationRuntimeSelectionRequest as Q, type ConversationRuntimeSelectionResult as R, type ConversationThreadOptions as S, type CreateBackendClientSessionRequest as T, type CreateClientDeploymentRequest as U, type CustomerIdentityRequest as V, type CustomerPrincipalRefRequest as W, type CustomerProfile as X, type CustomerProfileList as Y, type CustomerProfilePatch as Z, type CustomerProfileSearchOptions as _, type AgentCreateRequest as a, type McpAuthStartRequest as a$, type DelegationAction as a0, type DelegationActionReceipt as a1, type DelegationActionRequest as a2, type DelegationEvents as a3, type DelegationHistory as a4, type DelegationHistoryTurn as a5, type DelegationStatus as a6, type DelegationTask as a7, type DelegationTaskList as a8, type EffectiveCustomerResourcePolicyRequest as a9, type GraphValueRef as aA, type HitlAction as aB, type HitlAnswer as aC, type HostedArtifactDraft as aD, HostedArtifactsNamespace as aE, type IndexedCleanupAck as aF, type IndexedContent as aG, type IndexedContentListOptions as aH, type IndexedContentPage as aI, type IngestionBatch as aJ, type IngestionBatchListOptions as aK, type IngestionBatchPage as aL, type IngestionJob as aM, type IngestionJobAcknowledgment as aN, type IngestionJobGetOptions as aO, type IngestionJobListOptions as aP, type IngestionJobPage as aQ, type IngestionJobStart as aR, type KnowledgeStore as aS, type KnowledgeStoreChunking as aT, type KnowledgeStoreCreate as aU, type KnowledgeStoreListOptions as aV, type KnowledgeStoreNamespace as aW, type KnowledgeStorePage as aX, type KnowledgeStoreStats as aY, type KnowledgeStoreUpdate as aZ, type LatestOrPinnedPolicy as a_, type EffectiveResourcePolicy as aa, type EmbedAgentAliasResolution as ab, type EmbedAttachmentContentAccessRequest as ac, type EmbedCustomerPrincipalResolveRequest as ad, type EmbedCustomerPrincipalResolveResponse as ae, type EmbedDelegationOptions as af, type EmbedResourcePolicyRequest as ag, type EmbedRunCancelOptions as ah, type EmbedRunStartRequest as ai, type EmbedRuntimeBootstrap as aj, type EmbedStreamRequest as ak, type EmbedThreadMessageEdit as al, type EmbedThreadMessageScope as am, type EmbedThreadMessageSubmit as an, type EmbeddedResponseFeedbackInput as ao, type EvidenceLocation as ap, type FailureCategory as aq, type FailureView as ar, type FeedbackRating as as, type FeedbackReason as at, type FileAssetReference as au, GraphBuilder as av, type GraphDefinition as aw, type GraphEdge as ax, type GraphHints as ay, type GraphNode as az, AgentDefinitionBuilder as b, type ResourcePolicySummary as b$, type McpAuthStartResult as b0, type ModelCapabilitiesV1 as b1, type ModelRequirements as b2, type MultiAgentThreadListRequest as b3, type MultiAgentThreadSummaryEventOptions as b4, type NativePlatform as b5, type NodeAuthoringSpec as b6, type NodeCatalogItem as b7, type NodeCatalogResponse as b8, type NodeSchemaResponse as b9, type ResourceInstallationOperation as bA, type ResourceInstallationPlan as bB, type ResourceInstallationPlanUpload as bC, type ResourceInstallationPublication as bD, type ResourceInstallationPublishRequest as bE, type ResourceInstallationPullAcceptRequest as bF, type ResourceInstallationPullChange as bG, type ResourceInstallationPullPayload as bH, type ResourceInstallationPullPlan as bI, type ResourceInstallationResourceListOptions as bJ, type ResourceInstallationSecretStatus as bK, type ResourceInstallationSecretsRequest as bL, type ResourcePackageArchive as bM, type ResourcePackageCandidateOptions as bN, type ResourcePackageDependency as bO, type ResourcePackageDiagnostic as bP, type ResourcePackageExportPlan as bQ, type ResourcePackageExportRequest as bR, type ResourcePackageImportPreview as bS, type ResourcePackageImportResult as bT, type ResourcePackageImportUpload as bU, type ResourcePackageUpload as bV, type ResourcePackageValidationResult as bW, type ResourcePolicyList as bX, type ResourcePolicyQuotaSchedule as bY, type ResourcePolicyQuotaScheduleResult as bZ, type ResourcePolicySubjectRef as b_, type PipelineInputField as ba, type PipelineInputSchema as bb, type PipelineInputStep as bc, type PipelineInputUpload as bd, type PipelineListOptions as be, type PipelinePage as bf, type PipelineSummary as bg, type PortableResourceKind as bh, type ProcessedContent as bi, type ProcessedContentReference as bj, type ProcessingInput as bk, type ProcessingInputSource as bl, type PublishedExecutable as bm, type RequestOptions as bn, type ResetResourcePolicyQuotaRequest as bo, type ResourceCallableBinding as bp, type ResourceCallableBindingStatus as bq, type ResourceCandidateList as br, type ResourceInstallation as bs, type ResourceInstallationApplication as bt, type ResourceInstallationApplyRequest as bu, type ResourceInstallationBinding as bv, type ResourceInstallationCreateRequest as bw, type ResourceInstallationDeploymentRequest as bx, type ResourceInstallationLinkRequest as by, type ResourceInstallationList as bz, type AgentDefinitionOptions as c, type ResourceSelector as c0, type ResourceToolExport as c1, type ResponseFeedback as c2, type ResponseFeedbackResult as c3, type ResumeRunRequest as c4, type RetrievalEvidence as c5, type RunCancelOptions as c6, type RunContextOptions as c7, type RunStatus as c8, type RunTrace as c9, type UpdateClientDeploymentRequest as cA, type UploadPart as cB, type UploadPartAck as cC, type UploadSession as cD, type UploadSessionStart as cE, type WorkflowInputDefinition as cF, type ServerAttachmentUploadOptions as ca, type ServerEmbedAttachmentUploadOptions as cb, type SetCustomerResourcePolicyAssignmentRequest as cc, type SetResourcePolicyQuotaScheduleRequest as cd, type SourceDescriptor as ce, type SourceOutcome as cf, type StartRunResult as cg, type StateVariableDefinition as ch, type StreamRequestOptions as ci, type StreamResult as cj, type ThreadComputerContentAccess as ck, type ThreadComputerFile as cl, type ThreadComputerFileOptions as cm, type ThreadComputerFileText as cn, type ThreadComputerFiles as co, type ThreadComputerStatus as cp, type ThreadDeleteOptions as cq, type ThreadDetailOptions as cr, type ThreadListOptions as cs, type ThreadSummaryEventOptions as ct, type TraceContent as cu, type TraceError as cv, type TraceSpan as cw, type TraceSpanKind as cx, type TraceSpanStatus as cy, type TraceView as cz, type AgentListResponse as d, type AgentRef as e, type AgentResponse as f, type AgentStreamRequest as g, type AgentSummary as h, type AgentToolsetAttachment as i, type AgentUpdateRequest as j, type AgentValidationIssue as k, type AgentValidationResult as l, Agents24SDKError as m, type Agents24NodeErrorKind as n, type Agents24NodeOptions as o, type Agents24Options as p, type Agents24SDKErrorKind as q, type Agents24SDKSerializedError as r, type ArtifactDevelopmentSession as s, type ArtifactDevelopmentSessionAdmission as t, type ArtifactDevelopmentSessionPrepareRequest as u, type AttachRunRequest as v, type AttachmentContentAccessRequest as w, type BranchingHint as x, type ClientAuthMode as y, type ClientDeployment as z };
2448
+ export { type CustomerResourcePolicyAssignment as $, Agents24 as A, type BackendSessionRequestOptions as B, type ClearCustomerResourcePolicyAssignmentResult as C, type ClientDeploymentListQuery as D, type ClientDeploymentListResponse as E, type ClientNativeProfile as F, type ClientRuntimeNativeProfileInput as G, type ClientRuntimeOidcConfig as H, type ClientRuntimePolicyInput as I, type ClientSessionCredentials as J, type ContentChunk as K, type ContentSegment as L, type ControlPlaneAgentRunRequest as M, type ControlPlaneRunEventsResponse as N, type ConversationRunRequest as O, type ConversationRunResult as P, type ConversationRuntimeSelectionRequest as Q, type ConversationRuntimeSelectionResult as R, type ConversationThreadOptions as S, type CreateBackendClientSessionRequest as T, type CreateClientDeploymentRequest as U, type CustomerIdentityRequest as V, type CustomerPrincipalRefRequest as W, type CustomerProfile as X, type CustomerProfileList as Y, type CustomerProfilePatch as Z, type CustomerProfileSearchOptions as _, type AgentCreateRequest as a, type JobStepFieldOptions as a$, type DelegationAction as a0, type DelegationActionReceipt as a1, type DelegationActionRequest as a2, type DelegationEvents as a3, type DelegationHistory as a4, type DelegationHistoryTurn as a5, type DelegationStatus as a6, type DelegationTask as a7, type DelegationTaskList as a8, type EffectiveCustomerResourcePolicyRequest as a9, type GraphValueRef as aA, type HitlAction as aB, type HitlAnswer as aC, type HostedArtifactDraft as aD, HostedArtifactsNamespace as aE, type IndexedCleanupAck as aF, type IndexedContent as aG, type IndexedContentListOptions as aH, type IndexedContentPage as aI, type IndexedRecordIdListOptions as aJ, type IndexedRecordIdPage as aK, type IngestionBatch as aL, type IngestionBatchListOptions as aM, type IngestionBatchPage as aN, type IngestionJob as aO, type IngestionJobAcknowledgment as aP, type IngestionJobGetOptions as aQ, type IngestionJobListOptions as aR, type IngestionJobPage as aS, type IngestionJobStart as aT, type JobFieldData as aU, type JobPayloadDownload as aV, type JobResult as aW, type JobStep as aX, type JobStepData as aY, type JobStepDataOptions as aZ, type JobStepDownloadOptions as a_, type EffectiveResourcePolicy as aa, type EmbedAgentAliasResolution as ab, type EmbedAttachmentContentAccessRequest as ac, type EmbedCustomerPrincipalResolveRequest as ad, type EmbedCustomerPrincipalResolveResponse as ae, type EmbedDelegationOptions as af, type EmbedResourcePolicyRequest as ag, type EmbedRunCancelOptions as ah, type EmbedRunStartRequest as ai, type EmbedRuntimeBootstrap as aj, type EmbedStreamRequest as ak, type EmbedThreadMessageEdit as al, type EmbedThreadMessageScope as am, type EmbedThreadMessageSubmit as an, type EmbeddedResponseFeedbackInput as ao, type EvidenceLocation as ap, type FailureCategory as aq, type FailureView as ar, type FeedbackRating as as, type FeedbackReason as at, type FileAssetReference as au, GraphBuilder as av, type GraphDefinition as aw, type GraphEdge as ax, type GraphHints as ay, type GraphNode as az, AgentDefinitionBuilder as b, type ResourceCandidateList as b$, type JobSteps as b0, type KnowledgeStore as b1, type KnowledgeStoreChunking as b2, type KnowledgeStoreCreate as b3, type KnowledgeStoreListOptions as b4, type KnowledgeStoreNamespace as b5, type KnowledgeStorePage as b6, type KnowledgeStoreStats as b7, type KnowledgeStoreUpdate as b8, type LatestOrPinnedPolicy as b9, type PipelineSummary as bA, type PortableResourceKind as bB, type ProcessedContent as bC, type ProcessedContentOptions as bD, type ProcessedContentReference as bE, type ProcessingInput as bF, type ProcessingInputSource as bG, type PublishedExecutable as bH, type RagRetention as bI, type RawVectorMatch as bJ, type RawVectorRecord as bK, type RecordBatchResult as bL, type RecordCapabilities as bM, type RecordDeleteRequest as bN, type RecordFetchRequest as bO, type RecordFetchResult as bP, type RecordListRequest as bQ, type RecordMutationAck as bR, type RecordPage as bS, type RecordQueryRequest as bT, type RecordQueryResult as bU, type RecordUpdateRequest as bV, type RecordUpsertRequest as bW, type RequestOptions as bX, type ResetResourcePolicyQuotaRequest as bY, type ResourceCallableBinding as bZ, type ResourceCallableBindingStatus as b_, type McpAuthStartRequest as ba, type McpAuthStartResult as bb, type ModelCapabilitiesV1 as bc, type ModelPricingDimension as bd, type ModelRequirements as be, type ModelRuntimeKind as bf, type MultiAgentThreadListRequest as bg, type MultiAgentThreadSummaryEventOptions as bh, type NamespaceDataStats as bi, type NamespaceInput as bj, type NamespaceListOptions as bk, type NamespacePage as bl, type NamespaceSummary as bm, type NativePlatform as bn, type NodeAuthoringSpec as bo, type NodeCatalogItem as bp, type NodeCatalogResponse as bq, type NodeSchemaResponse as br, type OCROptions as bs, type PayloadAvailability as bt, type PipelineInputField as bu, type PipelineInputSchema as bv, type PipelineInputStep as bw, type PipelineInputUpload as bx, type PipelineListOptions as by, type PipelinePage as bz, type AgentDefinitionOptions as c, type ThreadDetailOptions as c$, type ResourceInstallation as c0, type ResourceInstallationApplication as c1, type ResourceInstallationApplyRequest as c2, type ResourceInstallationBinding as c3, type ResourceInstallationCreateRequest as c4, type ResourceInstallationDeploymentRequest as c5, type ResourceInstallationLinkRequest as c6, type ResourceInstallationList as c7, type ResourceInstallationOperation as c8, type ResourceInstallationPlan as c9, type ResourceSelector as cA, type ResourceToolExport as cB, type ResponseFeedback as cC, type ResponseFeedbackResult as cD, type ResumeRunRequest as cE, type RetrievalEvidence as cF, type RunCancelOptions as cG, type RunContextOptions as cH, type RunStatus as cI, type RunTrace as cJ, type ServerAttachmentUploadOptions as cK, type ServerEmbedAttachmentUploadOptions as cL, type SetCustomerResourcePolicyAssignmentRequest as cM, type SetResourcePolicyQuotaScheduleRequest as cN, type SourceDescriptor as cO, type SourceOutcome as cP, type StartRunResult as cQ, type StateVariableDefinition as cR, type StreamRequestOptions as cS, type StreamResult as cT, type ThreadComputerContentAccess as cU, type ThreadComputerFile as cV, type ThreadComputerFileOptions as cW, type ThreadComputerFileText as cX, type ThreadComputerFiles as cY, type ThreadComputerStatus as cZ, type ThreadDeleteOptions as c_, type ResourceInstallationPlanUpload as ca, type ResourceInstallationPublication as cb, type ResourceInstallationPublishRequest as cc, type ResourceInstallationPullAcceptRequest as cd, type ResourceInstallationPullChange as ce, type ResourceInstallationPullPayload as cf, type ResourceInstallationPullPlan as cg, type ResourceInstallationResourceListOptions as ch, type ResourceInstallationSecretStatus as ci, type ResourceInstallationSecretsRequest as cj, type ResourcePackageArchive as ck, type ResourcePackageCandidateOptions as cl, type ResourcePackageDependency as cm, type ResourcePackageDiagnostic as cn, type ResourcePackageExportPlan as co, type ResourcePackageExportRequest as cp, type ResourcePackageImportPreview as cq, type ResourcePackageImportResult as cr, type ResourcePackageImportUpload as cs, type ResourcePackageUpload as ct, type ResourcePackageValidationResult as cu, type ResourcePolicyList as cv, type ResourcePolicyQuotaSchedule as cw, type ResourcePolicyQuotaScheduleResult as cx, type ResourcePolicySubjectRef as cy, type ResourcePolicySummary as cz, type AgentListResponse as d, type ThreadListOptions as d0, type ThreadSummaryEventOptions as d1, type TraceContent as d2, type TraceError as d3, type TraceSpan as d4, type TraceSpanKind as d5, type TraceSpanStatus as d6, type TraceView as d7, type UpdateClientDeploymentRequest as d8, type UploadPart as d9, type UploadPartAck as da, type UploadSession as db, type UploadSessionStart as dc, type WorkflowInputDefinition as dd, type AgentRef as e, type AgentResponse as f, type AgentStreamRequest as g, type AgentSummary as h, type AgentToolsetAttachment as i, type AgentUpdateRequest as j, type AgentValidationIssue as k, type AgentValidationResult as l, Agents24SDKError as m, type Agents24NodeErrorKind as n, type Agents24NodeOptions as o, type Agents24Options as p, type Agents24SDKErrorKind as q, type Agents24SDKSerializedError as r, type ArtifactDevelopmentSession as s, type ArtifactDevelopmentSessionAdmission as t, type ArtifactDevelopmentSessionPrepareRequest as u, type AttachRunRequest as v, type AttachmentContentAccessRequest as w, type BranchingHint as x, type ClientAuthMode as y, type ClientDeployment as z };
package/dist/index.cjs CHANGED
@@ -1158,8 +1158,7 @@ var ResourceInstallationsNamespace = class {
1158
1158
  return this.http.requestJson(`/resource-installations/${encodeURIComponent(installationId)}/artifact-development-sessions`, {
1159
1159
  method: "POST",
1160
1160
  body: request,
1161
- options,
1162
- mutation: true
1161
+ options
1163
1162
  });
1164
1163
  }
1165
1164
  developmentSessionStatus(installationId, resourceKey) {
@@ -1532,8 +1531,99 @@ var IngestionJobsNamespace = class {
1532
1531
  mutation: true
1533
1532
  });
1534
1533
  }
1534
+ listSteps(jobId) {
1535
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/steps`);
1536
+ }
1537
+ getStepData(jobId, stepId, options) {
1538
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/steps/${encodeURIComponent(stepId)}/data`, {
1539
+ query: {
1540
+ type: options.type,
1541
+ page: options.page,
1542
+ limit: options.limit,
1543
+ reference_id: options.reference_id
1544
+ }
1545
+ });
1546
+ }
1547
+ getStepField(jobId, stepId, options) {
1548
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/steps/${encodeURIComponent(stepId)}/field`, {
1549
+ query: {
1550
+ type: options.type,
1551
+ path: options.path,
1552
+ offset: options.offset,
1553
+ limit: options.limit,
1554
+ reference_id: options.reference_id
1555
+ }
1556
+ });
1557
+ }
1558
+ downloadStepData(jobId, stepId, options) {
1559
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/steps/${encodeURIComponent(stepId)}/download`, {
1560
+ query: {
1561
+ type: options.type,
1562
+ reference_id: options.reference_id
1563
+ }
1564
+ });
1565
+ }
1566
+ getResult(jobId) {
1567
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/result`);
1568
+ }
1569
+ getProcessedContent(jobId, options) {
1570
+ return this.http.requestJson(`/admin/pipelines/jobs/${encodeURIComponent(jobId)}/processed-content`, {
1571
+ query: {
1572
+ reference: options.reference
1573
+ }
1574
+ });
1575
+ }
1535
1576
  };
1536
1577
 
1578
+ // src/knowledge-record-helpers.ts
1579
+ async function* recordPages(client, storeId, request) {
1580
+ let cursor = request.cursor;
1581
+ do {
1582
+ const page = await client.listRecords(storeId, { ...request, ...cursor ? { cursor } : {} });
1583
+ yield page;
1584
+ if (page.next_cursor && page.next_cursor === cursor) throw new Error("Record cursor did not advance");
1585
+ cursor = page.next_cursor;
1586
+ } while (cursor);
1587
+ }
1588
+ async function recordBatches(client, storeId, request, limits = {}) {
1589
+ const maxRecords = Math.min(limits.maxRecords ?? 100, 100);
1590
+ const maxBytes = Math.min(limits.maxBytes ?? 2 * 1024 * 1024, 2 * 1024 * 1024);
1591
+ if (!Number.isInteger(maxRecords) || maxRecords < 1 || !Number.isInteger(maxBytes) || maxBytes < 1) throw new Error("Invalid batching limits");
1592
+ if (!request.records.length) throw new Error("At least one record is required");
1593
+ if (new Set(request.records.map((record) => record.id)).size !== request.records.length) throw new Error("Duplicate record IDs");
1594
+ const batches = [];
1595
+ let records = [];
1596
+ const size = (items) => new TextEncoder().encode(JSON.stringify({ namespace: request.namespace, records: items })).byteLength;
1597
+ for (const record of request.records) {
1598
+ if (size([record]) > maxBytes) throw new Error("A record exceeds the request byte limit");
1599
+ if (records.length === maxRecords || size([...records, record]) > maxBytes) {
1600
+ batches.push({ namespace: request.namespace, records });
1601
+ records = [];
1602
+ }
1603
+ records.push(record);
1604
+ }
1605
+ if (records.length) batches.push({ namespace: request.namespace, records });
1606
+ const result = { acknowledged_ids: [], failed_ids: [], unknown_ids: [] };
1607
+ for (let index = 0; index < batches.length; index++) {
1608
+ const batch = batches[index];
1609
+ try {
1610
+ const receipt = await client.upsertRecords(storeId, batch);
1611
+ const ids = batch.records.map((record) => record.id);
1612
+ if (!receipt.acknowledged || !receipt.acknowledged_ids || receipt.acknowledged_ids.length !== ids.length || new Set(receipt.acknowledged_ids).size !== ids.length || ids.some((id) => !receipt.acknowledged_ids.includes(id))) {
1613
+ throw new Agents24SDKError("Incomplete record acknowledgement", { kind: "protocol" });
1614
+ }
1615
+ result.acknowledged_ids.push(...ids);
1616
+ } catch (error) {
1617
+ const rejected = error instanceof Agents24SDKError && error.kind === "http" && error.failure && (error.status ?? 500) < 500 && error.code !== "KNOWLEDGE_STORE_OPERATION_UNKNOWN";
1618
+ result[rejected ? "failed_ids" : "unknown_ids"].push(...batch.records.map((record) => record.id));
1619
+ result.failed_ids.push(...batches.slice(index + 1).flatMap((item) => item.records.map((record) => record.id)));
1620
+ if (error instanceof Agents24SDKError && error.failure) result.failure = error.failure;
1621
+ break;
1622
+ }
1623
+ }
1624
+ return result;
1625
+ }
1626
+
1537
1627
  // src/generated/knowledgeStores.ts
1538
1628
  var KnowledgeStoresNamespace = class {
1539
1629
  constructor(http) {
@@ -1586,6 +1676,14 @@ var KnowledgeStoresNamespace = class {
1586
1676
  getIndexedContent(storeId, indexedId) {
1587
1677
  return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/indexed-content/${encodeURIComponent(indexedId)}`);
1588
1678
  }
1679
+ listIndexedRecordIds(storeId, indexedId, options) {
1680
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/indexed-content/${encodeURIComponent(indexedId)}/record-ids`, {
1681
+ query: {
1682
+ cursor: options.cursor,
1683
+ limit: options.limit
1684
+ }
1685
+ });
1686
+ }
1589
1687
  deleteIndexedContent(storeId, indexedId, options) {
1590
1688
  return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/indexed-content/${encodeURIComponent(indexedId)}/delete`, {
1591
1689
  method: "POST",
@@ -1610,6 +1708,62 @@ var KnowledgeStoresNamespace = class {
1610
1708
  mutation: true
1611
1709
  });
1612
1710
  }
1711
+ upsertRecords(storeId, request) {
1712
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/upsert`, {
1713
+ method: "POST",
1714
+ body: request
1715
+ });
1716
+ }
1717
+ fetchRecords(storeId, request) {
1718
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/fetch`, {
1719
+ method: "POST",
1720
+ body: request
1721
+ });
1722
+ }
1723
+ listRecords(storeId, request) {
1724
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/list`, {
1725
+ method: "POST",
1726
+ body: request
1727
+ });
1728
+ }
1729
+ queryRecords(storeId, request) {
1730
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/query`, {
1731
+ method: "POST",
1732
+ body: request
1733
+ });
1734
+ }
1735
+ updateRecord(storeId, request) {
1736
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/update`, {
1737
+ method: "POST",
1738
+ body: request
1739
+ });
1740
+ }
1741
+ deleteRecords(storeId, request) {
1742
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/records/delete`, {
1743
+ method: "POST",
1744
+ body: request
1745
+ });
1746
+ }
1747
+ listNamespaces(storeId, options = {}) {
1748
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/namespaces`, {
1749
+ query: {
1750
+ limit: options.limit ?? 100,
1751
+ cursor: options.cursor
1752
+ }
1753
+ });
1754
+ }
1755
+ namespaceStats(storeId, request) {
1756
+ return this.http.requestJson(`/admin/knowledge-stores/${encodeURIComponent(storeId)}/namespaces/stats`, {
1757
+ method: "POST",
1758
+ body: request
1759
+ });
1760
+ }
1761
+ listRecordPages(storeId, request) {
1762
+ return recordPages(this, storeId, request);
1763
+ }
1764
+ upsertRecordsBatched(storeId, request, limits = {}) {
1765
+ return recordBatches(this, storeId, request, limits);
1766
+ }
1613
1767
  };
1614
1768
 
1615
1769
  // src/generated/integration-namespaces.ts
@@ -1774,10 +1928,16 @@ var SDK_OPERATION_IDS = [
1774
1928
  "ingestionJobs.cancel",
1775
1929
  "ingestionJobs.complete_upload",
1776
1930
  "ingestionJobs.create_upload",
1931
+ "ingestionJobs.download_step_data",
1777
1932
  "ingestionJobs.get",
1933
+ "ingestionJobs.get_processed_content",
1934
+ "ingestionJobs.get_result",
1935
+ "ingestionJobs.get_step_data",
1936
+ "ingestionJobs.get_step_field",
1778
1937
  "ingestionJobs.get_upload",
1779
1938
  "ingestionJobs.list",
1780
1939
  "ingestionJobs.list_batches",
1940
+ "ingestionJobs.list_steps",
1781
1941
  "ingestionJobs.put_upload_part",
1782
1942
  "ingestionJobs.resume",
1783
1943
  "ingestionJobs.start",
@@ -1787,14 +1947,23 @@ var SDK_OPERATION_IDS = [
1787
1947
  "knowledgeStores.cancel_cleanup_job",
1788
1948
  "knowledgeStores.create",
1789
1949
  "knowledgeStores.delete_indexed_content",
1950
+ "knowledgeStores.delete_records",
1951
+ "knowledgeStores.fetch_records",
1790
1952
  "knowledgeStores.get",
1791
1953
  "knowledgeStores.get_cleanup_job",
1792
1954
  "knowledgeStores.get_indexed_content",
1793
1955
  "knowledgeStores.list",
1794
1956
  "knowledgeStores.list_indexed_content",
1957
+ "knowledgeStores.list_indexed_record_ids",
1958
+ "knowledgeStores.list_namespaces",
1959
+ "knowledgeStores.list_records",
1960
+ "knowledgeStores.namespace_stats",
1961
+ "knowledgeStores.query_records",
1795
1962
  "knowledgeStores.resume_cleanup_job",
1796
1963
  "knowledgeStores.stats",
1797
1964
  "knowledgeStores.update",
1965
+ "knowledgeStores.update_record",
1966
+ "knowledgeStores.upsert_records",
1798
1967
  "pipelines.get",
1799
1968
  "pipelines.get_input_schema",
1800
1969
  "pipelines.get_published_executable",