@proteos/sdk 0.39.0 → 0.41.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -182,8 +182,10 @@ type ListSkillsOptions = AgentResourceListOptions;
182
182
  * - `client` is a host-provided builtin and carries no binding.
183
183
  * - `platform` binds to one tool of the platform MCP server (mcp-service),
184
184
  * executed server-side as the acting user.
185
+ * - `query` stores a SQL query with declared params, executed server-side
186
+ * against data-service as the acting user.
185
187
  */
186
- type ToolKind = 'action' | 'mcp' | 'client' | 'platform';
188
+ type ToolKind = 'action' | 'mcp' | 'client' | 'platform' | 'query';
187
189
  /** Binds to a function-service Action by its key (kind=action). */
188
190
  interface ActionBinding {
189
191
  action_key: string;
@@ -201,8 +203,18 @@ interface PlatformBinding {
201
203
  toolset: string;
202
204
  tool_name: string;
203
205
  }
206
+ /**
207
+ * Stores a SELECT-only SQL query (data-service dialect) whose `{{param}}`
208
+ * placeholders are filled from the declared `params` at execution time
209
+ * (kind=query). Params are scalar attribute definitions (string, number,
210
+ * integer, boolean, datetime, enum); they generate the tool's input schema.
211
+ */
212
+ interface QueryBinding {
213
+ sql: string;
214
+ params?: Attribute[];
215
+ }
204
216
  /** Kind-discriminated binding payload. `kind=client` carries no binding. */
205
- type ToolBinding = ActionBinding | McpBinding | PlatformBinding;
217
+ type ToolBinding = ActionBinding | McpBinding | PlatformBinding | QueryBinding;
206
218
  /**
207
219
  * A thin registry entry over one of three binding sources. `key` is the wire
208
220
  * name the model calls (`tool_use.name`) and what `Agent.tools` lists.
@@ -639,8 +651,15 @@ interface StopReason {
639
651
  type: string;
640
652
  }
641
653
  /**
642
- * Emitted when a turn ends. `event_ids` carries the tool_use event ids awaiting a
643
- * client response when `stop_reason.type` is `user_action_required`.
654
+ * Ends a turn published once per turn by the server, not an echo of the upstream
655
+ * provider's session status (which flips idle/running once per server-side tool
656
+ * round, mid-turn).
657
+ *
658
+ * `event_ids` is set only with `stop_reason.type: 'user_action_required'`, and lists
659
+ * the tool_use events still OUTSTANDING — the ones a client must answer. Tools the
660
+ * server executes itself are resolved before this event exists, so seeing this event
661
+ * at all means the turn cannot continue without you: answer each id with a
662
+ * `user.tool_result`.
644
663
  */
645
664
  interface SessionIdlePayload {
646
665
  stop_reason: StopReason;
@@ -2749,6 +2768,118 @@ interface ListConversationTypesQuery extends PaginationQuery {
2749
2768
  search?: string;
2750
2769
  module_slug?: string;
2751
2770
  }
2771
+ /** Who assigned a contact's group membership. */
2772
+ type ContactGroupSource = 'manual' | 'model';
2773
+ /**
2774
+ * A generic org-shared audience taxonomy entry ("external-client",
2775
+ * "internal-colleague", …) — NOT tone-specific. Membership lives on the
2776
+ * contact (`Contact.group_key`, one group per contact) and is assignable by
2777
+ * any flow; tone-of-voice synthesis both reads and auto-assigns groups.
2778
+ * Module-deployable (contact-groups/<key>.json).
2779
+ */
2780
+ interface ContactGroup {
2781
+ org_id: string;
2782
+ /** Immutable identity within the org — what models answer with. */
2783
+ key: string;
2784
+ name: string;
2785
+ /** Who belongs in the group — injected verbatim into the synthesis prompt. */
2786
+ description?: string;
2787
+ /** True when tone synthesis proposed the group. Server-owned. */
2788
+ is_auto_created: boolean;
2789
+ /** Module that deployed the group; absent when not module-owned. */
2790
+ module_slug?: string;
2791
+ created_at: string;
2792
+ created_by: UserRef;
2793
+ updated_at: string;
2794
+ updated_by: UserRef;
2795
+ }
2796
+ interface CreateContactGroupRequest {
2797
+ /** Lowercase kebab/snake/camel handle — no spaces. */
2798
+ key: string;
2799
+ name: string;
2800
+ description?: string;
2801
+ module_slug?: string;
2802
+ }
2803
+ interface UpdateContactGroupRequest {
2804
+ name?: string;
2805
+ description?: string;
2806
+ }
2807
+ interface ListContactGroupsQuery extends PaginationQuery {
2808
+ /** Case-insensitive substring match on key or name. */
2809
+ search?: string;
2810
+ module_slug?: string;
2811
+ }
2812
+ /** The whole-user synthesis lifecycle on a tone profile setup. */
2813
+ type ToneProfileSetupStatus = 'empty' | 'processing' | 'ready';
2814
+ /** A tone profile row's tier — derived, most specific wins at read time. */
2815
+ type ToneProfileScope = 'user' | 'channel' | 'group' | 'contact';
2816
+ /**
2817
+ * The per-user opt-in for tone-of-voice synthesis: only set-up users are
2818
+ * swept. Also carries the whole-user synthesis claim (status/started_at).
2819
+ */
2820
+ interface ToneProfileSetup {
2821
+ id: string;
2822
+ org_id: string;
2823
+ /** The profiled platform user. */
2824
+ owned_by: UserRef;
2825
+ status: ToneProfileSetupStatus;
2826
+ started_at?: string;
2827
+ last_synthesized_at?: string;
2828
+ created_at: string;
2829
+ created_by: UserRef;
2830
+ updated_at: string;
2831
+ updated_by: UserRef;
2832
+ }
2833
+ /**
2834
+ * One generated tone-of-voice instruction row. Rows form a specificity
2835
+ * hierarchy — user aggregate (the constant voice), per-channel base, per
2836
+ * contact-group, per individual contact — and every row is SELF-CONTAINED: a
2837
+ * drafting consumer injects exactly one row's `instructions` verbatim (use
2838
+ * the resolve endpoint), never a concatenation of tiers.
2839
+ */
2840
+ interface ToneProfile {
2841
+ id: string;
2842
+ org_id: string;
2843
+ /** The profiled platform user. */
2844
+ owned_by: UserRef;
2845
+ /** Absent = the cross-channel user aggregate (the voice proper). */
2846
+ channel?: Channel;
2847
+ /** Scopes the row to one contact group; absent = the (user, channel) base. */
2848
+ contact_group_key?: string;
2849
+ /** Scopes the row to one individual contact within the group. */
2850
+ contact_id?: string;
2851
+ scope: ToneProfileScope;
2852
+ /** COMPLETE markdown instruction set, served verbatim to a drafting model. */
2853
+ instructions: string;
2854
+ /** Short delta vs the tier above — what a human scans; empty on root tiers. */
2855
+ differences?: string;
2856
+ sample_count: number;
2857
+ last_message_at?: string;
2858
+ last_synthesized_at?: string;
2859
+ created_at: string;
2860
+ created_by: UserRef;
2861
+ updated_at: string;
2862
+ updated_by: UserRef;
2863
+ }
2864
+ interface CreateToneProfileSetupRequest {
2865
+ /** Bare platform user id; the service resolves the full ref. */
2866
+ owned_by_id: string;
2867
+ }
2868
+ type ListToneProfileSetupsQuery = PaginationQuery;
2869
+ interface ListToneProfilesQuery extends PaginationQuery {
2870
+ owned_by_id?: string;
2871
+ channel?: Channel;
2872
+ scope?: ToneProfileScope;
2873
+ }
2874
+ /**
2875
+ * A drafting context to resolve the single most-specific profile for:
2876
+ * contact → group → channel base → user aggregate.
2877
+ */
2878
+ interface ResolveToneProfileQuery {
2879
+ owned_by_id: string;
2880
+ channel?: Channel;
2881
+ contact_id?: string;
2882
+ }
2752
2883
  interface PaginationQuery {
2753
2884
  page?: number;
2754
2885
  page_size?: number;
@@ -2761,6 +2892,16 @@ interface ListConnectionsQuery extends PaginationQuery {
2761
2892
  scope?: string;
2762
2893
  status?: string;
2763
2894
  }
2895
+ /**
2896
+ * The delete's escape hatch. A connection delete makes the connector release
2897
+ * its provider-side registration first and refuses with a 502
2898
+ * `connector_uninstall_failed` when that fails — the row is the only handle on
2899
+ * that state. `is_forced` drops the row anyway, leaving the provider-side
2900
+ * leftovers as a manual cleanup.
2901
+ */
2902
+ interface DeleteConnectionQuery {
2903
+ is_forced?: boolean;
2904
+ }
2764
2905
  interface ListConversationsQuery extends PaginationQuery {
2765
2906
  channel?: string;
2766
2907
  status?: string;
@@ -2810,14 +2951,26 @@ interface ListAgentListenersQuery extends PaginationQuery {
2810
2951
  is_enabled?: boolean;
2811
2952
  }
2812
2953
  /**
2813
- * Conversation filters: ingest-time rules that drop matching inbound messages
2814
- * BEFORE persistence (no message, no contact — only a content-free audit
2815
- * event). Scope-first evaluation: connection-scoped rules are final when one
2816
- * matches; global rules apply otherwise. Specificity within a scope:
2817
- * address > domain > role_based > automated > internal_conversations > all,
2818
- * allow beats block within a class.
2819
- */
2820
- type ConversationFilterType = 'address' | 'domain' | 'role_based' | 'automated' | 'internal_conversations' | 'all';
2954
+ * Conversation filters: rules that drop matching inbound messages BEFORE
2955
+ * persistence (no message, no contact — only a content-free audit event) and,
2956
+ * on meeting calendar connections, gate whether the meeting bot is scheduled
2957
+ * at all (pre-join enforcement of the same rules — earliest possible point).
2958
+ * Scope-first evaluation: connection-scoped rules are final when one matches;
2959
+ * global rules apply otherwise. Specificity within a scope:
2960
+ * address > domain > title_keyword > role_based > automated >
2961
+ * self_originated > internal_participant > internal_conversations > all,
2962
+ * allow beats block within a class; an allow match is a final keep, which is
2963
+ * the auto-join composition mechanism (e.g. "organized by me" = a
2964
+ * connection-scoped all-block plus a self_originated allow).
2965
+ *
2966
+ * Channel matrix: address/self_originated/all act on every channel;
2967
+ * domain/title_keyword/internal_participant/internal_conversations act on
2968
+ * email + meeting connections; role_based/automated are email-only. A
2969
+ * connection-scoped rule of a type inert on that connection's channel is
2970
+ * rejected (invalid_filter_config); global rules are unrestricted and stay
2971
+ * inert where their facts are missing.
2972
+ */
2973
+ type ConversationFilterType = 'address' | 'domain' | 'title_keyword' | 'role_based' | 'automated' | 'self_originated' | 'internal_participant' | 'internal_conversations' | 'all';
2821
2974
  type ConversationFilterAction = 'block' | 'allow';
2822
2975
  /** Which side of the message address/domain rules test (default: sender). */
2823
2976
  type FilterMatchOn = 'sender' | 'any_participant';
@@ -2842,13 +2995,23 @@ interface RoleBasedFilterConfig {
2842
2995
  interface AutomatedFilterConfig {
2843
2996
  signals?: AutomatedSignal[];
2844
2997
  }
2998
+ /** Title/subject contains any keyword (case-insensitive substring; stored lowercased). */
2999
+ interface TitleKeywordFilterConfig {
3000
+ keywords: string[];
3001
+ }
3002
+ /** Conversation originates from the connection owner (meeting organizer / self sender). Empty config. */
3003
+ type SelfOriginatedFilterConfig = Record<string, never>;
3004
+ /** ≥1 participant OTHER than the connection self is on one of these domains (any-internal). */
3005
+ interface InternalParticipantFilterConfig {
3006
+ domains: string[];
3007
+ }
2845
3008
  /** Drops only when sender AND every recipient are on these domains. Always block. */
2846
3009
  interface InternalConversationsFilterConfig {
2847
3010
  domains: string[];
2848
3011
  }
2849
3012
  /** Matches every message (empty config) — the scope-control primitive. */
2850
3013
  type AllFilterConfig = Record<string, never>;
2851
- type ConversationFilterConfig = AddressFilterConfig | DomainFilterConfig | RoleBasedFilterConfig | AutomatedFilterConfig | InternalConversationsFilterConfig | AllFilterConfig;
3014
+ type ConversationFilterConfig = AddressFilterConfig | DomainFilterConfig | TitleKeywordFilterConfig | RoleBasedFilterConfig | AutomatedFilterConfig | SelfOriginatedFilterConfig | InternalParticipantFilterConfig | InternalConversationsFilterConfig | AllFilterConfig;
2852
3015
  interface ConversationFilter {
2853
3016
  id: string;
2854
3017
  org_id: string;
@@ -2944,6 +3107,13 @@ interface Contact {
2944
3107
  /** Merge tombstone redirect (set when status is 'merged'). */
2945
3108
  merged_into_contact_id?: string;
2946
3109
  source: ContactSource;
3110
+ /** ContactGroup membership (one group per contact); absent = unassigned. */
3111
+ group_key?: string;
3112
+ /**
3113
+ * Who assigned the group: 'manual' assignments are authoritative (tone
3114
+ * synthesis never overrides them), 'model' ones may be reassigned by a run.
3115
+ */
3116
+ group_source?: ContactGroupSource;
2947
3117
  has_manual_edits: boolean;
2948
3118
  /** The contact's reachable endpoints, embedded on reads. */
2949
3119
  addresses?: ContactAddress[];
@@ -3036,11 +3206,18 @@ interface ListContactsQuery extends PaginationQuery {
3036
3206
  /** Free-text needle matched against contact name + address values. */
3037
3207
  q?: string;
3038
3208
  status?: ContactStatus;
3209
+ /** Members of one contact group (drives group-member lists). */
3210
+ group_key?: string;
3039
3211
  }
3040
3212
  interface UpdateContactRequest {
3041
3213
  name?: string;
3042
3214
  status?: 'active' | 'archived';
3043
3215
  has_legal_hold?: boolean;
3216
+ /**
3217
+ * Assigns the contact to a contact group ('' clears). A PATCH assignment is
3218
+ * stamped group_source='manual' — tone synthesis never overrides it.
3219
+ */
3220
+ group_key?: string;
3044
3221
  }
3045
3222
  interface AttachContactAddressRequest {
3046
3223
  kind: ContactAddressKind;
@@ -3314,6 +3491,10 @@ declare class ConversationClient {
3314
3491
  readonly glossaryTerms: GlossaryTermService;
3315
3492
  /** Conversation taxonomy: the types the pre-summary classifier assigns. */
3316
3493
  readonly conversationTypes: ConversationTypeService;
3494
+ /** Generic audience taxonomy; membership lives on the contact. */
3495
+ readonly contactGroups: ContactGroupService;
3496
+ /** Tone-of-voice synthesis: per-user setups + the generated profiles. */
3497
+ readonly toneProfiles: ToneProfileService;
3317
3498
  readonly transcriptions: TranscriptionService;
3318
3499
  /** Review-pass findings: likely misheard terms awaiting accept/reject. */
3319
3500
  readonly mistranscribedTerms: MistranscribedTermService;
@@ -3354,7 +3535,14 @@ interface ConnectionService {
3354
3535
  get(id: string): Promise<Connection>;
3355
3536
  create(request: CreateConnectionRequest): Promise<Connection>;
3356
3537
  update(id: string, request: UpdateConnectionRequest): Promise<Connection>;
3357
- delete(id: string): Promise<void>;
3538
+ /**
3539
+ * Delete a connection. The connector first releases its provider-side
3540
+ * registration (a Recall calendar and the OAuth grant behind it); when that
3541
+ * fails the delete is refused with a `connector_uninstall_failed` 502 rather
3542
+ * than orphaning it. Pass `{ is_forced: true }` to drop the row anyway and
3543
+ * clean up at the provider by hand.
3544
+ */
3545
+ delete(id: string, query?: DeleteConnectionQuery): Promise<void>;
3358
3546
  /** Begin the connector's install flow; open the returned URL in a popup. */
3359
3547
  install(id: string): Promise<InstallConnectionResponse>;
3360
3548
  /**
@@ -3396,6 +3584,11 @@ interface ConversationService {
3396
3584
  /** Patch the user-editable surface (subject, summary, status, metadata). */
3397
3585
  update(id: string, request: UpdateConversationRequest): Promise<Conversation>;
3398
3586
  end(id: string): Promise<Conversation>;
3587
+ /**
3588
+ * Hard-delete the conversation, its thread children, and every dependent
3589
+ * row (messages, attachments, read markers, transcriptions). Irreversible.
3590
+ */
3591
+ delete(id: string): Promise<void>;
3399
3592
  /** Upsert the requesting user's read marker to now (open a conversation). */
3400
3593
  markRead(id: string): Promise<void>;
3401
3594
  /** Remove the marker — the conversation reads as unread again. */
@@ -3485,6 +3678,43 @@ interface ConversationTypeService {
3485
3678
  upsert(key: string, request: CreateConversationTypeRequest): Promise<ConversationType>;
3486
3679
  delete(key: string): Promise<void>;
3487
3680
  }
3681
+ /**
3682
+ * Contact groups: the generic org-shared audience taxonomy. Membership lives
3683
+ * on the contact (`Contact.group_key`, one group per contact — assign via
3684
+ * `contacts.update`); tone-of-voice synthesis reads the groups and
3685
+ * auto-assigns ungrouped correspondents. Keyed by `key` (not id); `upsert` is
3686
+ * the idempotent module-deploy door. Deleting a group clears its members'
3687
+ * membership and purges its tone profile rows.
3688
+ */
3689
+ interface ContactGroupService {
3690
+ list(query?: ListContactGroupsQuery): Promise<ListResponse<ContactGroup>>;
3691
+ get(key: string): Promise<ContactGroup>;
3692
+ create(request: CreateContactGroupRequest): Promise<ContactGroup>;
3693
+ update(key: string, request: UpdateContactGroupRequest): Promise<ContactGroup>;
3694
+ /** Idempotent create-or-update by key (PUT) — what `pro module deploy` calls. */
3695
+ upsert(key: string, request: CreateContactGroupRequest): Promise<ContactGroup>;
3696
+ delete(key: string): Promise<void>;
3697
+ }
3698
+ /**
3699
+ * Tone-of-voice synthesis. A setup opts one platform user in (only set-up
3700
+ * users are swept); `synthesize` triggers a whole-user run immediately (202;
3701
+ * 409 `synthesis_in_progress` while one is live). Generated profiles form a
3702
+ * specificity hierarchy — fetch a user's rows with `listProfiles`, or let the
3703
+ * server pick the single most-specific row for a drafting context with
3704
+ * `resolve` (each row is self-contained; never concatenate tiers).
3705
+ */
3706
+ interface ToneProfileService {
3707
+ listSetups(query?: ListToneProfileSetupsQuery): Promise<ListResponse<ToneProfileSetup>>;
3708
+ createSetup(request: CreateToneProfileSetupRequest): Promise<ToneProfileSetup>;
3709
+ /** Removes the setup AND the user's generated profiles. */
3710
+ deleteSetup(id: string): Promise<void>;
3711
+ /** Kicks a whole-user synthesis run off-request (bypasses cadence checks). */
3712
+ synthesize(setupId: string): Promise<void>;
3713
+ listProfiles(query?: ListToneProfilesQuery): Promise<ListResponse<ToneProfile>>;
3714
+ getProfile(id: string): Promise<ToneProfile>;
3715
+ /** The single most-specific profile for a drafting context; 404 when none. */
3716
+ resolve(query: ResolveToneProfileQuery): Promise<ToneProfile>;
3717
+ }
3488
3718
  /** Batch transcription of stored audio files + materialization. */
3489
3719
  interface TranscriptionService {
3490
3720
  /**
@@ -6241,4 +6471,4 @@ declare class WorkflowClient {
6241
6471
  constructor(client: ProteosClient);
6242
6472
  }
6243
6473
 
6244
- export { type AcceptMistranscribedTermRequest, AccountClient, type Action, type ActionBinding, ActionSchema, type ActionScope, ActionScopeSchema, type ActionService, type AddressFilterConfig, type Agent, type AgentActionParams, type AgentArtifactsPayload, AgentClient, type AgentListener, type AgentListenerAcknowledgementConfig, type AgentListenerAcknowledgementType, type AgentListenerActingUserMode, type AgentListenerService, type AgentListenerTriggerType, type AgentMessagePayload, type AgentResourceListOptions, type AgentService, type AllFilterConfig, type ApiErrorResponse, type AppendEventRequest, type AssignPermissionRequest, type AssignRoleRequest, type AttachContactAddressRequest, type Attachment, Attribute, AuditFields, type AuthListOptions, type AutomatedFilterConfig, type AutomatedSignal, type BatchTransactionError, BatchTransactionErrorSchema, type BatchTransactionStatus, type BatchUpsertRecordsResponse, BatchUpsertRecordsResponseSchema, type BatchUpsertTransaction, type BatchUpsertTransactionResult, BatchUpsertTransactionResultSchema, BatchUpsertTransactionSchema, type BinaryRef, type BlockContactRequest, type Channel, type ClientEventType, type ClientToolSchema, type Connection, type ConnectionCredentials, type ConnectionEndpoint, type ConnectionScope, type ConnectionService, type ConnectionStatus, type ConnectionSyncRange, type ConnectionSyncStatus, type Connector, ConnectorClient, type ConnectorConnection, type ConnectionScope$1 as ConnectorConnectionScope, type ConnectionStatus$1 as ConnectorConnectionStatus, type ConnectionTokenResponse as ConnectorConnectionTokenResponse, type CredentialKind as ConnectorCredentialKind, type ConnectorKey, type ConnectorMethod, type ConnectorProvider, type ConsentStatus, type ConsumerGroup, type Contact, type ContactAddress, type ContactAddressKind, type ContactAddressSource, type ContactErasureRequest, type ContactMergeProposal, type ContactRef, type ContactService, type ContactSource, type ContactStatus, type ContentBlock$1 as ContentBlock, type ContentMatch, type ContentResponse, type ContextCompactedPayload, type Conversation, ConversationClient, type ConversationFilter, type ConversationFilterAction, type ConversationFilterConfig, type ConversationFilterEvent, type ConversationFilterService, type ConversationFilterType, type ConversationParticipant, type ConversationService, type ConversationStatus, type ConversationSummaryStatus, type ConversationType, type ConversationTypeConfig, type ConversationTypeService, type CreateAgentListenerRequest, type CreateAgentRequest, type CreateConnectionRequest, type CreateConnectorConnectionRequest, type CreateConversationFilterRequest, type CreateConversationTypeRequest, type CreateFileMetadata, type CreateGlossaryTermRequest, type CreateLabelRequest, type CreateLinkRequest, type CreateMcpServerRequest, type CreateNodeRequest, type CreateOrganizationRequest, type CreatePromptRequest, type CreateRecordLinkRequest, type CreateRoleRequest, type CreateSessionRequest, type CreateToolRequest, type CreateToolsetRequest, type CreateUserRequest, type CreateWorkflowRequest, type CredentialSpec, type CronTriggerParams, DEFAULT_PORT, DataClient, type DependentAgent, type DependentSyncResult, type DispatchMeetingBotRequest, type DisplayOptions, type DomainFilterConfig, ERROR_PORT, type EditContentRequest, type EditContentResponse, type EmptyPayload, type ErasureRequestStatus, ErrorCode, type ErrorCodeType, type ErrorPayload, type EventTriggerParams, type EventType, type EventVerb, EventsClient, type ExecutionError, type ExecutionStatus, type ExecutionTriggerContext, type FileBlock, FileRef, type FileService, type FileVersionContent, type FilterMatchOn, FunctionsClient, type GetExecutionDetailResponse, type GetGraphOptions, type GetNodeExecutionItemsOptions, type GetNodeExecutionItemsResponse, type GetNodeTypesResponse, type GlossaryTerm, type GlossaryTermService, type GraphService, type InlineLinkRequest, type InstallConnectionResponse, type InstallConnectorConnectionResponse, type InternalConversationsFilterConfig, type InvokeActionResponse, type InvokeNodeMethodRequest, type InvokeNodeMethodResponse, type Item, type KickoffSource, type KickoffType, KnowledgeClient, type KnowledgeGraph, type KnowledgeGraphLink, type KnowledgeGraphNode, type KnowledgeLabel, KnowledgeLabelSchema, type KnowledgeLink, KnowledgeLinkSchema, type KnowledgeNode, type KnowledgeNodeLabel, KnowledgeNodeLabelSchema, type KnowledgeNodeMetadata, KnowledgeNodeMetadataSchema, KnowledgeNodeSchema, type KnowledgeNodeSearchResult, KnowledgeNodeSearchResultSchema, type KnowledgeRecordLink, KnowledgeRecordLinkSchema, type LabelService, type LinkService, type LinkType, type ListActionsOptions, type ListAgentListenersQuery, type ListAgentsOptions, type ListConnectionsQuery, type ListConnectorConnectionsQuery, type ListConnectorsQuery, type ListContactAddressesQuery, type ListContactMergeProposalsQuery, type ListContactsQuery, type ListConversationFilterEventsQuery, type ListConversationFiltersQuery, type ListConversationTypesQuery, type ListConversationsQuery, type ListEventsOptions, type ListExecutionsOptions, type ListGlossaryTermsQuery, type ListLabelsOptions, type ListLinksOptions, type ListMcpServersOptions, type ListMessagesQuery, type ListMistranscribedTermsQuery, type ListNodesOptions, ListOptions, type ListOrganizationsOptions, type ListPromptsOptions, type ListRecordLinksOptions, type ListRecordsOptions, type ListResponse, ListResult, type ListRolePermissionsOptions, type ListRolesOptions, type ListRoomsQuery, type ListSessionsOptions, type ListSkillsOptions, type ListToolsOptions, type ListToolsetsOptions, type ListUserRoleAssignmentsOptions, type ListUsersOptions, type ListWorkflowsOptions, type ManualTriggerParams, type MatchMode, type McpBinding, type McpConnectionState, type McpConnectionStatus, type McpServer, type McpServerAuth, type McpServerOAuth, type McpServerService, type McpToolSummary, type MeService, type MeetingService, type MergeContactsRequest, type MergeProposalStatus, type Message, type ContentBlock as MessageContentBlock, type MessageDirection, type MessagePreview, type MessageRecipient, type MessageService, type MessageStatus, type MessageTriggerParams, type MistranscribedTerm, type MistranscribedTermService, type MistranscribedTermStatus, type MistranscriptionSuggestionSource, type ModelCallParams, type ModelConfig, type ModelRequestEndPayload, type ModelRequestStartPayload, type ModelUsage, type NeighborDirection, type NeighborEdge, type NeighborNode, type NeighborsOptions, type NodeContentMatches, type NodeDescriptor, type NodeExecution, type NodeGroup, type NodeMethodOption, type NodeNeighborhood, NodeNeighborhoodSchema, type NodeOutline, type NodePosition, type NodeProperty, type NodeRetryPolicy, type NodeRuntime, type NodeService, type NodeStatus, type NodeType, type NodeTypeKey, type NodeTypeService, type NodeTypeStatus, type OnErrorPolicy, type Organization, OrganizationSchema, type OrganizationService, type OutlineHeading, type OutlineRequest, type OutlineResponse, PLATFORM_ENTITIES, PLATFORM_ENTITY_SLUGS, PageIterator, type PairedItem, type ParseStatus, type Permission, type PermissionEventSource, type PermissionEventType, type PlatformBinding, type PlatformEntity, type PlatformEvent, type PortSpec, type Prompt, type PromptService, type PromptVersion, type PropertyOption, type PropertyType, ProteosClient, ProteosError, PublicAccessOperation, type PublishEventRequest, type QueryExecuteMeta, type QueryExecuteResponse, type QueryObject, type QueryRow, type QueryService, type QueryValidateMeta, type QueryValidateResponse, type QueryValue, type Reaction, type ReactionCapability, type ReactionOption, type ReactionSetKind, type ReasoningPayload, type RecipientKind, type RecipientRole, type RecordData, type RecordLinkService, type RecordPermissionEventRequest, type RecordService, type RedriveResult, type ResultBlock, type Role, type RoleBasedFilterConfig, type RoleEntityPermission, RoleEntityPermissionSchema, RoleSchema, type RoleService, type Room, type RunWorkflowRequest, type SearchContentRequest, type SearchContentResponse, type SearchNodesRequest, type SendMessageRequest, type SendRecipient, type Session, type SessionEvent, type SessionEventEnvelope, type SessionEventsOptions, type SessionIdlePayload, type SessionService, type SessionStatus, type SessionStreamOptions, type SessionUpdatedPayload, type Skill, type SkillBundle, type SkillService, type SkillVersion, type StartMcpOAuthResponse, type StopReason, StorageClient, type StorageFile, type StorageFileVersion, type SyncConnectionRequest, type SystemSource, type TailOptions, type TestNodeCandidate, type TestNodeInputSource, type TestNodeRequest, type TestNodeResponse, type TextBlock, type Tool, type ToolBinding, type ToolConfirmationPayload, type ToolKind, type ToolResultPayload, type ToolService, type ToolUsePayload, type Toolset, type ToolsetKind, type ToolsetService, type ToolsetToolSummary, type Topic, type TopicKind, type TopicService, type TranscribeStreamOptions, type TranscriptResult, type TranscriptTurn, type Transcription, type TranscriptionReviewStatus, type TranscriptionStatus, type TriggerKind, type Turn, type UnreadCounts, type UpdateAgentListenerRequest, type UpdateAgentRequest, type UpdateConnectionRequest, type UpdateConnectorConnectionRequest, type UpdateContactRequest, type UpdateConversationFilterRequest, type UpdateConversationTypeRequest, type UpdateDraftRequest, type UpdateFileMetadata, type UpdateGlossaryTermRequest, type UpdateLabelRequest, type UpdateLinkRequest, type UpdateMcpServerRequest, type UpdateNodeRequest, type UpdateOrganizationRequest, type UpdatePromptRequest, type UpdateRoleRequest, type UpdateToolRequest, type UpdateToolsetRequest, type UpdateUserRequest, type UpdateWorkflowRequest, type User, type UserMessagePayload, UserRef$2 as UserRef, type UserRoleAssignment, UserRoleAssignmentSchema, UserSchema, type UserService, type VoiceService, type VoiceTranscriptionStream, type WebhookTriggerParams, type Workflow, WorkflowClient, type WorkflowConnection, type WorkflowExecution, type WorkflowGraph, type WorkflowNode, type WorkflowNodeType, type WorkflowStatus, type WorkflowVersion, type WorkflowVersionAuthor, type WorkflowVersionSummary, type WriteContentResponse, type WriteCredentialsRequest, buildUrl, getDefaultErrorCode, isBadRequest, isConflict, isForbidden, isNotFound, isPlatformEntity, isProteosError, isUnauthorized, parseErrorResponse, toQueryParams, toQueryString };
6474
+ export { type AcceptMistranscribedTermRequest, AccountClient, type Action, type ActionBinding, ActionSchema, type ActionScope, ActionScopeSchema, type ActionService, type AddressFilterConfig, type Agent, type AgentActionParams, type AgentArtifactsPayload, AgentClient, type AgentListener, type AgentListenerAcknowledgementConfig, type AgentListenerAcknowledgementType, type AgentListenerActingUserMode, type AgentListenerService, type AgentListenerTriggerType, type AgentMessagePayload, type AgentResourceListOptions, type AgentService, type AllFilterConfig, type ApiErrorResponse, type AppendEventRequest, type AssignPermissionRequest, type AssignRoleRequest, type AttachContactAddressRequest, type Attachment, Attribute, AuditFields, type AuthListOptions, type AutomatedFilterConfig, type AutomatedSignal, type BatchTransactionError, BatchTransactionErrorSchema, type BatchTransactionStatus, type BatchUpsertRecordsResponse, BatchUpsertRecordsResponseSchema, type BatchUpsertTransaction, type BatchUpsertTransactionResult, BatchUpsertTransactionResultSchema, BatchUpsertTransactionSchema, type BinaryRef, type BlockContactRequest, type Channel, type ClientEventType, type ClientToolSchema, type Connection, type ConnectionCredentials, type ConnectionEndpoint, type ConnectionScope, type ConnectionService, type ConnectionStatus, type ConnectionSyncRange, type ConnectionSyncStatus, type Connector, ConnectorClient, type ConnectorConnection, type ConnectionScope$1 as ConnectorConnectionScope, type ConnectionStatus$1 as ConnectorConnectionStatus, type ConnectionTokenResponse as ConnectorConnectionTokenResponse, type CredentialKind as ConnectorCredentialKind, type ConnectorKey, type ConnectorMethod, type ConnectorProvider, type ConsentStatus, type ConsumerGroup, type Contact, type ContactAddress, type ContactAddressKind, type ContactAddressSource, type ContactErasureRequest, type ContactGroup, type ContactGroupService, type ContactGroupSource, type ContactMergeProposal, type ContactRef, type ContactService, type ContactSource, type ContactStatus, type ContentBlock$1 as ContentBlock, type ContentMatch, type ContentResponse, type ContextCompactedPayload, type Conversation, ConversationClient, type ConversationFilter, type ConversationFilterAction, type ConversationFilterConfig, type ConversationFilterEvent, type ConversationFilterService, type ConversationFilterType, type ConversationParticipant, type ConversationService, type ConversationStatus, type ConversationSummaryStatus, type ConversationType, type ConversationTypeConfig, type ConversationTypeService, type CreateAgentListenerRequest, type CreateAgentRequest, type CreateConnectionRequest, type CreateConnectorConnectionRequest, type CreateContactGroupRequest, type CreateConversationFilterRequest, type CreateConversationTypeRequest, type CreateFileMetadata, type CreateGlossaryTermRequest, type CreateLabelRequest, type CreateLinkRequest, type CreateMcpServerRequest, type CreateNodeRequest, type CreateOrganizationRequest, type CreatePromptRequest, type CreateRecordLinkRequest, type CreateRoleRequest, type CreateSessionRequest, type CreateToneProfileSetupRequest, type CreateToolRequest, type CreateToolsetRequest, type CreateUserRequest, type CreateWorkflowRequest, type CredentialSpec, type CronTriggerParams, DEFAULT_PORT, DataClient, type DependentAgent, type DependentSyncResult, type DispatchMeetingBotRequest, type DisplayOptions, type DomainFilterConfig, ERROR_PORT, type EditContentRequest, type EditContentResponse, type EmptyPayload, type ErasureRequestStatus, ErrorCode, type ErrorCodeType, type ErrorPayload, type EventTriggerParams, type EventType, type EventVerb, EventsClient, type ExecutionError, type ExecutionStatus, type ExecutionTriggerContext, type FileBlock, FileRef, type FileService, type FileVersionContent, type FilterMatchOn, FunctionsClient, type GetExecutionDetailResponse, type GetGraphOptions, type GetNodeExecutionItemsOptions, type GetNodeExecutionItemsResponse, type GetNodeTypesResponse, type GlossaryTerm, type GlossaryTermService, type GraphService, type InlineLinkRequest, type InstallConnectionResponse, type InstallConnectorConnectionResponse, type InternalConversationsFilterConfig, type InvokeActionResponse, type InvokeNodeMethodRequest, type InvokeNodeMethodResponse, type Item, type KickoffSource, type KickoffType, KnowledgeClient, type KnowledgeGraph, type KnowledgeGraphLink, type KnowledgeGraphNode, type KnowledgeLabel, KnowledgeLabelSchema, type KnowledgeLink, KnowledgeLinkSchema, type KnowledgeNode, type KnowledgeNodeLabel, KnowledgeNodeLabelSchema, type KnowledgeNodeMetadata, KnowledgeNodeMetadataSchema, KnowledgeNodeSchema, type KnowledgeNodeSearchResult, KnowledgeNodeSearchResultSchema, type KnowledgeRecordLink, KnowledgeRecordLinkSchema, type LabelService, type LinkService, type LinkType, type ListActionsOptions, type ListAgentListenersQuery, type ListAgentsOptions, type ListConnectionsQuery, type ListConnectorConnectionsQuery, type ListConnectorsQuery, type ListContactAddressesQuery, type ListContactGroupsQuery, type ListContactMergeProposalsQuery, type ListContactsQuery, type ListConversationFilterEventsQuery, type ListConversationFiltersQuery, type ListConversationTypesQuery, type ListConversationsQuery, type ListEventsOptions, type ListExecutionsOptions, type ListGlossaryTermsQuery, type ListLabelsOptions, type ListLinksOptions, type ListMcpServersOptions, type ListMessagesQuery, type ListMistranscribedTermsQuery, type ListNodesOptions, ListOptions, type ListOrganizationsOptions, type ListPromptsOptions, type ListRecordLinksOptions, type ListRecordsOptions, type ListResponse, ListResult, type ListRolePermissionsOptions, type ListRolesOptions, type ListRoomsQuery, type ListSessionsOptions, type ListSkillsOptions, type ListToneProfileSetupsQuery, type ListToneProfilesQuery, type ListToolsOptions, type ListToolsetsOptions, type ListUserRoleAssignmentsOptions, type ListUsersOptions, type ListWorkflowsOptions, type ManualTriggerParams, type MatchMode, type McpBinding, type McpConnectionState, type McpConnectionStatus, type McpServer, type McpServerAuth, type McpServerOAuth, type McpServerService, type McpToolSummary, type MeService, type MeetingService, type MergeContactsRequest, type MergeProposalStatus, type Message, type ContentBlock as MessageContentBlock, type MessageDirection, type MessagePreview, type MessageRecipient, type MessageService, type MessageStatus, type MessageTriggerParams, type MistranscribedTerm, type MistranscribedTermService, type MistranscribedTermStatus, type MistranscriptionSuggestionSource, type ModelCallParams, type ModelConfig, type ModelRequestEndPayload, type ModelRequestStartPayload, type ModelUsage, type NeighborDirection, type NeighborEdge, type NeighborNode, type NeighborsOptions, type NodeContentMatches, type NodeDescriptor, type NodeExecution, type NodeGroup, type NodeMethodOption, type NodeNeighborhood, NodeNeighborhoodSchema, type NodeOutline, type NodePosition, type NodeProperty, type NodeRetryPolicy, type NodeRuntime, type NodeService, type NodeStatus, type NodeType, type NodeTypeKey, type NodeTypeService, type NodeTypeStatus, type OnErrorPolicy, type Organization, OrganizationSchema, type OrganizationService, type OutlineHeading, type OutlineRequest, type OutlineResponse, PLATFORM_ENTITIES, PLATFORM_ENTITY_SLUGS, PageIterator, type PairedItem, type ParseStatus, type Permission, type PermissionEventSource, type PermissionEventType, type PlatformBinding, type PlatformEntity, type PlatformEvent, type PortSpec, type Prompt, type PromptService, type PromptVersion, type PropertyOption, type PropertyType, ProteosClient, ProteosError, PublicAccessOperation, type PublishEventRequest, type QueryBinding, type QueryExecuteMeta, type QueryExecuteResponse, type QueryObject, type QueryRow, type QueryService, type QueryValidateMeta, type QueryValidateResponse, type QueryValue, type Reaction, type ReactionCapability, type ReactionOption, type ReactionSetKind, type ReasoningPayload, type RecipientKind, type RecipientRole, type RecordData, type RecordLinkService, type RecordPermissionEventRequest, type RecordService, type RedriveResult, type ResolveToneProfileQuery, type ResultBlock, type Role, type RoleBasedFilterConfig, type RoleEntityPermission, RoleEntityPermissionSchema, RoleSchema, type RoleService, type Room, type RunWorkflowRequest, type SearchContentRequest, type SearchContentResponse, type SearchNodesRequest, type SendMessageRequest, type SendRecipient, type Session, type SessionEvent, type SessionEventEnvelope, type SessionEventsOptions, type SessionIdlePayload, type SessionService, type SessionStatus, type SessionStreamOptions, type SessionUpdatedPayload, type Skill, type SkillBundle, type SkillService, type SkillVersion, type StartMcpOAuthResponse, type StopReason, StorageClient, type StorageFile, type StorageFileVersion, type SyncConnectionRequest, type SystemSource, type TailOptions, type TestNodeCandidate, type TestNodeInputSource, type TestNodeRequest, type TestNodeResponse, type TextBlock, type ToneProfile, type ToneProfileScope, type ToneProfileService, type ToneProfileSetup, type ToneProfileSetupStatus, type Tool, type ToolBinding, type ToolConfirmationPayload, type ToolKind, type ToolResultPayload, type ToolService, type ToolUsePayload, type Toolset, type ToolsetKind, type ToolsetService, type ToolsetToolSummary, type Topic, type TopicKind, type TopicService, type TranscribeStreamOptions, type TranscriptResult, type TranscriptTurn, type Transcription, type TranscriptionReviewStatus, type TranscriptionStatus, type TriggerKind, type Turn, type UnreadCounts, type UpdateAgentListenerRequest, type UpdateAgentRequest, type UpdateConnectionRequest, type UpdateConnectorConnectionRequest, type UpdateContactGroupRequest, type UpdateContactRequest, type UpdateConversationFilterRequest, type UpdateConversationTypeRequest, type UpdateDraftRequest, type UpdateFileMetadata, type UpdateGlossaryTermRequest, type UpdateLabelRequest, type UpdateLinkRequest, type UpdateMcpServerRequest, type UpdateNodeRequest, type UpdateOrganizationRequest, type UpdatePromptRequest, type UpdateRoleRequest, type UpdateToolRequest, type UpdateToolsetRequest, type UpdateUserRequest, type UpdateWorkflowRequest, type User, type UserMessagePayload, UserRef$2 as UserRef, type UserRoleAssignment, UserRoleAssignmentSchema, UserSchema, type UserService, type VoiceService, type VoiceTranscriptionStream, type WebhookTriggerParams, type Workflow, WorkflowClient, type WorkflowConnection, type WorkflowExecution, type WorkflowGraph, type WorkflowNode, type WorkflowNodeType, type WorkflowStatus, type WorkflowVersion, type WorkflowVersionAuthor, type WorkflowVersionSummary, type WriteContentResponse, type WriteCredentialsRequest, buildUrl, getDefaultErrorCode, isBadRequest, isConflict, isForbidden, isNotFound, isPlatformEntity, isProteosError, isUnauthorized, parseErrorResponse, toQueryParams, toQueryString };
package/dist/index.js CHANGED
@@ -1314,6 +1314,10 @@ var ConversationClient = class {
1314
1314
  glossaryTerms;
1315
1315
  /** Conversation taxonomy: the types the pre-summary classifier assigns. */
1316
1316
  conversationTypes;
1317
+ /** Generic audience taxonomy; membership lives on the contact. */
1318
+ contactGroups;
1319
+ /** Tone-of-voice synthesis: per-user setups + the generated profiles. */
1320
+ toneProfiles;
1317
1321
  transcriptions;
1318
1322
  /** Review-pass findings: likely misheard terms awaiting accept/reject. */
1319
1323
  mistranscribedTerms;
@@ -1330,6 +1334,8 @@ var ConversationClient = class {
1330
1334
  this.conversationFilters = new ConversationFilterServiceImpl(client);
1331
1335
  this.glossaryTerms = new GlossaryTermServiceImpl(client);
1332
1336
  this.conversationTypes = new ConversationTypeServiceImpl(client);
1337
+ this.contactGroups = new ContactGroupServiceImpl(client);
1338
+ this.toneProfiles = new ToneProfileServiceImpl(client);
1333
1339
  this.transcriptions = new TranscriptionServiceImpl(client);
1334
1340
  this.mistranscribedTerms = new MistranscribedTermServiceImpl(client);
1335
1341
  this.meetings = new MeetingServiceImpl(client);
@@ -1381,10 +1387,11 @@ var ConnectionServiceImpl = class {
1381
1387
  request
1382
1388
  );
1383
1389
  }
1384
- async delete(id) {
1385
- await this.client.request(
1390
+ async delete(id, query = {}) {
1391
+ await this.client.requestWithQuery(
1386
1392
  "DELETE",
1387
- `${CONVERSATION_BASE_PATH}/connections/${encodeURIComponent(id)}`
1393
+ `${CONVERSATION_BASE_PATH}/connections/${encodeURIComponent(id)}`,
1394
+ query
1388
1395
  );
1389
1396
  }
1390
1397
  install(id) {
@@ -1536,6 +1543,12 @@ var ConversationServiceImpl = class {
1536
1543
  `${CONVERSATION_BASE_PATH}/conversations/${encodeURIComponent(id)}/end`
1537
1544
  );
1538
1545
  }
1546
+ delete(id) {
1547
+ return this.client.request(
1548
+ "DELETE",
1549
+ `${CONVERSATION_BASE_PATH}/conversations/${encodeURIComponent(id)}`
1550
+ );
1551
+ }
1539
1552
  markRead(id) {
1540
1553
  return this.client.request(
1541
1554
  "POST",
@@ -1764,6 +1777,88 @@ var ConversationTypeServiceImpl = class {
1764
1777
  );
1765
1778
  }
1766
1779
  };
1780
+ var ContactGroupServiceImpl = class {
1781
+ constructor(client) {
1782
+ this.client = client;
1783
+ }
1784
+ client;
1785
+ list(query = {}) {
1786
+ return this.client.requestWithQuery("GET", `${CONVERSATION_BASE_PATH}/contact-groups`, query);
1787
+ }
1788
+ get(key) {
1789
+ return this.client.request(
1790
+ "GET",
1791
+ `${CONVERSATION_BASE_PATH}/contact-groups/${encodeURIComponent(key)}`
1792
+ );
1793
+ }
1794
+ create(request) {
1795
+ return this.client.request("POST", `${CONVERSATION_BASE_PATH}/contact-groups`, request);
1796
+ }
1797
+ update(key, request) {
1798
+ return this.client.request(
1799
+ "PATCH",
1800
+ `${CONVERSATION_BASE_PATH}/contact-groups/${encodeURIComponent(key)}`,
1801
+ request
1802
+ );
1803
+ }
1804
+ upsert(key, request) {
1805
+ return this.client.request(
1806
+ "PUT",
1807
+ `${CONVERSATION_BASE_PATH}/contact-groups/${encodeURIComponent(key)}`,
1808
+ { ...request, key }
1809
+ );
1810
+ }
1811
+ async delete(key) {
1812
+ await this.client.request(
1813
+ "DELETE",
1814
+ `${CONVERSATION_BASE_PATH}/contact-groups/${encodeURIComponent(key)}`
1815
+ );
1816
+ }
1817
+ };
1818
+ var ToneProfileServiceImpl = class {
1819
+ constructor(client) {
1820
+ this.client = client;
1821
+ }
1822
+ client;
1823
+ listSetups(query = {}) {
1824
+ return this.client.requestWithQuery(
1825
+ "GET",
1826
+ `${CONVERSATION_BASE_PATH}/tone-profile-setups`,
1827
+ query
1828
+ );
1829
+ }
1830
+ createSetup(request) {
1831
+ return this.client.request("POST", `${CONVERSATION_BASE_PATH}/tone-profile-setups`, request);
1832
+ }
1833
+ async deleteSetup(id) {
1834
+ await this.client.request(
1835
+ "DELETE",
1836
+ `${CONVERSATION_BASE_PATH}/tone-profile-setups/${encodeURIComponent(id)}`
1837
+ );
1838
+ }
1839
+ async synthesize(setupId) {
1840
+ await this.client.request(
1841
+ "POST",
1842
+ `${CONVERSATION_BASE_PATH}/tone-profile-setups/${encodeURIComponent(setupId)}/synthesize`
1843
+ );
1844
+ }
1845
+ listProfiles(query = {}) {
1846
+ return this.client.requestWithQuery("GET", `${CONVERSATION_BASE_PATH}/tone-profiles`, query);
1847
+ }
1848
+ getProfile(id) {
1849
+ return this.client.request(
1850
+ "GET",
1851
+ `${CONVERSATION_BASE_PATH}/tone-profiles/${encodeURIComponent(id)}`
1852
+ );
1853
+ }
1854
+ resolve(query) {
1855
+ return this.client.requestWithQuery(
1856
+ "GET",
1857
+ `${CONVERSATION_BASE_PATH}/tone-profiles/resolve`,
1858
+ query
1859
+ );
1860
+ }
1861
+ };
1767
1862
  var TranscriptionServiceImpl = class {
1768
1863
  constructor(client) {
1769
1864
  this.client = client;