@getsupervisor/agents-studio-sdk 1.41.0 → 1.41.1
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/CHANGELOG.md +103 -89
- package/README.md +20 -0
- package/dist/index.cjs +124 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +131 -6
- package/dist/index.d.ts +131 -6
- package/dist/index.js +120 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -452,6 +452,7 @@ type components = {
|
|
|
452
452
|
message?: string;
|
|
453
453
|
};
|
|
454
454
|
ToolConnectionRequest: {
|
|
455
|
+
connectionKey?: string;
|
|
455
456
|
agentId: string;
|
|
456
457
|
metadata?: {
|
|
457
458
|
[key: string]: unknown;
|
|
@@ -459,7 +460,7 @@ type components = {
|
|
|
459
460
|
auth?: components['schemas']['ToolConnectionAuth'];
|
|
460
461
|
};
|
|
461
462
|
ToolConnectionResponse: {
|
|
462
|
-
status: 'connected' | 'pending' | 'error';
|
|
463
|
+
status: 'connected' | 'pending' | 'error' | 'revoked';
|
|
463
464
|
toolAgentConnectionId?: string | null;
|
|
464
465
|
toolId: string;
|
|
465
466
|
workspaceId: string;
|
|
@@ -472,7 +473,7 @@ type components = {
|
|
|
472
473
|
};
|
|
473
474
|
};
|
|
474
475
|
ToolConnectionAuth: {
|
|
475
|
-
type: 'none' | 'oauth2' | 'api_key';
|
|
476
|
+
type: 'none' | 'oauth2' | 'api_key' | 'custom';
|
|
476
477
|
data?: {
|
|
477
478
|
[key: string]: unknown;
|
|
478
479
|
};
|
|
@@ -495,6 +496,7 @@ type components = {
|
|
|
495
496
|
toolId: string;
|
|
496
497
|
toolAgentConnectionId?: string | null;
|
|
497
498
|
providerRef?: string | null;
|
|
499
|
+
toolExecutionId: string;
|
|
498
500
|
message?: string | null;
|
|
499
501
|
};
|
|
500
502
|
CatalogItemLinks: {
|
|
@@ -545,6 +547,8 @@ type components = {
|
|
|
545
547
|
code: string;
|
|
546
548
|
message: string;
|
|
547
549
|
details?: {
|
|
550
|
+
subcode?: string;
|
|
551
|
+
workspaceId?: string;
|
|
548
552
|
[key: string]: unknown;
|
|
549
553
|
};
|
|
550
554
|
};
|
|
@@ -692,6 +696,14 @@ type components = {
|
|
|
692
696
|
CreateApiKeyResponse: components['schemas']['ApiKeySummary'] & {
|
|
693
697
|
key: string;
|
|
694
698
|
};
|
|
699
|
+
WorkspaceSummary: {
|
|
700
|
+
id: string;
|
|
701
|
+
name: string;
|
|
702
|
+
};
|
|
703
|
+
WorkspaceListResponse: {
|
|
704
|
+
data: components['schemas']['WorkspaceSummary'][];
|
|
705
|
+
meta: components['schemas']['PaginationMeta'];
|
|
706
|
+
};
|
|
695
707
|
ToolConfigSchemaActionPrompts: {
|
|
696
708
|
assistant?: string;
|
|
697
709
|
user?: string;
|
|
@@ -715,6 +727,36 @@ type components = {
|
|
|
715
727
|
[key: string]: components['schemas']['ToolConfigSchemaAction'];
|
|
716
728
|
};
|
|
717
729
|
};
|
|
730
|
+
ToolConnectionListItem: {
|
|
731
|
+
toolAgentConnectionId: string;
|
|
732
|
+
toolId: string;
|
|
733
|
+
workspaceId: string;
|
|
734
|
+
agentId: string;
|
|
735
|
+
connectionKey: string;
|
|
736
|
+
status: 'connected' | 'pending' | 'error' | 'revoked';
|
|
737
|
+
providerRef?: string | null;
|
|
738
|
+
descriptionUsage?: string | null;
|
|
739
|
+
usageExample?: string | null;
|
|
740
|
+
};
|
|
741
|
+
ToolConnectionListResponse: {
|
|
742
|
+
data: components['schemas']['ToolConnectionListItem'][];
|
|
743
|
+
meta: components['schemas']['PaginationMeta'];
|
|
744
|
+
};
|
|
745
|
+
CreateToolConnectionRequest: {
|
|
746
|
+
toolId: string;
|
|
747
|
+
agentId: string;
|
|
748
|
+
connectionKey?: string;
|
|
749
|
+
metadata?: {
|
|
750
|
+
[key: string]: unknown;
|
|
751
|
+
};
|
|
752
|
+
auth?: components['schemas']['ToolConnectionAuth'];
|
|
753
|
+
};
|
|
754
|
+
ExecuteToolConnectionRequest: {
|
|
755
|
+
action: string;
|
|
756
|
+
args?: {
|
|
757
|
+
[key: string]: unknown;
|
|
758
|
+
};
|
|
759
|
+
};
|
|
718
760
|
CatalogItemLanguageMetadata: {
|
|
719
761
|
code: string;
|
|
720
762
|
locale?: string | null;
|
|
@@ -770,7 +812,9 @@ type components = {
|
|
|
770
812
|
OrParam?: components['schemas']['QueryOrGroups'];
|
|
771
813
|
ScheduleId: string;
|
|
772
814
|
ApiKeyId: string;
|
|
815
|
+
XCacheRefresh?: boolean;
|
|
773
816
|
IdempotencyKey: string;
|
|
817
|
+
XApiKey?: string;
|
|
774
818
|
};
|
|
775
819
|
requestBodies: never;
|
|
776
820
|
headers: never;
|
|
@@ -839,6 +883,8 @@ type WorkspacePhonesResponse = components['schemas']['WorkspacePhonesResponse'];
|
|
|
839
883
|
type WorkspacePhoneChannel = 'voice';
|
|
840
884
|
type WorkspaceEnableRequest = components['schemas']['WorkspaceEnableRequest'];
|
|
841
885
|
type WorkspaceEnableResponse = components['schemas']['WorkspaceEnableResponse'];
|
|
886
|
+
type WorkspaceSummary = components['schemas']['WorkspaceSummary'];
|
|
887
|
+
type WorkspaceListResponse = components['schemas']['WorkspaceListResponse'];
|
|
842
888
|
type VoiceSummary = components['schemas']['VoiceSummary'];
|
|
843
889
|
type VoiceListResponse = components['schemas']['VoiceListResponse'];
|
|
844
890
|
type CatalogItemLinks = components['schemas']['CatalogItemLinks'];
|
|
@@ -1023,8 +1069,12 @@ type ToolResourceUploadRequest = components['schemas']['ToolResourceUploadReques
|
|
|
1023
1069
|
type ToolResourceUploadResponse = components['schemas']['ToolResourceUploadResponse'];
|
|
1024
1070
|
type ToolResourceReloadResponse = components['schemas']['ToolResourceReloadResponse'];
|
|
1025
1071
|
type ToolConnectionAuth = components['schemas']['ToolConnectionAuth'];
|
|
1072
|
+
type CreateToolConnectionRequest = components['schemas']['CreateToolConnectionRequest'];
|
|
1026
1073
|
type ToolConnectionRequest = components['schemas']['ToolConnectionRequest'];
|
|
1027
1074
|
type ToolConnectionResponse = components['schemas']['ToolConnectionResponse'];
|
|
1075
|
+
type ToolConnectionListItem = components['schemas']['ToolConnectionListItem'];
|
|
1076
|
+
type ToolConnectionListResponse = components['schemas']['ToolConnectionListResponse'];
|
|
1077
|
+
type ExecuteToolConnectionRequest = components['schemas']['ExecuteToolConnectionRequest'];
|
|
1028
1078
|
type ErrorResponse = components['schemas']['ErrorResponse'];
|
|
1029
1079
|
type CampaignStatus = components['schemas']['CampaignStatus'];
|
|
1030
1080
|
type Campaign = components['schemas']['Campaign'];
|
|
@@ -1042,13 +1092,17 @@ type EventSubscriptionListResponse = components['schemas']['EventSubscriptionLis
|
|
|
1042
1092
|
type CreateEventSubscriptionRequest = components['schemas']['CreateEventSubscriptionRequest'];
|
|
1043
1093
|
type UpdateEventSubscriptionRequest = components['schemas']['UpdateEventSubscriptionRequest'];
|
|
1044
1094
|
|
|
1045
|
-
declare class HttpError extends Error {
|
|
1095
|
+
declare class HttpError<TBody = unknown> extends Error {
|
|
1046
1096
|
status: number;
|
|
1047
1097
|
statusText: string;
|
|
1048
|
-
body?:
|
|
1098
|
+
body?: TBody;
|
|
1049
1099
|
url?: string;
|
|
1050
|
-
constructor(status: number, statusText: string, body?:
|
|
1100
|
+
constructor(status: number, statusText: string, body?: TBody, url?: string);
|
|
1051
1101
|
}
|
|
1102
|
+
type ApiErrorBody = ErrorResponse;
|
|
1103
|
+
type ApiHttpError = HttpError<ApiErrorBody>;
|
|
1104
|
+
declare function isApiErrorBody(body: unknown): body is ApiErrorBody;
|
|
1105
|
+
declare function isApiHttpError(err: unknown): err is ApiHttpError;
|
|
1052
1106
|
declare class TimeoutError extends Error {
|
|
1053
1107
|
ms: number;
|
|
1054
1108
|
url?: string;
|
|
@@ -1059,6 +1113,9 @@ declare class NetworkError extends Error {
|
|
|
1059
1113
|
url?: string;
|
|
1060
1114
|
constructor(cause?: unknown, url?: string);
|
|
1061
1115
|
}
|
|
1116
|
+
declare class WorkspaceNotSelectedError extends Error {
|
|
1117
|
+
constructor();
|
|
1118
|
+
}
|
|
1062
1119
|
type RetryPolicy = {
|
|
1063
1120
|
maxRetries?: number;
|
|
1064
1121
|
baseDelayMs?: number;
|
|
@@ -1651,19 +1708,31 @@ type ListToolsOptions = ListQueryOptions & {
|
|
|
1651
1708
|
type ListToolResourcesOptions = Pick<ListQueryOptions, 'page' | 'limit'> & {
|
|
1652
1709
|
type?: 'document' | 'media' | 'file';
|
|
1653
1710
|
};
|
|
1711
|
+
type ListToolConnectionsOptions = ListQueryOptions;
|
|
1654
1712
|
type UploadToolResourcePayload = FormData | (Omit<ToolResourceUploadRequest, 'file'> & {
|
|
1655
1713
|
file: unknown;
|
|
1656
1714
|
});
|
|
1657
1715
|
declare function createToolsApi(cfg: ClientConfig & {
|
|
1658
1716
|
retry?: RetryPolicy;
|
|
1659
1717
|
}): {
|
|
1718
|
+
connections: {
|
|
1719
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1720
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1721
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ExecuteToolResponse>;
|
|
1722
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1723
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1724
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ExecuteToolResponse>;
|
|
1725
|
+
};
|
|
1660
1726
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1661
1727
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
1728
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1662
1729
|
uploadResource(toolId: string, payload: UploadToolResourcePayload): Promise<ToolResourceUploadResponse>;
|
|
1663
1730
|
deleteResource(toolId: string, resourceId: string): Promise<void>;
|
|
1664
1731
|
reloadResource(toolId: string, resourceId: string): Promise<ToolResourceReloadResponse>;
|
|
1665
1732
|
execute(toolId: string, payload: ExecuteToolRequest, options?: IdempotentRequestOptions): Promise<ExecuteToolResponse>;
|
|
1666
1733
|
connect(toolId: string, payload: ToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ToolConnectionResponse>;
|
|
1734
|
+
createConnection(payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ToolConnectionResponse>;
|
|
1735
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ExecuteToolResponse>;
|
|
1667
1736
|
};
|
|
1668
1737
|
|
|
1669
1738
|
type ListVoicesOptions = ListQueryOptions & {
|
|
@@ -1699,9 +1768,13 @@ declare function createWebhooksApi(cfg: ClientConfig & {
|
|
|
1699
1768
|
type ListWorkspacePhonesOptions = ListQueryOptions & {
|
|
1700
1769
|
channel?: WorkspacePhoneChannel;
|
|
1701
1770
|
};
|
|
1771
|
+
type ListWorkspacesOptions = ListQueryOptions & {
|
|
1772
|
+
refreshCache?: boolean;
|
|
1773
|
+
};
|
|
1702
1774
|
declare function createWorkspacesApi(cfg: ClientConfig & {
|
|
1703
1775
|
retry?: RetryPolicy;
|
|
1704
1776
|
}): {
|
|
1777
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1705
1778
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1706
1779
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1707
1780
|
};
|
|
@@ -1796,12 +1869,32 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1796
1869
|
update(agentId: string, payload: UpdateAgentRequest): Promise<AgentEntity>;
|
|
1797
1870
|
};
|
|
1798
1871
|
workspaces: {
|
|
1872
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1799
1873
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1800
1874
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1801
1875
|
};
|
|
1802
1876
|
tools: {
|
|
1877
|
+
connections: {
|
|
1878
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1879
|
+
idempotencyKey?: string;
|
|
1880
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1881
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: {
|
|
1882
|
+
idempotencyKey?: string;
|
|
1883
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1884
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1885
|
+
idempotencyKey?: string;
|
|
1886
|
+
}) => Promise<ExecuteToolResponse>;
|
|
1887
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1888
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: {
|
|
1889
|
+
idempotencyKey?: string;
|
|
1890
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1891
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1892
|
+
idempotencyKey?: string;
|
|
1893
|
+
}) => Promise<ExecuteToolResponse>;
|
|
1894
|
+
};
|
|
1803
1895
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1804
1896
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
1897
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1805
1898
|
uploadResource(toolId: string, payload: FormData | (Omit<{
|
|
1806
1899
|
file: string;
|
|
1807
1900
|
type?: "document" | "media" | "file";
|
|
@@ -1820,6 +1913,12 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1820
1913
|
connect(toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1821
1914
|
idempotencyKey?: string;
|
|
1822
1915
|
}): Promise<ToolConnectionResponse>;
|
|
1916
|
+
createConnection(payload: CreateToolConnectionRequest, options?: {
|
|
1917
|
+
idempotencyKey?: string;
|
|
1918
|
+
}): Promise<ToolConnectionResponse>;
|
|
1919
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1920
|
+
idempotencyKey?: string;
|
|
1921
|
+
}): Promise<ExecuteToolResponse>;
|
|
1823
1922
|
};
|
|
1824
1923
|
catalogs: {
|
|
1825
1924
|
templates: {
|
|
@@ -1909,12 +2008,32 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1909
2008
|
update(agentId: string, payload: UpdateAgentRequest): Promise<AgentEntity>;
|
|
1910
2009
|
};
|
|
1911
2010
|
workspaces: {
|
|
2011
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1912
2012
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1913
2013
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1914
2014
|
};
|
|
1915
2015
|
tools: {
|
|
2016
|
+
connections: {
|
|
2017
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: {
|
|
2018
|
+
idempotencyKey?: string;
|
|
2019
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2020
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: {
|
|
2021
|
+
idempotencyKey?: string;
|
|
2022
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2023
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2024
|
+
idempotencyKey?: string;
|
|
2025
|
+
}) => Promise<ExecuteToolResponse>;
|
|
2026
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
2027
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: {
|
|
2028
|
+
idempotencyKey?: string;
|
|
2029
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2030
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2031
|
+
idempotencyKey?: string;
|
|
2032
|
+
}) => Promise<ExecuteToolResponse>;
|
|
2033
|
+
};
|
|
1916
2034
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1917
2035
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
2036
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1918
2037
|
uploadResource(toolId: string, payload: FormData | (Omit<{
|
|
1919
2038
|
file: string;
|
|
1920
2039
|
type?: "document" | "media" | "file";
|
|
@@ -1933,6 +2052,12 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1933
2052
|
connect(toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1934
2053
|
idempotencyKey?: string;
|
|
1935
2054
|
}): Promise<ToolConnectionResponse>;
|
|
2055
|
+
createConnection(payload: CreateToolConnectionRequest, options?: {
|
|
2056
|
+
idempotencyKey?: string;
|
|
2057
|
+
}): Promise<ToolConnectionResponse>;
|
|
2058
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2059
|
+
idempotencyKey?: string;
|
|
2060
|
+
}): Promise<ExecuteToolResponse>;
|
|
1936
2061
|
};
|
|
1937
2062
|
catalogs: {
|
|
1938
2063
|
templates: {
|
|
@@ -1991,4 +2116,4 @@ declare function createHttp(cfg: ClientConfig & {
|
|
|
1991
2116
|
resolveAccessToken: () => string;
|
|
1992
2117
|
};
|
|
1993
2118
|
|
|
1994
|
-
export { type AgentBlueprint, type AgentBlueprintListItem, type AgentBlueprintListResponse, type AgentBlueprintsApi$1 as AgentBlueprintsApi, type AgentDetail, type AgentEntity, type AgentEntityFactoryOptions, type AgentListResponse, type AgentSchedule, type AgentScheduleApi, type AgentScheduleException, type AgentScheduleExceptionListResponse, type AgentScheduleListResponse, type AgentStageTriggersApi$1 as AgentStageTriggersApi, type AgentStagesApi$1 as AgentStagesApi, type AgentSummary, type AgentTagRequest, type AgentTagsResponse, type AgentVersionDetail, type AgentVersionListResponse, type AgentVersionSummary, type AgentsApi, type AgentsApiWithEntities, type ApiKeyListResponse, type ApiKeySummary, type ApiKeysApi, type BlueprintStage, type BlueprintStageListResponse, type BlueprintStageReorderRequest, type BlueprintStageTrigger, type BlueprintStageTriggerListResponse, type Campaign, type CampaignExecution, type CampaignExecutionListResponse, type CampaignListResponse, type CampaignStatus, type CatalogItemCreateRequest, type CatalogItemDetail, type CatalogItemLinks, type CatalogItemListResponse, type CatalogItemSummary, type CatalogTemplateDetail, type CatalogTemplateListResponse, type CatalogTemplateSummary, type CatalogTemplateVisibility, type ClientConfig, type ConnectPhoneRequest, type CreateAgentBlueprintRequest, type CreateAgentRequest, type CreateAgentScheduleExceptionRequest, type CreateAgentVersionRequest, type CreateApiKeyRequest, type CreateApiKeyResponse, type CreateBlueprintStageRequest, type CreateBlueprintStageTriggerRequest, type CreateCampaignPayload, type CreateEventSubscriptionRequest, type CreateInstructionRequest, type CreateWebhookRequest, type ErrorResponse, type EventSubscriptionDetail, type EventSubscriptionListResponse, type EventSubscriptionSummary, type ExecuteToolRequest, type ExecuteToolResponse, type ForkAgentFromTemplateRequest, HttpError, type Instruction, type InstructionCreatedResponse, type InstructionListResponse, type ListAgentBlueprintsOptions, type ListAgentScheduleExceptionsOptions, type ListAgentSchedulesOptions, type ListAgentStageTriggersOptions, type ListAgentStagesOptions, type ListAgentVersionInstructionsOptions, type ListAgentVersionsOptions, type ListAgentsOptions, type ListCampaignExecutionsOptions, type ListCampaignsOptions, type ListCatalogItemsOptions, type ListCatalogTemplatesOptions, type ListQueryOptions, type ListToolResourcesOptions, type ListToolsOptions, type ListVoicesOptions, type ListWebhooksOptions, type ListWorkspacePhonesOptions, NetworkError, type PaginatedResult, type PaginationMeta, type PhoneAssignmentResponse, type PublishAgentVersionRequest, type QueryBuilderInput, type QueryBuilderSerializable, type QueryFilterOperators, type QueryFilters, type QueryOrGroups, type QueryValue, type RetryPolicy, TimeoutError, type ToolConnectionAuth, type ToolConnectionRequest, type ToolConnectionResponse, type ToolListResponse, type ToolResourceListResponse, type ToolResourceReloadResponse, type ToolResourceSummary, type ToolResourceUploadRequest, type ToolResourceUploadResponse, type ToolSummary, type UpdateAgentBlueprintRequest, type UpdateAgentRequest, type UpdateAgentScheduleExceptionRequest, type UpdateAgentScheduleRequest, type UpdateAgentVersionNotesRequest, type UpdateBlueprintStageRequest, type UpdateBlueprintStageTriggerRequest, type UpdateEventSubscriptionRequest, type UpdateInstructionRequest, type UpdateWebhookRequest, type VoiceListResponse, type VoiceSummary, type WebhookDetail, type WebhookListResponse, type WebhookSummary, type WorkspaceEnableRequest, type WorkspaceEnableResponse, type WorkspacePhone, type WorkspacePhoneChannel, type WorkspacePhonesResponse, bindAgentBlueprints, bindAgentPhones, bindAgentSchedule, bindAgentScheduleExceptions, bindAgentSchedules, bindAgentStageTriggers, bindAgentStages, bindAgentTags, bindAgentVersions, createAgentBlueprintsApi, createAgentEntity, createAgentPhonesApi, createAgentScheduleApi, createAgentScheduleExceptionsApi, createAgentStageTriggersApi, createAgentStagesApi, createAgentTagsApi, createAgentVersionsApi, createAgentsApi, createApiKeysApi, createCampaignsApi, createCatalogTemplatesApi, createCatalogsApi, createClient, createHttp, createToolsApi, createVoicesApi, createWebhooksApi, createWorkspacesApi };
|
|
2119
|
+
export { type AgentBlueprint, type AgentBlueprintListItem, type AgentBlueprintListResponse, type AgentBlueprintsApi$1 as AgentBlueprintsApi, type AgentDetail, type AgentEntity, type AgentEntityFactoryOptions, type AgentListResponse, type AgentSchedule, type AgentScheduleApi, type AgentScheduleException, type AgentScheduleExceptionListResponse, type AgentScheduleListResponse, type AgentStageTriggersApi$1 as AgentStageTriggersApi, type AgentStagesApi$1 as AgentStagesApi, type AgentSummary, type AgentTagRequest, type AgentTagsResponse, type AgentVersionDetail, type AgentVersionListResponse, type AgentVersionSummary, type AgentsApi, type AgentsApiWithEntities, type ApiErrorBody, type ApiHttpError, type ApiKeyListResponse, type ApiKeySummary, type ApiKeysApi, type BlueprintStage, type BlueprintStageListResponse, type BlueprintStageReorderRequest, type BlueprintStageTrigger, type BlueprintStageTriggerListResponse, type Campaign, type CampaignExecution, type CampaignExecutionListResponse, type CampaignListResponse, type CampaignStatus, type CatalogItemCreateRequest, type CatalogItemDetail, type CatalogItemLinks, type CatalogItemListResponse, type CatalogItemSummary, type CatalogTemplateDetail, type CatalogTemplateListResponse, type CatalogTemplateSummary, type CatalogTemplateVisibility, type ClientConfig, type ConnectPhoneRequest, type CreateAgentBlueprintRequest, type CreateAgentRequest, type CreateAgentScheduleExceptionRequest, type CreateAgentVersionRequest, type CreateApiKeyRequest, type CreateApiKeyResponse, type CreateBlueprintStageRequest, type CreateBlueprintStageTriggerRequest, type CreateCampaignPayload, type CreateEventSubscriptionRequest, type CreateInstructionRequest, type CreateToolConnectionRequest, type CreateWebhookRequest, type ErrorResponse, type EventSubscriptionDetail, type EventSubscriptionListResponse, type EventSubscriptionSummary, type ExecuteToolConnectionRequest, type ExecuteToolRequest, type ExecuteToolResponse, type ForkAgentFromTemplateRequest, HttpError, type Instruction, type InstructionCreatedResponse, type InstructionListResponse, type ListAgentBlueprintsOptions, type ListAgentScheduleExceptionsOptions, type ListAgentSchedulesOptions, type ListAgentStageTriggersOptions, type ListAgentStagesOptions, type ListAgentVersionInstructionsOptions, type ListAgentVersionsOptions, type ListAgentsOptions, type ListCampaignExecutionsOptions, type ListCampaignsOptions, type ListCatalogItemsOptions, type ListCatalogTemplatesOptions, type ListQueryOptions, type ListToolConnectionsOptions, type ListToolResourcesOptions, type ListToolsOptions, type ListVoicesOptions, type ListWebhooksOptions, type ListWorkspacePhonesOptions, type ListWorkspacesOptions, NetworkError, type PaginatedResult, type PaginationMeta, type PhoneAssignmentResponse, type PublishAgentVersionRequest, type QueryBuilderInput, type QueryBuilderSerializable, type QueryFilterOperators, type QueryFilters, type QueryOrGroups, type QueryValue, type RetryPolicy, TimeoutError, type ToolConnectionAuth, type ToolConnectionListItem, type ToolConnectionListResponse, type ToolConnectionRequest, type ToolConnectionResponse, type ToolListResponse, type ToolResourceListResponse, type ToolResourceReloadResponse, type ToolResourceSummary, type ToolResourceUploadRequest, type ToolResourceUploadResponse, type ToolSummary, type UpdateAgentBlueprintRequest, type UpdateAgentRequest, type UpdateAgentScheduleExceptionRequest, type UpdateAgentScheduleRequest, type UpdateAgentVersionNotesRequest, type UpdateBlueprintStageRequest, type UpdateBlueprintStageTriggerRequest, type UpdateEventSubscriptionRequest, type UpdateInstructionRequest, type UpdateWebhookRequest, type VoiceListResponse, type VoiceSummary, type WebhookDetail, type WebhookListResponse, type WebhookSummary, type WorkspaceEnableRequest, type WorkspaceEnableResponse, type WorkspaceListResponse, WorkspaceNotSelectedError, type WorkspacePhone, type WorkspacePhoneChannel, type WorkspacePhonesResponse, type WorkspaceSummary, bindAgentBlueprints, bindAgentPhones, bindAgentSchedule, bindAgentScheduleExceptions, bindAgentSchedules, bindAgentStageTriggers, bindAgentStages, bindAgentTags, bindAgentVersions, createAgentBlueprintsApi, createAgentEntity, createAgentPhonesApi, createAgentScheduleApi, createAgentScheduleExceptionsApi, createAgentStageTriggersApi, createAgentStagesApi, createAgentTagsApi, createAgentVersionsApi, createAgentsApi, createApiKeysApi, createCampaignsApi, createCatalogTemplatesApi, createCatalogsApi, createClient, createHttp, createToolsApi, createVoicesApi, createWebhooksApi, createWorkspacesApi, isApiErrorBody, isApiHttpError };
|
package/dist/index.d.ts
CHANGED
|
@@ -452,6 +452,7 @@ type components = {
|
|
|
452
452
|
message?: string;
|
|
453
453
|
};
|
|
454
454
|
ToolConnectionRequest: {
|
|
455
|
+
connectionKey?: string;
|
|
455
456
|
agentId: string;
|
|
456
457
|
metadata?: {
|
|
457
458
|
[key: string]: unknown;
|
|
@@ -459,7 +460,7 @@ type components = {
|
|
|
459
460
|
auth?: components['schemas']['ToolConnectionAuth'];
|
|
460
461
|
};
|
|
461
462
|
ToolConnectionResponse: {
|
|
462
|
-
status: 'connected' | 'pending' | 'error';
|
|
463
|
+
status: 'connected' | 'pending' | 'error' | 'revoked';
|
|
463
464
|
toolAgentConnectionId?: string | null;
|
|
464
465
|
toolId: string;
|
|
465
466
|
workspaceId: string;
|
|
@@ -472,7 +473,7 @@ type components = {
|
|
|
472
473
|
};
|
|
473
474
|
};
|
|
474
475
|
ToolConnectionAuth: {
|
|
475
|
-
type: 'none' | 'oauth2' | 'api_key';
|
|
476
|
+
type: 'none' | 'oauth2' | 'api_key' | 'custom';
|
|
476
477
|
data?: {
|
|
477
478
|
[key: string]: unknown;
|
|
478
479
|
};
|
|
@@ -495,6 +496,7 @@ type components = {
|
|
|
495
496
|
toolId: string;
|
|
496
497
|
toolAgentConnectionId?: string | null;
|
|
497
498
|
providerRef?: string | null;
|
|
499
|
+
toolExecutionId: string;
|
|
498
500
|
message?: string | null;
|
|
499
501
|
};
|
|
500
502
|
CatalogItemLinks: {
|
|
@@ -545,6 +547,8 @@ type components = {
|
|
|
545
547
|
code: string;
|
|
546
548
|
message: string;
|
|
547
549
|
details?: {
|
|
550
|
+
subcode?: string;
|
|
551
|
+
workspaceId?: string;
|
|
548
552
|
[key: string]: unknown;
|
|
549
553
|
};
|
|
550
554
|
};
|
|
@@ -692,6 +696,14 @@ type components = {
|
|
|
692
696
|
CreateApiKeyResponse: components['schemas']['ApiKeySummary'] & {
|
|
693
697
|
key: string;
|
|
694
698
|
};
|
|
699
|
+
WorkspaceSummary: {
|
|
700
|
+
id: string;
|
|
701
|
+
name: string;
|
|
702
|
+
};
|
|
703
|
+
WorkspaceListResponse: {
|
|
704
|
+
data: components['schemas']['WorkspaceSummary'][];
|
|
705
|
+
meta: components['schemas']['PaginationMeta'];
|
|
706
|
+
};
|
|
695
707
|
ToolConfigSchemaActionPrompts: {
|
|
696
708
|
assistant?: string;
|
|
697
709
|
user?: string;
|
|
@@ -715,6 +727,36 @@ type components = {
|
|
|
715
727
|
[key: string]: components['schemas']['ToolConfigSchemaAction'];
|
|
716
728
|
};
|
|
717
729
|
};
|
|
730
|
+
ToolConnectionListItem: {
|
|
731
|
+
toolAgentConnectionId: string;
|
|
732
|
+
toolId: string;
|
|
733
|
+
workspaceId: string;
|
|
734
|
+
agentId: string;
|
|
735
|
+
connectionKey: string;
|
|
736
|
+
status: 'connected' | 'pending' | 'error' | 'revoked';
|
|
737
|
+
providerRef?: string | null;
|
|
738
|
+
descriptionUsage?: string | null;
|
|
739
|
+
usageExample?: string | null;
|
|
740
|
+
};
|
|
741
|
+
ToolConnectionListResponse: {
|
|
742
|
+
data: components['schemas']['ToolConnectionListItem'][];
|
|
743
|
+
meta: components['schemas']['PaginationMeta'];
|
|
744
|
+
};
|
|
745
|
+
CreateToolConnectionRequest: {
|
|
746
|
+
toolId: string;
|
|
747
|
+
agentId: string;
|
|
748
|
+
connectionKey?: string;
|
|
749
|
+
metadata?: {
|
|
750
|
+
[key: string]: unknown;
|
|
751
|
+
};
|
|
752
|
+
auth?: components['schemas']['ToolConnectionAuth'];
|
|
753
|
+
};
|
|
754
|
+
ExecuteToolConnectionRequest: {
|
|
755
|
+
action: string;
|
|
756
|
+
args?: {
|
|
757
|
+
[key: string]: unknown;
|
|
758
|
+
};
|
|
759
|
+
};
|
|
718
760
|
CatalogItemLanguageMetadata: {
|
|
719
761
|
code: string;
|
|
720
762
|
locale?: string | null;
|
|
@@ -770,7 +812,9 @@ type components = {
|
|
|
770
812
|
OrParam?: components['schemas']['QueryOrGroups'];
|
|
771
813
|
ScheduleId: string;
|
|
772
814
|
ApiKeyId: string;
|
|
815
|
+
XCacheRefresh?: boolean;
|
|
773
816
|
IdempotencyKey: string;
|
|
817
|
+
XApiKey?: string;
|
|
774
818
|
};
|
|
775
819
|
requestBodies: never;
|
|
776
820
|
headers: never;
|
|
@@ -839,6 +883,8 @@ type WorkspacePhonesResponse = components['schemas']['WorkspacePhonesResponse'];
|
|
|
839
883
|
type WorkspacePhoneChannel = 'voice';
|
|
840
884
|
type WorkspaceEnableRequest = components['schemas']['WorkspaceEnableRequest'];
|
|
841
885
|
type WorkspaceEnableResponse = components['schemas']['WorkspaceEnableResponse'];
|
|
886
|
+
type WorkspaceSummary = components['schemas']['WorkspaceSummary'];
|
|
887
|
+
type WorkspaceListResponse = components['schemas']['WorkspaceListResponse'];
|
|
842
888
|
type VoiceSummary = components['schemas']['VoiceSummary'];
|
|
843
889
|
type VoiceListResponse = components['schemas']['VoiceListResponse'];
|
|
844
890
|
type CatalogItemLinks = components['schemas']['CatalogItemLinks'];
|
|
@@ -1023,8 +1069,12 @@ type ToolResourceUploadRequest = components['schemas']['ToolResourceUploadReques
|
|
|
1023
1069
|
type ToolResourceUploadResponse = components['schemas']['ToolResourceUploadResponse'];
|
|
1024
1070
|
type ToolResourceReloadResponse = components['schemas']['ToolResourceReloadResponse'];
|
|
1025
1071
|
type ToolConnectionAuth = components['schemas']['ToolConnectionAuth'];
|
|
1072
|
+
type CreateToolConnectionRequest = components['schemas']['CreateToolConnectionRequest'];
|
|
1026
1073
|
type ToolConnectionRequest = components['schemas']['ToolConnectionRequest'];
|
|
1027
1074
|
type ToolConnectionResponse = components['schemas']['ToolConnectionResponse'];
|
|
1075
|
+
type ToolConnectionListItem = components['schemas']['ToolConnectionListItem'];
|
|
1076
|
+
type ToolConnectionListResponse = components['schemas']['ToolConnectionListResponse'];
|
|
1077
|
+
type ExecuteToolConnectionRequest = components['schemas']['ExecuteToolConnectionRequest'];
|
|
1028
1078
|
type ErrorResponse = components['schemas']['ErrorResponse'];
|
|
1029
1079
|
type CampaignStatus = components['schemas']['CampaignStatus'];
|
|
1030
1080
|
type Campaign = components['schemas']['Campaign'];
|
|
@@ -1042,13 +1092,17 @@ type EventSubscriptionListResponse = components['schemas']['EventSubscriptionLis
|
|
|
1042
1092
|
type CreateEventSubscriptionRequest = components['schemas']['CreateEventSubscriptionRequest'];
|
|
1043
1093
|
type UpdateEventSubscriptionRequest = components['schemas']['UpdateEventSubscriptionRequest'];
|
|
1044
1094
|
|
|
1045
|
-
declare class HttpError extends Error {
|
|
1095
|
+
declare class HttpError<TBody = unknown> extends Error {
|
|
1046
1096
|
status: number;
|
|
1047
1097
|
statusText: string;
|
|
1048
|
-
body?:
|
|
1098
|
+
body?: TBody;
|
|
1049
1099
|
url?: string;
|
|
1050
|
-
constructor(status: number, statusText: string, body?:
|
|
1100
|
+
constructor(status: number, statusText: string, body?: TBody, url?: string);
|
|
1051
1101
|
}
|
|
1102
|
+
type ApiErrorBody = ErrorResponse;
|
|
1103
|
+
type ApiHttpError = HttpError<ApiErrorBody>;
|
|
1104
|
+
declare function isApiErrorBody(body: unknown): body is ApiErrorBody;
|
|
1105
|
+
declare function isApiHttpError(err: unknown): err is ApiHttpError;
|
|
1052
1106
|
declare class TimeoutError extends Error {
|
|
1053
1107
|
ms: number;
|
|
1054
1108
|
url?: string;
|
|
@@ -1059,6 +1113,9 @@ declare class NetworkError extends Error {
|
|
|
1059
1113
|
url?: string;
|
|
1060
1114
|
constructor(cause?: unknown, url?: string);
|
|
1061
1115
|
}
|
|
1116
|
+
declare class WorkspaceNotSelectedError extends Error {
|
|
1117
|
+
constructor();
|
|
1118
|
+
}
|
|
1062
1119
|
type RetryPolicy = {
|
|
1063
1120
|
maxRetries?: number;
|
|
1064
1121
|
baseDelayMs?: number;
|
|
@@ -1651,19 +1708,31 @@ type ListToolsOptions = ListQueryOptions & {
|
|
|
1651
1708
|
type ListToolResourcesOptions = Pick<ListQueryOptions, 'page' | 'limit'> & {
|
|
1652
1709
|
type?: 'document' | 'media' | 'file';
|
|
1653
1710
|
};
|
|
1711
|
+
type ListToolConnectionsOptions = ListQueryOptions;
|
|
1654
1712
|
type UploadToolResourcePayload = FormData | (Omit<ToolResourceUploadRequest, 'file'> & {
|
|
1655
1713
|
file: unknown;
|
|
1656
1714
|
});
|
|
1657
1715
|
declare function createToolsApi(cfg: ClientConfig & {
|
|
1658
1716
|
retry?: RetryPolicy;
|
|
1659
1717
|
}): {
|
|
1718
|
+
connections: {
|
|
1719
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1720
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1721
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ExecuteToolResponse>;
|
|
1722
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1723
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ToolConnectionResponse>;
|
|
1724
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions) => Promise<ExecuteToolResponse>;
|
|
1725
|
+
};
|
|
1660
1726
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1661
1727
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
1728
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1662
1729
|
uploadResource(toolId: string, payload: UploadToolResourcePayload): Promise<ToolResourceUploadResponse>;
|
|
1663
1730
|
deleteResource(toolId: string, resourceId: string): Promise<void>;
|
|
1664
1731
|
reloadResource(toolId: string, resourceId: string): Promise<ToolResourceReloadResponse>;
|
|
1665
1732
|
execute(toolId: string, payload: ExecuteToolRequest, options?: IdempotentRequestOptions): Promise<ExecuteToolResponse>;
|
|
1666
1733
|
connect(toolId: string, payload: ToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ToolConnectionResponse>;
|
|
1734
|
+
createConnection(payload: CreateToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ToolConnectionResponse>;
|
|
1735
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: IdempotentRequestOptions): Promise<ExecuteToolResponse>;
|
|
1667
1736
|
};
|
|
1668
1737
|
|
|
1669
1738
|
type ListVoicesOptions = ListQueryOptions & {
|
|
@@ -1699,9 +1768,13 @@ declare function createWebhooksApi(cfg: ClientConfig & {
|
|
|
1699
1768
|
type ListWorkspacePhonesOptions = ListQueryOptions & {
|
|
1700
1769
|
channel?: WorkspacePhoneChannel;
|
|
1701
1770
|
};
|
|
1771
|
+
type ListWorkspacesOptions = ListQueryOptions & {
|
|
1772
|
+
refreshCache?: boolean;
|
|
1773
|
+
};
|
|
1702
1774
|
declare function createWorkspacesApi(cfg: ClientConfig & {
|
|
1703
1775
|
retry?: RetryPolicy;
|
|
1704
1776
|
}): {
|
|
1777
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1705
1778
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1706
1779
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1707
1780
|
};
|
|
@@ -1796,12 +1869,32 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1796
1869
|
update(agentId: string, payload: UpdateAgentRequest): Promise<AgentEntity>;
|
|
1797
1870
|
};
|
|
1798
1871
|
workspaces: {
|
|
1872
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1799
1873
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1800
1874
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1801
1875
|
};
|
|
1802
1876
|
tools: {
|
|
1877
|
+
connections: {
|
|
1878
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1879
|
+
idempotencyKey?: string;
|
|
1880
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1881
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: {
|
|
1882
|
+
idempotencyKey?: string;
|
|
1883
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1884
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1885
|
+
idempotencyKey?: string;
|
|
1886
|
+
}) => Promise<ExecuteToolResponse>;
|
|
1887
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1888
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: {
|
|
1889
|
+
idempotencyKey?: string;
|
|
1890
|
+
}) => Promise<ToolConnectionResponse>;
|
|
1891
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1892
|
+
idempotencyKey?: string;
|
|
1893
|
+
}) => Promise<ExecuteToolResponse>;
|
|
1894
|
+
};
|
|
1803
1895
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1804
1896
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
1897
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1805
1898
|
uploadResource(toolId: string, payload: FormData | (Omit<{
|
|
1806
1899
|
file: string;
|
|
1807
1900
|
type?: "document" | "media" | "file";
|
|
@@ -1820,6 +1913,12 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1820
1913
|
connect(toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1821
1914
|
idempotencyKey?: string;
|
|
1822
1915
|
}): Promise<ToolConnectionResponse>;
|
|
1916
|
+
createConnection(payload: CreateToolConnectionRequest, options?: {
|
|
1917
|
+
idempotencyKey?: string;
|
|
1918
|
+
}): Promise<ToolConnectionResponse>;
|
|
1919
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
1920
|
+
idempotencyKey?: string;
|
|
1921
|
+
}): Promise<ExecuteToolResponse>;
|
|
1823
1922
|
};
|
|
1824
1923
|
catalogs: {
|
|
1825
1924
|
templates: {
|
|
@@ -1909,12 +2008,32 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1909
2008
|
update(agentId: string, payload: UpdateAgentRequest): Promise<AgentEntity>;
|
|
1910
2009
|
};
|
|
1911
2010
|
workspaces: {
|
|
2011
|
+
list(options?: ListWorkspacesOptions): Promise<PaginatedResult<WorkspaceListResponse, ListWorkspacesOptions>>;
|
|
1912
2012
|
listPhones(workspaceId: string, opts?: ListWorkspacePhonesOptions): Promise<PaginatedResult<WorkspacePhonesResponse, ListWorkspacePhonesOptions>>;
|
|
1913
2013
|
enable(workspaceId: string, payload: WorkspaceEnableRequest): Promise<WorkspaceEnableResponse>;
|
|
1914
2014
|
};
|
|
1915
2015
|
tools: {
|
|
2016
|
+
connections: {
|
|
2017
|
+
readonly connect: (toolId: string, payload: ToolConnectionRequest, options?: {
|
|
2018
|
+
idempotencyKey?: string;
|
|
2019
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2020
|
+
readonly create: (payload: CreateToolConnectionRequest, options?: {
|
|
2021
|
+
idempotencyKey?: string;
|
|
2022
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2023
|
+
readonly execute: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2024
|
+
idempotencyKey?: string;
|
|
2025
|
+
}) => Promise<ExecuteToolResponse>;
|
|
2026
|
+
readonly list: (options?: ListToolConnectionsOptions) => Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
2027
|
+
readonly createConnection: (payload: CreateToolConnectionRequest, options?: {
|
|
2028
|
+
idempotencyKey?: string;
|
|
2029
|
+
}) => Promise<ToolConnectionResponse>;
|
|
2030
|
+
readonly executeConnection: (toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2031
|
+
idempotencyKey?: string;
|
|
2032
|
+
}) => Promise<ExecuteToolResponse>;
|
|
2033
|
+
};
|
|
1916
2034
|
list(options?: ListToolsOptions): Promise<PaginatedResult<ToolListResponse, ListToolsOptions>>;
|
|
1917
2035
|
listResources(toolId: string, options?: ListToolResourcesOptions): Promise<PaginatedResult<ToolResourceListResponse, ListToolResourcesOptions>>;
|
|
2036
|
+
listConnections(options?: ListToolConnectionsOptions): Promise<PaginatedResult<ToolConnectionListResponse, ListToolConnectionsOptions>>;
|
|
1918
2037
|
uploadResource(toolId: string, payload: FormData | (Omit<{
|
|
1919
2038
|
file: string;
|
|
1920
2039
|
type?: "document" | "media" | "file";
|
|
@@ -1933,6 +2052,12 @@ declare function createClient(initialCfg: ClientConfig & {
|
|
|
1933
2052
|
connect(toolId: string, payload: ToolConnectionRequest, options?: {
|
|
1934
2053
|
idempotencyKey?: string;
|
|
1935
2054
|
}): Promise<ToolConnectionResponse>;
|
|
2055
|
+
createConnection(payload: CreateToolConnectionRequest, options?: {
|
|
2056
|
+
idempotencyKey?: string;
|
|
2057
|
+
}): Promise<ToolConnectionResponse>;
|
|
2058
|
+
executeConnection(toolAgentConnectionId: string, payload: ExecuteToolConnectionRequest, options?: {
|
|
2059
|
+
idempotencyKey?: string;
|
|
2060
|
+
}): Promise<ExecuteToolResponse>;
|
|
1936
2061
|
};
|
|
1937
2062
|
catalogs: {
|
|
1938
2063
|
templates: {
|
|
@@ -1991,4 +2116,4 @@ declare function createHttp(cfg: ClientConfig & {
|
|
|
1991
2116
|
resolveAccessToken: () => string;
|
|
1992
2117
|
};
|
|
1993
2118
|
|
|
1994
|
-
export { type AgentBlueprint, type AgentBlueprintListItem, type AgentBlueprintListResponse, type AgentBlueprintsApi$1 as AgentBlueprintsApi, type AgentDetail, type AgentEntity, type AgentEntityFactoryOptions, type AgentListResponse, type AgentSchedule, type AgentScheduleApi, type AgentScheduleException, type AgentScheduleExceptionListResponse, type AgentScheduleListResponse, type AgentStageTriggersApi$1 as AgentStageTriggersApi, type AgentStagesApi$1 as AgentStagesApi, type AgentSummary, type AgentTagRequest, type AgentTagsResponse, type AgentVersionDetail, type AgentVersionListResponse, type AgentVersionSummary, type AgentsApi, type AgentsApiWithEntities, type ApiKeyListResponse, type ApiKeySummary, type ApiKeysApi, type BlueprintStage, type BlueprintStageListResponse, type BlueprintStageReorderRequest, type BlueprintStageTrigger, type BlueprintStageTriggerListResponse, type Campaign, type CampaignExecution, type CampaignExecutionListResponse, type CampaignListResponse, type CampaignStatus, type CatalogItemCreateRequest, type CatalogItemDetail, type CatalogItemLinks, type CatalogItemListResponse, type CatalogItemSummary, type CatalogTemplateDetail, type CatalogTemplateListResponse, type CatalogTemplateSummary, type CatalogTemplateVisibility, type ClientConfig, type ConnectPhoneRequest, type CreateAgentBlueprintRequest, type CreateAgentRequest, type CreateAgentScheduleExceptionRequest, type CreateAgentVersionRequest, type CreateApiKeyRequest, type CreateApiKeyResponse, type CreateBlueprintStageRequest, type CreateBlueprintStageTriggerRequest, type CreateCampaignPayload, type CreateEventSubscriptionRequest, type CreateInstructionRequest, type CreateWebhookRequest, type ErrorResponse, type EventSubscriptionDetail, type EventSubscriptionListResponse, type EventSubscriptionSummary, type ExecuteToolRequest, type ExecuteToolResponse, type ForkAgentFromTemplateRequest, HttpError, type Instruction, type InstructionCreatedResponse, type InstructionListResponse, type ListAgentBlueprintsOptions, type ListAgentScheduleExceptionsOptions, type ListAgentSchedulesOptions, type ListAgentStageTriggersOptions, type ListAgentStagesOptions, type ListAgentVersionInstructionsOptions, type ListAgentVersionsOptions, type ListAgentsOptions, type ListCampaignExecutionsOptions, type ListCampaignsOptions, type ListCatalogItemsOptions, type ListCatalogTemplatesOptions, type ListQueryOptions, type ListToolResourcesOptions, type ListToolsOptions, type ListVoicesOptions, type ListWebhooksOptions, type ListWorkspacePhonesOptions, NetworkError, type PaginatedResult, type PaginationMeta, type PhoneAssignmentResponse, type PublishAgentVersionRequest, type QueryBuilderInput, type QueryBuilderSerializable, type QueryFilterOperators, type QueryFilters, type QueryOrGroups, type QueryValue, type RetryPolicy, TimeoutError, type ToolConnectionAuth, type ToolConnectionRequest, type ToolConnectionResponse, type ToolListResponse, type ToolResourceListResponse, type ToolResourceReloadResponse, type ToolResourceSummary, type ToolResourceUploadRequest, type ToolResourceUploadResponse, type ToolSummary, type UpdateAgentBlueprintRequest, type UpdateAgentRequest, type UpdateAgentScheduleExceptionRequest, type UpdateAgentScheduleRequest, type UpdateAgentVersionNotesRequest, type UpdateBlueprintStageRequest, type UpdateBlueprintStageTriggerRequest, type UpdateEventSubscriptionRequest, type UpdateInstructionRequest, type UpdateWebhookRequest, type VoiceListResponse, type VoiceSummary, type WebhookDetail, type WebhookListResponse, type WebhookSummary, type WorkspaceEnableRequest, type WorkspaceEnableResponse, type WorkspacePhone, type WorkspacePhoneChannel, type WorkspacePhonesResponse, bindAgentBlueprints, bindAgentPhones, bindAgentSchedule, bindAgentScheduleExceptions, bindAgentSchedules, bindAgentStageTriggers, bindAgentStages, bindAgentTags, bindAgentVersions, createAgentBlueprintsApi, createAgentEntity, createAgentPhonesApi, createAgentScheduleApi, createAgentScheduleExceptionsApi, createAgentStageTriggersApi, createAgentStagesApi, createAgentTagsApi, createAgentVersionsApi, createAgentsApi, createApiKeysApi, createCampaignsApi, createCatalogTemplatesApi, createCatalogsApi, createClient, createHttp, createToolsApi, createVoicesApi, createWebhooksApi, createWorkspacesApi };
|
|
2119
|
+
export { type AgentBlueprint, type AgentBlueprintListItem, type AgentBlueprintListResponse, type AgentBlueprintsApi$1 as AgentBlueprintsApi, type AgentDetail, type AgentEntity, type AgentEntityFactoryOptions, type AgentListResponse, type AgentSchedule, type AgentScheduleApi, type AgentScheduleException, type AgentScheduleExceptionListResponse, type AgentScheduleListResponse, type AgentStageTriggersApi$1 as AgentStageTriggersApi, type AgentStagesApi$1 as AgentStagesApi, type AgentSummary, type AgentTagRequest, type AgentTagsResponse, type AgentVersionDetail, type AgentVersionListResponse, type AgentVersionSummary, type AgentsApi, type AgentsApiWithEntities, type ApiErrorBody, type ApiHttpError, type ApiKeyListResponse, type ApiKeySummary, type ApiKeysApi, type BlueprintStage, type BlueprintStageListResponse, type BlueprintStageReorderRequest, type BlueprintStageTrigger, type BlueprintStageTriggerListResponse, type Campaign, type CampaignExecution, type CampaignExecutionListResponse, type CampaignListResponse, type CampaignStatus, type CatalogItemCreateRequest, type CatalogItemDetail, type CatalogItemLinks, type CatalogItemListResponse, type CatalogItemSummary, type CatalogTemplateDetail, type CatalogTemplateListResponse, type CatalogTemplateSummary, type CatalogTemplateVisibility, type ClientConfig, type ConnectPhoneRequest, type CreateAgentBlueprintRequest, type CreateAgentRequest, type CreateAgentScheduleExceptionRequest, type CreateAgentVersionRequest, type CreateApiKeyRequest, type CreateApiKeyResponse, type CreateBlueprintStageRequest, type CreateBlueprintStageTriggerRequest, type CreateCampaignPayload, type CreateEventSubscriptionRequest, type CreateInstructionRequest, type CreateToolConnectionRequest, type CreateWebhookRequest, type ErrorResponse, type EventSubscriptionDetail, type EventSubscriptionListResponse, type EventSubscriptionSummary, type ExecuteToolConnectionRequest, type ExecuteToolRequest, type ExecuteToolResponse, type ForkAgentFromTemplateRequest, HttpError, type Instruction, type InstructionCreatedResponse, type InstructionListResponse, type ListAgentBlueprintsOptions, type ListAgentScheduleExceptionsOptions, type ListAgentSchedulesOptions, type ListAgentStageTriggersOptions, type ListAgentStagesOptions, type ListAgentVersionInstructionsOptions, type ListAgentVersionsOptions, type ListAgentsOptions, type ListCampaignExecutionsOptions, type ListCampaignsOptions, type ListCatalogItemsOptions, type ListCatalogTemplatesOptions, type ListQueryOptions, type ListToolConnectionsOptions, type ListToolResourcesOptions, type ListToolsOptions, type ListVoicesOptions, type ListWebhooksOptions, type ListWorkspacePhonesOptions, type ListWorkspacesOptions, NetworkError, type PaginatedResult, type PaginationMeta, type PhoneAssignmentResponse, type PublishAgentVersionRequest, type QueryBuilderInput, type QueryBuilderSerializable, type QueryFilterOperators, type QueryFilters, type QueryOrGroups, type QueryValue, type RetryPolicy, TimeoutError, type ToolConnectionAuth, type ToolConnectionListItem, type ToolConnectionListResponse, type ToolConnectionRequest, type ToolConnectionResponse, type ToolListResponse, type ToolResourceListResponse, type ToolResourceReloadResponse, type ToolResourceSummary, type ToolResourceUploadRequest, type ToolResourceUploadResponse, type ToolSummary, type UpdateAgentBlueprintRequest, type UpdateAgentRequest, type UpdateAgentScheduleExceptionRequest, type UpdateAgentScheduleRequest, type UpdateAgentVersionNotesRequest, type UpdateBlueprintStageRequest, type UpdateBlueprintStageTriggerRequest, type UpdateEventSubscriptionRequest, type UpdateInstructionRequest, type UpdateWebhookRequest, type VoiceListResponse, type VoiceSummary, type WebhookDetail, type WebhookListResponse, type WebhookSummary, type WorkspaceEnableRequest, type WorkspaceEnableResponse, type WorkspaceListResponse, WorkspaceNotSelectedError, type WorkspacePhone, type WorkspacePhoneChannel, type WorkspacePhonesResponse, type WorkspaceSummary, bindAgentBlueprints, bindAgentPhones, bindAgentSchedule, bindAgentScheduleExceptions, bindAgentSchedules, bindAgentStageTriggers, bindAgentStages, bindAgentTags, bindAgentVersions, createAgentBlueprintsApi, createAgentEntity, createAgentPhonesApi, createAgentScheduleApi, createAgentScheduleExceptionsApi, createAgentStageTriggersApi, createAgentStagesApi, createAgentTagsApi, createAgentVersionsApi, createAgentsApi, createApiKeysApi, createCampaignsApi, createCatalogTemplatesApi, createCatalogsApi, createClient, createHttp, createToolsApi, createVoicesApi, createWebhooksApi, createWorkspacesApi, isApiErrorBody, isApiHttpError };
|