@elevasis/sdk 1.34.0 → 1.35.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -426,7 +426,7 @@ type GoogleModel = 'gemini-3-flash-preview' | 'gemini-3.1-flash-lite-preview';
426
426
  /**
427
427
  * Supported Anthropic models (direct SDK access via @anthropic-ai/sdk)
428
428
  */
429
- type AnthropicModel = 'claude-sonnet-4-5';
429
+ type AnthropicModel = 'claude-opus-4-8' | 'claude-sonnet-4-6' | 'claude-haiku-4-5-20251001' | 'claude-haiku-4-5' | 'claude-sonnet-4-5';
430
430
  /** Supported LLM models */
431
431
  type LLMModel = OpenAIModel | OpenRouterModel | GoogleModel | AnthropicModel | 'mock';
432
432
  /**
@@ -469,9 +469,9 @@ declare const GoogleOptionsSchema: z.ZodObject<{
469
469
  }, z.core.$strip>;
470
470
  /**
471
471
  * Anthropic model options schema
472
- * Currently empty - future options: budget_tokens for extended thinking
472
+ * Currently empty - future options must be added per supported model family
473
473
  */
474
- declare const AnthropicOptionsSchema: z.ZodObject<{}, z.core.$strip>;
474
+ declare const AnthropicOptionsSchema: z.ZodObject<{}, z.core.$strict>;
475
475
  /**
476
476
  * Infer TypeScript types from schemas
477
477
  */
@@ -558,7 +558,7 @@ declare const WorkflowResourceEntrySchema$1: z.ZodObject<{
558
558
  }>>;
559
559
  }, z.core.$strip>>>;
560
560
  }, z.core.$strip>;
