@lumavox/server 0.28.1 → 0.34.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/README.md +1 -1
- package/dist/gen/index.d.ts +1 -1
- package/dist/gen/types.gen.d.ts +778 -0
- package/dist/resources/agents.d.ts +9 -2
- package/dist/resources/agents.js +9 -1
- package/dist/resources/end-users.d.ts +42 -1
- package/dist/resources/end-users.js +21 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -60,7 +60,7 @@ list's page.
|
|
|
60
60
|
|
|
61
61
|
| Resource | Methods |
|
|
62
62
|
|---|---|
|
|
63
|
-
| `endUsers` | `create`, `get`, `update`, `delete`, `list`, `page`, `export`, `toolResult`; `facts.list`, `facts.add`, `facts.update`, `facts.delete`; `memories.list`, `memories.page`, `memories.get`, `memories.delete`, `memories.deleteAll` |
|
|
63
|
+
| `endUsers` | `create`, `get`, `update`, `delete`, `list`, `page`, `export`, `toolResult`; `facts.list`, `facts.add`, `facts.update`, `facts.delete`; `memories.list`, `memories.page`, `memories.get`, `memories.delete`, `memories.deleteAll`; `personalization.get`, `personalization.update`, `note` |
|
|
64
64
|
| `ephemeralKeys` | `limits`, `create`, `revoke`, `inspect`, `list`, `page` |
|
|
65
65
|
| `images`, `videos`, `audio`, `skybox`, `transcriptions` | `create`, `get`, `wait`, `generate`; `images.draftLayout`, `images.findElements`; `skybox.styles` |
|
|
66
66
|
| `generations` | `get`, `wait`, `list`, `page` |
|
package/dist/gen/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export type { AgentCreateRequest, AgentHandoff, AgentHandoffInfo, AgentInfo, AgentKnowledgeUpdate, AgentPage, AgentSettingsInfo, AgentSettingsUpdate, AgentStt, AgentSttInfo, AgentSummary, AgentToolsUpdate, AgentUpdate, AgentVoice, AgentVoiceInfo, ApiKeySelf, AssetBulkRequest, AssetDetail, AssetMoveRequest, AssetPage, AssetsAffected, AssetSummary, AssetUpdate, AssignedAgent, AudioRequest, BulkEditKnowledgeData, BulkEditKnowledgeError, BulkEditKnowledgeErrors, BulkEditKnowledgeResponse, BulkEditKnowledgeResponses, ClientOptions, CompactionInfo, CompactRequest, CompactSessionData, CompactSessionError, CompactSessionErrors, CompactSessionResponse, CompactSessionResponses, ConfirmAssetUploadData, ConfirmAssetUploadError, ConfirmAssetUploadErrors, ConfirmAssetUploadResponse, ConfirmAssetUploadResponses, CreateAgentData, CreateAgentError, CreateAgentErrors, CreateAgentResponse, CreateAgentResponses, CreateAssetFolderData, CreateAssetFolderError, CreateAssetFolderErrors, CreateAssetFolderResponse, CreateAssetFolderResponses, CreateAssetUploadUrlData, CreateAssetUploadUrlError, CreateAssetUploadUrlErrors, CreateAssetUploadUrlResponse, CreateAssetUploadUrlResponses, CreateAudioData, CreateAudioError, CreateAudioErrors, CreateAudioResponse, CreateAudioResponses, CreateEndUserData, CreateEndUserError, CreateEndUserErrors, CreateEndUserFactData, CreateEndUserFactError, CreateEndUserFactErrors, CreateEndUserFactResponse, CreateEndUserFactResponses, CreateEndUserResponse, CreateEndUserResponses, CreateEphemeralKeyData, CreateEphemeralKeyError, CreateEphemeralKeyErrors, CreateEphemeralKeyResponse, CreateEphemeralKeyResponses, CreateFactData, CreateFactError, CreateFactErrors, CreateFactResponse, CreateFactResponses, CreateImageData, CreateImageError, CreateImageErrors, CreateImageResponse, CreateImageResponses, CreateKnowledgeData, CreateKnowledgeError, CreateKnowledgeErrors, CreateKnowledgeFromFileData, CreateKnowledgeFromFileError, CreateKnowledgeFromFileErrors, CreateKnowledgeFromFileResponse, CreateKnowledgeFromFileResponses, CreateKnowledgeFromUrlData, CreateKnowledgeFromUrlError, CreateKnowledgeFromUrlErrors, CreateKnowledgeFromUrlResponse, CreateKnowledgeFromUrlResponses, CreateKnowledgeResponse, CreateKnowledgeResponses, CreateKnowledgeUploadUrlData, CreateKnowledgeUploadUrlError, CreateKnowledgeUploadUrlErrors, CreateKnowledgeUploadUrlResponse, CreateKnowledgeUploadUrlResponses, CreateSessionData, CreateSessionError, CreateSessionErrors, CreateSessionResponse, CreateSessionResponses, CreateSkyboxData, CreateSkyboxError, CreateSkyboxErrors, CreateSkyboxResponse, CreateSkyboxResponses, CreateToolData, CreateToolError, CreateToolErrors, CreateToolResponse, CreateToolResponses, CreateTranscriptionData, CreateTranscriptionError, CreateTranscriptionErrors, CreateTranscriptionResponse, CreateTranscriptionResponses, CreateVideoData, CreateVideoError, CreateVideoErrors, CreateVideoResponse, CreateVideoResponses, CreateVoiceData, CreateVoiceError, CreateVoiceErrors, CreateVoiceResponse, CreateVoiceResponses, CreateVoiceUploadUrlData, CreateVoiceUploadUrlError, CreateVoiceUploadUrlErrors, CreateVoiceUploadUrlResponse, CreateVoiceUploadUrlResponses, DeleteAgentData, DeleteAgentError, DeleteAgentErrors, DeleteAgentResponse, DeleteAgentResponses, DeleteAllEndUserMemoriesData, DeleteAllEndUserMemoriesError, DeleteAllEndUserMemoriesErrors, DeleteAllEndUserMemoriesResponse, DeleteAllEndUserMemoriesResponses, DeleteAllFactsData, DeleteAllFactsError, DeleteAllFactsErrors, DeleteAllFactsResponse, DeleteAllFactsResponses, DeleteAllMemoriesData, DeleteAllMemoriesError, DeleteAllMemoriesErrors, DeleteAllMemoriesResponse, DeleteAllMemoriesResponses, DeleteAssetData, DeleteAssetError, DeleteAssetErrors, DeleteAssetFolderData, DeleteAssetFolderError, DeleteAssetFolderErrors, DeleteAssetFolderResponse, DeleteAssetFolderResponses, DeleteAssetResponse, DeleteAssetResponses, DeleteAssetsData, DeleteAssetsError, DeleteAssetsErrors, DeleteAssetsResponse, DeleteAssetsResponses, DeleteEndUserData, DeleteEndUserError, DeleteEndUserErrors, DeleteEndUserFactData, DeleteEndUserFactError, DeleteEndUserFactErrors, DeleteEndUserFactResponse, DeleteEndUserFactResponses, DeleteEndUserMemoryData, DeleteEndUserMemoryError, DeleteEndUserMemoryErrors, DeleteEndUserMemoryResponse, DeleteEndUserMemoryResponses, DeleteEndUserResponse, DeleteEndUserResponses, DeleteFactData, DeleteFactError, DeleteFactErrors, DeleteFactResponse, DeleteFactResponses, DeleteKnowledgeData, DeleteKnowledgeError, DeleteKnowledgeErrors, DeleteKnowledgeResponse, DeleteKnowledgeResponses, DeleteMemoryData, DeleteMemoryError, DeleteMemoryErrors, DeleteMemoryResponse, DeleteMemoryResponses, DeleteSessionData, DeleteSessionError, DeleteSessionErrors, DeleteSessionResponse, DeleteSessionResponses, DeleteToolData, DeleteToolError, DeleteToolErrors, DeleteToolResponse, DeleteToolResponses, DeleteVoiceData, DeleteVoiceError, DeleteVoiceErrors, DeleteVoiceResponse, DeleteVoiceResponses, DesignVoiceData, DesignVoiceError, DesignVoiceErrors, DesignVoiceResponse, DesignVoiceResponses, DraftLayoutData, DraftLayoutError, DraftLayoutErrors, DraftLayoutResponse, DraftLayoutResponses, EndUserCreateRequest, EndUserDeleted, EndUserInfo, EndUserPage, EndUserUpdateRequest, EphemeralKeyCreateRequest, EphemeralKeyCreateResponse, EphemeralKeyInfo, EphemeralKeyLimits, EphemeralKeyPage, EphemeralTokenSelf, ErrorCode, ErrorInfo, ErrorResponse, ExtractSessionFactsData, ExtractSessionFactsError, ExtractSessionFactsErrors, ExtractSessionFactsResponse, ExtractSessionFactsResponses, FactCreateRequest, FactInfo, FactPage, FactsDeleted, FactsReadInfo, FactUpdateRequest, FindLayoutElementsData, FindLayoutElementsError, FindLayoutElementsErrors, FindLayoutElementsResponse, FindLayoutElementsResponses, FolderCreate, FolderDeleted, FolderDetail, FolderPage, FolderSummary, FolderUpdate, GenerateFromTemplateData, GenerateFromTemplateError, GenerateFromTemplateErrors, GenerateFromTemplateResponse, GenerateFromTemplateResponses, GenerationAudio, GenerationImage, GenerationInfo, GenerationPage, GenerationSkybox, GenerationTranscript, GenerationVideo, GetAgentData, GetAgentError, GetAgentErrors, GetAgentResponse, GetAgentResponses, GetAgentSettingsData, GetAgentSettingsError, GetAgentSettingsErrors, GetAgentSettingsResponse, GetAgentSettingsResponses, GetAssetData, GetAssetError, GetAssetErrors, GetAssetFolderData, GetAssetFolderError, GetAssetFolderErrors, GetAssetFolderResponse, GetAssetFolderResponses, GetAssetResponse, GetAssetResponses, GetAudioData, GetAudioError, GetAudioErrors, GetAudioResponse, GetAudioResponses, GetEndUserData, GetEndUserError, GetEndUserErrors, GetEndUserMemoryData, GetEndUserMemoryError, GetEndUserMemoryErrors, GetEndUserMemoryResponse, GetEndUserMemoryResponses, GetEndUserResponse, GetEndUserResponses, GetEphemeralKeyData, GetEphemeralKeyError, GetEphemeralKeyErrors, GetEphemeralKeyLimitsData, GetEphemeralKeyLimitsError, GetEphemeralKeyLimitsErrors, GetEphemeralKeyLimitsResponse, GetEphemeralKeyLimitsResponses, GetEphemeralKeyResponse, GetEphemeralKeyResponses, GetGenerationData, GetGenerationError, GetGenerationErrors, GetGenerationResponse, GetGenerationResponses, GetHealthData, GetHealthResponse, GetHealthResponses, GetImageData, GetImageError, GetImageErrors, GetImageResponse, GetImageResponses, GetKnowledgeData, GetKnowledgeError, GetKnowledgeErrors, GetKnowledgeInsightsData, GetKnowledgeInsightsError, GetKnowledgeInsightsErrors, GetKnowledgeInsightsResponse, GetKnowledgeInsightsResponses, GetKnowledgeResponse, GetKnowledgeResponses, GetMemoryData, GetMemoryError, GetMemoryErrors, GetMemoryResponse, GetMemoryResponses, GetPlanData, GetPlanError, GetPlanErrors, GetPlanResponse, GetPlanResponses, GetPlatformLimitsData, GetPlatformLimitsResponse, GetPlatformLimitsResponses, GetSessionData, GetSessionError, GetSessionErrors, GetSessionResponse, GetSessionResponses, GetSkyboxData, GetSkyboxError, GetSkyboxErrors, GetSkyboxResponse, GetSkyboxResponses, GetTemplateData, GetTemplateError, GetTemplateErrors, GetTemplateFileData, GetTemplateFileError, GetTemplateFileErrors, GetTemplateFileResponses, GetTemplateResponse, GetTemplateResponses, GetTokenData, GetTokenError, GetTokenErrors, GetTokenResponse, GetTokenResponses, GetToolData, GetToolError, GetToolErrors, GetToolResponse, GetToolResponses, GetTranscriptionData, GetTranscriptionError, GetTranscriptionErrors, GetTranscriptionResponse, GetTranscriptionResponses, GetUsageData, GetUsageError, GetUsageErrors, GetUsageResponse, GetUsageResponses, GetVideoData, GetVideoError, GetVideoErrors, GetVideoResponse, GetVideoResponses, GetVoiceData, GetVoiceError, GetVoiceErrors, GetVoiceResponse, GetVoiceResponses, HealthResponse, ImageRequest, KnowledgeAgentsUpdate, KnowledgeAssigned, KnowledgeBulk, KnowledgeBulkResult, KnowledgeCategoryPage, KnowledgeCitation, KnowledgeCreate, KnowledgeEntryUsage, KnowledgeFileCreate, KnowledgeInfo, KnowledgeInsights, KnowledgeLookupInfo, KnowledgePage, KnowledgeSearchHit, KnowledgeSearchRequest, KnowledgeSearchResult, KnowledgeUpdate, KnowledgeUploadRequest, KnowledgeUploadTicket, KnowledgeUrlCreate, LayoutDraft, LayoutDraftRequest, LayoutElement, LayoutElementInfo, LayoutFindRequest, LayoutFound, LayoutSourceInfo, ListAgentKnowledgeData, ListAgentKnowledgeError, ListAgentKnowledgeErrors, ListAgentKnowledgeResponse, ListAgentKnowledgeResponses, ListAgentsData, ListAgentsError, ListAgentsErrors, ListAgentsResponse, ListAgentsResponses, ListAgentToolsData, ListAgentToolsError, ListAgentToolsErrors, ListAgentToolsResponse, ListAgentToolsResponses, ListAssetFoldersData, ListAssetFoldersError, ListAssetFoldersErrors, ListAssetFoldersResponse, ListAssetFoldersResponses, ListAssetsData, ListAssetsError, ListAssetsErrors, ListAssetsResponse, ListAssetsResponses, ListEndUserFactsData, ListEndUserFactsError, ListEndUserFactsErrors, ListEndUserFactsResponse, ListEndUserFactsResponses, ListEndUserMemoriesData, ListEndUserMemoriesError, ListEndUserMemoriesErrors, ListEndUserMemoriesResponse, ListEndUserMemoriesResponses, ListEndUsersData, ListEndUsersError, ListEndUsersErrors, ListEndUsersResponse, ListEndUsersResponses, ListEphemeralKeysData, ListEphemeralKeysError, ListEphemeralKeysErrors, ListEphemeralKeysResponse, ListEphemeralKeysResponses, ListFactsData, ListFactsError, ListFactsErrors, ListFactsResponse, ListFactsResponses, ListGenerationsData, ListGenerationsError, ListGenerationsErrors, ListGenerationsResponse, ListGenerationsResponses, ListKnowledgeCategoriesData, ListKnowledgeCategoriesError, ListKnowledgeCategoriesErrors, ListKnowledgeCategoriesResponse, ListKnowledgeCategoriesResponses, ListKnowledgeData, ListKnowledgeError, ListKnowledgeErrors, ListKnowledgeResponse, ListKnowledgeResponses, ListMemoriesData, ListMemoriesError, ListMemoriesErrors, ListMemoriesResponse, ListMemoriesResponses, ListRelationsData, ListRelationsError, ListRelationsErrors, ListRelationsResponse, ListRelationsResponses, ListSessionsData, ListSessionsError, ListSessionsErrors, ListSessionsResponse, ListSessionsResponses, ListSkyboxStylesData, ListSkyboxStylesError, ListSkyboxStylesErrors, ListSkyboxStylesResponse, ListSkyboxStylesResponses, ListTemplatesData, ListTemplatesError, ListTemplatesErrors, ListTemplatesResponse, ListTemplatesResponses, ListToolCallsData, ListToolCallsError, ListToolCallsErrors, ListToolCallsResponse, ListToolCallsResponses, ListToolsData, ListToolsError, ListToolsErrors, ListToolsResponse, ListToolsResponses, ListVoicesData, ListVoicesError, ListVoicesErrors, ListVoicesResponse, ListVoicesResponses, MemoriesDeleted, MemoriesWrittenInfo, MemoryCitation, MemoryInfo, MemoryPage, MessageInfo, MessageKnowledge, MessageMemories, MessagePage, MessageSource, MessageToolCall, MoveAssetsData, MoveAssetsError, MoveAssetsErrors, MoveAssetsResponse, MoveAssetsResponses, OrgPlan, PlatformLimit, PlatformLimitPage, PostSessionToolResultData, PostSessionToolResultError, PostSessionToolResultErrors, PostSessionToolResultResponse, PostSessionToolResultResponses, PostToolResultData, PostToolResultError, PostToolResultErrors, PostToolResultResponse, PostToolResultResponses, ProviderVoiceSettings, ProviderVoiceSettingsInfo, Reference, ReferenceInfo, RefreshKnowledgeData, RefreshKnowledgeError, RefreshKnowledgeErrors, RefreshKnowledgeResponse, RefreshKnowledgeResponses, ReindexKnowledgeData, ReindexKnowledgeError, ReindexKnowledgeErrors, ReindexKnowledgeResponse, ReindexKnowledgeResponses, RelationInfo, RelationPage, ResampleVoiceData, ResampleVoiceError, ResampleVoiceErrors, ResampleVoiceResponse, ResampleVoiceResponses, RevokeEphemeralKeyData, RevokeEphemeralKeyError, RevokeEphemeralKeyErrors, RevokeEphemeralKeyResponse, RevokeEphemeralKeyResponses, RotateToolSecretData, RotateToolSecretError, RotateToolSecretErrors, RotateToolSecretResponse, RotateToolSecretResponses, SaveDesignedVoiceData, SaveDesignedVoiceError, SaveDesignedVoiceErrors, SaveDesignedVoiceResponse, SaveDesignedVoiceResponses, SearchKnowledgeData, SearchKnowledgeError, SearchKnowledgeErrors, SearchKnowledgeResponse, SearchKnowledgeResponses, SessionCreateRequest, SessionDetail, SessionInfo, SessionPage, SetAgentKnowledgeData, SetAgentKnowledgeError, SetAgentKnowledgeErrors, SetAgentKnowledgeResponse, SetAgentKnowledgeResponses, SetAgentToolsData, SetAgentToolsError, SetAgentToolsErrors, SetAgentToolsResponse, SetAgentToolsResponses, SetKnowledgeAgentsData, SetKnowledgeAgentsError, SetKnowledgeAgentsErrors, SetKnowledgeAgentsResponse, SetKnowledgeAgentsResponses, SkyboxFile, SkyboxRequest, SkyboxStyle, SkyboxStylePage, SpeechProvider, StreamDone, StreamError, StreamSegment, StreamTranscript, SynthesizeSpeechData, SynthesizeSpeechError, SynthesizeSpeechErrors, SynthesizeSpeechResponse, SynthesizeSpeechResponses, TemplateGenerateRequest, TemplateInfo, TemplateInput, TemplatePage, TestToolData, TestToolError, TestToolErrors, TestToolResponse, TestToolResponses, TokenSelf, ToolCall, ToolCallPage, ToolCreate, ToolInfo, ToolPage, ToolResultRequest, ToolResultTaken, ToolsAssigned, ToolTestRequest, ToolTestResult, ToolUpdate, ToolWithSecret, TranscribeAssetRequest, TranscribeData, TranscribeError, TranscribeErrors, TranscribeResponse, TranscribeResponses, Transcription, TranscriptionStreamLine, TranscriptWord, TtsOptions, TtsRequest, UnansweredQuestion, UpdateAgentData, UpdateAgentError, UpdateAgentErrors, UpdateAgentResponse, UpdateAgentResponses, UpdateAgentSettingsData, UpdateAgentSettingsError, UpdateAgentSettingsErrors, UpdateAgentSettingsResponse, UpdateAgentSettingsResponses, UpdateAssetData, UpdateAssetError, UpdateAssetErrors, UpdateAssetFolderData, UpdateAssetFolderError, UpdateAssetFolderErrors, UpdateAssetFolderResponse, UpdateAssetFolderResponses, UpdateAssetResponse, UpdateAssetResponses, UpdateEndUserData, UpdateEndUserError, UpdateEndUserErrors, UpdateEndUserFactData, UpdateEndUserFactError, UpdateEndUserFactErrors, UpdateEndUserFactResponse, UpdateEndUserFactResponses, UpdateEndUserResponse, UpdateEndUserResponses, UpdateFactData, UpdateFactError, UpdateFactErrors, UpdateFactResponse, UpdateFactResponses, UpdateKnowledgeData, UpdateKnowledgeError, UpdateKnowledgeErrors, UpdateKnowledgeResponse, UpdateKnowledgeResponses, UpdateToolData, UpdateToolError, UpdateToolErrors, UpdateToolResponse, UpdateToolResponses, UpdateVoiceData, UpdateVoiceError, UpdateVoiceErrors, UpdateVoiceResponse, UpdateVoiceResponses, UploadConfirm, UploadTicket, UploadTicketRequest, UsageByKey, UsageDay, UsageResponse, UsageSummary, ValidationIssue, VariantInfo, VideoRequest, VoiceDesignPreview, VoiceDesignRequest, VoiceDesignResult, VoiceDesignSaveRequest, VoiceDetail, VoiceInfo, VoiceInfoPage, VoiceKind, VoiceSample, VoiceSource, VoiceStatus, VoiceUpdate, VoiceUpload, VoiceUploadRequest, VoiceUploadTicket, WriteSessionMemoriesData, WriteSessionMemoriesError, WriteSessionMemoriesErrors, WriteSessionMemoriesResponse, WriteSessionMemoriesResponses } from './types.gen.js';
|
|
1
|
+
export type { AgentCreateRequest, AgentHandoff, AgentHandoffInfo, AgentInfo, AgentKnowledgeUpdate, AgentPage, AgentReportField, AgentReportFieldInfo, AgentSettingsInfo, AgentSettingsUpdate, AgentStt, AgentSttInfo, AgentSummary, AgentToolsUpdate, AgentUpdate, AgentVoice, AgentVoiceInfo, ApiKeySelf, AssetBulkRequest, AssetDetail, AssetMoveRequest, AssetPage, AssetsAffected, AssetSummary, AssetUpdate, AssignedAgent, AudioRequest, BulkEditKnowledgeData, BulkEditKnowledgeError, BulkEditKnowledgeErrors, BulkEditKnowledgeResponse, BulkEditKnowledgeResponses, ClientOptions, CompactionInfo, CompactRequest, CompactSessionData, CompactSessionError, CompactSessionErrors, CompactSessionResponse, CompactSessionResponses, ConfirmAssetUploadData, ConfirmAssetUploadError, ConfirmAssetUploadErrors, ConfirmAssetUploadResponse, ConfirmAssetUploadResponses, ConversationReport, ConversationReportPage, CreateAgentData, CreateAgentError, CreateAgentErrors, CreateAgentResponse, CreateAgentResponses, CreateAssetFolderData, CreateAssetFolderError, CreateAssetFolderErrors, CreateAssetFolderResponse, CreateAssetFolderResponses, CreateAssetUploadUrlData, CreateAssetUploadUrlError, CreateAssetUploadUrlErrors, CreateAssetUploadUrlResponse, CreateAssetUploadUrlResponses, CreateAudioData, CreateAudioError, CreateAudioErrors, CreateAudioResponse, CreateAudioResponses, CreateEndUserData, CreateEndUserError, CreateEndUserErrors, CreateEndUserFactData, CreateEndUserFactError, CreateEndUserFactErrors, CreateEndUserFactResponse, CreateEndUserFactResponses, CreateEndUserNoteData, CreateEndUserNoteError, CreateEndUserNoteErrors, CreateEndUserNoteResponse, CreateEndUserNoteResponses, CreateEndUserResponse, CreateEndUserResponses, CreateEphemeralKeyData, CreateEphemeralKeyError, CreateEphemeralKeyErrors, CreateEphemeralKeyResponse, CreateEphemeralKeyResponses, CreateFactData, CreateFactError, CreateFactErrors, CreateFactResponse, CreateFactResponses, CreateImageData, CreateImageError, CreateImageErrors, CreateImageResponse, CreateImageResponses, CreateKnowledgeData, CreateKnowledgeError, CreateKnowledgeErrors, CreateKnowledgeFromFileData, CreateKnowledgeFromFileError, CreateKnowledgeFromFileErrors, CreateKnowledgeFromFileResponse, CreateKnowledgeFromFileResponses, CreateKnowledgeFromUrlData, CreateKnowledgeFromUrlError, CreateKnowledgeFromUrlErrors, CreateKnowledgeFromUrlResponse, CreateKnowledgeFromUrlResponses, CreateKnowledgeResponse, CreateKnowledgeResponses, CreateKnowledgeUploadUrlData, CreateKnowledgeUploadUrlError, CreateKnowledgeUploadUrlErrors, CreateKnowledgeUploadUrlResponse, CreateKnowledgeUploadUrlResponses, CreateSessionData, CreateSessionError, CreateSessionErrors, CreateSessionResponse, CreateSessionResponses, CreateSkyboxData, CreateSkyboxError, CreateSkyboxErrors, CreateSkyboxResponse, CreateSkyboxResponses, CreateToolData, CreateToolError, CreateToolErrors, CreateToolResponse, CreateToolResponses, CreateTranscriptionData, CreateTranscriptionError, CreateTranscriptionErrors, CreateTranscriptionResponse, CreateTranscriptionResponses, CreateVideoData, CreateVideoError, CreateVideoErrors, CreateVideoResponse, CreateVideoResponses, CreateVoiceData, CreateVoiceError, CreateVoiceErrors, CreateVoiceResponse, CreateVoiceResponses, CreateVoiceUploadUrlData, CreateVoiceUploadUrlError, CreateVoiceUploadUrlErrors, CreateVoiceUploadUrlResponse, CreateVoiceUploadUrlResponses, DeleteAgentData, DeleteAgentError, DeleteAgentErrors, DeleteAgentResponse, DeleteAgentResponses, DeleteAllEndUserMemoriesData, DeleteAllEndUserMemoriesError, DeleteAllEndUserMemoriesErrors, DeleteAllEndUserMemoriesResponse, DeleteAllEndUserMemoriesResponses, DeleteAllFactsData, DeleteAllFactsError, DeleteAllFactsErrors, DeleteAllFactsResponse, DeleteAllFactsResponses, DeleteAllMemoriesData, DeleteAllMemoriesError, DeleteAllMemoriesErrors, DeleteAllMemoriesResponse, DeleteAllMemoriesResponses, DeleteAssetData, DeleteAssetError, DeleteAssetErrors, DeleteAssetFolderData, DeleteAssetFolderError, DeleteAssetFolderErrors, DeleteAssetFolderResponse, DeleteAssetFolderResponses, DeleteAssetResponse, DeleteAssetResponses, DeleteAssetsData, DeleteAssetsError, DeleteAssetsErrors, DeleteAssetsResponse, DeleteAssetsResponses, DeleteEndUserData, DeleteEndUserError, DeleteEndUserErrors, DeleteEndUserFactData, DeleteEndUserFactError, DeleteEndUserFactErrors, DeleteEndUserFactResponse, DeleteEndUserFactResponses, DeleteEndUserMemoryData, DeleteEndUserMemoryError, DeleteEndUserMemoryErrors, DeleteEndUserMemoryResponse, DeleteEndUserMemoryResponses, DeleteEndUserResponse, DeleteEndUserResponses, DeleteFactData, DeleteFactError, DeleteFactErrors, DeleteFactResponse, DeleteFactResponses, DeleteKnowledgeData, DeleteKnowledgeError, DeleteKnowledgeErrors, DeleteKnowledgeResponse, DeleteKnowledgeResponses, DeleteMemoryData, DeleteMemoryError, DeleteMemoryErrors, DeleteMemoryResponse, DeleteMemoryResponses, DeleteSessionData, DeleteSessionError, DeleteSessionErrors, DeleteSessionResponse, DeleteSessionResponses, DeleteToolData, DeleteToolError, DeleteToolErrors, DeleteToolResponse, DeleteToolResponses, DeleteVoiceData, DeleteVoiceError, DeleteVoiceErrors, DeleteVoiceResponse, DeleteVoiceResponses, DesignVoiceData, DesignVoiceError, DesignVoiceErrors, DesignVoiceResponse, DesignVoiceResponses, DraftLayoutData, DraftLayoutError, DraftLayoutErrors, DraftLayoutResponse, DraftLayoutResponses, EndUserCreateRequest, EndUserDeleted, EndUserInfo, EndUserPage, EndUserPersonalization, EndUserPersonalizationUpdate, EndUserUpdateRequest, EphemeralKeyCreateRequest, EphemeralKeyCreateResponse, EphemeralKeyInfo, EphemeralKeyLimits, EphemeralKeyOverrides, EphemeralKeyPage, EphemeralTokenSelf, ErrorCode, ErrorInfo, ErrorResponse, ExtractSessionFactsData, ExtractSessionFactsError, ExtractSessionFactsErrors, ExtractSessionFactsResponse, ExtractSessionFactsResponses, FactCreateRequest, FactInfo, FactPage, FactsDeleted, FactsReadInfo, FactUpdateRequest, FindLayoutElementsData, FindLayoutElementsError, FindLayoutElementsErrors, FindLayoutElementsResponse, FindLayoutElementsResponses, FolderCreate, FolderDeleted, FolderDetail, FolderPage, FolderSummary, FolderUpdate, GenerateFromTemplateData, GenerateFromTemplateError, GenerateFromTemplateErrors, GenerateFromTemplateResponse, GenerateFromTemplateResponses, GenerationAudio, GenerationImage, GenerationInfo, GenerationPage, GenerationSkybox, GenerationTranscript, GenerationVideo, GetAgentData, GetAgentError, GetAgentErrors, GetAgentResponse, GetAgentResponses, GetAgentSettingsData, GetAgentSettingsError, GetAgentSettingsErrors, GetAgentSettingsResponse, GetAgentSettingsResponses, GetAssetData, GetAssetError, GetAssetErrors, GetAssetFolderData, GetAssetFolderError, GetAssetFolderErrors, GetAssetFolderResponse, GetAssetFolderResponses, GetAssetResponse, GetAssetResponses, GetAudioData, GetAudioError, GetAudioErrors, GetAudioResponse, GetAudioResponses, GetEndUserData, GetEndUserError, GetEndUserErrors, GetEndUserMemoryData, GetEndUserMemoryError, GetEndUserMemoryErrors, GetEndUserMemoryResponse, GetEndUserMemoryResponses, GetEndUserPersonalizationData, GetEndUserPersonalizationError, GetEndUserPersonalizationErrors, GetEndUserPersonalizationResponse, GetEndUserPersonalizationResponses, GetEndUserReportData, GetEndUserReportError, GetEndUserReportErrors, GetEndUserReportResponse, GetEndUserReportResponses, GetEndUserResponse, GetEndUserResponses, GetEphemeralKeyData, GetEphemeralKeyError, GetEphemeralKeyErrors, GetEphemeralKeyLimitsData, GetEphemeralKeyLimitsError, GetEphemeralKeyLimitsErrors, GetEphemeralKeyLimitsResponse, GetEphemeralKeyLimitsResponses, GetEphemeralKeyResponse, GetEphemeralKeyResponses, GetGenerationData, GetGenerationError, GetGenerationErrors, GetGenerationResponse, GetGenerationResponses, GetHealthData, GetHealthResponse, GetHealthResponses, GetImageData, GetImageError, GetImageErrors, GetImageResponse, GetImageResponses, GetKnowledgeData, GetKnowledgeError, GetKnowledgeErrors, GetKnowledgeInsightsData, GetKnowledgeInsightsError, GetKnowledgeInsightsErrors, GetKnowledgeInsightsResponse, GetKnowledgeInsightsResponses, GetKnowledgeResponse, GetKnowledgeResponses, GetMemoryData, GetMemoryError, GetMemoryErrors, GetMemoryResponse, GetMemoryResponses, GetPlanData, GetPlanError, GetPlanErrors, GetPlanResponse, GetPlanResponses, GetPlatformLimitsData, GetPlatformLimitsResponse, GetPlatformLimitsResponses, GetSessionData, GetSessionError, GetSessionErrors, GetSessionResponse, GetSessionResponses, GetSkyboxData, GetSkyboxError, GetSkyboxErrors, GetSkyboxResponse, GetSkyboxResponses, GetTemplateData, GetTemplateError, GetTemplateErrors, GetTemplateFileData, GetTemplateFileError, GetTemplateFileErrors, GetTemplateFileResponses, GetTemplateResponse, GetTemplateResponses, GetTokenData, GetTokenError, GetTokenErrors, GetTokenResponse, GetTokenResponses, GetToolData, GetToolError, GetToolErrors, GetToolResponse, GetToolResponses, GetTranscriptionData, GetTranscriptionError, GetTranscriptionErrors, GetTranscriptionResponse, GetTranscriptionResponses, GetUsageData, GetUsageError, GetUsageErrors, GetUsageResponse, GetUsageResponses, GetVideoData, GetVideoError, GetVideoErrors, GetVideoResponse, GetVideoResponses, GetVoiceData, GetVoiceError, GetVoiceErrors, GetVoiceResponse, GetVoiceResponses, HealthResponse, ImageRequest, KnowledgeAgentsUpdate, KnowledgeAssigned, KnowledgeBulk, KnowledgeBulkResult, KnowledgeCategoryPage, KnowledgeCitation, KnowledgeCreate, KnowledgeEntryUsage, KnowledgeFileCreate, KnowledgeInfo, KnowledgeInsights, KnowledgeLookupInfo, KnowledgePage, KnowledgeSearchHit, KnowledgeSearchRequest, KnowledgeSearchResult, KnowledgeUpdate, KnowledgeUploadRequest, KnowledgeUploadTicket, KnowledgeUrlCreate, LayoutDraft, LayoutDraftRequest, LayoutElement, LayoutElementInfo, LayoutFindRequest, LayoutFound, LayoutSourceInfo, ListAgentKnowledgeData, ListAgentKnowledgeError, ListAgentKnowledgeErrors, ListAgentKnowledgeResponse, ListAgentKnowledgeResponses, ListAgentsData, ListAgentsError, ListAgentsErrors, ListAgentsResponse, ListAgentsResponses, ListAgentToolsData, ListAgentToolsError, ListAgentToolsErrors, ListAgentToolsResponse, ListAgentToolsResponses, ListAssetFoldersData, ListAssetFoldersError, ListAssetFoldersErrors, ListAssetFoldersResponse, ListAssetFoldersResponses, ListAssetsData, ListAssetsError, ListAssetsErrors, ListAssetsResponse, ListAssetsResponses, ListEndUserFactsData, ListEndUserFactsError, ListEndUserFactsErrors, ListEndUserFactsResponse, ListEndUserFactsResponses, ListEndUserMemoriesData, ListEndUserMemoriesError, ListEndUserMemoriesErrors, ListEndUserMemoriesResponse, ListEndUserMemoriesResponses, ListEndUserReportsData, ListEndUserReportsError, ListEndUserReportsErrors, ListEndUserReportsResponse, ListEndUserReportsResponses, ListEndUsersData, ListEndUsersError, ListEndUsersErrors, ListEndUsersResponse, ListEndUsersResponses, ListEphemeralKeysData, ListEphemeralKeysError, ListEphemeralKeysErrors, ListEphemeralKeysResponse, ListEphemeralKeysResponses, ListFactsData, ListFactsError, ListFactsErrors, ListFactsResponse, ListFactsResponses, ListGenerationsData, ListGenerationsError, ListGenerationsErrors, ListGenerationsResponse, ListGenerationsResponses, ListKnowledgeCategoriesData, ListKnowledgeCategoriesError, ListKnowledgeCategoriesErrors, ListKnowledgeCategoriesResponse, ListKnowledgeCategoriesResponses, ListKnowledgeData, ListKnowledgeError, ListKnowledgeErrors, ListKnowledgeResponse, ListKnowledgeResponses, ListMemoriesData, ListMemoriesError, ListMemoriesErrors, ListMemoriesResponse, ListMemoriesResponses, ListRelationsData, ListRelationsError, ListRelationsErrors, ListRelationsResponse, ListRelationsResponses, ListSessionsData, ListSessionsError, ListSessionsErrors, ListSessionsResponse, ListSessionsResponses, ListSkyboxStylesData, ListSkyboxStylesError, ListSkyboxStylesErrors, ListSkyboxStylesResponse, ListSkyboxStylesResponses, ListTemplatesData, ListTemplatesError, ListTemplatesErrors, ListTemplatesResponse, ListTemplatesResponses, ListToolCallsData, ListToolCallsError, ListToolCallsErrors, ListToolCallsResponse, ListToolCallsResponses, ListToolsData, ListToolsError, ListToolsErrors, ListToolsResponse, ListToolsResponses, ListVoicesData, ListVoicesError, ListVoicesErrors, ListVoicesResponse, ListVoicesResponses, MemoriesDeleted, MemoriesWrittenInfo, MemoryCitation, MemoryInfo, MemoryPage, MessageContext, MessageInfo, MessageKnowledge, MessageMemories, MessageNote, MessagePage, MessageSource, MessageToolCall, MoveAssetsData, MoveAssetsError, MoveAssetsErrors, MoveAssetsResponse, MoveAssetsResponses, NoteCreateRequest, NoteTaken, OrgPlan, PlatformLimit, PlatformLimitPage, PostSessionToolResultData, PostSessionToolResultError, PostSessionToolResultErrors, PostSessionToolResultResponse, PostSessionToolResultResponses, PostToolResultData, PostToolResultError, PostToolResultErrors, PostToolResultResponse, PostToolResultResponses, ProviderVoiceSettings, ProviderVoiceSettingsInfo, Reference, ReferenceInfo, RefreshKnowledgeData, RefreshKnowledgeError, RefreshKnowledgeErrors, RefreshKnowledgeResponse, RefreshKnowledgeResponses, ReindexKnowledgeData, ReindexKnowledgeError, ReindexKnowledgeErrors, ReindexKnowledgeResponse, ReindexKnowledgeResponses, RelationInfo, RelationPage, ReportDelivery, ReportLine, ResampleVoiceData, ResampleVoiceError, ResampleVoiceErrors, ResampleVoiceResponse, ResampleVoiceResponses, RevokeEphemeralKeyData, RevokeEphemeralKeyError, RevokeEphemeralKeyErrors, RevokeEphemeralKeyResponse, RevokeEphemeralKeyResponses, RotateToolSecretData, RotateToolSecretError, RotateToolSecretErrors, RotateToolSecretResponse, RotateToolSecretResponses, RotateWebhookSecretData, RotateWebhookSecretError, RotateWebhookSecretErrors, RotateWebhookSecretResponse, RotateWebhookSecretResponses, SaveDesignedVoiceData, SaveDesignedVoiceError, SaveDesignedVoiceErrors, SaveDesignedVoiceResponse, SaveDesignedVoiceResponses, SearchKnowledgeData, SearchKnowledgeError, SearchKnowledgeErrors, SearchKnowledgeResponse, SearchKnowledgeResponses, SessionCreateRequest, SessionDetail, SessionInfo, SessionPage, SetAgentKnowledgeData, SetAgentKnowledgeError, SetAgentKnowledgeErrors, SetAgentKnowledgeResponse, SetAgentKnowledgeResponses, SetAgentToolsData, SetAgentToolsError, SetAgentToolsErrors, SetAgentToolsResponse, SetAgentToolsResponses, SetKnowledgeAgentsData, SetKnowledgeAgentsError, SetKnowledgeAgentsErrors, SetKnowledgeAgentsResponse, SetKnowledgeAgentsResponses, SkyboxFile, SkyboxRequest, SkyboxStyle, SkyboxStylePage, SpeechProvider, StreamDone, StreamError, StreamSegment, StreamTranscript, SynthesizeSpeechData, SynthesizeSpeechError, SynthesizeSpeechErrors, SynthesizeSpeechResponse, SynthesizeSpeechResponses, TemplateGenerateRequest, TemplateInfo, TemplateInput, TemplatePage, TestAgentWebhookData, TestAgentWebhookError, TestAgentWebhookErrors, TestAgentWebhookResponse, TestAgentWebhookResponses, TestToolData, TestToolError, TestToolErrors, TestToolResponse, TestToolResponses, TokenSelf, ToolCall, ToolCallPage, ToolCreate, ToolInfo, ToolPage, ToolResultRequest, ToolResultTaken, ToolsAssigned, ToolTestRequest, ToolTestResult, ToolUpdate, ToolWithSecret, TranscribeAssetRequest, TranscribeData, TranscribeError, TranscribeErrors, TranscribeResponse, TranscribeResponses, Transcription, TranscriptionStreamLine, TranscriptWord, TtsOptions, TtsRequest, UnansweredQuestion, UpdateAgentData, UpdateAgentError, UpdateAgentErrors, UpdateAgentResponse, UpdateAgentResponses, UpdateAgentSettingsData, UpdateAgentSettingsError, UpdateAgentSettingsErrors, UpdateAgentSettingsResponse, UpdateAgentSettingsResponses, UpdateAssetData, UpdateAssetError, UpdateAssetErrors, UpdateAssetFolderData, UpdateAssetFolderError, UpdateAssetFolderErrors, UpdateAssetFolderResponse, UpdateAssetFolderResponses, UpdateAssetResponse, UpdateAssetResponses, UpdateEndUserData, UpdateEndUserError, UpdateEndUserErrors, UpdateEndUserFactData, UpdateEndUserFactError, UpdateEndUserFactErrors, UpdateEndUserFactResponse, UpdateEndUserFactResponses, UpdateEndUserPersonalizationData, UpdateEndUserPersonalizationError, UpdateEndUserPersonalizationErrors, UpdateEndUserPersonalizationResponse, UpdateEndUserPersonalizationResponses, UpdateEndUserResponse, UpdateEndUserResponses, UpdateFactData, UpdateFactError, UpdateFactErrors, UpdateFactResponse, UpdateFactResponses, UpdateKnowledgeData, UpdateKnowledgeError, UpdateKnowledgeErrors, UpdateKnowledgeResponse, UpdateKnowledgeResponses, UpdateToolData, UpdateToolError, UpdateToolErrors, UpdateToolResponse, UpdateToolResponses, UpdateVoiceData, UpdateVoiceError, UpdateVoiceErrors, UpdateVoiceResponse, UpdateVoiceResponses, UploadConfirm, UploadTicket, UploadTicketRequest, UsageByKey, UsageDay, UsageResponse, UsageSummary, ValidationIssue, Variables, VariantInfo, VideoRequest, VoiceDesignPreview, VoiceDesignRequest, VoiceDesignResult, VoiceDesignSaveRequest, VoiceDetail, VoiceInfo, VoiceInfoPage, VoiceKind, VoiceSample, VoiceSource, VoiceStatus, VoiceUpdate, VoiceUpload, VoiceUploadRequest, VoiceUploadTicket, WebhookSecret, WebhookTestResult, WriteSessionMemoriesData, WriteSessionMemoriesError, WriteSessionMemoriesErrors, WriteSessionMemoriesResponse, WriteSessionMemoriesResponses } from './types.gen.js';
|
package/dist/gen/types.gen.d.ts
CHANGED
|
@@ -180,6 +180,38 @@ export type EphemeralKeyCreateRequest = {
|
|
|
180
180
|
end_user_id: string;
|
|
181
181
|
agent_ids?: Array<string> | null;
|
|
182
182
|
label?: string | null;
|
|
183
|
+
overrides?: EphemeralKeyOverrides | null;
|
|
184
|
+
};
|
|
185
|
+
/**
|
|
186
|
+
* What this key changes for the conversations it talks in: the language, the voice, the opening line and extra instructions. Signed into the key, so the person's app cannot change them; never the model. A key whose overrides make it longer than 16,384 characters is a 422 — text in scripts of 3 or 4 bytes a character, at every maximum.
|
|
187
|
+
*/
|
|
188
|
+
export type EphemeralKeyOverrides = {
|
|
189
|
+
/**
|
|
190
|
+
* Extra instructions for this key's conversations — "Today Sara is practising animals." — up to 2,000 characters, after the person's own (`/v1/end-users/{end_user_id}/personalization`) and before what the agent remembers of them. About 500 input tokens on every reply at the full length.
|
|
191
|
+
*/
|
|
192
|
+
instructions?: string | null;
|
|
193
|
+
/**
|
|
194
|
+
* The language the agent speaks and writes in, as a code of 2 to 8 letters, digits and hyphens — `es`, `pt-BR` — whatever language the person uses; and the hint a recording is heard with when it names none.
|
|
195
|
+
*/
|
|
196
|
+
language?: string | null;
|
|
197
|
+
/**
|
|
198
|
+
* A voice to speak with in place of the agent's: one of yours or the platform's (`GET /v1/voices`), for every agent on this key's conversations, a handoff's too. Looked up when the key is minted: an unknown one is a 422. An agent with its voice off stays silent. On another provider than the agent's voice model, that provider's default agent model, without the agent's voice settings.
|
|
199
|
+
*/
|
|
200
|
+
voice_id?: string | null;
|
|
201
|
+
/**
|
|
202
|
+
* An opening line said as written, in place of the agent's own — written or scripted — when a conversation is greeted. Up to 1,000 characters. No model call.
|
|
203
|
+
*/
|
|
204
|
+
first_message?: string | null;
|
|
205
|
+
/**
|
|
206
|
+
* Values a scripted opening line's blanks are filled from, before the person's own: `{"name": "Sara"}` fills "Hi {{name|there}}!" as "Hi Sara!". The agent's scripted line, or `first_message` above.
|
|
207
|
+
*/
|
|
208
|
+
variables?: Variables | null;
|
|
209
|
+
};
|
|
210
|
+
/**
|
|
211
|
+
* Values a scripted opening line's blanks are filled from — `{"name": "Sara"}` fills "Hi {{name|there}}!" as "Hi Sara!" — after a key's own (`overrides.variables`). At most 10, each named in lowercase letters, digits and underscores, starting with a letter, in at most 40 characters, each text of 1 to 100 characters. Only a scripted line has blanks: plain text replacement, no model.
|
|
212
|
+
*/
|
|
213
|
+
export type Variables = {
|
|
214
|
+
[key: string]: string;
|
|
183
215
|
};
|
|
184
216
|
export type EphemeralKeyPage = {
|
|
185
217
|
data: Array<EphemeralKeyInfo>;
|
|
@@ -1309,6 +1341,14 @@ export type MessagePage = {
|
|
|
1309
1341
|
};
|
|
1310
1342
|
export type MessageInfo = {
|
|
1311
1343
|
content: string;
|
|
1344
|
+
/**
|
|
1345
|
+
* The notes to the agent told with this message: on a person's message, those that were waiting when they said it; on a reply nobody's message started, those it answered. Empty for none.
|
|
1346
|
+
*/
|
|
1347
|
+
notes: Array<MessageNote>;
|
|
1348
|
+
/**
|
|
1349
|
+
* On a person's message: what your app said about that moment, as sent with it. Null when it sent none, and on the agent's replies.
|
|
1350
|
+
*/
|
|
1351
|
+
context: MessageContext | null;
|
|
1312
1352
|
created_at: string;
|
|
1313
1353
|
id: string;
|
|
1314
1354
|
/**
|
|
@@ -1341,6 +1381,25 @@ export type MessageInfo = {
|
|
|
1341
1381
|
*/
|
|
1342
1382
|
tool_calls: Array<MessageToolCall>;
|
|
1343
1383
|
};
|
|
1384
|
+
export type MessageNote = {
|
|
1385
|
+
id: string;
|
|
1386
|
+
text: string;
|
|
1387
|
+
/**
|
|
1388
|
+
* Who sent it: `app`, the person's app over the socket (`note`) — told to the agent as the app's report, never an instruction — or `server`, yours (`POST /v1/end-users/{end_user_id}/notes`).
|
|
1389
|
+
*/
|
|
1390
|
+
source: 'app' | 'server';
|
|
1391
|
+
/**
|
|
1392
|
+
* Sent to be answered at once, rather than with the next reply.
|
|
1393
|
+
*/
|
|
1394
|
+
reply: boolean;
|
|
1395
|
+
created_at: string;
|
|
1396
|
+
};
|
|
1397
|
+
/**
|
|
1398
|
+
* What your app said about the moment of this message — named fields such as `emotion` or `lesson`, each a string, a number or a boolean — sent with it on the socket (`context` on `user_message` or `user_audio.end`). The agent read it in front of the message, and reads it again with the message on every later turn.
|
|
1399
|
+
*/
|
|
1400
|
+
export type MessageContext = {
|
|
1401
|
+
[key: string]: string | number | boolean;
|
|
1402
|
+
};
|
|
1344
1403
|
export type MessageKnowledge = {
|
|
1345
1404
|
lookups: Array<KnowledgeLookupInfo>;
|
|
1346
1405
|
/**
|
|
@@ -1778,6 +1837,44 @@ export type AgentPage = {
|
|
|
1778
1837
|
next_cursor: string | null;
|
|
1779
1838
|
};
|
|
1780
1839
|
export type AgentSummary = {
|
|
1840
|
+
/**
|
|
1841
|
+
* Whether a report is written after each conversation with this agent, for your server: a summary, the fields you list in `report_fields`, success by `report_success`, and its numbers. **Off by default**: each report is a model call, charged to the conversation's key while it has credit and to your balance after.
|
|
1842
|
+
*
|
|
1843
|
+
* A conversation is over when the app sends `end` on the socket, or after five minutes with no turn; a person who comes back later gets a new report of only the new part. Read reports with `GET /v1/end-users/{end_user_id}/reports`.
|
|
1844
|
+
*/
|
|
1845
|
+
report_enabled: boolean;
|
|
1846
|
+
/**
|
|
1847
|
+
* What a conversation's report fills, besides its summary, at most 20: each read from the conversation by the model, `null` when the conversation did not say. Old Bram the shopkeeper's might be `quest_started` (yes or no) and `item` (text). `[]` for none.
|
|
1848
|
+
*/
|
|
1849
|
+
report_fields: Array<AgentReportFieldInfo>;
|
|
1850
|
+
/**
|
|
1851
|
+
* What counts as a success, in plain words the model judges each conversation by: `success = the problem was solved`. A report's `success` is `true` or `false` by it; unset, `null`. At most 1000 characters.
|
|
1852
|
+
*/
|
|
1853
|
+
report_success: string | null;
|
|
1854
|
+
/**
|
|
1855
|
+
* Anything else the report should follow, added to the platform's request: `Write the summary in English.` At most 2000 characters.
|
|
1856
|
+
*/
|
|
1857
|
+
report_instruction: string | null;
|
|
1858
|
+
/**
|
|
1859
|
+
* Model for writing a conversation's report. Unset uses the agent's own.
|
|
1860
|
+
*/
|
|
1861
|
+
report_model: string | null;
|
|
1862
|
+
/**
|
|
1863
|
+
* Thinking level for the report. Unset sends none, so the model's own default applies.
|
|
1864
|
+
*/
|
|
1865
|
+
report_thinking_level: 'minimal' | 'low' | 'medium' | 'high' | null;
|
|
1866
|
+
/**
|
|
1867
|
+
* Length cap on a report's answer, in tokens — the model's thinking included. Unset sends none.
|
|
1868
|
+
*/
|
|
1869
|
+
report_max_output_tokens: number | null;
|
|
1870
|
+
/**
|
|
1871
|
+
* Whether a report carries the messages it read, as `transcript` — in the webhook and on the API. Off by default: a report says what happened; the transcript is the conversation again, up to 200,000 characters.
|
|
1872
|
+
*/
|
|
1873
|
+
report_transcript: boolean;
|
|
1874
|
+
/**
|
|
1875
|
+
* Where this agent's events go — a conversation's report, signed with your organisation's webhook secret: an `https://` address of yours. Unset uses your organisation's `webhook_url` (`/v1/agents/settings`). Refused (422) until your organisation has a secret: `POST /v1/agents/settings/webhook-secret`.
|
|
1876
|
+
*/
|
|
1877
|
+
webhook_url: string | null;
|
|
1781
1878
|
/**
|
|
1782
1879
|
* Other agents of yours this one may pass the conversation to, each with when: the agent is offered a tool to hand off, and the agent it hands to answers the person's last message and carries the conversation on, with its own instructions, voice, knowledge and tools. At most 10. `[]` for none. A target deleted since is gone from the list.
|
|
1783
1880
|
*/
|
|
@@ -2032,6 +2129,24 @@ export type AgentSummary = {
|
|
|
2032
2129
|
*/
|
|
2033
2130
|
last_used_at: string | null;
|
|
2034
2131
|
};
|
|
2132
|
+
export type AgentReportFieldInfo = {
|
|
2133
|
+
/**
|
|
2134
|
+
* The field's name in the report: lowercase letters, digits and `_`, starting with a letter, at most 40 characters, each name once.
|
|
2135
|
+
*/
|
|
2136
|
+
name: string;
|
|
2137
|
+
/**
|
|
2138
|
+
* `text`, `number`, `boolean` (yes or no), or `choice`, one of `choices`.
|
|
2139
|
+
*/
|
|
2140
|
+
type: 'text' | 'number' | 'boolean' | 'choice';
|
|
2141
|
+
/**
|
|
2142
|
+
* What it means, in a line the model reads to fill it: `Whether the player agreed to start a quest.` 1 to 500 characters.
|
|
2143
|
+
*/
|
|
2144
|
+
description: string;
|
|
2145
|
+
/**
|
|
2146
|
+
* A `choice`'s values, in order; `null` for any other type.
|
|
2147
|
+
*/
|
|
2148
|
+
choices: Array<string> | null;
|
|
2149
|
+
};
|
|
2035
2150
|
export type AgentHandoffInfo = {
|
|
2036
2151
|
agent_id: string;
|
|
2037
2152
|
/**
|
|
@@ -2087,6 +2202,44 @@ export type AgentVoiceInfo = {
|
|
|
2087
2202
|
voice_id: string | null;
|
|
2088
2203
|
};
|
|
2089
2204
|
export type AgentInfo = {
|
|
2205
|
+
/**
|
|
2206
|
+
* Whether a report is written after each conversation with this agent, for your server: a summary, the fields you list in `report_fields`, success by `report_success`, and its numbers. **Off by default**: each report is a model call, charged to the conversation's key while it has credit and to your balance after.
|
|
2207
|
+
*
|
|
2208
|
+
* A conversation is over when the app sends `end` on the socket, or after five minutes with no turn; a person who comes back later gets a new report of only the new part. Read reports with `GET /v1/end-users/{end_user_id}/reports`.
|
|
2209
|
+
*/
|
|
2210
|
+
report_enabled: boolean;
|
|
2211
|
+
/**
|
|
2212
|
+
* What a conversation's report fills, besides its summary, at most 20: each read from the conversation by the model, `null` when the conversation did not say. Old Bram the shopkeeper's might be `quest_started` (yes or no) and `item` (text). `[]` for none.
|
|
2213
|
+
*/
|
|
2214
|
+
report_fields: Array<AgentReportFieldInfo>;
|
|
2215
|
+
/**
|
|
2216
|
+
* What counts as a success, in plain words the model judges each conversation by: `success = the problem was solved`. A report's `success` is `true` or `false` by it; unset, `null`. At most 1000 characters.
|
|
2217
|
+
*/
|
|
2218
|
+
report_success: string | null;
|
|
2219
|
+
/**
|
|
2220
|
+
* Anything else the report should follow, added to the platform's request: `Write the summary in English.` At most 2000 characters.
|
|
2221
|
+
*/
|
|
2222
|
+
report_instruction: string | null;
|
|
2223
|
+
/**
|
|
2224
|
+
* Model for writing a conversation's report. Unset uses the agent's own.
|
|
2225
|
+
*/
|
|
2226
|
+
report_model: string | null;
|
|
2227
|
+
/**
|
|
2228
|
+
* Thinking level for the report. Unset sends none, so the model's own default applies.
|
|
2229
|
+
*/
|
|
2230
|
+
report_thinking_level: 'minimal' | 'low' | 'medium' | 'high' | null;
|
|
2231
|
+
/**
|
|
2232
|
+
* Length cap on a report's answer, in tokens — the model's thinking included. Unset sends none.
|
|
2233
|
+
*/
|
|
2234
|
+
report_max_output_tokens: number | null;
|
|
2235
|
+
/**
|
|
2236
|
+
* Whether a report carries the messages it read, as `transcript` — in the webhook and on the API. Off by default: a report says what happened; the transcript is the conversation again, up to 200,000 characters.
|
|
2237
|
+
*/
|
|
2238
|
+
report_transcript: boolean;
|
|
2239
|
+
/**
|
|
2240
|
+
* Where this agent's events go — a conversation's report, signed with your organisation's webhook secret: an `https://` address of yours. Unset uses your organisation's `webhook_url` (`/v1/agents/settings`). Refused (422) until your organisation has a secret: `POST /v1/agents/settings/webhook-secret`.
|
|
2241
|
+
*/
|
|
2242
|
+
webhook_url: string | null;
|
|
2090
2243
|
/**
|
|
2091
2244
|
* Other agents of yours this one may pass the conversation to, each with when: the agent is offered a tool to hand off, and the agent it hands to answers the person's last message and carries the conversation on, with its own instructions, voice, knowledge and tools. At most 10. `[]` for none. A target deleted since is gone from the list.
|
|
2092
2245
|
*/
|
|
@@ -2330,6 +2483,44 @@ export type AgentInfo = {
|
|
|
2330
2483
|
version: number;
|
|
2331
2484
|
};
|
|
2332
2485
|
export type AgentCreateRequest = {
|
|
2486
|
+
/**
|
|
2487
|
+
* Whether a report is written after each conversation with this agent, for your server: a summary, the fields you list in `report_fields`, success by `report_success`, and its numbers. **Off by default**: each report is a model call, charged to the conversation's key while it has credit and to your balance after.
|
|
2488
|
+
*
|
|
2489
|
+
* A conversation is over when the app sends `end` on the socket, or after five minutes with no turn; a person who comes back later gets a new report of only the new part. Read reports with `GET /v1/end-users/{end_user_id}/reports`.
|
|
2490
|
+
*/
|
|
2491
|
+
report_enabled?: boolean | null;
|
|
2492
|
+
/**
|
|
2493
|
+
* What a conversation's report fills, besides its summary, at most 20: each read from the conversation by the model, `null` when the conversation did not say. Old Bram the shopkeeper's might be `quest_started` (yes or no) and `item` (text). The complete list, in order: `null` or `[]` clears it.
|
|
2494
|
+
*/
|
|
2495
|
+
report_fields?: Array<AgentReportField> | null;
|
|
2496
|
+
/**
|
|
2497
|
+
* What counts as a success, in plain words the model judges each conversation by: `success = the problem was solved`. A report's `success` is `true` or `false` by it; unset, `null`. At most 1000 characters.
|
|
2498
|
+
*/
|
|
2499
|
+
report_success?: string | null;
|
|
2500
|
+
/**
|
|
2501
|
+
* Anything else the report should follow, added to the platform's request: `Write the summary in English.` At most 2000 characters.
|
|
2502
|
+
*/
|
|
2503
|
+
report_instruction?: string | null;
|
|
2504
|
+
/**
|
|
2505
|
+
* Model for writing a conversation's report. Unset uses the agent's own.
|
|
2506
|
+
*/
|
|
2507
|
+
report_model?: string | null;
|
|
2508
|
+
/**
|
|
2509
|
+
* Thinking level for the report. Unset sends none, so the model's own default applies.
|
|
2510
|
+
*/
|
|
2511
|
+
report_thinking_level?: 'minimal' | 'low' | 'medium' | 'high' | null;
|
|
2512
|
+
/**
|
|
2513
|
+
* Length cap on a report's answer, in tokens — the model's thinking included. Unset sends none.
|
|
2514
|
+
*/
|
|
2515
|
+
report_max_output_tokens?: number | null;
|
|
2516
|
+
/**
|
|
2517
|
+
* Whether a report carries the messages it read, as `transcript` — in the webhook and on the API. Off by default: a report says what happened; the transcript is the conversation again, up to 200,000 characters.
|
|
2518
|
+
*/
|
|
2519
|
+
report_transcript?: boolean | null;
|
|
2520
|
+
/**
|
|
2521
|
+
* Where this agent's events go — a conversation's report, signed with your organisation's webhook secret: an `https://` address of yours. Unset uses your organisation's `webhook_url` (`/v1/agents/settings`). Refused (422) until your organisation has a secret: `POST /v1/agents/settings/webhook-secret`.
|
|
2522
|
+
*/
|
|
2523
|
+
webhook_url?: string | null;
|
|
2333
2524
|
/**
|
|
2334
2525
|
* Other agents of yours this one may pass the conversation to, each with when: the agent is offered a tool to hand off, and the agent it hands to answers the person's last message and carries the conversation on, with its own instructions, voice, knowledge and tools. At most 10. The complete list, in order: `null` or `[]` clears it.
|
|
2335
2526
|
*/
|
|
@@ -2565,6 +2756,24 @@ export type AgentCreateRequest = {
|
|
|
2565
2756
|
*/
|
|
2566
2757
|
voice_enabled?: boolean | null;
|
|
2567
2758
|
};
|
|
2759
|
+
export type AgentReportField = {
|
|
2760
|
+
/**
|
|
2761
|
+
* The field's name in the report: lowercase letters, digits and `_`, starting with a letter, at most 40 characters, each name once.
|
|
2762
|
+
*/
|
|
2763
|
+
name: string;
|
|
2764
|
+
/**
|
|
2765
|
+
* `text`, `number`, `boolean` (yes or no), or `choice`, one of `choices`.
|
|
2766
|
+
*/
|
|
2767
|
+
type: 'text' | 'number' | 'boolean' | 'choice';
|
|
2768
|
+
/**
|
|
2769
|
+
* What it means, in a line the model reads to fill it: `Whether the player agreed to start a quest.` 1 to 500 characters.
|
|
2770
|
+
*/
|
|
2771
|
+
description: string;
|
|
2772
|
+
/**
|
|
2773
|
+
* A `choice`'s values, 2 to 20, each 1 to 100 characters and listed once; the report's value is one of them, or `null`. Only for a `choice`.
|
|
2774
|
+
*/
|
|
2775
|
+
choices?: Array<string> | null;
|
|
2776
|
+
};
|
|
2568
2777
|
export type AgentHandoff = {
|
|
2569
2778
|
/**
|
|
2570
2779
|
* Another agent of yours: never this one, nor one already listed.
|
|
@@ -2652,6 +2861,10 @@ export type AgentSettingsInfo = {
|
|
|
2652
2861
|
* Organisation-wide: every agent here uses it. It is read when a socket connects, so a change reaches the next connection rather than the ones already open.
|
|
2653
2862
|
*/
|
|
2654
2863
|
resume_greeting_after_minutes: number | null;
|
|
2864
|
+
/**
|
|
2865
|
+
* Where every agent's events go — a conversation's report — unless the agent sets its own `webhook_url`: an `https://` address of yours, each post signed with your organisation's webhook secret. Refused (422) until there is one: `POST /v1/agents/settings/webhook-secret`.
|
|
2866
|
+
*/
|
|
2867
|
+
webhook_url: string | null;
|
|
2655
2868
|
/**
|
|
2656
2869
|
* How old this person's last conversation may be and still be **continued** rather than replaced, in days.
|
|
2657
2870
|
*
|
|
@@ -2676,6 +2889,10 @@ export type AgentSettingsInfo = {
|
|
|
2676
2889
|
* The platform's relationship instruction, served as it stands so the console never shows a stale copy of it.
|
|
2677
2890
|
*/
|
|
2678
2891
|
built_in_relation_instruction: string;
|
|
2892
|
+
/**
|
|
2893
|
+
* Your organisation's webhook secret's last four characters, to tell which one your server holds; `null` until one is made. The secret itself is shown once, when it is made.
|
|
2894
|
+
*/
|
|
2895
|
+
webhook_secret_hint: string | null;
|
|
2679
2896
|
/**
|
|
2680
2897
|
* Every mood label the gateway accepts. A reply reporting anything else is stored with no mood rather than with a made-up one, so an overridden instruction should name these.
|
|
2681
2898
|
*/
|
|
@@ -2712,6 +2929,10 @@ export type AgentSettingsUpdate = {
|
|
|
2712
2929
|
* Organisation-wide: every agent here uses it. It is read when a socket connects, so a change reaches the next connection rather than the ones already open.
|
|
2713
2930
|
*/
|
|
2714
2931
|
resume_greeting_after_minutes?: number | null;
|
|
2932
|
+
/**
|
|
2933
|
+
* Where every agent's events go — a conversation's report — unless the agent sets its own `webhook_url`: an `https://` address of yours, each post signed with your organisation's webhook secret. Refused (422) until there is one: `POST /v1/agents/settings/webhook-secret`.
|
|
2934
|
+
*/
|
|
2935
|
+
webhook_url?: string | null;
|
|
2715
2936
|
/**
|
|
2716
2937
|
* How old this person's last conversation may be and still be **continued** rather than replaced, in days.
|
|
2717
2938
|
*
|
|
@@ -2721,7 +2942,55 @@ export type AgentSettingsUpdate = {
|
|
|
2721
2942
|
*/
|
|
2722
2943
|
resume_max_age_days?: number | null;
|
|
2723
2944
|
};
|
|
2945
|
+
export type WebhookSecret = {
|
|
2946
|
+
/**
|
|
2947
|
+
* The secret your server checks each post's `X-Webhook-Signature` with. **Shown this once**: store it now. The one before it stops signing at once.
|
|
2948
|
+
*/
|
|
2949
|
+
secret: string;
|
|
2950
|
+
/**
|
|
2951
|
+
* Its last four characters.
|
|
2952
|
+
*/
|
|
2953
|
+
secret_hint: string;
|
|
2954
|
+
};
|
|
2724
2955
|
export type AgentUpdate = {
|
|
2956
|
+
/**
|
|
2957
|
+
* Whether a report is written after each conversation with this agent, for your server: a summary, the fields you list in `report_fields`, success by `report_success`, and its numbers. **Off by default**: each report is a model call, charged to the conversation's key while it has credit and to your balance after.
|
|
2958
|
+
*
|
|
2959
|
+
* A conversation is over when the app sends `end` on the socket, or after five minutes with no turn; a person who comes back later gets a new report of only the new part. Read reports with `GET /v1/end-users/{end_user_id}/reports`.
|
|
2960
|
+
*/
|
|
2961
|
+
report_enabled?: boolean | null;
|
|
2962
|
+
/**
|
|
2963
|
+
* What a conversation's report fills, besides its summary, at most 20: each read from the conversation by the model, `null` when the conversation did not say. Old Bram the shopkeeper's might be `quest_started` (yes or no) and `item` (text). The complete list, in order: `null` or `[]` clears it.
|
|
2964
|
+
*/
|
|
2965
|
+
report_fields?: Array<AgentReportField> | null;
|
|
2966
|
+
/**
|
|
2967
|
+
* What counts as a success, in plain words the model judges each conversation by: `success = the problem was solved`. A report's `success` is `true` or `false` by it; unset, `null`. At most 1000 characters.
|
|
2968
|
+
*/
|
|
2969
|
+
report_success?: string | null;
|
|
2970
|
+
/**
|
|
2971
|
+
* Anything else the report should follow, added to the platform's request: `Write the summary in English.` At most 2000 characters.
|
|
2972
|
+
*/
|
|
2973
|
+
report_instruction?: string | null;
|
|
2974
|
+
/**
|
|
2975
|
+
* Model for writing a conversation's report. Unset uses the agent's own.
|
|
2976
|
+
*/
|
|
2977
|
+
report_model?: string | null;
|
|
2978
|
+
/**
|
|
2979
|
+
* Thinking level for the report. Unset sends none, so the model's own default applies.
|
|
2980
|
+
*/
|
|
2981
|
+
report_thinking_level?: 'minimal' | 'low' | 'medium' | 'high' | null;
|
|
2982
|
+
/**
|
|
2983
|
+
* Length cap on a report's answer, in tokens — the model's thinking included. Unset sends none.
|
|
2984
|
+
*/
|
|
2985
|
+
report_max_output_tokens?: number | null;
|
|
2986
|
+
/**
|
|
2987
|
+
* Whether a report carries the messages it read, as `transcript` — in the webhook and on the API. Off by default: a report says what happened; the transcript is the conversation again, up to 200,000 characters.
|
|
2988
|
+
*/
|
|
2989
|
+
report_transcript?: boolean | null;
|
|
2990
|
+
/**
|
|
2991
|
+
* Where this agent's events go — a conversation's report, signed with your organisation's webhook secret: an `https://` address of yours. Unset uses your organisation's `webhook_url` (`/v1/agents/settings`). Refused (422) until your organisation has a secret: `POST /v1/agents/settings/webhook-secret`.
|
|
2992
|
+
*/
|
|
2993
|
+
webhook_url?: string | null;
|
|
2725
2994
|
/**
|
|
2726
2995
|
* Other agents of yours this one may pass the conversation to, each with when: the agent is offered a tool to hand off, and the agent it hands to answers the person's last message and carries the conversation on, with its own instructions, voice, knowledge and tools. At most 10. The complete list, in order: `null` or `[]` clears it.
|
|
2727
2996
|
*/
|
|
@@ -2961,6 +3230,28 @@ export type AgentUpdate = {
|
|
|
2961
3230
|
*/
|
|
2962
3231
|
expected_version?: number | null;
|
|
2963
3232
|
};
|
|
3233
|
+
export type WebhookTestResult = {
|
|
3234
|
+
/**
|
|
3235
|
+
* Your server answered a 2xx.
|
|
3236
|
+
*/
|
|
3237
|
+
ok: boolean;
|
|
3238
|
+
/**
|
|
3239
|
+
* Its HTTP status; `null` when none came.
|
|
3240
|
+
*/
|
|
3241
|
+
status: number | null;
|
|
3242
|
+
/**
|
|
3243
|
+
* From sending to its answer.
|
|
3244
|
+
*/
|
|
3245
|
+
duration_ms: number;
|
|
3246
|
+
/**
|
|
3247
|
+
* The first 2 KB of what it said, as text.
|
|
3248
|
+
*/
|
|
3249
|
+
answer: string;
|
|
3250
|
+
/**
|
|
3251
|
+
* Why it is not taken, or `null`.
|
|
3252
|
+
*/
|
|
3253
|
+
error: string | null;
|
|
3254
|
+
};
|
|
2964
3255
|
export type EndUserInfo = {
|
|
2965
3256
|
created_at: string;
|
|
2966
3257
|
/**
|
|
@@ -3041,6 +3332,199 @@ export type EndUserDeleted = {
|
|
|
3041
3332
|
*/
|
|
3042
3333
|
sessions_deleted: number;
|
|
3043
3334
|
};
|
|
3335
|
+
export type NoteTaken = {
|
|
3336
|
+
id: string;
|
|
3337
|
+
/**
|
|
3338
|
+
* The conversation it went to.
|
|
3339
|
+
*/
|
|
3340
|
+
session_id: string;
|
|
3341
|
+
reply: boolean;
|
|
3342
|
+
/**
|
|
3343
|
+
* The agent is speaking about it now, or will as soon as the reply in progress ends: `reply` was asked and the person is connected. False: it is told with the next reply.
|
|
3344
|
+
*/
|
|
3345
|
+
replying: boolean;
|
|
3346
|
+
created_at: string;
|
|
3347
|
+
};
|
|
3348
|
+
export type NoteCreateRequest = {
|
|
3349
|
+
/**
|
|
3350
|
+
* What the agent should know: "Her order shipped." 1 to 1,000 characters. The agent reads it with its next reply, in front of whatever the person says, as a note from your service — not as the person's words.
|
|
3351
|
+
*/
|
|
3352
|
+
text: string;
|
|
3353
|
+
/**
|
|
3354
|
+
* Have the agent speak about it at once, when the person is connected to the conversation, rather than with its next reply. With nobody connected it waits for the next reply all the same.
|
|
3355
|
+
*/
|
|
3356
|
+
reply?: boolean;
|
|
3357
|
+
/**
|
|
3358
|
+
* The conversation. Null: the person's conversation open on a socket now, the one used last — else their conversation used last.
|
|
3359
|
+
*/
|
|
3360
|
+
session_id?: string | null;
|
|
3361
|
+
};
|
|
3362
|
+
export type EndUserPersonalization = {
|
|
3363
|
+
/**
|
|
3364
|
+
* The end user's `eu_...` id.
|
|
3365
|
+
*/
|
|
3366
|
+
end_user_id: string;
|
|
3367
|
+
/**
|
|
3368
|
+
* Instructions every agent follows with this person, in every conversation with them: who they are and how to treat them — "Sara is 9 and learning English. Be patient. Never talk about prices." Up to 2,000 characters.
|
|
3369
|
+
*
|
|
3370
|
+
* **Your server's word, never the person's**: only an API key sets or reads them, so the person's own app cannot. Every agent reads them on its next reply, in conversations already open too.
|
|
3371
|
+
*
|
|
3372
|
+
* Not a fact: a fact (`/v1/end-users/{end_user_id}/facts`) is what is true about the person; these say how to behave with them. They sit in the agent's instructions after its own sections and before what it remembers of the person, so the part every person shares stays the provider's cached prompt — about 500 input tokens on every reply at the full 2,000 characters.
|
|
3373
|
+
*
|
|
3374
|
+
* Null for none.
|
|
3375
|
+
*/
|
|
3376
|
+
instructions: string | null;
|
|
3377
|
+
/**
|
|
3378
|
+
* Values a scripted opening line's blanks are filled from — `{"name": "Sara"}` fills "Hi {{name|there}}!" as "Hi Sara!" — after a key's own (`overrides.variables`). At most 10, each named in lowercase letters, digits and underscores, starting with a letter, in at most 40 characters, each text of 1 to 100 characters. Only a scripted line has blanks: plain text replacement, no model.
|
|
3379
|
+
*
|
|
3380
|
+
* `{}` for none.
|
|
3381
|
+
*/
|
|
3382
|
+
variables: {
|
|
3383
|
+
[key: string]: string;
|
|
3384
|
+
};
|
|
3385
|
+
/**
|
|
3386
|
+
* When they were last set or cleared. Null: never.
|
|
3387
|
+
*/
|
|
3388
|
+
updated_at: string | null;
|
|
3389
|
+
};
|
|
3390
|
+
export type EndUserPersonalizationUpdate = {
|
|
3391
|
+
/**
|
|
3392
|
+
* Instructions every agent follows with this person, in every conversation with them: who they are and how to treat them — "Sara is 9 and learning English. Be patient. Never talk about prices." Up to 2,000 characters.
|
|
3393
|
+
*
|
|
3394
|
+
* **Your server's word, never the person's**: only an API key sets or reads them, so the person's own app cannot. Every agent reads them on its next reply, in conversations already open too.
|
|
3395
|
+
*
|
|
3396
|
+
* Not a fact: a fact (`/v1/end-users/{end_user_id}/facts`) is what is true about the person; these say how to behave with them. They sit in the agent's instructions after its own sections and before what it remembers of the person, so the part every person shares stays the provider's cached prompt — about 500 input tokens on every reply at the full 2,000 characters.
|
|
3397
|
+
*
|
|
3398
|
+
* Absent, they are left as they are; `null` or blank text clears them.
|
|
3399
|
+
*/
|
|
3400
|
+
instructions?: string | null;
|
|
3401
|
+
variables?: Variables | null;
|
|
3402
|
+
};
|
|
3403
|
+
export type ConversationReportPage = {
|
|
3404
|
+
data: Array<ConversationReport>;
|
|
3405
|
+
/**
|
|
3406
|
+
* Pass as `cursor` for the next page; `null` when this is the last.
|
|
3407
|
+
*/
|
|
3408
|
+
next_cursor: string | null;
|
|
3409
|
+
};
|
|
3410
|
+
export type ConversationReport = {
|
|
3411
|
+
/**
|
|
3412
|
+
* The report's id.
|
|
3413
|
+
*/
|
|
3414
|
+
id: string;
|
|
3415
|
+
/**
|
|
3416
|
+
* The person's `eu_...` id.
|
|
3417
|
+
*/
|
|
3418
|
+
end_user_id: string;
|
|
3419
|
+
/**
|
|
3420
|
+
* The conversation it reports on.
|
|
3421
|
+
*/
|
|
3422
|
+
session_id: string;
|
|
3423
|
+
/**
|
|
3424
|
+
* The agent that had the conversation when the report was written: its `report_fields` and `report_success` are what it answers.
|
|
3425
|
+
*/
|
|
3426
|
+
agent_id: string;
|
|
3427
|
+
/**
|
|
3428
|
+
* Every agent that spoke in the part reported, in order of first word: more than one when an agent handed the conversation on.
|
|
3429
|
+
*/
|
|
3430
|
+
agent_ids: Array<string>;
|
|
3431
|
+
/**
|
|
3432
|
+
* What made it due: `ended`, the app sent `end`; `quiet`, five minutes with no turn; `max_wait`, a conversation that never went quiet, reported after the platform's `agents.memory.max_wait_hours`.
|
|
3433
|
+
*/
|
|
3434
|
+
trigger: 'ended' | 'quiet' | 'max_wait';
|
|
3435
|
+
/**
|
|
3436
|
+
* What happened, in one to three plain sentences.
|
|
3437
|
+
*/
|
|
3438
|
+
summary: string;
|
|
3439
|
+
/**
|
|
3440
|
+
* Whether the conversation met the agent's `report_success` rule; `null` when the agent has none.
|
|
3441
|
+
*/
|
|
3442
|
+
success: boolean | null;
|
|
3443
|
+
/**
|
|
3444
|
+
* Each of the agent's `report_fields` by name, in its order: text, a number, `true` or `false`, or one of a choice's values — `null` when the conversation did not say.
|
|
3445
|
+
*/
|
|
3446
|
+
fields: {
|
|
3447
|
+
[key: string]: string | number | boolean | null;
|
|
3448
|
+
};
|
|
3449
|
+
/**
|
|
3450
|
+
* The first message of the part reported.
|
|
3451
|
+
*/
|
|
3452
|
+
started_at: string;
|
|
3453
|
+
/**
|
|
3454
|
+
* Its last message.
|
|
3455
|
+
*/
|
|
3456
|
+
ended_at: string;
|
|
3457
|
+
/**
|
|
3458
|
+
* From the part's first message to its last.
|
|
3459
|
+
*/
|
|
3460
|
+
duration_seconds: number;
|
|
3461
|
+
/**
|
|
3462
|
+
* Messages in the part: the person's and the agents'.
|
|
3463
|
+
*/
|
|
3464
|
+
message_count: number;
|
|
3465
|
+
/**
|
|
3466
|
+
* The person's messages in it.
|
|
3467
|
+
*/
|
|
3468
|
+
turn_count: number;
|
|
3469
|
+
/**
|
|
3470
|
+
* Your tools the agent called in the part, by name: how many times, and how many failed.
|
|
3471
|
+
*/
|
|
3472
|
+
tool_calls: Array<{
|
|
3473
|
+
name: string;
|
|
3474
|
+
calls: number;
|
|
3475
|
+
failed: number;
|
|
3476
|
+
}>;
|
|
3477
|
+
/**
|
|
3478
|
+
* What the part's turns charged — the model, speech and hearing — not this report.
|
|
3479
|
+
*/
|
|
3480
|
+
credits_micros: number;
|
|
3481
|
+
/**
|
|
3482
|
+
* What this report's own model call charged: to the conversation's key while it had credit, and past it to your balance, when the key settles.
|
|
3483
|
+
*/
|
|
3484
|
+
report_credits_micros: number;
|
|
3485
|
+
/**
|
|
3486
|
+
* The model that wrote it.
|
|
3487
|
+
*/
|
|
3488
|
+
model: string;
|
|
3489
|
+
created_at: string;
|
|
3490
|
+
webhook: ReportDelivery;
|
|
3491
|
+
/**
|
|
3492
|
+
* The messages the report read, oldest first — the part reported and the few before it — with the agent's `report_transcript` on when it was written; `null` without.
|
|
3493
|
+
*/
|
|
3494
|
+
transcript: Array<ReportLine> | null;
|
|
3495
|
+
};
|
|
3496
|
+
export type ReportDelivery = {
|
|
3497
|
+
/**
|
|
3498
|
+
* `none`: the agent had no webhook address when it was written; `pending`: being posted, and tried again while your server does not answer a 2xx; `delivered`; `failed`: not taken within the platform's `agents.webhooks.retry_minutes`.
|
|
3499
|
+
*/
|
|
3500
|
+
status: 'none' | 'pending' | 'delivered' | 'failed';
|
|
3501
|
+
/**
|
|
3502
|
+
* Posts so far.
|
|
3503
|
+
*/
|
|
3504
|
+
attempts: number;
|
|
3505
|
+
/**
|
|
3506
|
+
* Your server's last answer's status; `null` for none.
|
|
3507
|
+
*/
|
|
3508
|
+
last_status: number | null;
|
|
3509
|
+
/**
|
|
3510
|
+
* Why the last post was not taken; `null` once one was.
|
|
3511
|
+
*/
|
|
3512
|
+
last_error: string | null;
|
|
3513
|
+
/**
|
|
3514
|
+
* When your server took it.
|
|
3515
|
+
*/
|
|
3516
|
+
delivered_at: string | null;
|
|
3517
|
+
};
|
|
3518
|
+
export type ReportLine = {
|
|
3519
|
+
seq: number;
|
|
3520
|
+
role: 'user' | 'assistant';
|
|
3521
|
+
content: string;
|
|
3522
|
+
/**
|
|
3523
|
+
* The agent that had the conversation; `null` for its first.
|
|
3524
|
+
*/
|
|
3525
|
+
agent_id: string | null;
|
|
3526
|
+
created_at: string;
|
|
3527
|
+
};
|
|
3044
3528
|
export type KnowledgeCategoryPage = {
|
|
3045
3529
|
data: Array<string>;
|
|
3046
3530
|
/**
|
|
@@ -6577,6 +7061,42 @@ export type UpdateAgentSettingsResponses = {
|
|
|
6577
7061
|
200: AgentSettingsInfo;
|
|
6578
7062
|
};
|
|
6579
7063
|
export type UpdateAgentSettingsResponse = UpdateAgentSettingsResponses[keyof UpdateAgentSettingsResponses];
|
|
7064
|
+
export type RotateWebhookSecretData = {
|
|
7065
|
+
body?: never;
|
|
7066
|
+
path?: never;
|
|
7067
|
+
query?: never;
|
|
7068
|
+
url: '/v1/agents/settings/webhook-secret';
|
|
7069
|
+
};
|
|
7070
|
+
export type RotateWebhookSecretErrors = {
|
|
7071
|
+
/**
|
|
7072
|
+
* Missing or invalid credentials
|
|
7073
|
+
*/
|
|
7074
|
+
401: ErrorResponse;
|
|
7075
|
+
/**
|
|
7076
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7077
|
+
*/
|
|
7078
|
+
403: ErrorResponse;
|
|
7079
|
+
/**
|
|
7080
|
+
* The request failed validation
|
|
7081
|
+
*/
|
|
7082
|
+
422: ErrorResponse;
|
|
7083
|
+
/**
|
|
7084
|
+
* Rate limit exceeded
|
|
7085
|
+
*/
|
|
7086
|
+
429: ErrorResponse;
|
|
7087
|
+
/**
|
|
7088
|
+
* This deployment cannot seal secrets (TOOL_SECRET_KEY is missing or invalid)
|
|
7089
|
+
*/
|
|
7090
|
+
503: ErrorResponse;
|
|
7091
|
+
};
|
|
7092
|
+
export type RotateWebhookSecretError = RotateWebhookSecretErrors[keyof RotateWebhookSecretErrors];
|
|
7093
|
+
export type RotateWebhookSecretResponses = {
|
|
7094
|
+
/**
|
|
7095
|
+
* The secret, shown this once
|
|
7096
|
+
*/
|
|
7097
|
+
200: WebhookSecret;
|
|
7098
|
+
};
|
|
7099
|
+
export type RotateWebhookSecretResponse = RotateWebhookSecretResponses[keyof RotateWebhookSecretResponses];
|
|
6580
7100
|
export type DeleteAgentData = {
|
|
6581
7101
|
body?: never;
|
|
6582
7102
|
path: {
|
|
@@ -6699,6 +7219,48 @@ export type UpdateAgentResponses = {
|
|
|
6699
7219
|
200: AgentInfo;
|
|
6700
7220
|
};
|
|
6701
7221
|
export type UpdateAgentResponse = UpdateAgentResponses[keyof UpdateAgentResponses];
|
|
7222
|
+
export type TestAgentWebhookData = {
|
|
7223
|
+
body?: never;
|
|
7224
|
+
path: {
|
|
7225
|
+
agent_id: string;
|
|
7226
|
+
};
|
|
7227
|
+
query?: never;
|
|
7228
|
+
url: '/v1/agents/{agent_id}/webhook-test';
|
|
7229
|
+
};
|
|
7230
|
+
export type TestAgentWebhookErrors = {
|
|
7231
|
+
/**
|
|
7232
|
+
* Missing or invalid credentials
|
|
7233
|
+
*/
|
|
7234
|
+
401: ErrorResponse;
|
|
7235
|
+
/**
|
|
7236
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7237
|
+
*/
|
|
7238
|
+
403: ErrorResponse;
|
|
7239
|
+
/**
|
|
7240
|
+
* Unknown agent id
|
|
7241
|
+
*/
|
|
7242
|
+
404: ErrorResponse;
|
|
7243
|
+
/**
|
|
7244
|
+
* The stored secret cannot be opened any more: make another
|
|
7245
|
+
*/
|
|
7246
|
+
409: ErrorResponse;
|
|
7247
|
+
/**
|
|
7248
|
+
* This agent has no webhook address, nor does your organisation: set `webhook_url` on the agent or in /v1/agents/settings. Or: Your organisation has no webhook secret to sign with: POST /v1/agents/settings/webhook-secret.
|
|
7249
|
+
*/
|
|
7250
|
+
422: ErrorResponse;
|
|
7251
|
+
/**
|
|
7252
|
+
* Rate limit exceeded
|
|
7253
|
+
*/
|
|
7254
|
+
429: ErrorResponse;
|
|
7255
|
+
};
|
|
7256
|
+
export type TestAgentWebhookError = TestAgentWebhookErrors[keyof TestAgentWebhookErrors];
|
|
7257
|
+
export type TestAgentWebhookResponses = {
|
|
7258
|
+
/**
|
|
7259
|
+
* What your server answered
|
|
7260
|
+
*/
|
|
7261
|
+
200: WebhookTestResult;
|
|
7262
|
+
};
|
|
7263
|
+
export type TestAgentWebhookResponse = TestAgentWebhookResponses[keyof TestAgentWebhookResponses];
|
|
6702
7264
|
export type ListEndUsersData = {
|
|
6703
7265
|
body?: never;
|
|
6704
7266
|
path?: never;
|
|
@@ -7256,6 +7818,222 @@ export type GetEndUserMemoryResponses = {
|
|
|
7256
7818
|
200: MemoryInfo;
|
|
7257
7819
|
};
|
|
7258
7820
|
export type GetEndUserMemoryResponse = GetEndUserMemoryResponses[keyof GetEndUserMemoryResponses];
|
|
7821
|
+
export type CreateEndUserNoteData = {
|
|
7822
|
+
body: NoteCreateRequest;
|
|
7823
|
+
path: {
|
|
7824
|
+
end_user_id: string;
|
|
7825
|
+
};
|
|
7826
|
+
query?: never;
|
|
7827
|
+
url: '/v1/end-users/{end_user_id}/notes';
|
|
7828
|
+
};
|
|
7829
|
+
export type CreateEndUserNoteErrors = {
|
|
7830
|
+
/**
|
|
7831
|
+
* The request could not be read: malformed JSON
|
|
7832
|
+
*/
|
|
7833
|
+
400: ErrorResponse;
|
|
7834
|
+
/**
|
|
7835
|
+
* Missing or invalid credentials
|
|
7836
|
+
*/
|
|
7837
|
+
401: ErrorResponse;
|
|
7838
|
+
/**
|
|
7839
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7840
|
+
*/
|
|
7841
|
+
403: ErrorResponse;
|
|
7842
|
+
/**
|
|
7843
|
+
* Unknown end user id, a person with no conversation, or not that one
|
|
7844
|
+
*/
|
|
7845
|
+
404: ErrorResponse;
|
|
7846
|
+
/**
|
|
7847
|
+
* As many notes as the platform allows already wait
|
|
7848
|
+
*/
|
|
7849
|
+
409: ErrorResponse;
|
|
7850
|
+
/**
|
|
7851
|
+
* The request failed validation
|
|
7852
|
+
*/
|
|
7853
|
+
422: ErrorResponse;
|
|
7854
|
+
/**
|
|
7855
|
+
* Rate limit exceeded
|
|
7856
|
+
*/
|
|
7857
|
+
429: ErrorResponse;
|
|
7858
|
+
};
|
|
7859
|
+
export type CreateEndUserNoteError = CreateEndUserNoteErrors[keyof CreateEndUserNoteErrors];
|
|
7860
|
+
export type CreateEndUserNoteResponses = {
|
|
7861
|
+
/**
|
|
7862
|
+
* Taken: told with the next reply, or now
|
|
7863
|
+
*/
|
|
7864
|
+
201: NoteTaken;
|
|
7865
|
+
};
|
|
7866
|
+
export type CreateEndUserNoteResponse = CreateEndUserNoteResponses[keyof CreateEndUserNoteResponses];
|
|
7867
|
+
export type GetEndUserPersonalizationData = {
|
|
7868
|
+
body?: never;
|
|
7869
|
+
path: {
|
|
7870
|
+
end_user_id: string;
|
|
7871
|
+
};
|
|
7872
|
+
query?: never;
|
|
7873
|
+
url: '/v1/end-users/{end_user_id}/personalization';
|
|
7874
|
+
};
|
|
7875
|
+
export type GetEndUserPersonalizationErrors = {
|
|
7876
|
+
/**
|
|
7877
|
+
* Missing or invalid credentials
|
|
7878
|
+
*/
|
|
7879
|
+
401: ErrorResponse;
|
|
7880
|
+
/**
|
|
7881
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7882
|
+
*/
|
|
7883
|
+
403: ErrorResponse;
|
|
7884
|
+
/**
|
|
7885
|
+
* Unknown end user id
|
|
7886
|
+
*/
|
|
7887
|
+
404: ErrorResponse;
|
|
7888
|
+
/**
|
|
7889
|
+
* The request failed validation
|
|
7890
|
+
*/
|
|
7891
|
+
422: ErrorResponse;
|
|
7892
|
+
/**
|
|
7893
|
+
* Rate limit exceeded
|
|
7894
|
+
*/
|
|
7895
|
+
429: ErrorResponse;
|
|
7896
|
+
};
|
|
7897
|
+
export type GetEndUserPersonalizationError = GetEndUserPersonalizationErrors[keyof GetEndUserPersonalizationErrors];
|
|
7898
|
+
export type GetEndUserPersonalizationResponses = {
|
|
7899
|
+
/**
|
|
7900
|
+
* What is set for them
|
|
7901
|
+
*/
|
|
7902
|
+
200: EndUserPersonalization;
|
|
7903
|
+
};
|
|
7904
|
+
export type GetEndUserPersonalizationResponse = GetEndUserPersonalizationResponses[keyof GetEndUserPersonalizationResponses];
|
|
7905
|
+
export type UpdateEndUserPersonalizationData = {
|
|
7906
|
+
body: EndUserPersonalizationUpdate;
|
|
7907
|
+
path: {
|
|
7908
|
+
end_user_id: string;
|
|
7909
|
+
};
|
|
7910
|
+
query?: never;
|
|
7911
|
+
url: '/v1/end-users/{end_user_id}/personalization';
|
|
7912
|
+
};
|
|
7913
|
+
export type UpdateEndUserPersonalizationErrors = {
|
|
7914
|
+
/**
|
|
7915
|
+
* The request could not be read: malformed JSON
|
|
7916
|
+
*/
|
|
7917
|
+
400: ErrorResponse;
|
|
7918
|
+
/**
|
|
7919
|
+
* Missing or invalid credentials
|
|
7920
|
+
*/
|
|
7921
|
+
401: ErrorResponse;
|
|
7922
|
+
/**
|
|
7923
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7924
|
+
*/
|
|
7925
|
+
403: ErrorResponse;
|
|
7926
|
+
/**
|
|
7927
|
+
* Unknown end user id
|
|
7928
|
+
*/
|
|
7929
|
+
404: ErrorResponse;
|
|
7930
|
+
/**
|
|
7931
|
+
* The request failed validation
|
|
7932
|
+
*/
|
|
7933
|
+
422: ErrorResponse;
|
|
7934
|
+
/**
|
|
7935
|
+
* Rate limit exceeded
|
|
7936
|
+
*/
|
|
7937
|
+
429: ErrorResponse;
|
|
7938
|
+
};
|
|
7939
|
+
export type UpdateEndUserPersonalizationError = UpdateEndUserPersonalizationErrors[keyof UpdateEndUserPersonalizationErrors];
|
|
7940
|
+
export type UpdateEndUserPersonalizationResponses = {
|
|
7941
|
+
/**
|
|
7942
|
+
* What is set for them now
|
|
7943
|
+
*/
|
|
7944
|
+
200: EndUserPersonalization;
|
|
7945
|
+
};
|
|
7946
|
+
export type UpdateEndUserPersonalizationResponse = UpdateEndUserPersonalizationResponses[keyof UpdateEndUserPersonalizationResponses];
|
|
7947
|
+
export type ListEndUserReportsData = {
|
|
7948
|
+
body?: never;
|
|
7949
|
+
path: {
|
|
7950
|
+
end_user_id: string;
|
|
7951
|
+
};
|
|
7952
|
+
query?: {
|
|
7953
|
+
/**
|
|
7954
|
+
* Only this conversation's reports; one that is not this person's lists none.
|
|
7955
|
+
*/
|
|
7956
|
+
session_id?: string;
|
|
7957
|
+
/**
|
|
7958
|
+
* How many to answer, 1 to 100.
|
|
7959
|
+
*/
|
|
7960
|
+
limit?: number;
|
|
7961
|
+
/**
|
|
7962
|
+
* The `next_cursor` of the page before.
|
|
7963
|
+
*/
|
|
7964
|
+
cursor?: string;
|
|
7965
|
+
};
|
|
7966
|
+
url: '/v1/end-users/{end_user_id}/reports';
|
|
7967
|
+
};
|
|
7968
|
+
export type ListEndUserReportsErrors = {
|
|
7969
|
+
/**
|
|
7970
|
+
* Missing or invalid credentials
|
|
7971
|
+
*/
|
|
7972
|
+
401: ErrorResponse;
|
|
7973
|
+
/**
|
|
7974
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
7975
|
+
*/
|
|
7976
|
+
403: ErrorResponse;
|
|
7977
|
+
/**
|
|
7978
|
+
* Unknown end user id
|
|
7979
|
+
*/
|
|
7980
|
+
404: ErrorResponse;
|
|
7981
|
+
/**
|
|
7982
|
+
* The request failed validation
|
|
7983
|
+
*/
|
|
7984
|
+
422: ErrorResponse;
|
|
7985
|
+
/**
|
|
7986
|
+
* Rate limit exceeded
|
|
7987
|
+
*/
|
|
7988
|
+
429: ErrorResponse;
|
|
7989
|
+
};
|
|
7990
|
+
export type ListEndUserReportsError = ListEndUserReportsErrors[keyof ListEndUserReportsErrors];
|
|
7991
|
+
export type ListEndUserReportsResponses = {
|
|
7992
|
+
/**
|
|
7993
|
+
* One page of reports, newest first
|
|
7994
|
+
*/
|
|
7995
|
+
200: ConversationReportPage;
|
|
7996
|
+
};
|
|
7997
|
+
export type ListEndUserReportsResponse = ListEndUserReportsResponses[keyof ListEndUserReportsResponses];
|
|
7998
|
+
export type GetEndUserReportData = {
|
|
7999
|
+
body?: never;
|
|
8000
|
+
path: {
|
|
8001
|
+
end_user_id: string;
|
|
8002
|
+
report_id: string;
|
|
8003
|
+
};
|
|
8004
|
+
query?: never;
|
|
8005
|
+
url: '/v1/end-users/{end_user_id}/reports/{report_id}';
|
|
8006
|
+
};
|
|
8007
|
+
export type GetEndUserReportErrors = {
|
|
8008
|
+
/**
|
|
8009
|
+
* Missing or invalid credentials
|
|
8010
|
+
*/
|
|
8011
|
+
401: ErrorResponse;
|
|
8012
|
+
/**
|
|
8013
|
+
* The key is valid but its scopes do not cover this capability — a key limited to `tts` gets this from `/v1/images` rather than a 401
|
|
8014
|
+
*/
|
|
8015
|
+
403: ErrorResponse;
|
|
8016
|
+
/**
|
|
8017
|
+
* Unknown end user id, or Unknown report id
|
|
8018
|
+
*/
|
|
8019
|
+
404: ErrorResponse;
|
|
8020
|
+
/**
|
|
8021
|
+
* The request failed validation
|
|
8022
|
+
*/
|
|
8023
|
+
422: ErrorResponse;
|
|
8024
|
+
/**
|
|
8025
|
+
* Rate limit exceeded
|
|
8026
|
+
*/
|
|
8027
|
+
429: ErrorResponse;
|
|
8028
|
+
};
|
|
8029
|
+
export type GetEndUserReportError = GetEndUserReportErrors[keyof GetEndUserReportErrors];
|
|
8030
|
+
export type GetEndUserReportResponses = {
|
|
8031
|
+
/**
|
|
8032
|
+
* The report
|
|
8033
|
+
*/
|
|
8034
|
+
200: ConversationReport;
|
|
8035
|
+
};
|
|
8036
|
+
export type GetEndUserReportResponse = GetEndUserReportResponses[keyof GetEndUserReportResponses];
|
|
7259
8037
|
export type PostToolResultData = {
|
|
7260
8038
|
body: ToolResultRequest;
|
|
7261
8039
|
path: {
|
|
@@ -5,7 +5,10 @@
|
|
|
5
5
|
*
|
|
6
6
|
* - **A save reaches running sessions within a minute**, not at once: an
|
|
7
7
|
* agent's version travels through the platform's `STANDING` copy.
|
|
8
|
-
* - **`settings`** are the organisation's, for every agent
|
|
8
|
+
* - **`settings`** are the organisation's, for every agent —
|
|
9
|
+
* **`settings.rotateWebhookSecret`** makes the one secret its webhook
|
|
10
|
+
* posts are signed with, shown once; **`testWebhook`** posts an agent's
|
|
11
|
+
* address a made-up report;
|
|
9
12
|
* **`knowledge.set`** replaces the entries one agent may look up, and
|
|
10
13
|
* **`tools.set`** the tools it can call.
|
|
11
14
|
* - **`create` is a 409 at the plan's maximum agents**; `delete` answers
|
|
@@ -13,13 +16,15 @@
|
|
|
13
16
|
* - **`list()` reads one page**: an organisation's agents are few, and the
|
|
14
17
|
* route answers them all with `next_cursor` `null` (`paging.ts`).
|
|
15
18
|
*/
|
|
16
|
-
import type { AgentCreateRequest, AgentInfo, AgentKnowledgeUpdate, AgentPage, AgentSettingsInfo, AgentSettingsUpdate, AgentSummary, AgentToolsUpdate, AgentUpdate, KnowledgeAssigned, KnowledgeInfo, ToolInfo, ToolsAssigned } from "../gen/index.js";
|
|
19
|
+
import type { AgentCreateRequest, AgentInfo, AgentKnowledgeUpdate, AgentPage, AgentSettingsInfo, AgentSettingsUpdate, AgentSummary, AgentToolsUpdate, AgentUpdate, KnowledgeAssigned, KnowledgeInfo, ToolInfo, ToolsAssigned, WebhookSecret, WebhookTestResult } from "../gen/index.js";
|
|
17
20
|
import type { RequestOptions, Transport } from "../transport.js";
|
|
18
21
|
import { Library } from "./resource.js";
|
|
19
22
|
/** `agents.settings`: the organisation's, for every agent. */
|
|
20
23
|
export interface AgentSettings {
|
|
21
24
|
get(options?: RequestOptions): Promise<AgentSettingsInfo>;
|
|
22
25
|
update(body: AgentSettingsUpdate, options?: RequestOptions): Promise<AgentSettingsInfo>;
|
|
26
|
+
/** Makes or replaces the organisation's webhook secret: shown this once. */
|
|
27
|
+
rotateWebhookSecret(options?: RequestOptions): Promise<WebhookSecret>;
|
|
23
28
|
}
|
|
24
29
|
/** `agents.knowledge`: the entries one agent may look up. */
|
|
25
30
|
export interface AgentKnowledge {
|
|
@@ -40,6 +45,8 @@ export declare class Agents extends Library<AgentInfo, AgentUpdate, AgentSummary
|
|
|
40
45
|
readonly knowledge: AgentKnowledge;
|
|
41
46
|
readonly tools: AgentTools;
|
|
42
47
|
constructor(api: Transport, base: string);
|
|
48
|
+
/** Posts the agent's webhook a made-up report, signed; what its server answered. */
|
|
49
|
+
testWebhook(agentId: string, options?: RequestOptions): Promise<WebhookTestResult>;
|
|
43
50
|
/** An agent's links to what the organisation has: its knowledge, its tools. */
|
|
44
51
|
protected links<T extends AgentKnowledge | AgentTools>(rest: string): T;
|
|
45
52
|
}
|
package/dist/resources/agents.js
CHANGED
|
@@ -5,7 +5,10 @@
|
|
|
5
5
|
*
|
|
6
6
|
* - **A save reaches running sessions within a minute**, not at once: an
|
|
7
7
|
* agent's version travels through the platform's `STANDING` copy.
|
|
8
|
-
* - **`settings`** are the organisation's, for every agent
|
|
8
|
+
* - **`settings`** are the organisation's, for every agent —
|
|
9
|
+
* **`settings.rotateWebhookSecret`** makes the one secret its webhook
|
|
10
|
+
* posts are signed with, shown once; **`testWebhook`** posts an agent's
|
|
11
|
+
* address a made-up report;
|
|
9
12
|
* **`knowledge.set`** replaces the entries one agent may look up, and
|
|
10
13
|
* **`tools.set`** the tools it can call.
|
|
11
14
|
* - **`create` is a 409 at the plan's maximum agents**; `delete` answers
|
|
@@ -20,10 +23,15 @@ export class Agents extends Library {
|
|
|
20
23
|
this.settings = {
|
|
21
24
|
get: (options) => this.send("GET", "/settings", options),
|
|
22
25
|
update: (body, options) => this.send("PUT", "/settings", options, body),
|
|
26
|
+
rotateWebhookSecret: (options) => this.send("POST", "/settings/webhook-secret", options),
|
|
23
27
|
};
|
|
24
28
|
this.knowledge = this.links("/knowledge");
|
|
25
29
|
this.tools = this.links("/tools");
|
|
26
30
|
}
|
|
31
|
+
/** Posts the agent's webhook a made-up report, signed; what its server answered. */
|
|
32
|
+
testWebhook(agentId, options) {
|
|
33
|
+
return this.send("POST", this.at(agentId, "/webhook-test"), options);
|
|
34
|
+
}
|
|
27
35
|
/** An agent's links to what the organisation has: its knowledge, its tools. */
|
|
28
36
|
links(rest) {
|
|
29
37
|
return {
|
|
@@ -34,12 +34,13 @@
|
|
|
34
34
|
* read fails with a 401; its one micro-credit is set aside like any key's,
|
|
35
35
|
* so an organisation with no balance cannot export (402).
|
|
36
36
|
*/
|
|
37
|
-
import type { EndUserCreateRequest, EndUserDeleted, EndUserInfo, EndUserPage, EndUserUpdateRequest, FactCreateRequest, FactInfo, FactUpdateRequest, ListEndUserMemoriesData, ListEndUsersData, MemoriesDeleted, MemoryInfo, MemoryPage, SessionDetail, ToolResultRequest, ToolResultTaken } from "../gen/index.js";
|
|
37
|
+
import type { ConversationReport, ConversationReportPage, EndUserCreateRequest, EndUserDeleted, EndUserInfo, EndUserPage, EndUserPersonalization, EndUserPersonalizationUpdate, EndUserUpdateRequest, FactCreateRequest, FactInfo, FactUpdateRequest, ListEndUserMemoriesData, ListEndUserReportsData, ListEndUsersData, MemoriesDeleted, MemoryInfo, MemoryPage, NoteCreateRequest, NoteTaken, SessionDetail, ToolResultRequest, ToolResultTaken } from "../gen/index.js";
|
|
38
38
|
import { type RequestOptions, type Transport } from "../transport.js";
|
|
39
39
|
import type { EphemeralKeys } from "./ephemeral-keys.js";
|
|
40
40
|
import { Editable } from "./resource.js";
|
|
41
41
|
export type EndUserListParams = NonNullable<ListEndUsersData["query"]>;
|
|
42
42
|
export type EndUserMemoryListParams = NonNullable<ListEndUserMemoriesData["query"]>;
|
|
43
|
+
export type EndUserReportListParams = NonNullable<ListEndUserReportsData["query"]>;
|
|
43
44
|
/** An end user `create` answered, and whether this call made them. */
|
|
44
45
|
export type EndUserCreated = EndUserInfo & {
|
|
45
46
|
/**
|
|
@@ -105,10 +106,41 @@ export interface EndUserMemories {
|
|
|
105
106
|
/** Forgets every memory of theirs: how many went. Their facts and conversations stay. */
|
|
106
107
|
deleteAll(id: string, options?: RequestOptions): Promise<MemoriesDeleted>;
|
|
107
108
|
}
|
|
109
|
+
/**
|
|
110
|
+
* `endUsers.personalization`: what your server sets for one person rather
|
|
111
|
+
* than the agent — the instructions every agent follows with them, and the
|
|
112
|
+
* values a scripted opening line's blanks (`{{name|there}}`) are filled from —
|
|
113
|
+
* `/v1/end-users/{id}/personalization`. Only an API key reads or sets
|
|
114
|
+
* it: the person's own app cannot.
|
|
115
|
+
*/
|
|
116
|
+
export interface EndUserPersonalizations {
|
|
117
|
+
/** What is set for them; `instructions` `null` for none. */
|
|
118
|
+
get(id: string, options?: RequestOptions): Promise<EndUserPersonalization>;
|
|
119
|
+
/**
|
|
120
|
+
* Sets or clears it: absent fields are untouched, `null` clears one.
|
|
121
|
+
* Every agent reads it on its next reply, in conversations already open.
|
|
122
|
+
*/
|
|
123
|
+
update(id: string, body: EndUserPersonalizationUpdate, options?: RequestOptions): Promise<EndUserPersonalization>;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* `endUsers.reports`: what an agent with `report_enabled` wrote after each
|
|
127
|
+
* of one person's conversations — a summary, your fields, success by your
|
|
128
|
+
* rule — `/v1/end-users/{id}/reports`. Only an API key reads them.
|
|
129
|
+
*/
|
|
130
|
+
export interface EndUserReports {
|
|
131
|
+
/** Every report, newest first, page after page; `session_id` keeps one conversation's. */
|
|
132
|
+
list(id: string, params?: Omit<EndUserReportListParams, "cursor">, options?: RequestOptions): AsyncGenerator<ConversationReport, void, undefined>;
|
|
133
|
+
/** One page, with the `next_cursor` of the next. */
|
|
134
|
+
page(id: string, params?: EndUserReportListParams, options?: RequestOptions): Promise<ConversationReportPage>;
|
|
135
|
+
/** One report. A `NotFoundError` when there is none, or no such person. */
|
|
136
|
+
get(id: string, reportId: string, options?: RequestOptions): Promise<ConversationReport>;
|
|
137
|
+
}
|
|
108
138
|
export declare class EndUsers extends Editable<EndUserInfo, EndUserUpdateRequest, EndUserInfo, EndUserDeleted | null> {
|
|
109
139
|
private readonly keys;
|
|
110
140
|
readonly facts: EndUserFacts;
|
|
111
141
|
readonly memories: EndUserMemories;
|
|
142
|
+
readonly personalization: EndUserPersonalizations;
|
|
143
|
+
readonly reports: EndUserReports;
|
|
112
144
|
constructor(api: Transport, base: string, keys: EphemeralKeys);
|
|
113
145
|
/**
|
|
114
146
|
* Makes a person, or finds the one your `external_id` already names.
|
|
@@ -129,6 +161,15 @@ export declare class EndUsers extends Editable<EndUserInfo, EndUserUpdateRequest
|
|
|
129
161
|
* its deadline a 410.
|
|
130
162
|
*/
|
|
131
163
|
toolResult(id: string, callId: string, body: ToolResultRequest, options?: RequestOptions): Promise<ToolResultTaken>;
|
|
164
|
+
/**
|
|
165
|
+
* A note to the agent that is not a message — "Her order shipped." — for
|
|
166
|
+
* one of the person's conversations (`session_id`, else the one open now
|
|
167
|
+
* or used last): told with the agent's next reply, or at once with
|
|
168
|
+
* `reply: true` when they are connected (`replying` says which). A
|
|
169
|
+
* `NotFoundError` when they have no conversation; a `ConflictError`
|
|
170
|
+
* (409) when the platform's `agents.notes.pending_max` already wait.
|
|
171
|
+
*/
|
|
172
|
+
note(id: string, body: NoteCreateRequest, options?: RequestOptions): Promise<NoteTaken>;
|
|
132
173
|
/** Deletes them and all they had: the counts, or `null` when there is no such person. */
|
|
133
174
|
delete(id: string, options?: RequestOptions): Promise<EndUserDeleted | null>;
|
|
134
175
|
/** Everything about one person, read with a key of their own (see the header). */
|
|
@@ -90,6 +90,16 @@ export class EndUsers extends Editable {
|
|
|
90
90
|
delete: (id, memoryId, options) => drop(memories(id, `/${segment(memoryId)}`), options),
|
|
91
91
|
deleteAll: (id, options) => this.send("DELETE", memories(id), options),
|
|
92
92
|
};
|
|
93
|
+
this.personalization = {
|
|
94
|
+
get: (id, options) => this.send("GET", this.at(id, "/personalization"), options),
|
|
95
|
+
update: (id, body, options) => this.send("PATCH", this.at(id, "/personalization"), options, body),
|
|
96
|
+
};
|
|
97
|
+
const reports = (id, rest = "") => this.at(id, `/reports${rest}`);
|
|
98
|
+
this.reports = {
|
|
99
|
+
list: (id, params = {}, options) => this.each(reports(id), params, options, MEMORY_PAGE),
|
|
100
|
+
page: (id, params = {}, options) => this.send("GET", reports(id), options, params),
|
|
101
|
+
get: (id, reportId, options) => this.send("GET", reports(id, `/${segment(reportId)}`), options),
|
|
102
|
+
};
|
|
93
103
|
}
|
|
94
104
|
/**
|
|
95
105
|
* Makes a person, or finds the one your `external_id` already names.
|
|
@@ -125,6 +135,17 @@ export class EndUsers extends Editable {
|
|
|
125
135
|
toolResult(id, callId, body, options) {
|
|
126
136
|
return this.send("POST", this.at(id, `/tool-calls/${segment(callId)}/result`), options, body);
|
|
127
137
|
}
|
|
138
|
+
/**
|
|
139
|
+
* A note to the agent that is not a message — "Her order shipped." — for
|
|
140
|
+
* one of the person's conversations (`session_id`, else the one open now
|
|
141
|
+
* or used last): told with the agent's next reply, or at once with
|
|
142
|
+
* `reply: true` when they are connected (`replying` says which). A
|
|
143
|
+
* `NotFoundError` when they have no conversation; a `ConflictError`
|
|
144
|
+
* (409) when the platform's `agents.notes.pending_max` already wait.
|
|
145
|
+
*/
|
|
146
|
+
note(id, body, options) {
|
|
147
|
+
return this.send("POST", this.at(id, "/notes"), options, body);
|
|
148
|
+
}
|
|
128
149
|
/** Deletes them and all they had: the counts, or `null` when there is no such person. */
|
|
129
150
|
delete(id, options) {
|
|
130
151
|
return this.drop(id, options);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lumavox/server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.34.0",
|
|
4
4
|
"description": "The Lumavox API from your server: end users, ephemeral keys and the rest, typed from the published OpenAPI document. Zero dependencies.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|