@teamlearners/clawops 0.28.0 → 0.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +42 -11
- package/dist/agent/index.cjs +9 -9
- package/dist/agent/index.js +1 -1
- package/dist/{chunk-5MCVFEXW.js → chunk-622J6BJ5.js} +3 -3
- package/dist/{chunk-5MCVFEXW.js.map → chunk-622J6BJ5.js.map} +1 -1
- package/dist/{chunk-OBVMJFXL.cjs → chunk-IGFGK3XZ.cjs} +3 -3
- package/dist/{chunk-OBVMJFXL.cjs.map → chunk-IGFGK3XZ.cjs.map} +1 -1
- package/dist/index.cjs +101 -42
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +168 -45
- package/dist/index.d.ts +168 -45
- package/dist/index.js +68 -9
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -230,7 +230,7 @@ type AssignmentLink = z.infer<typeof AssignmentLinkSchema>;
|
|
|
230
230
|
type AssignmentLinkCreateResponse = z.infer<typeof AssignmentLinkCreateResponseSchema>;
|
|
231
231
|
type AssignmentLinkStatus = AssignmentLink['status'];
|
|
232
232
|
|
|
233
|
-
type RequestOptions$
|
|
233
|
+
type RequestOptions$2 = {
|
|
234
234
|
extraHeaders?: Record<string, string>;
|
|
235
235
|
extraQuery?: Record<string, unknown>;
|
|
236
236
|
timeout?: number;
|
|
@@ -246,13 +246,13 @@ declare class AssignmentLinks extends APIResource {
|
|
|
246
246
|
webhookUrl?: string;
|
|
247
247
|
webhookMethod?: 'POST' | 'GET';
|
|
248
248
|
note?: string;
|
|
249
|
-
}, options?: RequestOptions$
|
|
249
|
+
}, options?: RequestOptions$2): Promise<AssignmentLinkCreateResponse>;
|
|
250
250
|
list(params?: {
|
|
251
251
|
status?: AssignmentLinkStatus;
|
|
252
252
|
page?: number;
|
|
253
253
|
pageSize?: number;
|
|
254
|
-
}, options?: RequestOptions$
|
|
255
|
-
retrieve(linkId: string, options?: RequestOptions$
|
|
254
|
+
}, options?: RequestOptions$2): Promise<Page<AssignmentLink>>;
|
|
255
|
+
retrieve(linkId: string, options?: RequestOptions$2): Promise<AssignmentLink>;
|
|
256
256
|
revoke(linkId: string, options?: {
|
|
257
257
|
extraHeaders?: Record<string, string>;
|
|
258
258
|
timeout?: number;
|
|
@@ -316,7 +316,7 @@ type BlockedChannel = BlockedRecipient['channel'];
|
|
|
316
316
|
type BlockedRecipientStatus = 'active' | 'released' | 'all';
|
|
317
317
|
type BlockedRecipientSource = 'api' | 'console' | 'import';
|
|
318
318
|
|
|
319
|
-
type RequestOptions = {
|
|
319
|
+
type RequestOptions$1 = {
|
|
320
320
|
extraHeaders?: Record<string, string>;
|
|
321
321
|
extraQuery?: Record<string, unknown>;
|
|
322
322
|
timeout?: number;
|
|
@@ -345,7 +345,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
345
345
|
source?: BlockedRecipientSource;
|
|
346
346
|
sourceRef?: string;
|
|
347
347
|
note?: string;
|
|
348
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
348
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
349
349
|
/**
|
|
350
350
|
* 수신거부 목록을 조회합니다. 기본은 **현재 차단 중인 항목만** 이며,
|
|
351
351
|
* 해제 이력까지 보려면 `status` 를 `'released'` 또는 `'all'` 로 지정합니다.
|
|
@@ -356,9 +356,9 @@ declare class BlockedRecipients extends APIResource {
|
|
|
356
356
|
status?: BlockedRecipientStatus;
|
|
357
357
|
page?: number;
|
|
358
358
|
pageSize?: number;
|
|
359
|
-
}, options?: RequestOptions): Promise<Page<BlockedRecipient>>;
|
|
359
|
+
}, options?: RequestOptions$1): Promise<Page<BlockedRecipient>>;
|
|
360
360
|
/** 항목 상세를 조회합니다. 해제된 항목도 이력으로 남아 조회됩니다(`active: false`). */
|
|
361
|
-
retrieve(blockId: string, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
361
|
+
retrieve(blockId: string, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
362
362
|
/**
|
|
363
363
|
* 메모를 수정합니다.
|
|
364
364
|
*
|
|
@@ -367,7 +367,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
367
367
|
*/
|
|
368
368
|
update(blockId: string, params?: {
|
|
369
369
|
note?: string | null;
|
|
370
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
370
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
371
371
|
/**
|
|
372
372
|
* 수신거부를 해제해 다시 발신할 수 있게 합니다.
|
|
373
373
|
*
|
|
@@ -379,7 +379,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
379
379
|
*/
|
|
380
380
|
release(blockId: string, params?: {
|
|
381
381
|
note?: string;
|
|
382
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
382
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
383
383
|
}
|
|
384
384
|
|
|
385
385
|
declare const CallSchema: z.ZodObject<{
|
|
@@ -534,11 +534,48 @@ declare const CallControlResponseSchema: z.ZodObject<{
|
|
|
534
534
|
}, z.ZodTypeAny, "passthrough">>;
|
|
535
535
|
type CallControlResponse = z.infer<typeof CallControlResponseSchema>;
|
|
536
536
|
|
|
537
|
+
/**
|
|
538
|
+
* `agentId` 에이전트의 **이번 통화에만** 적용되는 컨텍스트.
|
|
539
|
+
*
|
|
540
|
+
* 에이전트 자체의 설정은 그대로 두고 이 통화만 다르게 행동시킬 때 사용한다.
|
|
541
|
+
* 같은 에이전트로 동시에 거는 다른 통화에는 영향이 없다.
|
|
542
|
+
*/
|
|
543
|
+
interface CallContextParam {
|
|
544
|
+
/** 이번 통화에서 수행할 실행 요구사항 (최대 4000자). */
|
|
545
|
+
instruction: string;
|
|
546
|
+
/** 요구사항에서 참조할 통화별 구조화 데이터 (최대 50개). */
|
|
547
|
+
variables?: Record<string, string | number | boolean>;
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* 발신 전화 생성 요청 파라미터.
|
|
551
|
+
*
|
|
552
|
+
* **4가지 모드** — `url`, `agentId`, `callFlowId` 는 서로 배타적이다.
|
|
553
|
+
*
|
|
554
|
+
* - **VoiceML 모드**: `url` 을 지정하면 VoiceML 로 통화를 제어한다.
|
|
555
|
+
* - **매니지드 에이전트 모드**: `agentId` 를 지정하면 콘솔에서 만든 AI 에이전트가
|
|
556
|
+
* 통화를 처리한다. `callContext` 로 이번 통화만의 지시를 덧붙일 수 있다.
|
|
557
|
+
* - **콜 플로우 모드**: `callFlowId` 를 지정하면 결정적 ARS 플로우가 진행한다.
|
|
558
|
+
* `variables` 로 시작 변수를 넘긴다.
|
|
559
|
+
* - **Agent SDK 모드**: 셋 다 생략하면 From 번호에 연결된 Agent SDK 로 연결된다.
|
|
560
|
+
*/
|
|
537
561
|
interface CallCreateParams {
|
|
538
562
|
to: string;
|
|
539
563
|
from: string;
|
|
540
|
-
/** VoiceML 명령을 반환할 URL. */
|
|
564
|
+
/** VoiceML 명령을 반환할 URL. `agentId`·`callFlowId` 와 배타. */
|
|
541
565
|
url?: string;
|
|
566
|
+
/** 콘솔에서 만든 매니지드 에이전트 ID. `url`·`callFlowId` 와 배타. */
|
|
567
|
+
agentId?: string;
|
|
568
|
+
/** `agentId` 에이전트의 이번 통화에만 적용되는 컨텍스트. */
|
|
569
|
+
callContext?: CallContextParam;
|
|
570
|
+
/** 콜 플로우(결정적 ARS) ID. `url`·`agentId` 와 배타. */
|
|
571
|
+
callFlowId?: string;
|
|
572
|
+
/**
|
|
573
|
+
* 콜 플로우 시작 변수. 멘트·URL·본문의 `{{이름}}` 이 이 값으로 치환된다.
|
|
574
|
+
* `callFlowId` 와 함께일 때만 쓸 수 있다(단독 지정 시 400).
|
|
575
|
+
* `caller`·`callee`·`recording_url`·`recording_duration`·`http_status` 는
|
|
576
|
+
* 통화 중 자동으로 채워지는 예약 변수라 지정할 수 없다.
|
|
577
|
+
*/
|
|
578
|
+
variables?: Record<string, string | number | boolean>;
|
|
542
579
|
statusCallback?: string;
|
|
543
580
|
statusCallbackEvent?: string;
|
|
544
581
|
/** 발신 타임아웃 (초). 기본값: 60. */
|
|
@@ -838,70 +875,156 @@ declare class Messages extends APIResource {
|
|
|
838
875
|
}): Promise<Message>;
|
|
839
876
|
}
|
|
840
877
|
|
|
878
|
+
/**
|
|
879
|
+
* 착신 라우팅 모드.
|
|
880
|
+
*
|
|
881
|
+
* - `webhook` : webhookUrl 의 VoiceML 이 처리.
|
|
882
|
+
* - `agent` : agentId 의 매니지드 에이전트가 착신.
|
|
883
|
+
* - `callflow` : callFlowId 의 콜 플로우(ARS)가 착신.
|
|
884
|
+
* - `forward` : forwardTo(같은 계정 보유 번호)로 내부 착신전환.
|
|
885
|
+
* - `sip` : sipEndpointId 의 라우트로 외부 PBX 다이얼.
|
|
886
|
+
* - `softphone` : sipCredentialId 의 등록 단말로 착신.
|
|
887
|
+
*/
|
|
888
|
+
declare const ROUTING_TYPES: readonly ["webhook", "sip", "softphone", "forward", "agent", "callflow"];
|
|
889
|
+
type RoutingType = (typeof ROUTING_TYPES)[number];
|
|
841
890
|
declare const PhoneNumberSchema: z.ZodObject<{
|
|
842
891
|
number: z.ZodString;
|
|
892
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
843
893
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
894
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
895
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
896
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
897
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
847
898
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
848
899
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
900
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
901
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
902
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
903
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
904
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
905
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
906
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
849
907
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
850
908
|
}, "passthrough", z.ZodTypeAny, z.objectOutputType<{
|
|
851
909
|
number: z.ZodString;
|
|
910
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
852
911
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
912
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
913
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
914
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
915
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
856
916
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
857
917
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
918
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
919
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
920
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
921
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
922
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
923
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
924
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
858
925
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
859
926
|
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
860
927
|
number: z.ZodString;
|
|
928
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
861
929
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
930
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
931
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
932
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
933
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
865
934
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
866
935
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
936
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
937
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
938
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
939
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
940
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
941
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
942
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
867
943
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
868
944
|
}, z.ZodTypeAny, "passthrough">>;
|
|
869
|
-
|
|
945
|
+
/**
|
|
946
|
+
* 전화번호. `routingType` 은 알려진 값에 자동완성이 뜨지만, 서버가 새 라우팅을 추가해도
|
|
947
|
+
* 파싱이 깨지지 않도록 임의의 문자열을 허용한다.
|
|
948
|
+
*/
|
|
949
|
+
type PhoneNumber = Omit<z.infer<typeof PhoneNumberSchema>, 'routingType'> & {
|
|
950
|
+
routingType?: RoutingType | (string & {}) | null;
|
|
951
|
+
};
|
|
870
952
|
type NumberListItem = PhoneNumber;
|
|
871
953
|
type NumberUpdateResponse = PhoneNumber;
|
|
872
954
|
|
|
873
955
|
interface NumberCreateParams {
|
|
956
|
+
/** 수신 전화 처리용 Webhook URL. */
|
|
874
957
|
webhookUrl?: string;
|
|
958
|
+
/** Webhook 호출 HTTP 메서드. */
|
|
959
|
+
webhookMethod?: 'POST' | 'GET';
|
|
960
|
+
/** Webhook 호출 시 덧붙일 헤더. 키는 'X-' 로 시작해야 한다. */
|
|
961
|
+
webhookHeaders?: Record<string, string>;
|
|
962
|
+
/** 수신(inbound) 통화 상태 통지 URL. */
|
|
963
|
+
statusCallback?: string;
|
|
964
|
+
/** 구독할 상태 이벤트(공백 구분). 미지정 시 'initiated ringing answered completed'. */
|
|
965
|
+
statusCallbackEvents?: string;
|
|
875
966
|
}
|
|
876
967
|
interface NumberUpdateParams {
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
/**
|
|
880
|
-
|
|
881
|
-
/** routingType='
|
|
968
|
+
/** 착신 라우팅 모드. */
|
|
969
|
+
routingType?: RoutingType;
|
|
970
|
+
/** routingType='agent' 일 때 필수. 같은 계정의 에이전트 id. */
|
|
971
|
+
agentId?: string | null;
|
|
972
|
+
/** routingType='callflow' 일 때 필수. 같은 계정의 콜 플로우 id. */
|
|
973
|
+
callFlowId?: string | null;
|
|
974
|
+
/** routingType='forward' 일 때 필수. 같은 계정이 보유한 번호. */
|
|
975
|
+
forwardTo?: string | null;
|
|
976
|
+
/** routingType='sip' 일 때 필수. SipEndpoint id. */
|
|
882
977
|
sipEndpointId?: string | null;
|
|
883
|
-
/** routingType='softphone' 일 때
|
|
978
|
+
/** routingType='softphone' 일 때 필수. 등록 단말의 SIP credential id. */
|
|
884
979
|
sipCredentialId?: string | null;
|
|
980
|
+
/** 수신 전화 처리용 Webhook URL. */
|
|
981
|
+
webhookUrl?: string;
|
|
982
|
+
/** Webhook 호출 HTTP 메서드. */
|
|
983
|
+
webhookMethod?: 'POST' | 'GET';
|
|
984
|
+
/** Webhook 호출 시 덧붙일 헤더. */
|
|
985
|
+
webhookHeaders?: Record<string, string> | null;
|
|
986
|
+
/** routingType='agent' 에서 통화별 컨텍스트를 조회할 endpoint. */
|
|
987
|
+
callContextUrl?: string | null;
|
|
988
|
+
/** 수신(inbound) 통화 상태 통지 URL. */
|
|
989
|
+
statusCallback?: string | null;
|
|
990
|
+
/** 구독할 상태 이벤트(공백 구분). */
|
|
991
|
+
statusCallbackEvents?: string | null;
|
|
992
|
+
/** 이 번호의 통화 전사에 적용할 받아쓰기 사전 id. */
|
|
993
|
+
dictionaryId?: string | null;
|
|
885
994
|
}
|
|
886
995
|
|
|
996
|
+
interface RequestOptions {
|
|
997
|
+
extraHeaders?: Record<string, string>;
|
|
998
|
+
extraQuery?: Record<string, unknown>;
|
|
999
|
+
timeout?: number;
|
|
1000
|
+
}
|
|
887
1001
|
declare class Numbers extends APIResource {
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
1002
|
+
/**
|
|
1003
|
+
* 번호를 발급합니다. 번호 풀에서 자동으로 배정되며 어떤 번호가 나올지는 지정할 수 없습니다.
|
|
1004
|
+
*
|
|
1005
|
+
* 발급 직후 번호는 `routingType: "webhook"` 이고 `webhookUrl` 이 비어 있어, 그대로 두면
|
|
1006
|
+
* 걸려온 전화가 거절됩니다. 이어서 `update()` 로 착신 라우팅을 지정하세요.
|
|
1007
|
+
*/
|
|
1008
|
+
create(params?: NumberCreateParams, options?: RequestOptions): Promise<PhoneNumber>;
|
|
1009
|
+
/**
|
|
1010
|
+
* 등록된 번호 목록을 조회합니다. 페이지네이션과 필터가 없으며 보유한 번호가 한 번에 전부
|
|
1011
|
+
* 반환됩니다.
|
|
1012
|
+
*/
|
|
1013
|
+
list(options?: RequestOptions): Promise<NumberListItem[]>;
|
|
1014
|
+
/**
|
|
1015
|
+
* 번호 설정을 수정합니다. 착신 라우팅(webhook/agent/callflow/forward/sip/softphone)과
|
|
1016
|
+
* webhook, 상태 통지, 받아쓰기 사전을 변경할 수 있습니다. 보낸 필드만 반영되고 생략한
|
|
1017
|
+
* 필드는 유지됩니다.
|
|
1018
|
+
*
|
|
1019
|
+
* 라우팅을 바꾸면 다른 라우팅 필드는 서버에서 자동으로 비워집니다. `agent` 에서
|
|
1020
|
+
* `webhook` 으로 되돌리면 `agentId` 가 null 이 되므로, 다시 `agent` 로 돌아갈 때
|
|
1021
|
+
* `agentId` 를 새로 지정해야 합니다.
|
|
1022
|
+
*/
|
|
1023
|
+
update(number: string, params?: NumberUpdateParams, options?: RequestOptions): Promise<NumberUpdateResponse>;
|
|
1024
|
+
/**
|
|
1025
|
+
* 번호를 반납합니다. 번호는 풀로 복귀하며 되돌릴 수 없습니다. 같은 번호를 다시
|
|
1026
|
+
* 발급받는다는 보장이 없습니다.
|
|
1027
|
+
*/
|
|
905
1028
|
delete(number: string, options?: {
|
|
906
1029
|
extraHeaders?: Record<string, string>;
|
|
907
1030
|
timeout?: number;
|
|
@@ -1337,4 +1460,4 @@ declare const PaginationMetaSchema: z.ZodObject<{
|
|
|
1337
1460
|
}, z.ZodTypeAny, "passthrough">>;
|
|
1338
1461
|
type PaginationMeta = z.infer<typeof PaginationMetaSchema>;
|
|
1339
1462
|
|
|
1340
|
-
export { APIClient, type APIClientOptions, APIConnectionError, APIError, APIResponseValidationError, APIStatusError, APITimeoutError, AccountContext, AgentConnectionError, AgentError, type AssignmentLink, type AssignmentLinkAssignment, type AssignmentLinkCreateResponse, type AssignmentLinkStatus, AssignmentLinks, AuthenticationError, BadRequestError, type BlockedChannel, type BlockedRecipient, type BlockedRecipientSource, type BlockedRecipientStatus, BlockedRecipients, type Call, type CallControlResponse, type CallCreateParams, type CallListParams, type CallUpdateParams, Calls, ClawOps, ClawOpsError, type ClawOpsOptions, ConflictError, InternalServerError, type Message, type MessageCreateParams, type MessageListParams, Messages, NotFoundError, type NumberCreateParams, type NumberListItem, type NumberUpdateParams, type NumberUpdateResponse, Numbers, Page, type PaginationMeta, PermissionDeniedError, type PhoneNumber, RateLimitError, type RecordingDownload, Recordings, ServiceUnavailableError, type SipCredential, SipCredentials, type SipEndpoint, SipEndpoints, UnprocessableEntityError, VERSION, type WebhookLog, WebhookLogs, WebhookVerificationError, Webhooks, ClawOps as default };
|
|
1463
|
+
export { APIClient, type APIClientOptions, APIConnectionError, APIError, APIResponseValidationError, APIStatusError, APITimeoutError, AccountContext, AgentConnectionError, AgentError, type AssignmentLink, type AssignmentLinkAssignment, type AssignmentLinkCreateResponse, type AssignmentLinkStatus, AssignmentLinks, AuthenticationError, BadRequestError, type BlockedChannel, type BlockedRecipient, type BlockedRecipientSource, type BlockedRecipientStatus, BlockedRecipients, type Call, type CallContextParam, type CallControlResponse, type CallCreateParams, type CallListParams, type CallUpdateParams, Calls, ClawOps, ClawOpsError, type ClawOpsOptions, ConflictError, InternalServerError, type Message, type MessageCreateParams, type MessageListParams, Messages, NotFoundError, type NumberCreateParams, type NumberListItem, type NumberUpdateParams, type NumberUpdateResponse, Numbers, Page, type PaginationMeta, PermissionDeniedError, type PhoneNumber, RateLimitError, type RecordingDownload, Recordings, type RoutingType, ServiceUnavailableError, type SipCredential, SipCredentials, type SipEndpoint, SipEndpoints, UnprocessableEntityError, VERSION, type WebhookLog, WebhookLogs, WebhookVerificationError, Webhooks, ClawOps as default };
|
package/dist/index.d.ts
CHANGED
|
@@ -230,7 +230,7 @@ type AssignmentLink = z.infer<typeof AssignmentLinkSchema>;
|
|
|
230
230
|
type AssignmentLinkCreateResponse = z.infer<typeof AssignmentLinkCreateResponseSchema>;
|
|
231
231
|
type AssignmentLinkStatus = AssignmentLink['status'];
|
|
232
232
|
|
|
233
|
-
type RequestOptions$
|
|
233
|
+
type RequestOptions$2 = {
|
|
234
234
|
extraHeaders?: Record<string, string>;
|
|
235
235
|
extraQuery?: Record<string, unknown>;
|
|
236
236
|
timeout?: number;
|
|
@@ -246,13 +246,13 @@ declare class AssignmentLinks extends APIResource {
|
|
|
246
246
|
webhookUrl?: string;
|
|
247
247
|
webhookMethod?: 'POST' | 'GET';
|
|
248
248
|
note?: string;
|
|
249
|
-
}, options?: RequestOptions$
|
|
249
|
+
}, options?: RequestOptions$2): Promise<AssignmentLinkCreateResponse>;
|
|
250
250
|
list(params?: {
|
|
251
251
|
status?: AssignmentLinkStatus;
|
|
252
252
|
page?: number;
|
|
253
253
|
pageSize?: number;
|
|
254
|
-
}, options?: RequestOptions$
|
|
255
|
-
retrieve(linkId: string, options?: RequestOptions$
|
|
254
|
+
}, options?: RequestOptions$2): Promise<Page<AssignmentLink>>;
|
|
255
|
+
retrieve(linkId: string, options?: RequestOptions$2): Promise<AssignmentLink>;
|
|
256
256
|
revoke(linkId: string, options?: {
|
|
257
257
|
extraHeaders?: Record<string, string>;
|
|
258
258
|
timeout?: number;
|
|
@@ -316,7 +316,7 @@ type BlockedChannel = BlockedRecipient['channel'];
|
|
|
316
316
|
type BlockedRecipientStatus = 'active' | 'released' | 'all';
|
|
317
317
|
type BlockedRecipientSource = 'api' | 'console' | 'import';
|
|
318
318
|
|
|
319
|
-
type RequestOptions = {
|
|
319
|
+
type RequestOptions$1 = {
|
|
320
320
|
extraHeaders?: Record<string, string>;
|
|
321
321
|
extraQuery?: Record<string, unknown>;
|
|
322
322
|
timeout?: number;
|
|
@@ -345,7 +345,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
345
345
|
source?: BlockedRecipientSource;
|
|
346
346
|
sourceRef?: string;
|
|
347
347
|
note?: string;
|
|
348
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
348
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
349
349
|
/**
|
|
350
350
|
* 수신거부 목록을 조회합니다. 기본은 **현재 차단 중인 항목만** 이며,
|
|
351
351
|
* 해제 이력까지 보려면 `status` 를 `'released'` 또는 `'all'` 로 지정합니다.
|
|
@@ -356,9 +356,9 @@ declare class BlockedRecipients extends APIResource {
|
|
|
356
356
|
status?: BlockedRecipientStatus;
|
|
357
357
|
page?: number;
|
|
358
358
|
pageSize?: number;
|
|
359
|
-
}, options?: RequestOptions): Promise<Page<BlockedRecipient>>;
|
|
359
|
+
}, options?: RequestOptions$1): Promise<Page<BlockedRecipient>>;
|
|
360
360
|
/** 항목 상세를 조회합니다. 해제된 항목도 이력으로 남아 조회됩니다(`active: false`). */
|
|
361
|
-
retrieve(blockId: string, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
361
|
+
retrieve(blockId: string, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
362
362
|
/**
|
|
363
363
|
* 메모를 수정합니다.
|
|
364
364
|
*
|
|
@@ -367,7 +367,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
367
367
|
*/
|
|
368
368
|
update(blockId: string, params?: {
|
|
369
369
|
note?: string | null;
|
|
370
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
370
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
371
371
|
/**
|
|
372
372
|
* 수신거부를 해제해 다시 발신할 수 있게 합니다.
|
|
373
373
|
*
|
|
@@ -379,7 +379,7 @@ declare class BlockedRecipients extends APIResource {
|
|
|
379
379
|
*/
|
|
380
380
|
release(blockId: string, params?: {
|
|
381
381
|
note?: string;
|
|
382
|
-
}, options?: RequestOptions): Promise<BlockedRecipient>;
|
|
382
|
+
}, options?: RequestOptions$1): Promise<BlockedRecipient>;
|
|
383
383
|
}
|
|
384
384
|
|
|
385
385
|
declare const CallSchema: z.ZodObject<{
|
|
@@ -534,11 +534,48 @@ declare const CallControlResponseSchema: z.ZodObject<{
|
|
|
534
534
|
}, z.ZodTypeAny, "passthrough">>;
|
|
535
535
|
type CallControlResponse = z.infer<typeof CallControlResponseSchema>;
|
|
536
536
|
|
|
537
|
+
/**
|
|
538
|
+
* `agentId` 에이전트의 **이번 통화에만** 적용되는 컨텍스트.
|
|
539
|
+
*
|
|
540
|
+
* 에이전트 자체의 설정은 그대로 두고 이 통화만 다르게 행동시킬 때 사용한다.
|
|
541
|
+
* 같은 에이전트로 동시에 거는 다른 통화에는 영향이 없다.
|
|
542
|
+
*/
|
|
543
|
+
interface CallContextParam {
|
|
544
|
+
/** 이번 통화에서 수행할 실행 요구사항 (최대 4000자). */
|
|
545
|
+
instruction: string;
|
|
546
|
+
/** 요구사항에서 참조할 통화별 구조화 데이터 (최대 50개). */
|
|
547
|
+
variables?: Record<string, string | number | boolean>;
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* 발신 전화 생성 요청 파라미터.
|
|
551
|
+
*
|
|
552
|
+
* **4가지 모드** — `url`, `agentId`, `callFlowId` 는 서로 배타적이다.
|
|
553
|
+
*
|
|
554
|
+
* - **VoiceML 모드**: `url` 을 지정하면 VoiceML 로 통화를 제어한다.
|
|
555
|
+
* - **매니지드 에이전트 모드**: `agentId` 를 지정하면 콘솔에서 만든 AI 에이전트가
|
|
556
|
+
* 통화를 처리한다. `callContext` 로 이번 통화만의 지시를 덧붙일 수 있다.
|
|
557
|
+
* - **콜 플로우 모드**: `callFlowId` 를 지정하면 결정적 ARS 플로우가 진행한다.
|
|
558
|
+
* `variables` 로 시작 변수를 넘긴다.
|
|
559
|
+
* - **Agent SDK 모드**: 셋 다 생략하면 From 번호에 연결된 Agent SDK 로 연결된다.
|
|
560
|
+
*/
|
|
537
561
|
interface CallCreateParams {
|
|
538
562
|
to: string;
|
|
539
563
|
from: string;
|
|
540
|
-
/** VoiceML 명령을 반환할 URL. */
|
|
564
|
+
/** VoiceML 명령을 반환할 URL. `agentId`·`callFlowId` 와 배타. */
|
|
541
565
|
url?: string;
|
|
566
|
+
/** 콘솔에서 만든 매니지드 에이전트 ID. `url`·`callFlowId` 와 배타. */
|
|
567
|
+
agentId?: string;
|
|
568
|
+
/** `agentId` 에이전트의 이번 통화에만 적용되는 컨텍스트. */
|
|
569
|
+
callContext?: CallContextParam;
|
|
570
|
+
/** 콜 플로우(결정적 ARS) ID. `url`·`agentId` 와 배타. */
|
|
571
|
+
callFlowId?: string;
|
|
572
|
+
/**
|
|
573
|
+
* 콜 플로우 시작 변수. 멘트·URL·본문의 `{{이름}}` 이 이 값으로 치환된다.
|
|
574
|
+
* `callFlowId` 와 함께일 때만 쓸 수 있다(단독 지정 시 400).
|
|
575
|
+
* `caller`·`callee`·`recording_url`·`recording_duration`·`http_status` 는
|
|
576
|
+
* 통화 중 자동으로 채워지는 예약 변수라 지정할 수 없다.
|
|
577
|
+
*/
|
|
578
|
+
variables?: Record<string, string | number | boolean>;
|
|
542
579
|
statusCallback?: string;
|
|
543
580
|
statusCallbackEvent?: string;
|
|
544
581
|
/** 발신 타임아웃 (초). 기본값: 60. */
|
|
@@ -838,70 +875,156 @@ declare class Messages extends APIResource {
|
|
|
838
875
|
}): Promise<Message>;
|
|
839
876
|
}
|
|
840
877
|
|
|
878
|
+
/**
|
|
879
|
+
* 착신 라우팅 모드.
|
|
880
|
+
*
|
|
881
|
+
* - `webhook` : webhookUrl 의 VoiceML 이 처리.
|
|
882
|
+
* - `agent` : agentId 의 매니지드 에이전트가 착신.
|
|
883
|
+
* - `callflow` : callFlowId 의 콜 플로우(ARS)가 착신.
|
|
884
|
+
* - `forward` : forwardTo(같은 계정 보유 번호)로 내부 착신전환.
|
|
885
|
+
* - `sip` : sipEndpointId 의 라우트로 외부 PBX 다이얼.
|
|
886
|
+
* - `softphone` : sipCredentialId 의 등록 단말로 착신.
|
|
887
|
+
*/
|
|
888
|
+
declare const ROUTING_TYPES: readonly ["webhook", "sip", "softphone", "forward", "agent", "callflow"];
|
|
889
|
+
type RoutingType = (typeof ROUTING_TYPES)[number];
|
|
841
890
|
declare const PhoneNumberSchema: z.ZodObject<{
|
|
842
891
|
number: z.ZodString;
|
|
892
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
843
893
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
894
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
895
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
896
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
897
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
847
898
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
848
899
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
900
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
901
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
902
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
903
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
904
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
905
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
906
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
849
907
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
850
908
|
}, "passthrough", z.ZodTypeAny, z.objectOutputType<{
|
|
851
909
|
number: z.ZodString;
|
|
910
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
852
911
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
912
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
913
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
914
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
915
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
856
916
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
857
917
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
918
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
919
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
920
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
921
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
922
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
923
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
924
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
858
925
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
859
926
|
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
860
927
|
number: z.ZodString;
|
|
928
|
+
numberType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
861
929
|
source: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
930
|
+
routingType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
931
|
+
agentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
932
|
+
callFlowId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
933
|
+
forwardTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
865
934
|
sipEndpointId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
866
935
|
sipCredentialId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
936
|
+
webhookUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
937
|
+
webhookMethod: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
938
|
+
webhookHeaders: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
939
|
+
callContextUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
940
|
+
statusCallback: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
941
|
+
statusCallbackEvents: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
942
|
+
dictionaryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
867
943
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
868
944
|
}, z.ZodTypeAny, "passthrough">>;
|
|
869
|
-
|
|
945
|
+
/**
|
|
946
|
+
* 전화번호. `routingType` 은 알려진 값에 자동완성이 뜨지만, 서버가 새 라우팅을 추가해도
|
|
947
|
+
* 파싱이 깨지지 않도록 임의의 문자열을 허용한다.
|
|
948
|
+
*/
|
|
949
|
+
type PhoneNumber = Omit<z.infer<typeof PhoneNumberSchema>, 'routingType'> & {
|
|
950
|
+
routingType?: RoutingType | (string & {}) | null;
|
|
951
|
+
};
|
|
870
952
|
type NumberListItem = PhoneNumber;
|
|
871
953
|
type NumberUpdateResponse = PhoneNumber;
|
|
872
954
|
|
|
873
955
|
interface NumberCreateParams {
|
|
956
|
+
/** 수신 전화 처리용 Webhook URL. */
|
|
874
957
|
webhookUrl?: string;
|
|
958
|
+
/** Webhook 호출 HTTP 메서드. */
|
|
959
|
+
webhookMethod?: 'POST' | 'GET';
|
|
960
|
+
/** Webhook 호출 시 덧붙일 헤더. 키는 'X-' 로 시작해야 한다. */
|
|
961
|
+
webhookHeaders?: Record<string, string>;
|
|
962
|
+
/** 수신(inbound) 통화 상태 통지 URL. */
|
|
963
|
+
statusCallback?: string;
|
|
964
|
+
/** 구독할 상태 이벤트(공백 구분). 미지정 시 'initiated ringing answered completed'. */
|
|
965
|
+
statusCallbackEvents?: string;
|
|
875
966
|
}
|
|
876
967
|
interface NumberUpdateParams {
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
/**
|
|
880
|
-
|
|
881
|
-
/** routingType='
|
|
968
|
+
/** 착신 라우팅 모드. */
|
|
969
|
+
routingType?: RoutingType;
|
|
970
|
+
/** routingType='agent' 일 때 필수. 같은 계정의 에이전트 id. */
|
|
971
|
+
agentId?: string | null;
|
|
972
|
+
/** routingType='callflow' 일 때 필수. 같은 계정의 콜 플로우 id. */
|
|
973
|
+
callFlowId?: string | null;
|
|
974
|
+
/** routingType='forward' 일 때 필수. 같은 계정이 보유한 번호. */
|
|
975
|
+
forwardTo?: string | null;
|
|
976
|
+
/** routingType='sip' 일 때 필수. SipEndpoint id. */
|
|
882
977
|
sipEndpointId?: string | null;
|
|
883
|
-
/** routingType='softphone' 일 때
|
|
978
|
+
/** routingType='softphone' 일 때 필수. 등록 단말의 SIP credential id. */
|
|
884
979
|
sipCredentialId?: string | null;
|
|
980
|
+
/** 수신 전화 처리용 Webhook URL. */
|
|
981
|
+
webhookUrl?: string;
|
|
982
|
+
/** Webhook 호출 HTTP 메서드. */
|
|
983
|
+
webhookMethod?: 'POST' | 'GET';
|
|
984
|
+
/** Webhook 호출 시 덧붙일 헤더. */
|
|
985
|
+
webhookHeaders?: Record<string, string> | null;
|
|
986
|
+
/** routingType='agent' 에서 통화별 컨텍스트를 조회할 endpoint. */
|
|
987
|
+
callContextUrl?: string | null;
|
|
988
|
+
/** 수신(inbound) 통화 상태 통지 URL. */
|
|
989
|
+
statusCallback?: string | null;
|
|
990
|
+
/** 구독할 상태 이벤트(공백 구분). */
|
|
991
|
+
statusCallbackEvents?: string | null;
|
|
992
|
+
/** 이 번호의 통화 전사에 적용할 받아쓰기 사전 id. */
|
|
993
|
+
dictionaryId?: string | null;
|
|
885
994
|
}
|
|
886
995
|
|
|
996
|
+
interface RequestOptions {
|
|
997
|
+
extraHeaders?: Record<string, string>;
|
|
998
|
+
extraQuery?: Record<string, unknown>;
|
|
999
|
+
timeout?: number;
|
|
1000
|
+
}
|
|
887
1001
|
declare class Numbers extends APIResource {
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
1002
|
+
/**
|
|
1003
|
+
* 번호를 발급합니다. 번호 풀에서 자동으로 배정되며 어떤 번호가 나올지는 지정할 수 없습니다.
|
|
1004
|
+
*
|
|
1005
|
+
* 발급 직후 번호는 `routingType: "webhook"` 이고 `webhookUrl` 이 비어 있어, 그대로 두면
|
|
1006
|
+
* 걸려온 전화가 거절됩니다. 이어서 `update()` 로 착신 라우팅을 지정하세요.
|
|
1007
|
+
*/
|
|
1008
|
+
create(params?: NumberCreateParams, options?: RequestOptions): Promise<PhoneNumber>;
|
|
1009
|
+
/**
|
|
1010
|
+
* 등록된 번호 목록을 조회합니다. 페이지네이션과 필터가 없으며 보유한 번호가 한 번에 전부
|
|
1011
|
+
* 반환됩니다.
|
|
1012
|
+
*/
|
|
1013
|
+
list(options?: RequestOptions): Promise<NumberListItem[]>;
|
|
1014
|
+
/**
|
|
1015
|
+
* 번호 설정을 수정합니다. 착신 라우팅(webhook/agent/callflow/forward/sip/softphone)과
|
|
1016
|
+
* webhook, 상태 통지, 받아쓰기 사전을 변경할 수 있습니다. 보낸 필드만 반영되고 생략한
|
|
1017
|
+
* 필드는 유지됩니다.
|
|
1018
|
+
*
|
|
1019
|
+
* 라우팅을 바꾸면 다른 라우팅 필드는 서버에서 자동으로 비워집니다. `agent` 에서
|
|
1020
|
+
* `webhook` 으로 되돌리면 `agentId` 가 null 이 되므로, 다시 `agent` 로 돌아갈 때
|
|
1021
|
+
* `agentId` 를 새로 지정해야 합니다.
|
|
1022
|
+
*/
|
|
1023
|
+
update(number: string, params?: NumberUpdateParams, options?: RequestOptions): Promise<NumberUpdateResponse>;
|
|
1024
|
+
/**
|
|
1025
|
+
* 번호를 반납합니다. 번호는 풀로 복귀하며 되돌릴 수 없습니다. 같은 번호를 다시
|
|
1026
|
+
* 발급받는다는 보장이 없습니다.
|
|
1027
|
+
*/
|
|
905
1028
|
delete(number: string, options?: {
|
|
906
1029
|
extraHeaders?: Record<string, string>;
|
|
907
1030
|
timeout?: number;
|
|
@@ -1337,4 +1460,4 @@ declare const PaginationMetaSchema: z.ZodObject<{
|
|
|
1337
1460
|
}, z.ZodTypeAny, "passthrough">>;
|
|
1338
1461
|
type PaginationMeta = z.infer<typeof PaginationMetaSchema>;
|
|
1339
1462
|
|
|
1340
|
-
export { APIClient, type APIClientOptions, APIConnectionError, APIError, APIResponseValidationError, APIStatusError, APITimeoutError, AccountContext, AgentConnectionError, AgentError, type AssignmentLink, type AssignmentLinkAssignment, type AssignmentLinkCreateResponse, type AssignmentLinkStatus, AssignmentLinks, AuthenticationError, BadRequestError, type BlockedChannel, type BlockedRecipient, type BlockedRecipientSource, type BlockedRecipientStatus, BlockedRecipients, type Call, type CallControlResponse, type CallCreateParams, type CallListParams, type CallUpdateParams, Calls, ClawOps, ClawOpsError, type ClawOpsOptions, ConflictError, InternalServerError, type Message, type MessageCreateParams, type MessageListParams, Messages, NotFoundError, type NumberCreateParams, type NumberListItem, type NumberUpdateParams, type NumberUpdateResponse, Numbers, Page, type PaginationMeta, PermissionDeniedError, type PhoneNumber, RateLimitError, type RecordingDownload, Recordings, ServiceUnavailableError, type SipCredential, SipCredentials, type SipEndpoint, SipEndpoints, UnprocessableEntityError, VERSION, type WebhookLog, WebhookLogs, WebhookVerificationError, Webhooks, ClawOps as default };
|
|
1463
|
+
export { APIClient, type APIClientOptions, APIConnectionError, APIError, APIResponseValidationError, APIStatusError, APITimeoutError, AccountContext, AgentConnectionError, AgentError, type AssignmentLink, type AssignmentLinkAssignment, type AssignmentLinkCreateResponse, type AssignmentLinkStatus, AssignmentLinks, AuthenticationError, BadRequestError, type BlockedChannel, type BlockedRecipient, type BlockedRecipientSource, type BlockedRecipientStatus, BlockedRecipients, type Call, type CallContextParam, type CallControlResponse, type CallCreateParams, type CallListParams, type CallUpdateParams, Calls, ClawOps, ClawOpsError, type ClawOpsOptions, ConflictError, InternalServerError, type Message, type MessageCreateParams, type MessageListParams, Messages, NotFoundError, type NumberCreateParams, type NumberListItem, type NumberUpdateParams, type NumberUpdateResponse, Numbers, Page, type PaginationMeta, PermissionDeniedError, type PhoneNumber, RateLimitError, type RecordingDownload, Recordings, type RoutingType, ServiceUnavailableError, type SipCredential, SipCredentials, type SipEndpoint, SipEndpoints, UnprocessableEntityError, VERSION, type WebhookLog, WebhookLogs, WebhookVerificationError, Webhooks, ClawOps as default };
|