561
- declare const AgentResourceEntrySchema: z.ZodObject<{
561
+ declare const AgentResourceEntrySchema$1: z.ZodObject<{
562
562
  id: z.ZodString;
563
563
  order: z.ZodDefault<z.ZodNumber>;
564
564
  systemPath: z.ZodString;
@@ -860,7 +860,7 @@ declare const ResourceEntrySchema$1: z.ZodDiscriminatedUnion<[z.ZodObject<{
860
860
  }, z.core.$strip>], "kind">;
861
861
  type ResourceGovernanceStatus = z.infer<typeof ResourceGovernanceStatusSchema>;
862
862
  type WorkflowResourceEntry = z.infer<typeof WorkflowResourceEntrySchema$1>;
863
- type AgentResourceEntry = z.infer<typeof AgentResourceEntrySchema>;
863
+ type AgentResourceEntry = z.infer<typeof AgentResourceEntrySchema$1>;
864
864
  type ResourceEntry$1 = z.infer<typeof ResourceEntrySchema$1>;
865
865
 
866
866
  /**
@@ -3537,6 +3537,138 @@ type Database = {
3537
3537
  };
3538
3538
  Relationships: [];
3539
3539
  };
3540
+ agent_access_grants: {
3541
+ Row: {
3542
+ allowed_origins: string[];
3543
+ branding: Json;
3544
+ capture_fields: Json;
3545
+ code_hash: string | null;
3546
+ code_salt: string | null;
3547
+ created_at: string;
3548
+ disabled_at: string | null;
3549
+ expires_at: string | null;
3550
+ id: string;
3551
+ max_sessions_per_visitor: number;
3552
+ max_turns_per_session: number;
3553
+ mode: string;
3554
+ organization_id: string;
3555
+ resource_id: string;
3556
+ slug: string;
3557
+ tool_policy: Json;
3558
+ updated_at: string;
3559
+ };
3560
+ Insert: {
3561
+ allowed_origins?: string[];
3562
+ branding?: Json;
3563
+ capture_fields?: Json;
3564
+ code_hash?: string | null;
3565
+ code_salt?: string | null;
3566
+ created_at?: string;
3567
+ disabled_at?: string | null;
3568
+ expires_at?: string | null;
3569
+ id?: string;
3570
+ max_sessions_per_visitor?: number;
3571
+ max_turns_per_session?: number;
3572
+ mode?: string;
3573
+ organization_id: string;
3574
+ resource_id: string;
3575
+ slug: string;
3576
+ tool_policy?: Json;
3577
+ updated_at?: string;
3578
+ };
3579
+ Update: {
3580
+ allowed_origins?: string[];
3581
+ branding?: Json;
3582
+ capture_fields?: Json;
3583
+ code_hash?: string | null;
3584
+ code_salt?: string | null;
3585
+ created_at?: string;
3586
+ disabled_at?: string | null;
3587
+ expires_at?: string | null;
3588
+ id?: string;
3589
+ max_sessions_per_visitor?: number;
3590
+ max_turns_per_session?: number;
3591
+ mode?: string;
3592
+ organization_id?: string;
3593
+ resource_id?: string;
3594
+ slug?: string;
3595
+ tool_policy?: Json;
3596
+ updated_at?: string;
3597
+ };
3598
+ Relationships: [
3599
+ {
3600
+ foreignKeyName: "agent_access_grants_organization_id_fkey";
3601
+ columns: ["organization_id"];
3602
+ isOneToOne: false;
3603
+ referencedRelation: "organizations";
3604
+ referencedColumns: ["id"];
3605
+ }
3606
+ ];
3607
+ };
3608
+ agent_chat_capabilities: {
3609
+ Row: {
3610
+ created_at: string;
3611
+ expires_at: string;
3612
+ grant_id: string;
3613
+ id: string;
3614
+ organization_id: string;
3615
+ origin: string | null;
3616
+ resource_id: string;
3617
+ revoked_at: string | null;
3618
+ session_id: string | null;
3619
+ token_hash: string;
3620
+ visitor_id: string | null;
3621
+ };
3622
+ Insert: {
3623
+ created_at?: string;
3624
+ expires_at: string;
3625
+ grant_id: string;
3626
+ id?: string;
3627
+ organization_id: string;
3628
+ origin?: string | null;
3629
+ resource_id: string;
3630
+ revoked_at?: string | null;
3631
+ session_id?: string | null;
3632
+ token_hash: string;
3633
+ visitor_id?: string | null;
3634
+ };
3635
+ Update: {
3636
+ created_at?: string;
3637
+ expires_at?: string;
3638
+ grant_id?: string;
3639
+ id?: string;
3640
+ organization_id?: string;
3641
+ origin?: string | null;
3642
+ resource_id?: string;
3643
+ revoked_at?: string | null;
3644
+ session_id?: string | null;
3645
+ token_hash?: string;
3646
+ visitor_id?: string | null;
3647
+ };
3648
+ Relationships: [
3649
+ {
3650
+ foreignKeyName: "agent_chat_capabilities_grant_id_fkey";
3651
+ columns: ["grant_id"];
3652
+ isOneToOne: false;
3653
+ referencedRelation: "agent_access_grants";
3654
+ referencedColumns: ["id"];
3655
+ },
3656
+ {
3657
+ foreignKeyName: "agent_chat_capabilities_organization_id_fkey";
3658
+ columns: ["organization_id"];
3659
+ isOneToOne: false;
3660
+ referencedRelation: "organizations";
3661
+ referencedColumns: ["id"];
3662
+ },
3663
+ {
3664
+ foreignKeyName: "agent_chat_capabilities_session_id_fkey";
3665
+ columns: ["session_id"];
3666
+ isOneToOne: false;
3667
+ referencedRelation: "sessions";
3668
+ referencedColumns: ["session_id"];
3669
+ }
3670
+ ];
3671
+ };
3540
3672
  organizations: {
3541
3673
  Row: {
3542
3674
  config: Json;
@@ -12262,6 +12394,19 @@ declare const WorkflowResourceEntrySchema = ResourceEntryBaseSchema.extend({
12262
12394
  emits: z.array(EventEmissionDescriptorSchema).optional()
12263
12395
  })
12264
12396
 
12397
+ declare const AgentResourceEntrySchema = ResourceEntryBaseSchema.extend({
12398
+ kind: z.literal('agent'),
12399
+ /** Mirrors code-side AgentConfig.kind. */
12400
+ agentKind: AgentKindSchema,
12401
+ /** Role this agent embodies, if any. */
12402
+ actsAsRoleId: ModelIdSchema.meta({ ref: 'role' }).optional(),
12403
+ /** Mirrors AgentConfig.sessionCapable. */
12404
+ sessionCapable: z.boolean(),
12405
+ /** Broad/composite callable entry points orchestrated by this agent. */
12406
+ invocations: z.array(ActionInvocationSchema).default([]),
12407
+ emits: z.array(EventEmissionDescriptorSchema).optional()
12408
+ })
12409
+
12265
12410
  declare const IntegrationResourceEntrySchema = ResourceEntryBaseSchema.extend({
12266
12411
  kind: z.literal('integration'),
12267
12412
  provider: z.string().trim().min(1).max(100)
@@ -12449,6 +12594,7 @@ type OrganizationModel = z.infer<typeof OrganizationModelSchema>
12449
12594
  type OrganizationModelResourceEntry = z.infer<typeof ResourceEntrySchema>
12450
12595
  type OrganizationModelResourceOntologyBinding = z.infer<typeof ResourceOntologyBindingSchema>
12451
12596
  type OrganizationModelWorkflowResourceEntry = z.infer<typeof WorkflowResourceEntrySchema>
12597
+ type OrganizationModelAgentResourceEntry = z.infer<typeof AgentResourceEntrySchema>
12452
12598
  type OrganizationModelIntegrationResourceEntry = z.infer<typeof IntegrationResourceEntrySchema>
12453
12599
  type OrganizationModelTopology = z.infer<typeof OmTopologyDomainSchema>
12454
12600
  type OrganizationModelTopologyNodeRef = z.infer<typeof OmTopologyNodeRefSchema>
@@ -12486,6 +12632,7 @@ type CrmStateKey = z.infer<typeof CrmStateKeySchema>
12486
12632
 
12487
12633
  type ResourceOntologyBindingResolver = (resourceId: string) => OrganizationModelResourceOntologyBinding | undefined;
12488
12634
  type WorkflowResourceDescriptorResolver = (resourceId: string) => OrganizationModelWorkflowResourceEntry;
12635
+ type AgentResourceDescriptorResolver = (resourceId: string) => OrganizationModelAgentResourceEntry;
12489
12636
  type IntegrationResourceDescriptorResolver = (resourceId: string) => OrganizationModelIntegrationResourceEntry;
12490
12637
  interface ProjectDeploymentSpecOptions {
12491
12638
  version: string;
@@ -12497,6 +12644,7 @@ interface ProjectDeploymentSpecOptions {
12497
12644
  externalResources?: DeploymentSpec['externalResources'];
12498
12645
  humanCheckpoints?: DeploymentSpec['humanCheckpoints'];
12499
12646
  getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver;
12647
+ getAgentResourceDescriptor?: AgentResourceDescriptorResolver;
12500
12648
  getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver;
12501
12649
  getResourceOntologyBinding?: ResourceOntologyBindingResolver;
12502
12650
  }
@@ -12508,6 +12656,8 @@ declare function toSdkResourceDescriptor<TResource extends {
12508
12656
  };
12509
12657
  declare function withPlatformResourceDescriptor(workflow: WorkflowDefinition, getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): WorkflowDefinition;
12510
12658
  declare function withPlatformResourceDescriptors(workflows: WorkflowDefinition[], getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): WorkflowDefinition[];
12659
+ declare function withPlatformAgentResourceDescriptor(agent: AgentDefinition, getAgentResourceDescriptor: AgentResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): AgentDefinition;
12660
+ declare function withPlatformAgentResourceDescriptors(agents: AgentDefinition[], getAgentResourceDescriptor: AgentResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): AgentDefinition[];
12511
12661
  declare function withPlatformIntegrationResourceDescriptor(integration: IntegrationDefinition, getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): IntegrationDefinition;
12512
12662
  declare function withPlatformIntegrationResourceDescriptors(integrations: IntegrationDefinition[], getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): IntegrationDefinition[];
12513
12663
  declare function projectTopologyRelationships(model: Pick<OrganizationModel, 'resources' | 'topology'>): ResourceRelationships;
@@ -12545,5 +12695,5 @@ declare function defineWorkflowConfig<const TResourceId extends string>(resource
12545
12695
  declare const ListBuilderStageKeySchema: z.ZodString;
12546
12696
  type ListBuilderStageKey = z.infer<typeof ListBuilderStageKeySchema>;
12547
12697
 
12548
- export { ActivityEventSchema, BuildPlanSnapshotStepSchema, ProspectingBuildTemplateSchema as BuildTemplateSchema, ContractRefResolutionError, CrmStageKeySchema, CrmStateKeySchema, EmailSchema, ExecutionError, ListBuilderStageKeySchema, ProcessingStageStatusSchema, RegistryValidationError, ResourceRegistry, StepType, ToolingError, bindResourceDescriptor, compileBusinessOntologyValidationIndex, concurrentPool, createLeadGenStageValidators, defineContract, defineResource, defineResourceOntology, defineResources, defineStep, defineTopology, defineTopologyRelationship, defineWorkflow, defineWorkflowConfig, deriveActions, diagnosticOutput, integrationInput, isZodType, parseTopologyNodeRef, projectDeploymentSpec, projectTopologyRelationships, resolveContractRef, runDiagnostic, splitName, toSdkResourceDescriptor, topologyRef, topologyRelationship, validateDeclaredSystemInterfaceReadiness, validateResourceGovernance, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
12549
- export type { AbsoluteScheduleConfig, AcqCompany, AcqContact, AcqDeal, AcqDealRow, AcqList, Action$1 as Action, ActionDef, ActivityEvent, AddToCampaignLead, AddToCampaignParams, AddToCampaignResult, AgentConfig, AgentConstraints, AgentDefinition, AgentMemory, FindCompanyEmailParams as AnymailfinderFindCompanyEmailParams, FindCompanyEmailResult as AnymailfinderFindCompanyEmailResult, FindDecisionMakerEmailParams as AnymailfinderFindDecisionMakerEmailParams, FindDecisionMakerEmailResult as AnymailfinderFindDecisionMakerEmailResult, FindPersonEmailParams as AnymailfinderFindPersonEmailParams, FindPersonEmailResult as AnymailfinderFindPersonEmailResult, AnymailfinderToolMap, VerifyEmailParams as AnymailfinderVerifyEmailParams, VerifyEmailResult as AnymailfinderVerifyEmailResult, ApifyToolMap, ApifyWebhookConfig, AppendRowsParams, AppendRowsResult, ApprovalToolMap, AttioToolMap, BatchUpdateParams, BatchUpdateResult, BuildPlanSnapshotStep, BulkDeleteLeadsParams, BulkDeleteLeadsResult, BulkImportParams, BulkImportResult, BusinessOntologyValidationIndex, CancelHitlByDealIdParams, CancelSchedulesAndHitlByEmailParams, ClearDealFieldsParams, ClearRangeParams, ClearRangeResult, ClickUpToolMap, CompanyFilters, ConcurrentPoolOptions, ConcurrentPoolResult, ConditionalNext, ContactFilters, Contract, ContractRefResolutionErrorCode, ContractRegistry, CreateAttributeParams, CreateAttributeResult, CreateAutoPaymentLinkParams, CreateAutoPaymentLinkResult, CreateCheckoutSessionParams, CreateCheckoutSessionResult, CreateCompanyParams, CreateContactParams, CreateEnvelopeParams, CreateEnvelopeResult, CreateFolderParams, CreateFolderResult, CreateListParams, CreateNoteParams, CreateNoteResult, CreatePaymentLinkParams, CreatePaymentLinkResult, CreateRecordParams, CreateRecordResult, CreateScheduleInput, CrmStageKey, CrmStateKey, CrmToolMap, DeleteDealParams, DeleteNoteParams, DeleteNoteResult, DeleteRecordParams, DeleteRecordResult, DeleteRowByValueParams, DeleteRowByValueResult, DeploymentSpec, DiagnosticOutput, DownloadDocumentParams, DownloadDocumentResult, DropboxToolMap, ElevasConfig, EmailToolMap, EnvelopeDocument, EventTriggerConfig, ExecutionContext, ExecutionInterface, ExecutionMetadata, ExecutionToolMap, FilterExpression, FilterRowsParams, FilterRowsResult, FormField, FormFieldType, FormSchema, GetDailyCampaignAnalyticsParams, GetDailyCampaignAnalyticsResult, GetEmailsParams, GetEmailsResult, GetEnvelopeParams, GetEnvelopeResult, GetHeadersParams, GetHeadersResult, GetLastRowParams, GetLastRowResult, GetPaymentLinkParams, GetPaymentLinkResult, GetRecordParams, GetRecordResult, GetRowByValueParams, GetRowByValueResult, GetSpreadsheetMetadataParams, GetSpreadsheetMetadataResult, GmailSendEmailParams, GmailSendEmailResult, GmailToolMap, GoogleSheetsToolMap, HumanCheckpointDefinition, InstantlyToolMap, IntegrationDefinition, IntegrationResourceDescriptorResolver, LLMAdapterFactory, LLMGenerateRequest, LLMGenerateResponse, LLMMessage, LLMModel, LeadGenStageValidators, LeadToolMap, LinearNext, ListAttributesParams, ListAttributesResult, ListBuilderStageKey, ListBuilderStep, ListLeadsParams, ListLeadsResult, ListNotesParams, ListNotesResult, ListObjectsResult, ListPaymentLinksParams, ListPaymentLinksResult, ListToolMap, MarkProposalReviewedParams, MarkProposalSentParams, MethodEntry, MillionVerifierToolMap, ModelConfig, NextConfig, NotificationSDKInput, NotificationToolMap, OrganizationModelIntegrationResourceEntry, OrganizationModelResourceEntry, OrganizationModelResourceOntologyBinding, OrganizationModelTopology, OrganizationModelTopologyNodeRef, OrganizationModelTopologyRelationship, OrganizationModelWorkflowResourceEntry, PaginatedResult, PaginationParams, PdfToolMap, ProcessingStageStatus, ProjectDeploymentSpecOptions, ProjectsToolMap, QueryRecordsParams, QueryRecordsResult, ReadSheetParams, ReadSheetResult, Recipient, RecurringScheduleConfig, RelationshipDeclaration, RelativeScheduleConfig, RemoveFromSubsequenceParams, RemoveFromSubsequenceResult, ResendGetEmailParams, ResendGetEmailResult, ResendSendEmailParams, ResendSendEmailResult, ResendToolMap, ResolvedContractRef, ResourceCategory, ResourceDefinition, ResourceLink, ResourceMetricsConfig, ResourceOntologyBindingResolver, ResourceRelationships, ResourceStatus$1 as ResourceStatus, ResourceType, RunActorParams, RunActorResult, SDKLLMGenerateParams, ScheduleOriginTracking, ScheduleTarget, ScheduleTriggerConfig, SchedulerToolMap, SendReplyParams, SendReplyResult, SetContactNurtureParams, SheetInfo, SignatureApiFieldType, SignatureApiToolMap, SigningPlace, SortCriteria, StartActorParams, StartActorResult, StepHandler, StorageDeleteInput, StorageDeleteOutput, StorageDownloadInput, StorageDownloadOutput, StorageListInput, StorageListOutput, StorageSignedUrlInput, StorageSignedUrlOutput, StorageToolMap, StorageUploadInput, StorageUploadOutput, StripeToolMap, TaskSchedule, TaskScheduleConfig, TombaToolMap, Tool, ToolExecutionOptions, ToolMethodMap, ToolingErrorType, TransitionItemParams, TriggerConfig, TriggerDefinition, UpdateAttributeParams, UpdateAttributeResult, UpdateCloseLostReasonParams, UpdateCompanyParams, UpdateContactParams, UpdateDiscoveryDataParams, UpdateFeesParams, UpdateInterestStatusParams, UpdateInterestStatusResult, UpdateListParams, UpdatePaymentLinkParams, UpdatePaymentLinkResult, UpdateProposalDataParams, UpdateRecordParams, UpdateRecordResult, UpdateRowByValueParams, UpdateRowByValueResult, UploadFileParams, UploadFileResult, UpsertCompanyParams, UpsertContactParams, UpsertDealParams, UpsertRowParams, UpsertRowResult, VoidEnvelopeParams, VoidEnvelopeResult, WebhookProviderType, WebhookTriggerConfig, WorkflowConfig, WorkflowConfigActionRegistry, WorkflowDefinition, WorkflowLogger, WorkflowResourceDescriptorMap, WorkflowResourceDescriptorResolver, WorkflowStep, WriteSheetParams, WriteSheetResult };
12698
+ export { ActivityEventSchema, BuildPlanSnapshotStepSchema, ProspectingBuildTemplateSchema as BuildTemplateSchema, ContractRefResolutionError, CrmStageKeySchema, CrmStateKeySchema, EmailSchema, ExecutionError, ListBuilderStageKeySchema, ProcessingStageStatusSchema, RegistryValidationError, ResourceRegistry, StepType, ToolingError, bindResourceDescriptor, compileBusinessOntologyValidationIndex, concurrentPool, createLeadGenStageValidators, defineContract, defineResource, defineResourceOntology, defineResources, defineStep, defineTopology, defineTopologyRelationship, defineWorkflow, defineWorkflowConfig, deriveActions, diagnosticOutput, integrationInput, isZodType, parseTopologyNodeRef, projectDeploymentSpec, projectTopologyRelationships, resolveContractRef, runDiagnostic, splitName, toSdkResourceDescriptor, topologyRef, topologyRelationship, validateDeclaredSystemInterfaceReadiness, validateResourceGovernance, withPlatformAgentResourceDescriptor, withPlatformAgentResourceDescriptors, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
12699
+ export type { AbsoluteScheduleConfig, AcqCompany, AcqContact, AcqDeal, AcqDealRow, AcqList, Action$1 as Action, ActionDef, ActivityEvent, AddToCampaignLead, AddToCampaignParams, AddToCampaignResult, AgentConfig, AgentConstraints, AgentDefinition, AgentMemory, AgentResourceDescriptorResolver, FindCompanyEmailParams as AnymailfinderFindCompanyEmailParams, FindCompanyEmailResult as AnymailfinderFindCompanyEmailResult, FindDecisionMakerEmailParams as AnymailfinderFindDecisionMakerEmailParams, FindDecisionMakerEmailResult as AnymailfinderFindDecisionMakerEmailResult, FindPersonEmailParams as AnymailfinderFindPersonEmailParams, FindPersonEmailResult as AnymailfinderFindPersonEmailResult, AnymailfinderToolMap, VerifyEmailParams as AnymailfinderVerifyEmailParams, VerifyEmailResult as AnymailfinderVerifyEmailResult, ApifyToolMap, ApifyWebhookConfig, AppendRowsParams, AppendRowsResult, ApprovalToolMap, AttioToolMap, BatchUpdateParams, BatchUpdateResult, BuildPlanSnapshotStep, BulkDeleteLeadsParams, BulkDeleteLeadsResult, BulkImportParams, BulkImportResult, BusinessOntologyValidationIndex, CancelHitlByDealIdParams, CancelSchedulesAndHitlByEmailParams, ClearDealFieldsParams, ClearRangeParams, ClearRangeResult, ClickUpToolMap, CompanyFilters, ConcurrentPoolOptions, ConcurrentPoolResult, ConditionalNext, ContactFilters, Contract, ContractRefResolutionErrorCode, ContractRegistry, CreateAttributeParams, CreateAttributeResult, CreateAutoPaymentLinkParams, CreateAutoPaymentLinkResult, CreateCheckoutSessionParams, CreateCheckoutSessionResult, CreateCompanyParams, CreateContactParams, CreateEnvelopeParams, CreateEnvelopeResult, CreateFolderParams, CreateFolderResult, CreateListParams, CreateNoteParams, CreateNoteResult, CreatePaymentLinkParams, CreatePaymentLinkResult, CreateRecordParams, CreateRecordResult, CreateScheduleInput, CrmStageKey, CrmStateKey, CrmToolMap, DeleteDealParams, DeleteNoteParams, DeleteNoteResult, DeleteRecordParams, DeleteRecordResult, DeleteRowByValueParams, DeleteRowByValueResult, DeploymentSpec, DiagnosticOutput, DownloadDocumentParams, DownloadDocumentResult, DropboxToolMap, ElevasConfig, EmailToolMap, EnvelopeDocument, EventTriggerConfig, ExecutionContext, ExecutionInterface, ExecutionMetadata, ExecutionToolMap, FilterExpression, FilterRowsParams, FilterRowsResult, FormField, FormFieldType, FormSchema, GetDailyCampaignAnalyticsParams, GetDailyCampaignAnalyticsResult, GetEmailsParams, GetEmailsResult, GetEnvelopeParams, GetEnvelopeResult, GetHeadersParams, GetHeadersResult, GetLastRowParams, GetLastRowResult, GetPaymentLinkParams, GetPaymentLinkResult, GetRecordParams, GetRecordResult, GetRowByValueParams, GetRowByValueResult, GetSpreadsheetMetadataParams, GetSpreadsheetMetadataResult, GmailSendEmailParams, GmailSendEmailResult, GmailToolMap, GoogleSheetsToolMap, HumanCheckpointDefinition, InstantlyToolMap, IntegrationDefinition, IntegrationResourceDescriptorResolver, LLMAdapterFactory, LLMGenerateRequest, LLMGenerateResponse, LLMMessage, LLMModel, LeadGenStageValidators, LeadToolMap, LinearNext, ListAttributesParams, ListAttributesResult, ListBuilderStageKey, ListBuilderStep, ListLeadsParams, ListLeadsResult, ListNotesParams, ListNotesResult, ListObjectsResult, ListPaymentLinksParams, ListPaymentLinksResult, ListToolMap, MarkProposalReviewedParams, MarkProposalSentParams, MethodEntry, MillionVerifierToolMap, ModelConfig, NextConfig, NotificationSDKInput, NotificationToolMap, OrganizationModelAgentResourceEntry, OrganizationModelIntegrationResourceEntry, OrganizationModelResourceEntry, OrganizationModelResourceOntologyBinding, OrganizationModelTopology, OrganizationModelTopologyNodeRef, OrganizationModelTopologyRelationship, OrganizationModelWorkflowResourceEntry, PaginatedResult, PaginationParams, PdfToolMap, ProcessingStageStatus, ProjectDeploymentSpecOptions, ProjectsToolMap, QueryRecordsParams, QueryRecordsResult, ReadSheetParams, ReadSheetResult, Recipient, RecurringScheduleConfig, RelationshipDeclaration, RelativeScheduleConfig, RemoveFromSubsequenceParams, RemoveFromSubsequenceResult, ResendGetEmailParams, ResendGetEmailResult, ResendSendEmailParams, ResendSendEmailResult, ResendToolMap, ResolvedContractRef, ResourceCategory, ResourceDefinition, ResourceLink, ResourceMetricsConfig, ResourceOntologyBindingResolver, ResourceRelationships, ResourceStatus$1 as ResourceStatus, ResourceType, RunActorParams, RunActorResult, SDKLLMGenerateParams, ScheduleOriginTracking, ScheduleTarget, ScheduleTriggerConfig, SchedulerToolMap, SendReplyParams, SendReplyResult, SetContactNurtureParams, SheetInfo, SignatureApiFieldType, SignatureApiToolMap, SigningPlace, SortCriteria, StartActorParams, StartActorResult, StepHandler, StorageDeleteInput, StorageDeleteOutput, StorageDownloadInput, StorageDownloadOutput, StorageListInput, StorageListOutput, StorageSignedUrlInput, StorageSignedUrlOutput, StorageToolMap, StorageUploadInput, StorageUploadOutput, StripeToolMap, TaskSchedule, TaskScheduleConfig, TombaToolMap, Tool, ToolExecutionOptions, ToolMethodMap, ToolingErrorType, TransitionItemParams, TriggerConfig, TriggerDefinition, UpdateAttributeParams, UpdateAttributeResult, UpdateCloseLostReasonParams, UpdateCompanyParams, UpdateContactParams, UpdateDiscoveryDataParams, UpdateFeesParams, UpdateInterestStatusParams, UpdateInterestStatusResult, UpdateListParams, UpdatePaymentLinkParams, UpdatePaymentLinkResult, UpdateProposalDataParams, UpdateRecordParams, UpdateRecordResult, UpdateRowByValueParams, UpdateRowByValueResult, UploadFileParams, UploadFileResult, UpsertCompanyParams, UpsertContactParams, UpsertDealParams, UpsertRowParams, UpsertRowResult, VoidEnvelopeParams, VoidEnvelopeResult, WebhookProviderType, WebhookTriggerConfig, WorkflowConfig, WorkflowConfigActionRegistry, WorkflowDefinition, WorkflowLogger, WorkflowResourceDescriptorMap, WorkflowResourceDescriptorResolver, WorkflowStep, WriteSheetParams, WriteSheetResult };
package/dist/index.js CHANGED
@@ -1427,17 +1427,38 @@ var GoogleConfigSchema = z.object({
1427
1427
  topP: z.number().min(0).max(1).optional(),
1428
1428
  modelOptions: GoogleOptionsSchema.optional()
1429
1429
  });
1430
- var AnthropicOptionsSchema = z.object({});
1431
- var AnthropicConfigSchema = z.object({
1432
- model: z.enum(["claude-sonnet-4-5"]),
1430
+ var AnthropicOptionsSchema = z.object({}).strict();
1431
+ var AnthropicStandardConfigSchema = z.object({
1432
+ model: z.enum([
1433
+ "claude-sonnet-4-6",
1434
+ "claude-haiku-4-5-20251001",
1435
+ "claude-haiku-4-5",
1436
+ "claude-sonnet-4-5"
1437
+ ]),
1433
1438
  provider: z.literal("anthropic"),
1434
1439
  apiKey: z.string(),
1435
1440
  temperature: z.number().min(0).max(1).optional(),
1436
- maxOutputTokens: z.number().min(1e3).optional(),
1441
+ maxOutputTokens: z.number().min(1e3).max(64e3).optional(),
1437
1442
  // Anthropic requires max_tokens
1438
1443
  topP: z.number().min(0).max(1).optional(),
1439
1444
  modelOptions: AnthropicOptionsSchema.optional()
1440
1445
  });
1446
+ var AnthropicOpus48ConfigSchema = z.object({
1447
+ model: z.literal("claude-opus-4-8"),
1448
+ provider: z.literal("anthropic"),
1449
+ apiKey: z.string(),
1450
+ temperature: z.literal(1).optional(),
1451
+ maxOutputTokens: z.number().min(1e3).max(128e3).optional(),
1452
+ // Anthropic requires max_tokens
1453
+ topP: z.literal(1).optional(),
1454
+ topK: z.undefined().optional(),
1455
+ top_k: z.undefined().optional(),
1456
+ modelOptions: AnthropicOptionsSchema.optional()
1457
+ });
1458
+ var AnthropicConfigSchema = z.discriminatedUnion("model", [
1459
+ AnthropicOpus48ConfigSchema,
1460
+ AnthropicStandardConfigSchema
1461
+ ]);
1441
1462
  var MODEL_INFO = {
1442
1463
  // OpenAI GPT-5 (Reasoning Models)
1443
1464
  "gpt-5": {
@@ -1530,6 +1551,58 @@ var MODEL_INFO = {
1530
1551
  configSchema: GoogleConfigSchema
1531
1552
  },
1532
1553
  // Anthropic Claude Models (direct SDK access via @anthropic-ai/sdk)
1554
+ "claude-opus-4-8": {
1555
+ inputCostPer1M: 500,
1556
+ // $5.00 per 1M tokens
1557
+ outputCostPer1M: 2500,
1558
+ // $25.00 per 1M tokens
1559
+ minTokens: 4e3,
1560
+ recommendedTokens: 8e3,
1561
+ maxTokens: 1e6,
1562
+ // 1M context window
1563
+ maxOutputTokens: 128e3,
1564
+ category: "reasoning",
1565
+ configSchema: AnthropicConfigSchema
1566
+ },
1567
+ "claude-sonnet-4-6": {
1568
+ inputCostPer1M: 300,
1569
+ // $3.00 per 1M tokens
1570
+ outputCostPer1M: 1500,
1571
+ // $15.00 per 1M tokens
1572
+ minTokens: 4e3,
1573
+ recommendedTokens: 8e3,
1574
+ maxTokens: 1e6,
1575
+ // 1M context window
1576
+ maxOutputTokens: 64e3,
1577
+ category: "standard",
1578
+ configSchema: AnthropicConfigSchema
1579
+ },
1580
+ "claude-haiku-4-5-20251001": {
1581
+ inputCostPer1M: 100,
1582
+ // $1.00 per 1M tokens
1583
+ outputCostPer1M: 500,
1584
+ // $5.00 per 1M tokens
1585
+ minTokens: 4e3,
1586
+ recommendedTokens: 8e3,
1587
+ maxTokens: 2e5,
1588
+ // 200k context window
1589
+ maxOutputTokens: 64e3,
1590
+ category: "standard",
1591
+ configSchema: AnthropicConfigSchema
1592
+ },
1593
+ "claude-haiku-4-5": {
1594
+ inputCostPer1M: 100,
1595
+ // $1.00 per 1M tokens
1596
+ outputCostPer1M: 500,
1597
+ // $5.00 per 1M tokens
1598
+ minTokens: 4e3,
1599
+ recommendedTokens: 8e3,
1600
+ maxTokens: 2e5,
1601
+ // 200k context window
1602
+ maxOutputTokens: 64e3,
1603
+ category: "standard",
1604
+ configSchema: AnthropicConfigSchema
1605
+ },
1533
1606
  "claude-sonnet-4-5": {
1534
1607
  inputCostPer1M: 300,
1535
1608
  // $3.00 per 1M tokens
@@ -1539,6 +1612,7 @@ var MODEL_INFO = {
1539
1612
  recommendedTokens: 8e3,
1540
1613
  maxTokens: 2e5,
1541
1614
  // 200k context window
1615
+ maxOutputTokens: 64e3,
1542
1616
  category: "standard",
1543
1617
  configSchema: AnthropicConfigSchema
1544
1618
  }
@@ -6873,6 +6947,24 @@ function withPlatformResourceDescriptors(workflows, getWorkflowResourceDescripto
6873
6947
  (workflow) => withPlatformResourceDescriptor(workflow, getWorkflowResourceDescriptor, getResourceOntologyBinding)
6874
6948
  );
6875
6949
  }
6950
+ function withPlatformAgentResourceDescriptor(agent, getAgentResourceDescriptor, getResourceOntologyBinding) {
6951
+ const resource = getAgentResourceDescriptor(agent.config.resourceId);
6952
+ const sdkResource = toSdkResourceDescriptor(resource, getResourceOntologyBinding);
6953
+ return {
6954
+ ...agent,
6955
+ config: {
6956
+ ...agent.config,
6957
+ resource: sdkResource,
6958
+ resourceId: sdkResource.id,
6959
+ type: sdkResource.kind
6960
+ }
6961
+ };
6962
+ }
6963
+ function withPlatformAgentResourceDescriptors(agents, getAgentResourceDescriptor, getResourceOntologyBinding) {
6964
+ return agents.map(
6965
+ (agent) => withPlatformAgentResourceDescriptor(agent, getAgentResourceDescriptor, getResourceOntologyBinding)
6966
+ );
6967
+ }
6876
6968
  function withPlatformIntegrationResourceDescriptor(integration, getIntegrationResourceDescriptor, getResourceOntologyBinding) {
6877
6969
  const resource = getIntegrationResourceDescriptor(integration.resourceId);
6878
6970
  const sdkResource = toSdkResourceDescriptor(resource, getResourceOntologyBinding);
@@ -6932,11 +7024,16 @@ function projectDeploymentSpec(options) {
6932
7024
  options.getIntegrationResourceDescriptor,
6933
7025
  options.getResourceOntologyBinding
6934
7026
  );
7027
+ const agents = options.getAgentResourceDescriptor === void 0 ? options.agents ?? [] : withPlatformAgentResourceDescriptors(
7028
+ options.agents ?? [],
7029
+ options.getAgentResourceDescriptor,
7030
+ options.getResourceOntologyBinding
7031
+ );
6935
7032
  return {
6936
7033
  version: options.version,
6937
7034
  organizationModel: options.organizationModel,
6938
7035
  workflows,
6939
- agents: options.agents ?? [],
7036
+ agents,
6940
7037
  triggers: options.triggers,
6941
7038
  integrations,
6942
7039
  humanCheckpoints: options.humanCheckpoints,
@@ -6971,4 +7068,4 @@ function defineWorkflowConfig(resourceId, descriptors, actionRegistry = []) {
6971
7068
  }
6972
7069
  var ListBuilderStageKeySchema = z.string().min(1);
6973
7070
 
6974
- export { ActivityEventSchema, BuildPlanSnapshotStepSchema, ProspectingBuildTemplateSchema as BuildTemplateSchema, ContractRefResolutionError, CrmStageKeySchema, CrmStateKeySchema, EmailSchema, ExecutionError, ListBuilderStageKeySchema, ProcessingStageStatusSchema, RegistryValidationError, ResourceRegistry, StepType, ToolingError, bindResourceDescriptor, compileBusinessOntologyValidationIndex, concurrentPool, createLeadGenStageValidators, defineContract, defineResource, defineResourceOntology, defineResources, defineStep, defineTopology, defineTopologyRelationship, defineWorkflow, defineWorkflowConfig, deriveActions, diagnosticOutput, integrationInput, isZodType, parseTopologyNodeRef, projectDeploymentSpec, projectTopologyRelationships, resolveContractRef, runDiagnostic, splitName, toSdkResourceDescriptor, topologyRef, topologyRelationship, validateDeclaredSystemInterfaceReadiness, validateResourceGovernance, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
7071
+ export { ActivityEventSchema, BuildPlanSnapshotStepSchema, ProspectingBuildTemplateSchema as BuildTemplateSchema, ContractRefResolutionError, CrmStageKeySchema, CrmStateKeySchema, EmailSchema, ExecutionError, ListBuilderStageKeySchema, ProcessingStageStatusSchema, RegistryValidationError, ResourceRegistry, StepType, ToolingError, bindResourceDescriptor, compileBusinessOntologyValidationIndex, concurrentPool, createLeadGenStageValidators, defineContract, defineResource, defineResourceOntology, defineResources, defineStep, defineTopology, defineTopologyRelationship, defineWorkflow, defineWorkflowConfig, deriveActions, diagnosticOutput, integrationInput, isZodType, parseTopologyNodeRef, projectDeploymentSpec, projectTopologyRelationships, resolveContractRef, runDiagnostic, splitName, toSdkResourceDescriptor, topologyRef, topologyRelationship, validateDeclaredSystemInterfaceReadiness, validateResourceGovernance, withPlatformAgentResourceDescriptor, withPlatformAgentResourceDescriptors, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
@@ -296,7 +296,7 @@ type GoogleModel = 'gemini-3-flash-preview' | 'gemini-3.1-flash-lite-preview';
296
296
  /**
297
297
  * Supported Anthropic models (direct SDK access via @anthropic-ai/sdk)
298
298
  */
299
- type AnthropicModel = 'claude-sonnet-4-5';
299
+ type AnthropicModel = 'claude-opus-4-8' | 'claude-sonnet-4-6' | 'claude-haiku-4-5-20251001' | 'claude-haiku-4-5' | 'claude-sonnet-4-5';
300
300
  /** Supported LLM models */
301
301
  type LLMModel = OpenAIModel | OpenRouterModel | GoogleModel | AnthropicModel | 'mock';
302
302
  /**
@@ -339,9 +339,9 @@ declare const GoogleOptionsSchema: z.ZodObject<{
339
339
  }, z.core.$strip>;
340
340
  /**
341
341
  * Anthropic model options schema
342
- * Currently empty - future options: budget_tokens for extended thinking
342
+ * Currently empty - future options must be added per supported model family
343
343
  */
344
- declare const AnthropicOptionsSchema: z.ZodObject<{}, z.core.$strip>;
344
+ declare const AnthropicOptionsSchema: z.ZodObject<{}, z.core.$strict>;
345
345
  /**
346
346
  * Infer TypeScript types from schemas
347
347
  */
@@ -428,7 +428,7 @@ declare const WorkflowResourceEntrySchema$1: z.ZodObject<{
428
428
  }>>;
429
429
  }, z.core.$strip>>>;
430
430
  }, z.core.$strip>;
431
- declare const AgentResourceEntrySchema: z.ZodObject<{
431
+ declare const AgentResourceEntrySchema$1: z.ZodObject<{
432
432
  id: z.ZodString;
433
433
  order: z.ZodDefault<z.ZodNumber>;
434
434
  systemPath: z.ZodString;
@@ -730,7 +730,7 @@ declare const ResourceEntrySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
730
730
  }, z.core.$strip>], "kind">;
731
731
  type ResourceGovernanceStatus = z.infer<typeof ResourceGovernanceStatusSchema>;
732
732
  type WorkflowResourceEntry = z.infer<typeof WorkflowResourceEntrySchema$1>;
733
- type AgentResourceEntry = z.infer<typeof AgentResourceEntrySchema>;
733
+ type AgentResourceEntry = z.infer<typeof AgentResourceEntrySchema$1>;
734
734
  type ResourceEntry = z.infer<typeof ResourceEntrySchema>;
735
735
 
736
736
  /**
@@ -3250,6 +3250,19 @@ declare const WorkflowResourceEntrySchema = ResourceEntryBaseSchema.extend({
3250
3250
  emits: z.array(EventEmissionDescriptorSchema).optional()
3251
3251
  })
3252
3252
 
3253
+ declare const AgentResourceEntrySchema = ResourceEntryBaseSchema.extend({
3254
+ kind: z.literal('agent'),
3255
+ /** Mirrors code-side AgentConfig.kind. */
3256
+ agentKind: AgentKindSchema,
3257
+ /** Role this agent embodies, if any. */
3258
+ actsAsRoleId: ModelIdSchema.meta({ ref: 'role' }).optional(),
3259
+ /** Mirrors AgentConfig.sessionCapable. */
3260
+ sessionCapable: z.boolean(),
3261
+ /** Broad/composite callable entry points orchestrated by this agent. */
3262
+ invocations: z.array(ActionInvocationSchema).default([]),
3263
+ emits: z.array(EventEmissionDescriptorSchema).optional()
3264
+ })
3265
+
3253
3266
  declare const IntegrationResourceEntrySchema = ResourceEntryBaseSchema.extend({
3254
3267
  kind: z.literal('integration'),
3255
3268
  provider: z.string().trim().min(1).max(100)
@@ -3260,10 +3273,12 @@ declare const OrganizationModelSchema = OrganizationModelSchemaBase.superRefine(
3260
3273
  type OrganizationModel = z.infer<typeof OrganizationModelSchema>
3261
3274
  type OrganizationModelResourceOntologyBinding = z.infer<typeof ResourceOntologyBindingSchema>
3262
3275
  type OrganizationModelWorkflowResourceEntry = z.infer<typeof WorkflowResourceEntrySchema>
3276
+ type OrganizationModelAgentResourceEntry = z.infer<typeof AgentResourceEntrySchema>
3263
3277
  type OrganizationModelIntegrationResourceEntry = z.infer<typeof IntegrationResourceEntrySchema>
3264
3278
 
3265
3279
  type ResourceOntologyBindingResolver = (resourceId: string) => OrganizationModelResourceOntologyBinding | undefined;
3266
3280
  type WorkflowResourceDescriptorResolver = (resourceId: string) => OrganizationModelWorkflowResourceEntry;
3281
+ type AgentResourceDescriptorResolver = (resourceId: string) => OrganizationModelAgentResourceEntry;
3267
3282
  type IntegrationResourceDescriptorResolver = (resourceId: string) => OrganizationModelIntegrationResourceEntry;
3268
3283
  interface ProjectDeploymentSpecOptions {
3269
3284
  version: string;
@@ -3275,6 +3290,7 @@ interface ProjectDeploymentSpecOptions {
3275
3290
  externalResources?: DeploymentSpec['externalResources'];
3276
3291
  humanCheckpoints?: DeploymentSpec['humanCheckpoints'];
3277
3292
  getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver;
3293
+ getAgentResourceDescriptor?: AgentResourceDescriptorResolver;
3278
3294
  getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver;
3279
3295
  getResourceOntologyBinding?: ResourceOntologyBindingResolver;
3280
3296
  }
@@ -3286,10 +3302,12 @@ declare function toSdkResourceDescriptor<TResource extends {
3286
3302
  };
3287
3303
  declare function withPlatformResourceDescriptor(workflow: WorkflowDefinition, getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): WorkflowDefinition;
3288
3304
  declare function withPlatformResourceDescriptors(workflows: WorkflowDefinition[], getWorkflowResourceDescriptor: WorkflowResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): WorkflowDefinition[];
3305
+ declare function withPlatformAgentResourceDescriptor(agent: AgentDefinition, getAgentResourceDescriptor: AgentResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): AgentDefinition;
3306
+ declare function withPlatformAgentResourceDescriptors(agents: AgentDefinition[], getAgentResourceDescriptor: AgentResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): AgentDefinition[];
3289
3307
  declare function withPlatformIntegrationResourceDescriptor(integration: IntegrationDefinition, getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): IntegrationDefinition;
3290
3308
  declare function withPlatformIntegrationResourceDescriptors(integrations: IntegrationDefinition[], getIntegrationResourceDescriptor: IntegrationResourceDescriptorResolver, getResourceOntologyBinding?: ResourceOntologyBindingResolver): IntegrationDefinition[];
3291
3309
  declare function projectTopologyRelationships(model: Pick<OrganizationModel, 'resources' | 'topology'>): ResourceRelationships;
3292
3310
  declare function projectDeploymentSpec(options: ProjectDeploymentSpecOptions): DeploymentSpec;
3293
3311
 
3294
- export { generateKnowledgeBodies, generateKnowledgeNodes, generateKnowledgeNodesTs, projectDeploymentSpec, projectTopologyRelationships, readKnowledgeNodeMdx, runKnowledgeCodegen, toSdkResourceDescriptor, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
3295
- export type { CodegenResult, DeploymentSpec, GenerateKnowledgeNodesOptions, GenerateKnowledgeNodesResult, IntegrationDefinition, IntegrationResourceDescriptorResolver, KnowledgeCodegenNode, KnowledgeKind, KnowledgeNodeInput, KnowledgeSearchEntry, ProjectDeploymentSpecOptions, ResolvedKnowledgeLayout, ResourceOntologyBindingResolver, ResourceRelationships, WorkflowDefinition, WorkflowResourceDescriptorResolver };
3312
+ export { generateKnowledgeBodies, generateKnowledgeNodes, generateKnowledgeNodesTs, projectDeploymentSpec, projectTopologyRelationships, readKnowledgeNodeMdx, runKnowledgeCodegen, toSdkResourceDescriptor, withPlatformAgentResourceDescriptor, withPlatformAgentResourceDescriptors, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
3313
+ export type { AgentResourceDescriptorResolver, CodegenResult, DeploymentSpec, GenerateKnowledgeNodesOptions, GenerateKnowledgeNodesResult, IntegrationDefinition, IntegrationResourceDescriptorResolver, KnowledgeCodegenNode, KnowledgeKind, KnowledgeNodeInput, KnowledgeSearchEntry, ProjectDeploymentSpecOptions, ResolvedKnowledgeLayout, ResourceOntologyBindingResolver, ResourceRelationships, WorkflowDefinition, WorkflowResourceDescriptorResolver };
@@ -32,6 +32,9 @@ function parseScalar(value) {
32
32
  const quoted = trimmed.match(/^['"]([\s\S]*)['"]$/);
33
33
  return quoted ? quoted[1] : trimmed;
34
34
  }
35
+ function normalizeLineEndings(value) {
36
+ return value.replace(/\r\n/g, "\n");
37
+ }
35
38
  function parseFrontmatter(raw, filePath) {
36
39
  const match = raw.match(/^---\r?\n([\s\S]*?)\r?\n---\r?\n?([\s\S]*)$/);
37
40
  if (!match) throw new Error(`[knowledge-node-codegen] Missing frontmatter in ${filePath}`);
@@ -55,7 +58,7 @@ function parseFrontmatter(raw, filePath) {
55
58
  }
56
59
  frontmatter[key] = values;
57
60
  }
58
- return { frontmatter, body: match[2].trim() };
61
+ return { frontmatter, body: normalizeLineEndings(match[2]).trim() };
59
62
  }
60
63
  function assertString(frontmatter, key, filePath) {
61
64
  const value = frontmatter[key];
@@ -538,6 +541,24 @@ function withPlatformResourceDescriptors(workflows, getWorkflowResourceDescripto
538
541
  (workflow) => withPlatformResourceDescriptor(workflow, getWorkflowResourceDescriptor, getResourceOntologyBinding)
539
542
  );
540
543
  }
544
+ function withPlatformAgentResourceDescriptor(agent, getAgentResourceDescriptor, getResourceOntologyBinding) {
545
+ const resource = getAgentResourceDescriptor(agent.config.resourceId);
546
+ const sdkResource = toSdkResourceDescriptor(resource, getResourceOntologyBinding);
547
+ return {
548
+ ...agent,
549
+ config: {
550
+ ...agent.config,
551
+ resource: sdkResource,
552
+ resourceId: sdkResource.id,
553
+ type: sdkResource.kind
554
+ }
555
+ };
556
+ }
557
+ function withPlatformAgentResourceDescriptors(agents, getAgentResourceDescriptor, getResourceOntologyBinding) {
558
+ return agents.map(
559
+ (agent) => withPlatformAgentResourceDescriptor(agent, getAgentResourceDescriptor, getResourceOntologyBinding)
560
+ );
561
+ }
541
562
  function withPlatformIntegrationResourceDescriptor(integration, getIntegrationResourceDescriptor, getResourceOntologyBinding) {
542
563
  const resource = getIntegrationResourceDescriptor(integration.resourceId);
543
564
  const sdkResource = toSdkResourceDescriptor(resource, getResourceOntologyBinding);
@@ -597,11 +618,16 @@ function projectDeploymentSpec(options) {
597
618
  options.getIntegrationResourceDescriptor,
598
619
  options.getResourceOntologyBinding
599
620
  );
621
+ const agents = options.getAgentResourceDescriptor === void 0 ? options.agents ?? [] : withPlatformAgentResourceDescriptors(
622
+ options.agents ?? [],
623
+ options.getAgentResourceDescriptor,
624
+ options.getResourceOntologyBinding
625
+ );
600
626
  return {
601
627
  version: options.version,
602
628
  organizationModel: options.organizationModel,
603
629
  workflows,
604
- agents: options.agents ?? [],
630
+ agents,
605
631
  triggers: options.triggers,
606
632
  integrations,
607
633
  humanCheckpoints: options.humanCheckpoints,
@@ -610,4 +636,4 @@ function projectDeploymentSpec(options) {
610
636
  };
611
637
  }
612
638
 
613
- export { generateKnowledgeBodies, generateKnowledgeNodes, generateKnowledgeNodesTs, projectDeploymentSpec, projectTopologyRelationships, readKnowledgeNodeMdx, runKnowledgeCodegen, toSdkResourceDescriptor, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };
639
+ export { generateKnowledgeBodies, generateKnowledgeNodes, generateKnowledgeNodesTs, projectDeploymentSpec, projectTopologyRelationships, readKnowledgeNodeMdx, runKnowledgeCodegen, toSdkResourceDescriptor, withPlatformAgentResourceDescriptor, withPlatformAgentResourceDescriptors, withPlatformIntegrationResourceDescriptor, withPlatformIntegrationResourceDescriptors, withPlatformResourceDescriptor, withPlatformResourceDescriptors };