@linqapp/sdk 0.14.0 → 0.15.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/CHANGELOG.md +20 -0
- package/client.d.mts +2 -2
- package/client.d.mts.map +1 -1
- package/client.d.ts +2 -2
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/chats/chats.d.mts +10 -1
- package/resources/chats/chats.d.mts.map +1 -1
- package/resources/chats/chats.d.ts +10 -1
- package/resources/chats/chats.d.ts.map +1 -1
- package/resources/chats/chats.js.map +1 -1
- package/resources/chats/chats.mjs.map +1 -1
- package/resources/chats/typing.d.mts +4 -2
- package/resources/chats/typing.d.mts.map +1 -1
- package/resources/chats/typing.d.ts +4 -2
- package/resources/chats/typing.d.ts.map +1 -1
- package/resources/chats/typing.js +4 -2
- package/resources/chats/typing.js.map +1 -1
- package/resources/chats/typing.mjs +4 -2
- package/resources/chats/typing.mjs.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/webhooks.d.mts +160 -1411
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +160 -1411
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs.map +1 -1
- package/src/client.ts +36 -70
- package/src/resources/chats/chats.ts +11 -1
- package/src/resources/chats/typing.ts +4 -2
- package/src/resources/index.ts +18 -35
- package/src/resources/webhooks.ts +204 -1744
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../core/resource';
|
|
4
|
-
import * as WebhooksAPI from './webhooks';
|
|
5
4
|
import * as Shared from './shared';
|
|
6
5
|
import * as WebhookEventsAPI from './webhook-events';
|
|
7
6
|
|
|
@@ -412,7 +411,7 @@ export interface SchemasTextPartResponse {
|
|
|
412
411
|
/**
|
|
413
412
|
* Complete webhook payload for message.sent events (2026-02-03 format)
|
|
414
413
|
*/
|
|
415
|
-
export interface
|
|
414
|
+
export interface MessageSentWebhookEvent {
|
|
416
415
|
/**
|
|
417
416
|
* API version for the webhook payload format
|
|
418
417
|
*/
|
|
@@ -481,7 +480,7 @@ export interface MessageSentV2026_02_03WebhookEvent {
|
|
|
481
480
|
/**
|
|
482
481
|
* Complete webhook payload for message.received events (2026-02-03 format)
|
|
483
482
|
*/
|
|
484
|
-
export interface
|
|
483
|
+
export interface MessageReceivedWebhookEvent {
|
|
485
484
|
/**
|
|
486
485
|
* API version for the webhook payload format
|
|
487
486
|
*/
|
|
@@ -550,7 +549,7 @@ export interface MessageReceivedV2026_02_03WebhookEvent {
|
|
|
550
549
|
/**
|
|
551
550
|
* Complete webhook payload for message.read events (2026-02-03 format)
|
|
552
551
|
*/
|
|
553
|
-
export interface
|
|
552
|
+
export interface MessageReadWebhookEvent {
|
|
554
553
|
/**
|
|
555
554
|
* API version for the webhook payload format
|
|
556
555
|
*/
|
|
@@ -619,7 +618,7 @@ export interface MessageReadV2026_02_03WebhookEvent {
|
|
|
619
618
|
/**
|
|
620
619
|
* Complete webhook payload for message.delivered events (2026-02-03 format)
|
|
621
620
|
*/
|
|
622
|
-
export interface
|
|
621
|
+
export interface MessageDeliveredWebhookEvent {
|
|
623
622
|
/**
|
|
624
623
|
* API version for the webhook payload format
|
|
625
624
|
*/
|
|
@@ -688,7 +687,7 @@ export interface MessageDeliveredV2026_02_03WebhookEvent {
|
|
|
688
687
|
/**
|
|
689
688
|
* Complete webhook payload for message.failed events
|
|
690
689
|
*/
|
|
691
|
-
export interface
|
|
690
|
+
export interface MessageFailedWebhookEvent {
|
|
692
691
|
/**
|
|
693
692
|
* API version for the webhook payload format
|
|
694
693
|
*/
|
|
@@ -704,7 +703,7 @@ export interface MessageFailedV2026_02_03WebhookEvent {
|
|
|
704
703
|
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
705
704
|
* code reference.
|
|
706
705
|
*/
|
|
707
|
-
data:
|
|
706
|
+
data: MessageFailedWebhookEvent.Data;
|
|
708
707
|
|
|
709
708
|
/**
|
|
710
709
|
* Unique identifier for this event (for deduplication)
|
|
@@ -738,7 +737,7 @@ export interface MessageFailedV2026_02_03WebhookEvent {
|
|
|
738
737
|
webhook_version: string;
|
|
739
738
|
}
|
|
740
739
|
|
|
741
|
-
export namespace
|
|
740
|
+
export namespace MessageFailedWebhookEvent {
|
|
742
741
|
/**
|
|
743
742
|
* Error details for message.failed webhook events. See
|
|
744
743
|
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
@@ -773,1558 +772,9 @@ export namespace MessageFailedV2026_02_03WebhookEvent {
|
|
|
773
772
|
}
|
|
774
773
|
|
|
775
774
|
/**
|
|
776
|
-
* Complete webhook payload for
|
|
777
|
-
*/
|
|
778
|
-
export interface ReactionAddedV2026_02_03WebhookEvent {
|
|
779
|
-
/**
|
|
780
|
-
* API version for the webhook payload format
|
|
781
|
-
*/
|
|
782
|
-
api_version: string;
|
|
783
|
-
|
|
784
|
-
/**
|
|
785
|
-
* When the event was created
|
|
786
|
-
*/
|
|
787
|
-
created_at: string;
|
|
788
|
-
|
|
789
|
-
/**
|
|
790
|
-
* Payload for reaction.added webhook events
|
|
791
|
-
*/
|
|
792
|
-
data: ReactionEventBase;
|
|
793
|
-
|
|
794
|
-
/**
|
|
795
|
-
* Unique identifier for this event (for deduplication)
|
|
796
|
-
*/
|
|
797
|
-
event_id: string;
|
|
798
|
-
|
|
799
|
-
/**
|
|
800
|
-
* Valid webhook event types that can be subscribed to.
|
|
801
|
-
*
|
|
802
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
803
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
804
|
-
* subscription will not produce any deliveries.
|
|
805
|
-
*/
|
|
806
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
807
|
-
|
|
808
|
-
/**
|
|
809
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
810
|
-
*/
|
|
811
|
-
partner_id: string;
|
|
812
|
-
|
|
813
|
-
/**
|
|
814
|
-
* Trace ID for debugging and correlation across systems.
|
|
815
|
-
*/
|
|
816
|
-
trace_id: string;
|
|
817
|
-
|
|
818
|
-
/**
|
|
819
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
820
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
821
|
-
* specified, defaults based on subscription creation date.
|
|
822
|
-
*/
|
|
823
|
-
webhook_version: string;
|
|
824
|
-
}
|
|
825
|
-
|
|
826
|
-
/**
|
|
827
|
-
* Complete webhook payload for reaction.removed events
|
|
828
|
-
*/
|
|
829
|
-
export interface ReactionRemovedV2026_02_03WebhookEvent {
|
|
830
|
-
/**
|
|
831
|
-
* API version for the webhook payload format
|
|
832
|
-
*/
|
|
833
|
-
api_version: string;
|
|
834
|
-
|
|
835
|
-
/**
|
|
836
|
-
* When the event was created
|
|
837
|
-
*/
|
|
838
|
-
created_at: string;
|
|
839
|
-
|
|
840
|
-
/**
|
|
841
|
-
* Payload for reaction.removed webhook events
|
|
842
|
-
*/
|
|
843
|
-
data: ReactionEventBase;
|
|
844
|
-
|
|
845
|
-
/**
|
|
846
|
-
* Unique identifier for this event (for deduplication)
|
|
847
|
-
*/
|
|
848
|
-
event_id: string;
|
|
849
|
-
|
|
850
|
-
/**
|
|
851
|
-
* Valid webhook event types that can be subscribed to.
|
|
852
|
-
*
|
|
853
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
854
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
855
|
-
* subscription will not produce any deliveries.
|
|
856
|
-
*/
|
|
857
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
858
|
-
|
|
859
|
-
/**
|
|
860
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
861
|
-
*/
|
|
862
|
-
partner_id: string;
|
|
863
|
-
|
|
864
|
-
/**
|
|
865
|
-
* Trace ID for debugging and correlation across systems.
|
|
866
|
-
*/
|
|
867
|
-
trace_id: string;
|
|
868
|
-
|
|
869
|
-
/**
|
|
870
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
871
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
872
|
-
* specified, defaults based on subscription creation date.
|
|
873
|
-
*/
|
|
874
|
-
webhook_version: string;
|
|
875
|
-
}
|
|
876
|
-
|
|
877
|
-
/**
|
|
878
|
-
* Complete webhook payload for participant.added events
|
|
879
|
-
*/
|
|
880
|
-
export interface ParticipantAddedV2026_02_03WebhookEvent {
|
|
881
|
-
/**
|
|
882
|
-
* API version for the webhook payload format
|
|
883
|
-
*/
|
|
884
|
-
api_version: string;
|
|
885
|
-
|
|
886
|
-
/**
|
|
887
|
-
* When the event was created
|
|
888
|
-
*/
|
|
889
|
-
created_at: string;
|
|
890
|
-
|
|
891
|
-
/**
|
|
892
|
-
* Payload for participant.added webhook events
|
|
893
|
-
*/
|
|
894
|
-
data: ParticipantAddedV2026_02_03WebhookEvent.Data;
|
|
895
|
-
|
|
896
|
-
/**
|
|
897
|
-
* Unique identifier for this event (for deduplication)
|
|
898
|
-
*/
|
|
899
|
-
event_id: string;
|
|
900
|
-
|
|
901
|
-
/**
|
|
902
|
-
* Valid webhook event types that can be subscribed to.
|
|
903
|
-
*
|
|
904
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
905
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
906
|
-
* subscription will not produce any deliveries.
|
|
907
|
-
*/
|
|
908
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
909
|
-
|
|
910
|
-
/**
|
|
911
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
912
|
-
*/
|
|
913
|
-
partner_id: string;
|
|
914
|
-
|
|
915
|
-
/**
|
|
916
|
-
* Trace ID for debugging and correlation across systems.
|
|
917
|
-
*/
|
|
918
|
-
trace_id: string;
|
|
919
|
-
|
|
920
|
-
/**
|
|
921
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
922
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
923
|
-
* specified, defaults based on subscription creation date.
|
|
924
|
-
*/
|
|
925
|
-
webhook_version: string;
|
|
926
|
-
}
|
|
927
|
-
|
|
928
|
-
export namespace ParticipantAddedV2026_02_03WebhookEvent {
|
|
929
|
-
/**
|
|
930
|
-
* Payload for participant.added webhook events
|
|
931
|
-
*/
|
|
932
|
-
export interface Data {
|
|
933
|
-
/**
|
|
934
|
-
* @deprecated DEPRECATED: Use participant instead. Handle (phone number or email
|
|
935
|
-
* address) of the added participant.
|
|
936
|
-
*/
|
|
937
|
-
handle: string;
|
|
938
|
-
|
|
939
|
-
/**
|
|
940
|
-
* When the participant was added
|
|
941
|
-
*/
|
|
942
|
-
added_at?: string;
|
|
943
|
-
|
|
944
|
-
/**
|
|
945
|
-
* Chat identifier (UUID) of the group chat
|
|
946
|
-
*/
|
|
947
|
-
chat_id?: string;
|
|
948
|
-
|
|
949
|
-
/**
|
|
950
|
-
* The added participant as a full handle object
|
|
951
|
-
*/
|
|
952
|
-
participant?: Shared.ChatHandle;
|
|
953
|
-
}
|
|
954
|
-
}
|
|
955
|
-
|
|
956
|
-
/**
|
|
957
|
-
* Complete webhook payload for participant.removed events
|
|
958
|
-
*/
|
|
959
|
-
export interface ParticipantRemovedV2026_02_03WebhookEvent {
|
|
960
|
-
/**
|
|
961
|
-
* API version for the webhook payload format
|
|
962
|
-
*/
|
|
963
|
-
api_version: string;
|
|
964
|
-
|
|
965
|
-
/**
|
|
966
|
-
* When the event was created
|
|
967
|
-
*/
|
|
968
|
-
created_at: string;
|
|
969
|
-
|
|
970
|
-
/**
|
|
971
|
-
* Payload for participant.removed webhook events
|
|
972
|
-
*/
|
|
973
|
-
data: ParticipantRemovedV2026_02_03WebhookEvent.Data;
|
|
974
|
-
|
|
975
|
-
/**
|
|
976
|
-
* Unique identifier for this event (for deduplication)
|
|
977
|
-
*/
|
|
978
|
-
event_id: string;
|
|
979
|
-
|
|
980
|
-
/**
|
|
981
|
-
* Valid webhook event types that can be subscribed to.
|
|
982
|
-
*
|
|
983
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
984
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
985
|
-
* subscription will not produce any deliveries.
|
|
986
|
-
*/
|
|
987
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
988
|
-
|
|
989
|
-
/**
|
|
990
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
991
|
-
*/
|
|
992
|
-
partner_id: string;
|
|
993
|
-
|
|
994
|
-
/**
|
|
995
|
-
* Trace ID for debugging and correlation across systems.
|
|
996
|
-
*/
|
|
997
|
-
trace_id: string;
|
|
998
|
-
|
|
999
|
-
/**
|
|
1000
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1001
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1002
|
-
* specified, defaults based on subscription creation date.
|
|
1003
|
-
*/
|
|
1004
|
-
webhook_version: string;
|
|
1005
|
-
}
|
|
1006
|
-
|
|
1007
|
-
export namespace ParticipantRemovedV2026_02_03WebhookEvent {
|
|
1008
|
-
/**
|
|
1009
|
-
* Payload for participant.removed webhook events
|
|
1010
|
-
*/
|
|
1011
|
-
export interface Data {
|
|
1012
|
-
/**
|
|
1013
|
-
* @deprecated DEPRECATED: Use participant instead. Handle (phone number or email
|
|
1014
|
-
* address) of the removed participant.
|
|
1015
|
-
*/
|
|
1016
|
-
handle: string;
|
|
1017
|
-
|
|
1018
|
-
/**
|
|
1019
|
-
* Chat identifier (UUID) of the group chat
|
|
1020
|
-
*/
|
|
1021
|
-
chat_id?: string;
|
|
1022
|
-
|
|
1023
|
-
/**
|
|
1024
|
-
* The removed participant as a full handle object
|
|
1025
|
-
*/
|
|
1026
|
-
participant?: Shared.ChatHandle;
|
|
1027
|
-
|
|
1028
|
-
/**
|
|
1029
|
-
* When the participant was removed
|
|
1030
|
-
*/
|
|
1031
|
-
removed_at?: string;
|
|
1032
|
-
}
|
|
1033
|
-
}
|
|
1034
|
-
|
|
1035
|
-
/**
|
|
1036
|
-
* Complete webhook payload for chat.group_name_updated events
|
|
1037
|
-
*/
|
|
1038
|
-
export interface ChatGroupNameUpdatedV2026_02_03WebhookEvent {
|
|
1039
|
-
/**
|
|
1040
|
-
* API version for the webhook payload format
|
|
1041
|
-
*/
|
|
1042
|
-
api_version: string;
|
|
1043
|
-
|
|
1044
|
-
/**
|
|
1045
|
-
* When the event was created
|
|
1046
|
-
*/
|
|
1047
|
-
created_at: string;
|
|
1048
|
-
|
|
1049
|
-
/**
|
|
1050
|
-
* Payload for chat.group_name_updated webhook events
|
|
1051
|
-
*/
|
|
1052
|
-
data: ChatGroupNameUpdatedV2026_02_03WebhookEvent.Data;
|
|
1053
|
-
|
|
1054
|
-
/**
|
|
1055
|
-
* Unique identifier for this event (for deduplication)
|
|
1056
|
-
*/
|
|
1057
|
-
event_id: string;
|
|
1058
|
-
|
|
1059
|
-
/**
|
|
1060
|
-
* Valid webhook event types that can be subscribed to.
|
|
1061
|
-
*
|
|
1062
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1063
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1064
|
-
* subscription will not produce any deliveries.
|
|
1065
|
-
*/
|
|
1066
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1067
|
-
|
|
1068
|
-
/**
|
|
1069
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1070
|
-
*/
|
|
1071
|
-
partner_id: string;
|
|
1072
|
-
|
|
1073
|
-
/**
|
|
1074
|
-
* Trace ID for debugging and correlation across systems.
|
|
1075
|
-
*/
|
|
1076
|
-
trace_id: string;
|
|
1077
|
-
|
|
1078
|
-
/**
|
|
1079
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1080
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1081
|
-
* specified, defaults based on subscription creation date.
|
|
1082
|
-
*/
|
|
1083
|
-
webhook_version: string;
|
|
1084
|
-
}
|
|
1085
|
-
|
|
1086
|
-
export namespace ChatGroupNameUpdatedV2026_02_03WebhookEvent {
|
|
1087
|
-
/**
|
|
1088
|
-
* Payload for chat.group_name_updated webhook events
|
|
1089
|
-
*/
|
|
1090
|
-
export interface Data {
|
|
1091
|
-
/**
|
|
1092
|
-
* Chat identifier (UUID) of the group chat
|
|
1093
|
-
*/
|
|
1094
|
-
chat_id: string;
|
|
1095
|
-
|
|
1096
|
-
/**
|
|
1097
|
-
* When the update occurred
|
|
1098
|
-
*/
|
|
1099
|
-
updated_at: string;
|
|
1100
|
-
|
|
1101
|
-
/**
|
|
1102
|
-
* The handle who made the change.
|
|
1103
|
-
*/
|
|
1104
|
-
changed_by_handle?: Shared.ChatHandle | null;
|
|
1105
|
-
|
|
1106
|
-
/**
|
|
1107
|
-
* New group name (null if the name was removed)
|
|
1108
|
-
*/
|
|
1109
|
-
new_value?: string | null;
|
|
1110
|
-
|
|
1111
|
-
/**
|
|
1112
|
-
* Previous group name (null if no previous name)
|
|
1113
|
-
*/
|
|
1114
|
-
old_value?: string | null;
|
|
1115
|
-
}
|
|
1116
|
-
}
|
|
1117
|
-
|
|
1118
|
-
/**
|
|
1119
|
-
* Complete webhook payload for chat.group_icon_updated events
|
|
1120
|
-
*/
|
|
1121
|
-
export interface ChatGroupIconUpdatedV2026_02_03WebhookEvent {
|
|
1122
|
-
/**
|
|
1123
|
-
* API version for the webhook payload format
|
|
1124
|
-
*/
|
|
1125
|
-
api_version: string;
|
|
1126
|
-
|
|
1127
|
-
/**
|
|
1128
|
-
* When the event was created
|
|
1129
|
-
*/
|
|
1130
|
-
created_at: string;
|
|
1131
|
-
|
|
1132
|
-
/**
|
|
1133
|
-
* Payload for chat.group_icon_updated webhook events
|
|
1134
|
-
*/
|
|
1135
|
-
data: ChatGroupIconUpdatedV2026_02_03WebhookEvent.Data;
|
|
1136
|
-
|
|
1137
|
-
/**
|
|
1138
|
-
* Unique identifier for this event (for deduplication)
|
|
1139
|
-
*/
|
|
1140
|
-
event_id: string;
|
|
1141
|
-
|
|
1142
|
-
/**
|
|
1143
|
-
* Valid webhook event types that can be subscribed to.
|
|
1144
|
-
*
|
|
1145
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1146
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1147
|
-
* subscription will not produce any deliveries.
|
|
1148
|
-
*/
|
|
1149
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1150
|
-
|
|
1151
|
-
/**
|
|
1152
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1153
|
-
*/
|
|
1154
|
-
partner_id: string;
|
|
1155
|
-
|
|
1156
|
-
/**
|
|
1157
|
-
* Trace ID for debugging and correlation across systems.
|
|
1158
|
-
*/
|
|
1159
|
-
trace_id: string;
|
|
1160
|
-
|
|
1161
|
-
/**
|
|
1162
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1163
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1164
|
-
* specified, defaults based on subscription creation date.
|
|
1165
|
-
*/
|
|
1166
|
-
webhook_version: string;
|
|
1167
|
-
}
|
|
1168
|
-
|
|
1169
|
-
export namespace ChatGroupIconUpdatedV2026_02_03WebhookEvent {
|
|
1170
|
-
/**
|
|
1171
|
-
* Payload for chat.group_icon_updated webhook events
|
|
1172
|
-
*/
|
|
1173
|
-
export interface Data {
|
|
1174
|
-
/**
|
|
1175
|
-
* Chat identifier (UUID) of the group chat
|
|
1176
|
-
*/
|
|
1177
|
-
chat_id: string;
|
|
1178
|
-
|
|
1179
|
-
/**
|
|
1180
|
-
* When the update occurred
|
|
1181
|
-
*/
|
|
1182
|
-
updated_at: string;
|
|
1183
|
-
|
|
1184
|
-
/**
|
|
1185
|
-
* The handle who made the change.
|
|
1186
|
-
*/
|
|
1187
|
-
changed_by_handle?: Shared.ChatHandle | null;
|
|
1188
|
-
|
|
1189
|
-
/**
|
|
1190
|
-
* New icon URL (null if the icon was removed)
|
|
1191
|
-
*/
|
|
1192
|
-
new_value?: string | null;
|
|
1193
|
-
|
|
1194
|
-
/**
|
|
1195
|
-
* Previous icon URL (null if no previous icon)
|
|
1196
|
-
*/
|
|
1197
|
-
old_value?: string | null;
|
|
1198
|
-
}
|
|
1199
|
-
}
|
|
1200
|
-
|
|
1201
|
-
/**
|
|
1202
|
-
* Complete webhook payload for chat.group_name_update_failed events
|
|
1203
|
-
*/
|
|
1204
|
-
export interface ChatGroupNameUpdateFailedV2026_02_03WebhookEvent {
|
|
1205
|
-
/**
|
|
1206
|
-
* API version for the webhook payload format
|
|
1207
|
-
*/
|
|
1208
|
-
api_version: string;
|
|
1209
|
-
|
|
1210
|
-
/**
|
|
1211
|
-
* When the event was created
|
|
1212
|
-
*/
|
|
1213
|
-
created_at: string;
|
|
1214
|
-
|
|
1215
|
-
/**
|
|
1216
|
-
* Error details for chat.group_name_update_failed webhook events. See
|
|
1217
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1218
|
-
* code reference.
|
|
1219
|
-
*/
|
|
1220
|
-
data: ChatGroupNameUpdateFailedV2026_02_03WebhookEvent.Data;
|
|
1221
|
-
|
|
1222
|
-
/**
|
|
1223
|
-
* Unique identifier for this event (for deduplication)
|
|
1224
|
-
*/
|
|
1225
|
-
event_id: string;
|
|
1226
|
-
|
|
1227
|
-
/**
|
|
1228
|
-
* Valid webhook event types that can be subscribed to.
|
|
1229
|
-
*
|
|
1230
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1231
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1232
|
-
* subscription will not produce any deliveries.
|
|
1233
|
-
*/
|
|
1234
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1235
|
-
|
|
1236
|
-
/**
|
|
1237
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1238
|
-
*/
|
|
1239
|
-
partner_id: string;
|
|
1240
|
-
|
|
1241
|
-
/**
|
|
1242
|
-
* Trace ID for debugging and correlation across systems.
|
|
1243
|
-
*/
|
|
1244
|
-
trace_id: string;
|
|
1245
|
-
|
|
1246
|
-
/**
|
|
1247
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1248
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1249
|
-
* specified, defaults based on subscription creation date.
|
|
1250
|
-
*/
|
|
1251
|
-
webhook_version: string;
|
|
1252
|
-
}
|
|
1253
|
-
|
|
1254
|
-
export namespace ChatGroupNameUpdateFailedV2026_02_03WebhookEvent {
|
|
1255
|
-
/**
|
|
1256
|
-
* Error details for chat.group_name_update_failed webhook events. See
|
|
1257
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1258
|
-
* code reference.
|
|
1259
|
-
*/
|
|
1260
|
-
export interface Data {
|
|
1261
|
-
/**
|
|
1262
|
-
* Chat identifier (UUID) of the group chat
|
|
1263
|
-
*/
|
|
1264
|
-
chat_id: string;
|
|
1265
|
-
|
|
1266
|
-
/**
|
|
1267
|
-
* Error codes in webhook failure events (3007, 4001).
|
|
1268
|
-
*/
|
|
1269
|
-
error_code: number;
|
|
1270
|
-
|
|
1271
|
-
/**
|
|
1272
|
-
* When the failure was detected
|
|
1273
|
-
*/
|
|
1274
|
-
failed_at: string;
|
|
1275
|
-
}
|
|
1276
|
-
}
|
|
1277
|
-
|
|
1278
|
-
/**
|
|
1279
|
-
* Complete webhook payload for chat.group_icon_update_failed events
|
|
1280
|
-
*/
|
|
1281
|
-
export interface ChatGroupIconUpdateFailedV2026_02_03WebhookEvent {
|
|
1282
|
-
/**
|
|
1283
|
-
* API version for the webhook payload format
|
|
1284
|
-
*/
|
|
1285
|
-
api_version: string;
|
|
1286
|
-
|
|
1287
|
-
/**
|
|
1288
|
-
* When the event was created
|
|
1289
|
-
*/
|
|
1290
|
-
created_at: string;
|
|
1291
|
-
|
|
1292
|
-
/**
|
|
1293
|
-
* Error details for chat.group_icon_update_failed webhook events. See
|
|
1294
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1295
|
-
* code reference.
|
|
1296
|
-
*/
|
|
1297
|
-
data: ChatGroupIconUpdateFailedV2026_02_03WebhookEvent.Data;
|
|
1298
|
-
|
|
1299
|
-
/**
|
|
1300
|
-
* Unique identifier for this event (for deduplication)
|
|
1301
|
-
*/
|
|
1302
|
-
event_id: string;
|
|
1303
|
-
|
|
1304
|
-
/**
|
|
1305
|
-
* Valid webhook event types that can be subscribed to.
|
|
1306
|
-
*
|
|
1307
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1308
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1309
|
-
* subscription will not produce any deliveries.
|
|
1310
|
-
*/
|
|
1311
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1312
|
-
|
|
1313
|
-
/**
|
|
1314
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1315
|
-
*/
|
|
1316
|
-
partner_id: string;
|
|
1317
|
-
|
|
1318
|
-
/**
|
|
1319
|
-
* Trace ID for debugging and correlation across systems.
|
|
1320
|
-
*/
|
|
1321
|
-
trace_id: string;
|
|
1322
|
-
|
|
1323
|
-
/**
|
|
1324
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1325
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1326
|
-
* specified, defaults based on subscription creation date.
|
|
1327
|
-
*/
|
|
1328
|
-
webhook_version: string;
|
|
1329
|
-
}
|
|
1330
|
-
|
|
1331
|
-
export namespace ChatGroupIconUpdateFailedV2026_02_03WebhookEvent {
|
|
1332
|
-
/**
|
|
1333
|
-
* Error details for chat.group_icon_update_failed webhook events. See
|
|
1334
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1335
|
-
* code reference.
|
|
1336
|
-
*/
|
|
1337
|
-
export interface Data {
|
|
1338
|
-
/**
|
|
1339
|
-
* Chat identifier (UUID) of the group chat
|
|
1340
|
-
*/
|
|
1341
|
-
chat_id: string;
|
|
1342
|
-
|
|
1343
|
-
/**
|
|
1344
|
-
* Error codes in webhook failure events (3007, 4001).
|
|
1345
|
-
*/
|
|
1346
|
-
error_code: number;
|
|
1347
|
-
|
|
1348
|
-
/**
|
|
1349
|
-
* When the failure was detected
|
|
1350
|
-
*/
|
|
1351
|
-
failed_at: string;
|
|
1352
|
-
}
|
|
1353
|
-
}
|
|
1354
|
-
|
|
1355
|
-
/**
|
|
1356
|
-
* Complete webhook payload for chat.created events
|
|
1357
|
-
*/
|
|
1358
|
-
export interface ChatCreatedV2026_02_03WebhookEvent {
|
|
1359
|
-
/**
|
|
1360
|
-
* API version for the webhook payload format
|
|
1361
|
-
*/
|
|
1362
|
-
api_version: string;
|
|
1363
|
-
|
|
1364
|
-
/**
|
|
1365
|
-
* When the event was created
|
|
1366
|
-
*/
|
|
1367
|
-
created_at: string;
|
|
1368
|
-
|
|
1369
|
-
/**
|
|
1370
|
-
* Payload for chat.created webhook events. Matches GET /v3/chats/{chatId}
|
|
1371
|
-
* response.
|
|
1372
|
-
*/
|
|
1373
|
-
data: ChatCreatedV2026_02_03WebhookEvent.Data;
|
|
1374
|
-
|
|
1375
|
-
/**
|
|
1376
|
-
* Unique identifier for this event (for deduplication)
|
|
1377
|
-
*/
|
|
1378
|
-
event_id: string;
|
|
1379
|
-
|
|
1380
|
-
/**
|
|
1381
|
-
* Valid webhook event types that can be subscribed to.
|
|
1382
|
-
*
|
|
1383
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1384
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1385
|
-
* subscription will not produce any deliveries.
|
|
1386
|
-
*/
|
|
1387
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1388
|
-
|
|
1389
|
-
/**
|
|
1390
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1391
|
-
*/
|
|
1392
|
-
partner_id: string;
|
|
1393
|
-
|
|
1394
|
-
/**
|
|
1395
|
-
* Trace ID for debugging and correlation across systems.
|
|
1396
|
-
*/
|
|
1397
|
-
trace_id: string;
|
|
1398
|
-
|
|
1399
|
-
/**
|
|
1400
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1401
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1402
|
-
* specified, defaults based on subscription creation date.
|
|
1403
|
-
*/
|
|
1404
|
-
webhook_version: string;
|
|
1405
|
-
}
|
|
1406
|
-
|
|
1407
|
-
export namespace ChatCreatedV2026_02_03WebhookEvent {
|
|
1408
|
-
/**
|
|
1409
|
-
* Payload for chat.created webhook events. Matches GET /v3/chats/{chatId}
|
|
1410
|
-
* response.
|
|
1411
|
-
*/
|
|
1412
|
-
export interface Data {
|
|
1413
|
-
/**
|
|
1414
|
-
* Unique identifier for the chat
|
|
1415
|
-
*/
|
|
1416
|
-
id: string;
|
|
1417
|
-
|
|
1418
|
-
/**
|
|
1419
|
-
* When the chat was created
|
|
1420
|
-
*/
|
|
1421
|
-
created_at: string;
|
|
1422
|
-
|
|
1423
|
-
/**
|
|
1424
|
-
* Display name for the chat. Defaults to a comma-separated list of recipient
|
|
1425
|
-
* handles. Can be updated for group chats.
|
|
1426
|
-
*/
|
|
1427
|
-
display_name: string | null;
|
|
1428
|
-
|
|
1429
|
-
/**
|
|
1430
|
-
* List of chat participants with full handle details. Always contains at least two
|
|
1431
|
-
* handles (your phone number and the other participant).
|
|
1432
|
-
*/
|
|
1433
|
-
handles: Array<Shared.ChatHandle>;
|
|
1434
|
-
|
|
1435
|
-
/**
|
|
1436
|
-
* Whether this is a group chat
|
|
1437
|
-
*/
|
|
1438
|
-
is_group: boolean;
|
|
1439
|
-
|
|
1440
|
-
/**
|
|
1441
|
-
* When the chat was last updated
|
|
1442
|
-
*/
|
|
1443
|
-
updated_at: string;
|
|
1444
|
-
|
|
1445
|
-
/**
|
|
1446
|
-
* Messaging service type
|
|
1447
|
-
*/
|
|
1448
|
-
service?: Shared.ServiceType | null;
|
|
1449
|
-
}
|
|
1450
|
-
}
|
|
1451
|
-
|
|
1452
|
-
/**
|
|
1453
|
-
* Complete webhook payload for chat.typing_indicator.started events
|
|
1454
|
-
*/
|
|
1455
|
-
export interface ChatTypingIndicatorStartedV2026_02_03WebhookEvent {
|
|
1456
|
-
/**
|
|
1457
|
-
* API version for the webhook payload format
|
|
1458
|
-
*/
|
|
1459
|
-
api_version: string;
|
|
1460
|
-
|
|
1461
|
-
/**
|
|
1462
|
-
* When the event was created
|
|
1463
|
-
*/
|
|
1464
|
-
created_at: string;
|
|
1465
|
-
|
|
1466
|
-
/**
|
|
1467
|
-
* Payload for chat.typing_indicator.started webhook events
|
|
1468
|
-
*/
|
|
1469
|
-
data: ChatTypingIndicatorStartedV2026_02_03WebhookEvent.Data;
|
|
1470
|
-
|
|
1471
|
-
/**
|
|
1472
|
-
* Unique identifier for this event (for deduplication)
|
|
1473
|
-
*/
|
|
1474
|
-
event_id: string;
|
|
1475
|
-
|
|
1476
|
-
/**
|
|
1477
|
-
* Valid webhook event types that can be subscribed to.
|
|
1478
|
-
*
|
|
1479
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1480
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1481
|
-
* subscription will not produce any deliveries.
|
|
1482
|
-
*/
|
|
1483
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1484
|
-
|
|
1485
|
-
/**
|
|
1486
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1487
|
-
*/
|
|
1488
|
-
partner_id: string;
|
|
1489
|
-
|
|
1490
|
-
/**
|
|
1491
|
-
* Trace ID for debugging and correlation across systems.
|
|
1492
|
-
*/
|
|
1493
|
-
trace_id: string;
|
|
1494
|
-
|
|
1495
|
-
/**
|
|
1496
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1497
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1498
|
-
* specified, defaults based on subscription creation date.
|
|
1499
|
-
*/
|
|
1500
|
-
webhook_version: string;
|
|
1501
|
-
}
|
|
1502
|
-
|
|
1503
|
-
export namespace ChatTypingIndicatorStartedV2026_02_03WebhookEvent {
|
|
1504
|
-
/**
|
|
1505
|
-
* Payload for chat.typing_indicator.started webhook events
|
|
1506
|
-
*/
|
|
1507
|
-
export interface Data {
|
|
1508
|
-
/**
|
|
1509
|
-
* Chat identifier
|
|
1510
|
-
*/
|
|
1511
|
-
chat_id: string;
|
|
1512
|
-
}
|
|
1513
|
-
}
|
|
1514
|
-
|
|
1515
|
-
/**
|
|
1516
|
-
* Complete webhook payload for chat.typing_indicator.stopped events
|
|
1517
|
-
*/
|
|
1518
|
-
export interface ChatTypingIndicatorStoppedV2026_02_03WebhookEvent {
|
|
1519
|
-
/**
|
|
1520
|
-
* API version for the webhook payload format
|
|
1521
|
-
*/
|
|
1522
|
-
api_version: string;
|
|
1523
|
-
|
|
1524
|
-
/**
|
|
1525
|
-
* When the event was created
|
|
1526
|
-
*/
|
|
1527
|
-
created_at: string;
|
|
1528
|
-
|
|
1529
|
-
/**
|
|
1530
|
-
* Payload for chat.typing_indicator.stopped webhook events
|
|
1531
|
-
*/
|
|
1532
|
-
data: ChatTypingIndicatorStoppedV2026_02_03WebhookEvent.Data;
|
|
1533
|
-
|
|
1534
|
-
/**
|
|
1535
|
-
* Unique identifier for this event (for deduplication)
|
|
1536
|
-
*/
|
|
1537
|
-
event_id: string;
|
|
1538
|
-
|
|
1539
|
-
/**
|
|
1540
|
-
* Valid webhook event types that can be subscribed to.
|
|
1541
|
-
*
|
|
1542
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1543
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1544
|
-
* subscription will not produce any deliveries.
|
|
1545
|
-
*/
|
|
1546
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1547
|
-
|
|
1548
|
-
/**
|
|
1549
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1550
|
-
*/
|
|
1551
|
-
partner_id: string;
|
|
1552
|
-
|
|
1553
|
-
/**
|
|
1554
|
-
* Trace ID for debugging and correlation across systems.
|
|
1555
|
-
*/
|
|
1556
|
-
trace_id: string;
|
|
1557
|
-
|
|
1558
|
-
/**
|
|
1559
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1560
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1561
|
-
* specified, defaults based on subscription creation date.
|
|
1562
|
-
*/
|
|
1563
|
-
webhook_version: string;
|
|
1564
|
-
}
|
|
1565
|
-
|
|
1566
|
-
export namespace ChatTypingIndicatorStoppedV2026_02_03WebhookEvent {
|
|
1567
|
-
/**
|
|
1568
|
-
* Payload for chat.typing_indicator.stopped webhook events
|
|
1569
|
-
*/
|
|
1570
|
-
export interface Data {
|
|
1571
|
-
/**
|
|
1572
|
-
* Chat identifier
|
|
1573
|
-
*/
|
|
1574
|
-
chat_id: string;
|
|
1575
|
-
}
|
|
1576
|
-
}
|
|
1577
|
-
|
|
1578
|
-
/**
|
|
1579
|
-
* Complete webhook payload for message.edited events (2026-02-03 format only)
|
|
1580
|
-
*/
|
|
1581
|
-
export interface MessageEditedV2026_02_03WebhookEvent {
|
|
1582
|
-
/**
|
|
1583
|
-
* API version for the webhook payload format
|
|
1584
|
-
*/
|
|
1585
|
-
api_version: string;
|
|
1586
|
-
|
|
1587
|
-
/**
|
|
1588
|
-
* When the event was created
|
|
1589
|
-
*/
|
|
1590
|
-
created_at: string;
|
|
1591
|
-
|
|
1592
|
-
/**
|
|
1593
|
-
* Payload for `message.edited` events (2026-02-03 format).
|
|
1594
|
-
*
|
|
1595
|
-
* Describes which part of a message was edited and when. Only text parts can be
|
|
1596
|
-
* edited. Only available for subscriptions using `webhook_version: "2026-02-03"`.
|
|
1597
|
-
*/
|
|
1598
|
-
data: MessageEditedV2026_02_03WebhookEvent.Data;
|
|
1599
|
-
|
|
1600
|
-
/**
|
|
1601
|
-
* Unique identifier for this event (for deduplication)
|
|
1602
|
-
*/
|
|
1603
|
-
event_id: string;
|
|
1604
|
-
|
|
1605
|
-
/**
|
|
1606
|
-
* Valid webhook event types that can be subscribed to.
|
|
1607
|
-
*
|
|
1608
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1609
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1610
|
-
* subscription will not produce any deliveries.
|
|
1611
|
-
*/
|
|
1612
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1613
|
-
|
|
1614
|
-
/**
|
|
1615
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1616
|
-
*/
|
|
1617
|
-
partner_id: string;
|
|
1618
|
-
|
|
1619
|
-
/**
|
|
1620
|
-
* Trace ID for debugging and correlation across systems.
|
|
1621
|
-
*/
|
|
1622
|
-
trace_id: string;
|
|
1623
|
-
|
|
1624
|
-
/**
|
|
1625
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1626
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1627
|
-
* specified, defaults based on subscription creation date.
|
|
1628
|
-
*/
|
|
1629
|
-
webhook_version: string;
|
|
1630
|
-
}
|
|
1631
|
-
|
|
1632
|
-
export namespace MessageEditedV2026_02_03WebhookEvent {
|
|
1633
|
-
/**
|
|
1634
|
-
* Payload for `message.edited` events (2026-02-03 format).
|
|
1635
|
-
*
|
|
1636
|
-
* Describes which part of a message was edited and when. Only text parts can be
|
|
1637
|
-
* edited. Only available for subscriptions using `webhook_version: "2026-02-03"`.
|
|
1638
|
-
*/
|
|
1639
|
-
export interface Data {
|
|
1640
|
-
/**
|
|
1641
|
-
* Message identifier
|
|
1642
|
-
*/
|
|
1643
|
-
id: string;
|
|
1644
|
-
|
|
1645
|
-
/**
|
|
1646
|
-
* Chat context
|
|
1647
|
-
*/
|
|
1648
|
-
chat: Data.Chat;
|
|
1649
|
-
|
|
1650
|
-
/**
|
|
1651
|
-
* "outbound" if you sent the original message, "inbound" if you received it
|
|
1652
|
-
*/
|
|
1653
|
-
direction: 'outbound' | 'inbound';
|
|
1654
|
-
|
|
1655
|
-
/**
|
|
1656
|
-
* When the edit occurred
|
|
1657
|
-
*/
|
|
1658
|
-
edited_at: string;
|
|
1659
|
-
|
|
1660
|
-
/**
|
|
1661
|
-
* The edited part
|
|
1662
|
-
*/
|
|
1663
|
-
part: Data.Part;
|
|
1664
|
-
|
|
1665
|
-
/**
|
|
1666
|
-
* The handle that sent (and edited) this message
|
|
1667
|
-
*/
|
|
1668
|
-
sender_handle: Shared.ChatHandle;
|
|
1669
|
-
}
|
|
1670
|
-
|
|
1671
|
-
export namespace Data {
|
|
1672
|
-
/**
|
|
1673
|
-
* Chat context
|
|
1674
|
-
*/
|
|
1675
|
-
export interface Chat {
|
|
1676
|
-
/**
|
|
1677
|
-
* Chat identifier
|
|
1678
|
-
*/
|
|
1679
|
-
id: string;
|
|
1680
|
-
|
|
1681
|
-
/**
|
|
1682
|
-
* Whether this is a group chat
|
|
1683
|
-
*/
|
|
1684
|
-
is_group: boolean;
|
|
1685
|
-
|
|
1686
|
-
/**
|
|
1687
|
-
* The handle that owns this chat (your phone number)
|
|
1688
|
-
*/
|
|
1689
|
-
owner_handle: Shared.ChatHandle;
|
|
1690
|
-
}
|
|
1691
|
-
|
|
1692
|
-
/**
|
|
1693
|
-
* The edited part
|
|
1694
|
-
*/
|
|
1695
|
-
export interface Part {
|
|
1696
|
-
/**
|
|
1697
|
-
* Zero-based index of the edited part within the message
|
|
1698
|
-
*/
|
|
1699
|
-
index: number;
|
|
1700
|
-
|
|
1701
|
-
/**
|
|
1702
|
-
* New text content of the part
|
|
1703
|
-
*/
|
|
1704
|
-
text: string;
|
|
1705
|
-
}
|
|
1706
|
-
}
|
|
1707
|
-
}
|
|
1708
|
-
|
|
1709
|
-
/**
|
|
1710
|
-
* Complete webhook payload for phone_number.status_updated events
|
|
1711
|
-
*/
|
|
1712
|
-
export interface PhoneNumberStatusUpdatedV2026_02_03WebhookEvent {
|
|
1713
|
-
/**
|
|
1714
|
-
* API version for the webhook payload format
|
|
1715
|
-
*/
|
|
1716
|
-
api_version: string;
|
|
1717
|
-
|
|
1718
|
-
/**
|
|
1719
|
-
* When the event was created
|
|
1720
|
-
*/
|
|
1721
|
-
created_at: string;
|
|
1722
|
-
|
|
1723
|
-
/**
|
|
1724
|
-
* Payload for phone_number.status_updated webhook events
|
|
1725
|
-
*/
|
|
1726
|
-
data: PhoneNumberStatusUpdatedV2026_02_03WebhookEvent.Data;
|
|
1727
|
-
|
|
1728
|
-
/**
|
|
1729
|
-
* Unique identifier for this event (for deduplication)
|
|
1730
|
-
*/
|
|
1731
|
-
event_id: string;
|
|
1732
|
-
|
|
1733
|
-
/**
|
|
1734
|
-
* The type of event
|
|
1735
|
-
*/
|
|
1736
|
-
event_type:
|
|
1737
|
-
| 'message.sent'
|
|
1738
|
-
| 'message.received'
|
|
1739
|
-
| 'message.read'
|
|
1740
|
-
| 'message.delivered'
|
|
1741
|
-
| 'message.failed'
|
|
1742
|
-
| 'message.edited'
|
|
1743
|
-
| 'reaction.added'
|
|
1744
|
-
| 'reaction.removed'
|
|
1745
|
-
| 'participant.added'
|
|
1746
|
-
| 'participant.removed'
|
|
1747
|
-
| 'chat.created'
|
|
1748
|
-
| 'chat.group_name_updated'
|
|
1749
|
-
| 'chat.group_icon_updated'
|
|
1750
|
-
| 'chat.group_name_update_failed'
|
|
1751
|
-
| 'chat.group_icon_update_failed'
|
|
1752
|
-
| 'chat.typing_indicator.started'
|
|
1753
|
-
| 'chat.typing_indicator.stopped'
|
|
1754
|
-
| 'phone_number.status_updated'
|
|
1755
|
-
| 'call.initiated'
|
|
1756
|
-
| 'call.ringing'
|
|
1757
|
-
| 'call.answered'
|
|
1758
|
-
| 'call.ended'
|
|
1759
|
-
| 'call.failed'
|
|
1760
|
-
| 'call.declined'
|
|
1761
|
-
| 'call.no_answer';
|
|
1762
|
-
|
|
1763
|
-
/**
|
|
1764
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1765
|
-
*/
|
|
1766
|
-
partner_id: string;
|
|
1767
|
-
|
|
1768
|
-
/**
|
|
1769
|
-
* Trace ID for debugging and correlation across systems.
|
|
1770
|
-
*/
|
|
1771
|
-
trace_id: string;
|
|
1772
|
-
|
|
1773
|
-
/**
|
|
1774
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1775
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1776
|
-
* specified, defaults based on subscription creation date.
|
|
1777
|
-
*/
|
|
1778
|
-
webhook_version: string;
|
|
1779
|
-
}
|
|
1780
|
-
|
|
1781
|
-
export namespace PhoneNumberStatusUpdatedV2026_02_03WebhookEvent {
|
|
1782
|
-
/**
|
|
1783
|
-
* Payload for phone_number.status_updated webhook events
|
|
1784
|
-
*/
|
|
1785
|
-
export interface Data {
|
|
1786
|
-
/**
|
|
1787
|
-
* When the status change occurred
|
|
1788
|
-
*/
|
|
1789
|
-
changed_at: string;
|
|
1790
|
-
|
|
1791
|
-
/**
|
|
1792
|
-
* The new service status
|
|
1793
|
-
*/
|
|
1794
|
-
new_status: 'ACTIVE' | 'FLAGGED';
|
|
1795
|
-
|
|
1796
|
-
/**
|
|
1797
|
-
* Phone number in E.164 format
|
|
1798
|
-
*/
|
|
1799
|
-
phone_number: string;
|
|
1800
|
-
|
|
1801
|
-
/**
|
|
1802
|
-
* The previous service status
|
|
1803
|
-
*/
|
|
1804
|
-
previous_status: 'ACTIVE' | 'FLAGGED';
|
|
1805
|
-
}
|
|
1806
|
-
}
|
|
1807
|
-
|
|
1808
|
-
/**
|
|
1809
|
-
* Complete webhook payload for message.sent events (2025-01-01 format)
|
|
1810
|
-
*/
|
|
1811
|
-
export interface MessageSentV2025_01_01WebhookEvent {
|
|
1812
|
-
/**
|
|
1813
|
-
* API version for the webhook payload format
|
|
1814
|
-
*/
|
|
1815
|
-
api_version: string;
|
|
1816
|
-
|
|
1817
|
-
/**
|
|
1818
|
-
* When the event was created
|
|
1819
|
-
*/
|
|
1820
|
-
created_at: string;
|
|
1821
|
-
|
|
1822
|
-
/**
|
|
1823
|
-
* Unified payload for message.sent and message.received webhook events (2025-01-01
|
|
1824
|
-
* format)
|
|
1825
|
-
*/
|
|
1826
|
-
data: MessageSentV2025_01_01WebhookEvent.Data;
|
|
1827
|
-
|
|
1828
|
-
/**
|
|
1829
|
-
* Unique identifier for this event (for deduplication)
|
|
1830
|
-
*/
|
|
1831
|
-
event_id: string;
|
|
1832
|
-
|
|
1833
|
-
/**
|
|
1834
|
-
* Valid webhook event types that can be subscribed to.
|
|
1835
|
-
*
|
|
1836
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1837
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1838
|
-
* subscription will not produce any deliveries.
|
|
1839
|
-
*/
|
|
1840
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1841
|
-
|
|
1842
|
-
/**
|
|
1843
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1844
|
-
*/
|
|
1845
|
-
partner_id: string;
|
|
1846
|
-
|
|
1847
|
-
/**
|
|
1848
|
-
* Trace ID for debugging and correlation across systems.
|
|
1849
|
-
*/
|
|
1850
|
-
trace_id: string;
|
|
1851
|
-
|
|
1852
|
-
/**
|
|
1853
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1854
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1855
|
-
* specified, defaults based on subscription creation date.
|
|
1856
|
-
*/
|
|
1857
|
-
webhook_version: string;
|
|
1858
|
-
}
|
|
1859
|
-
|
|
1860
|
-
export namespace MessageSentV2025_01_01WebhookEvent {
|
|
1861
|
-
/**
|
|
1862
|
-
* Unified payload for message.sent and message.received webhook events (2025-01-01
|
|
1863
|
-
* format)
|
|
1864
|
-
*/
|
|
1865
|
-
export interface Data {
|
|
1866
|
-
/**
|
|
1867
|
-
* Chat identifier
|
|
1868
|
-
*/
|
|
1869
|
-
chat_id?: string;
|
|
1870
|
-
|
|
1871
|
-
/**
|
|
1872
|
-
* @deprecated DEPRECATED: Use from_handle instead. Phone number or email address
|
|
1873
|
-
* of the message sender.
|
|
1874
|
-
*/
|
|
1875
|
-
from?: string;
|
|
1876
|
-
|
|
1877
|
-
/**
|
|
1878
|
-
* The sender of this message as a full handle object
|
|
1879
|
-
*/
|
|
1880
|
-
from_handle?: Shared.ChatHandle;
|
|
1881
|
-
|
|
1882
|
-
/**
|
|
1883
|
-
* Idempotency key for the message. Used for deduplication of outbound messages.
|
|
1884
|
-
*/
|
|
1885
|
-
idempotency_key?: string | null;
|
|
1886
|
-
|
|
1887
|
-
/**
|
|
1888
|
-
* Whether the message was sent by us (true for sent events, false for received
|
|
1889
|
-
* events)
|
|
1890
|
-
*/
|
|
1891
|
-
is_from_me?: boolean;
|
|
1892
|
-
|
|
1893
|
-
/**
|
|
1894
|
-
* Whether this is a group chat
|
|
1895
|
-
*/
|
|
1896
|
-
is_group?: boolean;
|
|
1897
|
-
|
|
1898
|
-
/**
|
|
1899
|
-
* Message content nested within webhook events
|
|
1900
|
-
*/
|
|
1901
|
-
message?: WebhooksAPI.MessagePayload;
|
|
1902
|
-
|
|
1903
|
-
/**
|
|
1904
|
-
* Preferred messaging service type. Includes "auto" for default fallback behavior.
|
|
1905
|
-
*/
|
|
1906
|
-
preferred_service?: 'iMessage' | 'SMS' | 'RCS' | 'auto' | null;
|
|
1907
|
-
|
|
1908
|
-
/**
|
|
1909
|
-
* When the message was received. Null for sent events.
|
|
1910
|
-
*/
|
|
1911
|
-
received_at?: string | null;
|
|
1912
|
-
|
|
1913
|
-
/**
|
|
1914
|
-
* Our phone number that received the message as a full handle object. Null for
|
|
1915
|
-
* sent events.
|
|
1916
|
-
*/
|
|
1917
|
-
recipient_handle?: Shared.ChatHandle | null;
|
|
1918
|
-
|
|
1919
|
-
/**
|
|
1920
|
-
* @deprecated DEPRECATED: Use recipient_handle instead. Our phone number that
|
|
1921
|
-
* received the message. Null for sent events.
|
|
1922
|
-
*/
|
|
1923
|
-
recipient_phone?: string | null;
|
|
1924
|
-
|
|
1925
|
-
/**
|
|
1926
|
-
* Messaging service type
|
|
1927
|
-
*/
|
|
1928
|
-
service?: Shared.ServiceType | null;
|
|
1929
|
-
}
|
|
1930
|
-
}
|
|
1931
|
-
|
|
1932
|
-
/**
|
|
1933
|
-
* Complete webhook payload for message.received events (2025-01-01 format)
|
|
1934
|
-
*/
|
|
1935
|
-
export interface MessageReceivedV2025_01_01WebhookEvent {
|
|
1936
|
-
/**
|
|
1937
|
-
* API version for the webhook payload format
|
|
1938
|
-
*/
|
|
1939
|
-
api_version: string;
|
|
1940
|
-
|
|
1941
|
-
/**
|
|
1942
|
-
* When the event was created
|
|
1943
|
-
*/
|
|
1944
|
-
created_at: string;
|
|
1945
|
-
|
|
1946
|
-
/**
|
|
1947
|
-
* Unified payload for message.sent and message.received webhook events (2025-01-01
|
|
1948
|
-
* format)
|
|
1949
|
-
*/
|
|
1950
|
-
data: MessageReceivedV2025_01_01WebhookEvent.Data;
|
|
1951
|
-
|
|
1952
|
-
/**
|
|
1953
|
-
* Unique identifier for this event (for deduplication)
|
|
1954
|
-
*/
|
|
1955
|
-
event_id: string;
|
|
1956
|
-
|
|
1957
|
-
/**
|
|
1958
|
-
* Valid webhook event types that can be subscribed to.
|
|
1959
|
-
*
|
|
1960
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
1961
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
1962
|
-
* subscription will not produce any deliveries.
|
|
1963
|
-
*/
|
|
1964
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
1965
|
-
|
|
1966
|
-
/**
|
|
1967
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
1968
|
-
*/
|
|
1969
|
-
partner_id: string;
|
|
1970
|
-
|
|
1971
|
-
/**
|
|
1972
|
-
* Trace ID for debugging and correlation across systems.
|
|
1973
|
-
*/
|
|
1974
|
-
trace_id: string;
|
|
1975
|
-
|
|
1976
|
-
/**
|
|
1977
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
1978
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
1979
|
-
* specified, defaults based on subscription creation date.
|
|
1980
|
-
*/
|
|
1981
|
-
webhook_version: string;
|
|
1982
|
-
}
|
|
1983
|
-
|
|
1984
|
-
export namespace MessageReceivedV2025_01_01WebhookEvent {
|
|
1985
|
-
/**
|
|
1986
|
-
* Unified payload for message.sent and message.received webhook events (2025-01-01
|
|
1987
|
-
* format)
|
|
1988
|
-
*/
|
|
1989
|
-
export interface Data {
|
|
1990
|
-
/**
|
|
1991
|
-
* Chat identifier
|
|
1992
|
-
*/
|
|
1993
|
-
chat_id?: string;
|
|
1994
|
-
|
|
1995
|
-
/**
|
|
1996
|
-
* @deprecated DEPRECATED: Use from_handle instead. Phone number or email address
|
|
1997
|
-
* of the message sender.
|
|
1998
|
-
*/
|
|
1999
|
-
from?: string;
|
|
2000
|
-
|
|
2001
|
-
/**
|
|
2002
|
-
* The sender of this message as a full handle object
|
|
2003
|
-
*/
|
|
2004
|
-
from_handle?: Shared.ChatHandle;
|
|
2005
|
-
|
|
2006
|
-
/**
|
|
2007
|
-
* Idempotency key for the message. Used for deduplication of outbound messages.
|
|
2008
|
-
*/
|
|
2009
|
-
idempotency_key?: string | null;
|
|
2010
|
-
|
|
2011
|
-
/**
|
|
2012
|
-
* Whether the message was sent by us (true for sent events, false for received
|
|
2013
|
-
* events)
|
|
2014
|
-
*/
|
|
2015
|
-
is_from_me?: boolean;
|
|
2016
|
-
|
|
2017
|
-
/**
|
|
2018
|
-
* Whether this is a group chat
|
|
2019
|
-
*/
|
|
2020
|
-
is_group?: boolean;
|
|
2021
|
-
|
|
2022
|
-
/**
|
|
2023
|
-
* Message content nested within webhook events
|
|
2024
|
-
*/
|
|
2025
|
-
message?: WebhooksAPI.MessagePayload;
|
|
2026
|
-
|
|
2027
|
-
/**
|
|
2028
|
-
* Preferred messaging service type. Includes "auto" for default fallback behavior.
|
|
2029
|
-
*/
|
|
2030
|
-
preferred_service?: 'iMessage' | 'SMS' | 'RCS' | 'auto' | null;
|
|
2031
|
-
|
|
2032
|
-
/**
|
|
2033
|
-
* When the message was received. Null for sent events.
|
|
2034
|
-
*/
|
|
2035
|
-
received_at?: string | null;
|
|
2036
|
-
|
|
2037
|
-
/**
|
|
2038
|
-
* Our phone number that received the message as a full handle object. Null for
|
|
2039
|
-
* sent events.
|
|
2040
|
-
*/
|
|
2041
|
-
recipient_handle?: Shared.ChatHandle | null;
|
|
2042
|
-
|
|
2043
|
-
/**
|
|
2044
|
-
* @deprecated DEPRECATED: Use recipient_handle instead. Our phone number that
|
|
2045
|
-
* received the message. Null for sent events.
|
|
2046
|
-
*/
|
|
2047
|
-
recipient_phone?: string | null;
|
|
2048
|
-
|
|
2049
|
-
/**
|
|
2050
|
-
* Messaging service type
|
|
2051
|
-
*/
|
|
2052
|
-
service?: Shared.ServiceType | null;
|
|
2053
|
-
}
|
|
2054
|
-
}
|
|
2055
|
-
|
|
2056
|
-
/**
|
|
2057
|
-
* Complete webhook payload for message.read events (2025-01-01 format)
|
|
2058
|
-
*/
|
|
2059
|
-
export interface MessageReadV2025_01_01WebhookEvent {
|
|
2060
|
-
/**
|
|
2061
|
-
* API version for the webhook payload format
|
|
2062
|
-
*/
|
|
2063
|
-
api_version: string;
|
|
2064
|
-
|
|
2065
|
-
/**
|
|
2066
|
-
* When the event was created
|
|
2067
|
-
*/
|
|
2068
|
-
created_at: string;
|
|
2069
|
-
|
|
2070
|
-
/**
|
|
2071
|
-
* Payload for message.read webhook events (2025-01-01 format). Extends
|
|
2072
|
-
* MessageEvent with read_at and message_id.
|
|
2073
|
-
*/
|
|
2074
|
-
data: MessageReadV2025_01_01WebhookEvent.Data;
|
|
2075
|
-
|
|
2076
|
-
/**
|
|
2077
|
-
* Unique identifier for this event (for deduplication)
|
|
2078
|
-
*/
|
|
2079
|
-
event_id: string;
|
|
2080
|
-
|
|
2081
|
-
/**
|
|
2082
|
-
* Valid webhook event types that can be subscribed to.
|
|
2083
|
-
*
|
|
2084
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
2085
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
2086
|
-
* subscription will not produce any deliveries.
|
|
2087
|
-
*/
|
|
2088
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
2089
|
-
|
|
2090
|
-
/**
|
|
2091
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
2092
|
-
*/
|
|
2093
|
-
partner_id: string;
|
|
2094
|
-
|
|
2095
|
-
/**
|
|
2096
|
-
* Trace ID for debugging and correlation across systems.
|
|
2097
|
-
*/
|
|
2098
|
-
trace_id: string;
|
|
2099
|
-
|
|
2100
|
-
/**
|
|
2101
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
2102
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
2103
|
-
* specified, defaults based on subscription creation date.
|
|
2104
|
-
*/
|
|
2105
|
-
webhook_version: string;
|
|
2106
|
-
}
|
|
2107
|
-
|
|
2108
|
-
export namespace MessageReadV2025_01_01WebhookEvent {
|
|
2109
|
-
/**
|
|
2110
|
-
* Payload for message.read webhook events (2025-01-01 format). Extends
|
|
2111
|
-
* MessageEvent with read_at and message_id.
|
|
2112
|
-
*/
|
|
2113
|
-
export interface Data {
|
|
2114
|
-
/**
|
|
2115
|
-
* When the message was read
|
|
2116
|
-
*/
|
|
2117
|
-
read_at: string;
|
|
2118
|
-
|
|
2119
|
-
/**
|
|
2120
|
-
* Chat identifier
|
|
2121
|
-
*/
|
|
2122
|
-
chat_id?: string;
|
|
2123
|
-
|
|
2124
|
-
/**
|
|
2125
|
-
* @deprecated DEPRECATED: Use from_handle instead. Phone number or email address
|
|
2126
|
-
* of the message sender.
|
|
2127
|
-
*/
|
|
2128
|
-
from?: string;
|
|
2129
|
-
|
|
2130
|
-
/**
|
|
2131
|
-
* The sender of this message as a full handle object
|
|
2132
|
-
*/
|
|
2133
|
-
from_handle?: Shared.ChatHandle;
|
|
2134
|
-
|
|
2135
|
-
/**
|
|
2136
|
-
* Idempotency key for the message. Used for deduplication of outbound messages.
|
|
2137
|
-
*/
|
|
2138
|
-
idempotency_key?: string | null;
|
|
2139
|
-
|
|
2140
|
-
/**
|
|
2141
|
-
* Whether the message was sent by us (true for sent events, false for received
|
|
2142
|
-
* events)
|
|
2143
|
-
*/
|
|
2144
|
-
is_from_me?: boolean;
|
|
2145
|
-
|
|
2146
|
-
/**
|
|
2147
|
-
* Whether this is a group chat
|
|
2148
|
-
*/
|
|
2149
|
-
is_group?: boolean;
|
|
2150
|
-
|
|
2151
|
-
/**
|
|
2152
|
-
* Message content nested within webhook events
|
|
2153
|
-
*/
|
|
2154
|
-
message?: WebhooksAPI.MessagePayload;
|
|
2155
|
-
|
|
2156
|
-
/**
|
|
2157
|
-
* Message identifier (UUID)
|
|
2158
|
-
*/
|
|
2159
|
-
message_id?: string;
|
|
2160
|
-
|
|
2161
|
-
/**
|
|
2162
|
-
* Preferred messaging service type. Includes "auto" for default fallback behavior.
|
|
2163
|
-
*/
|
|
2164
|
-
preferred_service?: 'iMessage' | 'SMS' | 'RCS' | 'auto' | null;
|
|
2165
|
-
|
|
2166
|
-
/**
|
|
2167
|
-
* When the message was received. Null for sent events.
|
|
2168
|
-
*/
|
|
2169
|
-
received_at?: string | null;
|
|
2170
|
-
|
|
2171
|
-
/**
|
|
2172
|
-
* Our phone number that received the message as a full handle object. Null for
|
|
2173
|
-
* sent events.
|
|
2174
|
-
*/
|
|
2175
|
-
recipient_handle?: Shared.ChatHandle | null;
|
|
2176
|
-
|
|
2177
|
-
/**
|
|
2178
|
-
* @deprecated DEPRECATED: Use recipient_handle instead. Our phone number that
|
|
2179
|
-
* received the message. Null for sent events.
|
|
2180
|
-
*/
|
|
2181
|
-
recipient_phone?: string | null;
|
|
2182
|
-
|
|
2183
|
-
/**
|
|
2184
|
-
* Messaging service type
|
|
2185
|
-
*/
|
|
2186
|
-
service?: Shared.ServiceType | null;
|
|
2187
|
-
}
|
|
2188
|
-
}
|
|
2189
|
-
|
|
2190
|
-
/**
|
|
2191
|
-
* Complete webhook payload for message.delivered events (2025-01-01 format)
|
|
2192
|
-
*/
|
|
2193
|
-
export interface MessageDeliveredV2025_01_01WebhookEvent {
|
|
2194
|
-
/**
|
|
2195
|
-
* API version for the webhook payload format
|
|
2196
|
-
*/
|
|
2197
|
-
api_version: string;
|
|
2198
|
-
|
|
2199
|
-
/**
|
|
2200
|
-
* When the event was created
|
|
2201
|
-
*/
|
|
2202
|
-
created_at: string;
|
|
2203
|
-
|
|
2204
|
-
/**
|
|
2205
|
-
* Payload for message.delivered webhook events (2025-01-01 format). Extends
|
|
2206
|
-
* MessageEvent with delivered_at and message_id.
|
|
2207
|
-
*/
|
|
2208
|
-
data: MessageDeliveredV2025_01_01WebhookEvent.Data;
|
|
2209
|
-
|
|
2210
|
-
/**
|
|
2211
|
-
* Unique identifier for this event (for deduplication)
|
|
2212
|
-
*/
|
|
2213
|
-
event_id: string;
|
|
2214
|
-
|
|
2215
|
-
/**
|
|
2216
|
-
* Valid webhook event types that can be subscribed to.
|
|
2217
|
-
*
|
|
2218
|
-
* **Note:** `message.edited` is only delivered to subscriptions using
|
|
2219
|
-
* `webhook_version: "2026-02-03"`. Subscribing to this event on a v2025
|
|
2220
|
-
* subscription will not produce any deliveries.
|
|
2221
|
-
*/
|
|
2222
|
-
event_type: WebhookEventsAPI.WebhookEventType;
|
|
2223
|
-
|
|
2224
|
-
/**
|
|
2225
|
-
* Partner identifier. Present on all webhooks for cross-referencing.
|
|
2226
|
-
*/
|
|
2227
|
-
partner_id: string;
|
|
2228
|
-
|
|
2229
|
-
/**
|
|
2230
|
-
* Trace ID for debugging and correlation across systems.
|
|
2231
|
-
*/
|
|
2232
|
-
trace_id: string;
|
|
2233
|
-
|
|
2234
|
-
/**
|
|
2235
|
-
* Date-based webhook payload version. Determined by the `?version=` query
|
|
2236
|
-
* parameter in your webhook subscription URL. If no version parameter is
|
|
2237
|
-
* specified, defaults based on subscription creation date.
|
|
2238
|
-
*/
|
|
2239
|
-
webhook_version: string;
|
|
2240
|
-
}
|
|
2241
|
-
|
|
2242
|
-
export namespace MessageDeliveredV2025_01_01WebhookEvent {
|
|
2243
|
-
/**
|
|
2244
|
-
* Payload for message.delivered webhook events (2025-01-01 format). Extends
|
|
2245
|
-
* MessageEvent with delivered_at and message_id.
|
|
2246
|
-
*/
|
|
2247
|
-
export interface Data {
|
|
2248
|
-
/**
|
|
2249
|
-
* When the message was delivered to the recipient's device
|
|
2250
|
-
*/
|
|
2251
|
-
delivered_at: string;
|
|
2252
|
-
|
|
2253
|
-
/**
|
|
2254
|
-
* Chat identifier
|
|
2255
|
-
*/
|
|
2256
|
-
chat_id?: string;
|
|
2257
|
-
|
|
2258
|
-
/**
|
|
2259
|
-
* @deprecated DEPRECATED: Use from_handle instead. Phone number or email address
|
|
2260
|
-
* of the message sender.
|
|
2261
|
-
*/
|
|
2262
|
-
from?: string;
|
|
2263
|
-
|
|
2264
|
-
/**
|
|
2265
|
-
* The sender of this message as a full handle object
|
|
2266
|
-
*/
|
|
2267
|
-
from_handle?: Shared.ChatHandle;
|
|
2268
|
-
|
|
2269
|
-
/**
|
|
2270
|
-
* Idempotency key for the message. Used for deduplication of outbound messages.
|
|
2271
|
-
*/
|
|
2272
|
-
idempotency_key?: string | null;
|
|
2273
|
-
|
|
2274
|
-
/**
|
|
2275
|
-
* Whether the message was sent by us (true for sent events, false for received
|
|
2276
|
-
* events)
|
|
2277
|
-
*/
|
|
2278
|
-
is_from_me?: boolean;
|
|
2279
|
-
|
|
2280
|
-
/**
|
|
2281
|
-
* Whether this is a group chat
|
|
2282
|
-
*/
|
|
2283
|
-
is_group?: boolean;
|
|
2284
|
-
|
|
2285
|
-
/**
|
|
2286
|
-
* Message content nested within webhook events
|
|
2287
|
-
*/
|
|
2288
|
-
message?: WebhooksAPI.MessagePayload;
|
|
2289
|
-
|
|
2290
|
-
/**
|
|
2291
|
-
* Message identifier (UUID)
|
|
2292
|
-
*/
|
|
2293
|
-
message_id?: string;
|
|
2294
|
-
|
|
2295
|
-
/**
|
|
2296
|
-
* Preferred messaging service type. Includes "auto" for default fallback behavior.
|
|
2297
|
-
*/
|
|
2298
|
-
preferred_service?: 'iMessage' | 'SMS' | 'RCS' | 'auto' | null;
|
|
2299
|
-
|
|
2300
|
-
/**
|
|
2301
|
-
* When the message was received. Null for sent events.
|
|
2302
|
-
*/
|
|
2303
|
-
received_at?: string | null;
|
|
2304
|
-
|
|
2305
|
-
/**
|
|
2306
|
-
* Our phone number that received the message as a full handle object. Null for
|
|
2307
|
-
* sent events.
|
|
2308
|
-
*/
|
|
2309
|
-
recipient_handle?: Shared.ChatHandle | null;
|
|
2310
|
-
|
|
2311
|
-
/**
|
|
2312
|
-
* @deprecated DEPRECATED: Use recipient_handle instead. Our phone number that
|
|
2313
|
-
* received the message. Null for sent events.
|
|
2314
|
-
*/
|
|
2315
|
-
recipient_phone?: string | null;
|
|
2316
|
-
|
|
2317
|
-
/**
|
|
2318
|
-
* Messaging service type
|
|
2319
|
-
*/
|
|
2320
|
-
service?: Shared.ServiceType | null;
|
|
2321
|
-
}
|
|
2322
|
-
}
|
|
2323
|
-
|
|
2324
|
-
/**
|
|
2325
|
-
* Complete webhook payload for message.failed events
|
|
775
|
+
* Complete webhook payload for message.edited events (2026-02-03 format only)
|
|
2326
776
|
*/
|
|
2327
|
-
export interface
|
|
777
|
+
export interface MessageEditedWebhookEvent {
|
|
2328
778
|
/**
|
|
2329
779
|
* API version for the webhook payload format
|
|
2330
780
|
*/
|
|
@@ -2336,11 +786,12 @@ export interface MessageFailedV2025_01_01WebhookEvent {
|
|
|
2336
786
|
created_at: string;
|
|
2337
787
|
|
|
2338
788
|
/**
|
|
2339
|
-
*
|
|
2340
|
-
*
|
|
2341
|
-
*
|
|
789
|
+
* Payload for `message.edited` events (2026-02-03 format).
|
|
790
|
+
*
|
|
791
|
+
* Describes which part of a message was edited and when. Only text parts can be
|
|
792
|
+
* edited. Only available for subscriptions using `webhook_version: "2026-02-03"`.
|
|
2342
793
|
*/
|
|
2343
|
-
data:
|
|
794
|
+
data: MessageEditedWebhookEvent.Data;
|
|
2344
795
|
|
|
2345
796
|
/**
|
|
2346
797
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2374,44 +825,87 @@ export interface MessageFailedV2025_01_01WebhookEvent {
|
|
|
2374
825
|
webhook_version: string;
|
|
2375
826
|
}
|
|
2376
827
|
|
|
2377
|
-
export namespace
|
|
828
|
+
export namespace MessageEditedWebhookEvent {
|
|
2378
829
|
/**
|
|
2379
|
-
*
|
|
2380
|
-
*
|
|
2381
|
-
*
|
|
830
|
+
* Payload for `message.edited` events (2026-02-03 format).
|
|
831
|
+
*
|
|
832
|
+
* Describes which part of a message was edited and when. Only text parts can be
|
|
833
|
+
* edited. Only available for subscriptions using `webhook_version: "2026-02-03"`.
|
|
2382
834
|
*/
|
|
2383
835
|
export interface Data {
|
|
2384
836
|
/**
|
|
2385
|
-
*
|
|
837
|
+
* Message identifier
|
|
2386
838
|
*/
|
|
2387
|
-
|
|
839
|
+
id: string;
|
|
2388
840
|
|
|
2389
841
|
/**
|
|
2390
|
-
*
|
|
842
|
+
* Chat context
|
|
2391
843
|
*/
|
|
2392
|
-
|
|
844
|
+
chat: Data.Chat;
|
|
2393
845
|
|
|
2394
846
|
/**
|
|
2395
|
-
*
|
|
847
|
+
* "outbound" if you sent the original message, "inbound" if you received it
|
|
2396
848
|
*/
|
|
2397
|
-
|
|
849
|
+
direction: 'outbound' | 'inbound';
|
|
2398
850
|
|
|
2399
851
|
/**
|
|
2400
|
-
*
|
|
852
|
+
* When the edit occurred
|
|
2401
853
|
*/
|
|
2402
|
-
|
|
854
|
+
edited_at: string;
|
|
2403
855
|
|
|
2404
856
|
/**
|
|
2405
|
-
*
|
|
857
|
+
* The edited part
|
|
2406
858
|
*/
|
|
2407
|
-
|
|
859
|
+
part: Data.Part;
|
|
860
|
+
|
|
861
|
+
/**
|
|
862
|
+
* The handle that sent (and edited) this message
|
|
863
|
+
*/
|
|
864
|
+
sender_handle: Shared.ChatHandle;
|
|
865
|
+
}
|
|
866
|
+
|
|
867
|
+
export namespace Data {
|
|
868
|
+
/**
|
|
869
|
+
* Chat context
|
|
870
|
+
*/
|
|
871
|
+
export interface Chat {
|
|
872
|
+
/**
|
|
873
|
+
* Chat identifier
|
|
874
|
+
*/
|
|
875
|
+
id: string;
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* Whether this is a group chat
|
|
879
|
+
*/
|
|
880
|
+
is_group: boolean;
|
|
881
|
+
|
|
882
|
+
/**
|
|
883
|
+
* The handle that owns this chat (your phone number)
|
|
884
|
+
*/
|
|
885
|
+
owner_handle: Shared.ChatHandle;
|
|
886
|
+
}
|
|
887
|
+
|
|
888
|
+
/**
|
|
889
|
+
* The edited part
|
|
890
|
+
*/
|
|
891
|
+
export interface Part {
|
|
892
|
+
/**
|
|
893
|
+
* Zero-based index of the edited part within the message
|
|
894
|
+
*/
|
|
895
|
+
index: number;
|
|
896
|
+
|
|
897
|
+
/**
|
|
898
|
+
* New text content of the part
|
|
899
|
+
*/
|
|
900
|
+
text: string;
|
|
901
|
+
}
|
|
2408
902
|
}
|
|
2409
903
|
}
|
|
2410
904
|
|
|
2411
905
|
/**
|
|
2412
906
|
* Complete webhook payload for reaction.added events
|
|
2413
907
|
*/
|
|
2414
|
-
export interface
|
|
908
|
+
export interface ReactionAddedWebhookEvent {
|
|
2415
909
|
/**
|
|
2416
910
|
* API version for the webhook payload format
|
|
2417
911
|
*/
|
|
@@ -2462,7 +956,7 @@ export interface ReactionAddedV2025_01_01WebhookEvent {
|
|
|
2462
956
|
/**
|
|
2463
957
|
* Complete webhook payload for reaction.removed events
|
|
2464
958
|
*/
|
|
2465
|
-
export interface
|
|
959
|
+
export interface ReactionRemovedWebhookEvent {
|
|
2466
960
|
/**
|
|
2467
961
|
* API version for the webhook payload format
|
|
2468
962
|
*/
|
|
@@ -2513,7 +1007,7 @@ export interface ReactionRemovedV2025_01_01WebhookEvent {
|
|
|
2513
1007
|
/**
|
|
2514
1008
|
* Complete webhook payload for participant.added events
|
|
2515
1009
|
*/
|
|
2516
|
-
export interface
|
|
1010
|
+
export interface ParticipantAddedWebhookEvent {
|
|
2517
1011
|
/**
|
|
2518
1012
|
* API version for the webhook payload format
|
|
2519
1013
|
*/
|
|
@@ -2527,7 +1021,7 @@ export interface ParticipantAddedV2025_01_01WebhookEvent {
|
|
|
2527
1021
|
/**
|
|
2528
1022
|
* Payload for participant.added webhook events
|
|
2529
1023
|
*/
|
|
2530
|
-
data:
|
|
1024
|
+
data: ParticipantAddedWebhookEvent.Data;
|
|
2531
1025
|
|
|
2532
1026
|
/**
|
|
2533
1027
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2561,7 +1055,7 @@ export interface ParticipantAddedV2025_01_01WebhookEvent {
|
|
|
2561
1055
|
webhook_version: string;
|
|
2562
1056
|
}
|
|
2563
1057
|
|
|
2564
|
-
export namespace
|
|
1058
|
+
export namespace ParticipantAddedWebhookEvent {
|
|
2565
1059
|
/**
|
|
2566
1060
|
* Payload for participant.added webhook events
|
|
2567
1061
|
*/
|
|
@@ -2592,7 +1086,7 @@ export namespace ParticipantAddedV2025_01_01WebhookEvent {
|
|
|
2592
1086
|
/**
|
|
2593
1087
|
* Complete webhook payload for participant.removed events
|
|
2594
1088
|
*/
|
|
2595
|
-
export interface
|
|
1089
|
+
export interface ParticipantRemovedWebhookEvent {
|
|
2596
1090
|
/**
|
|
2597
1091
|
* API version for the webhook payload format
|
|
2598
1092
|
*/
|
|
@@ -2606,7 +1100,7 @@ export interface ParticipantRemovedV2025_01_01WebhookEvent {
|
|
|
2606
1100
|
/**
|
|
2607
1101
|
* Payload for participant.removed webhook events
|
|
2608
1102
|
*/
|
|
2609
|
-
data:
|
|
1103
|
+
data: ParticipantRemovedWebhookEvent.Data;
|
|
2610
1104
|
|
|
2611
1105
|
/**
|
|
2612
1106
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2640,7 +1134,7 @@ export interface ParticipantRemovedV2025_01_01WebhookEvent {
|
|
|
2640
1134
|
webhook_version: string;
|
|
2641
1135
|
}
|
|
2642
1136
|
|
|
2643
|
-
export namespace
|
|
1137
|
+
export namespace ParticipantRemovedWebhookEvent {
|
|
2644
1138
|
/**
|
|
2645
1139
|
* Payload for participant.removed webhook events
|
|
2646
1140
|
*/
|
|
@@ -2669,9 +1163,9 @@ export namespace ParticipantRemovedV2025_01_01WebhookEvent {
|
|
|
2669
1163
|
}
|
|
2670
1164
|
|
|
2671
1165
|
/**
|
|
2672
|
-
* Complete webhook payload for chat.
|
|
1166
|
+
* Complete webhook payload for chat.created events
|
|
2673
1167
|
*/
|
|
2674
|
-
export interface
|
|
1168
|
+
export interface ChatCreatedWebhookEvent {
|
|
2675
1169
|
/**
|
|
2676
1170
|
* API version for the webhook payload format
|
|
2677
1171
|
*/
|
|
@@ -2683,9 +1177,10 @@ export interface ChatGroupNameUpdatedV2025_01_01WebhookEvent {
|
|
|
2683
1177
|
created_at: string;
|
|
2684
1178
|
|
|
2685
1179
|
/**
|
|
2686
|
-
* Payload for chat.
|
|
1180
|
+
* Payload for chat.created webhook events. Matches GET /v3/chats/{chatId}
|
|
1181
|
+
* response.
|
|
2687
1182
|
*/
|
|
2688
|
-
data:
|
|
1183
|
+
data: ChatCreatedWebhookEvent.Data;
|
|
2689
1184
|
|
|
2690
1185
|
/**
|
|
2691
1186
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2719,42 +1214,55 @@ export interface ChatGroupNameUpdatedV2025_01_01WebhookEvent {
|
|
|
2719
1214
|
webhook_version: string;
|
|
2720
1215
|
}
|
|
2721
1216
|
|
|
2722
|
-
export namespace
|
|
1217
|
+
export namespace ChatCreatedWebhookEvent {
|
|
2723
1218
|
/**
|
|
2724
|
-
* Payload for chat.
|
|
1219
|
+
* Payload for chat.created webhook events. Matches GET /v3/chats/{chatId}
|
|
1220
|
+
* response.
|
|
2725
1221
|
*/
|
|
2726
1222
|
export interface Data {
|
|
2727
1223
|
/**
|
|
2728
|
-
*
|
|
1224
|
+
* Unique identifier for the chat
|
|
2729
1225
|
*/
|
|
2730
|
-
|
|
1226
|
+
id: string;
|
|
2731
1227
|
|
|
2732
1228
|
/**
|
|
2733
|
-
* When the
|
|
1229
|
+
* When the chat was created
|
|
2734
1230
|
*/
|
|
2735
|
-
|
|
1231
|
+
created_at: string;
|
|
2736
1232
|
|
|
2737
1233
|
/**
|
|
2738
|
-
*
|
|
1234
|
+
* Display name for the chat. Defaults to a comma-separated list of recipient
|
|
1235
|
+
* handles. Can be updated for group chats.
|
|
2739
1236
|
*/
|
|
2740
|
-
|
|
1237
|
+
display_name: string | null;
|
|
2741
1238
|
|
|
2742
1239
|
/**
|
|
2743
|
-
*
|
|
1240
|
+
* List of chat participants with full handle details. Always contains at least two
|
|
1241
|
+
* handles (your phone number and the other participant).
|
|
2744
1242
|
*/
|
|
2745
|
-
|
|
1243
|
+
handles: Array<Shared.ChatHandle>;
|
|
2746
1244
|
|
|
2747
1245
|
/**
|
|
2748
|
-
*
|
|
1246
|
+
* Whether this is a group chat
|
|
2749
1247
|
*/
|
|
2750
|
-
|
|
1248
|
+
is_group: boolean;
|
|
1249
|
+
|
|
1250
|
+
/**
|
|
1251
|
+
* When the chat was last updated
|
|
1252
|
+
*/
|
|
1253
|
+
updated_at: string;
|
|
1254
|
+
|
|
1255
|
+
/**
|
|
1256
|
+
* Messaging service type
|
|
1257
|
+
*/
|
|
1258
|
+
service?: Shared.ServiceType | null;
|
|
2751
1259
|
}
|
|
2752
1260
|
}
|
|
2753
1261
|
|
|
2754
1262
|
/**
|
|
2755
|
-
* Complete webhook payload for chat.
|
|
1263
|
+
* Complete webhook payload for chat.group_name_updated events
|
|
2756
1264
|
*/
|
|
2757
|
-
export interface
|
|
1265
|
+
export interface ChatGroupNameUpdatedWebhookEvent {
|
|
2758
1266
|
/**
|
|
2759
1267
|
* API version for the webhook payload format
|
|
2760
1268
|
*/
|
|
@@ -2766,9 +1274,9 @@ export interface ChatGroupIconUpdatedV2025_01_01WebhookEvent {
|
|
|
2766
1274
|
created_at: string;
|
|
2767
1275
|
|
|
2768
1276
|
/**
|
|
2769
|
-
* Payload for chat.
|
|
1277
|
+
* Payload for chat.group_name_updated webhook events
|
|
2770
1278
|
*/
|
|
2771
|
-
data:
|
|
1279
|
+
data: ChatGroupNameUpdatedWebhookEvent.Data;
|
|
2772
1280
|
|
|
2773
1281
|
/**
|
|
2774
1282
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2802,9 +1310,9 @@ export interface ChatGroupIconUpdatedV2025_01_01WebhookEvent {
|
|
|
2802
1310
|
webhook_version: string;
|
|
2803
1311
|
}
|
|
2804
1312
|
|
|
2805
|
-
export namespace
|
|
1313
|
+
export namespace ChatGroupNameUpdatedWebhookEvent {
|
|
2806
1314
|
/**
|
|
2807
|
-
* Payload for chat.
|
|
1315
|
+
* Payload for chat.group_name_updated webhook events
|
|
2808
1316
|
*/
|
|
2809
1317
|
export interface Data {
|
|
2810
1318
|
/**
|
|
@@ -2823,21 +1331,21 @@ export namespace ChatGroupIconUpdatedV2025_01_01WebhookEvent {
|
|
|
2823
1331
|
changed_by_handle?: Shared.ChatHandle | null;
|
|
2824
1332
|
|
|
2825
1333
|
/**
|
|
2826
|
-
* New
|
|
1334
|
+
* New group name (null if the name was removed)
|
|
2827
1335
|
*/
|
|
2828
1336
|
new_value?: string | null;
|
|
2829
1337
|
|
|
2830
1338
|
/**
|
|
2831
|
-
* Previous
|
|
1339
|
+
* Previous group name (null if no previous name)
|
|
2832
1340
|
*/
|
|
2833
1341
|
old_value?: string | null;
|
|
2834
1342
|
}
|
|
2835
1343
|
}
|
|
2836
1344
|
|
|
2837
1345
|
/**
|
|
2838
|
-
* Complete webhook payload for chat.
|
|
1346
|
+
* Complete webhook payload for chat.group_icon_updated events
|
|
2839
1347
|
*/
|
|
2840
|
-
export interface
|
|
1348
|
+
export interface ChatGroupIconUpdatedWebhookEvent {
|
|
2841
1349
|
/**
|
|
2842
1350
|
* API version for the webhook payload format
|
|
2843
1351
|
*/
|
|
@@ -2849,11 +1357,9 @@ export interface ChatGroupNameUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2849
1357
|
created_at: string;
|
|
2850
1358
|
|
|
2851
1359
|
/**
|
|
2852
|
-
*
|
|
2853
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
2854
|
-
* code reference.
|
|
1360
|
+
* Payload for chat.group_icon_updated webhook events
|
|
2855
1361
|
*/
|
|
2856
|
-
data:
|
|
1362
|
+
data: ChatGroupIconUpdatedWebhookEvent.Data;
|
|
2857
1363
|
|
|
2858
1364
|
/**
|
|
2859
1365
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2887,11 +1393,9 @@ export interface ChatGroupNameUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2887
1393
|
webhook_version: string;
|
|
2888
1394
|
}
|
|
2889
1395
|
|
|
2890
|
-
export namespace
|
|
1396
|
+
export namespace ChatGroupIconUpdatedWebhookEvent {
|
|
2891
1397
|
/**
|
|
2892
|
-
*
|
|
2893
|
-
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
2894
|
-
* code reference.
|
|
1398
|
+
* Payload for chat.group_icon_updated webhook events
|
|
2895
1399
|
*/
|
|
2896
1400
|
export interface Data {
|
|
2897
1401
|
/**
|
|
@@ -2900,21 +1404,31 @@ export namespace ChatGroupNameUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2900
1404
|
chat_id: string;
|
|
2901
1405
|
|
|
2902
1406
|
/**
|
|
2903
|
-
*
|
|
1407
|
+
* When the update occurred
|
|
2904
1408
|
*/
|
|
2905
|
-
|
|
1409
|
+
updated_at: string;
|
|
2906
1410
|
|
|
2907
1411
|
/**
|
|
2908
|
-
*
|
|
1412
|
+
* The handle who made the change.
|
|
2909
1413
|
*/
|
|
2910
|
-
|
|
1414
|
+
changed_by_handle?: Shared.ChatHandle | null;
|
|
1415
|
+
|
|
1416
|
+
/**
|
|
1417
|
+
* New icon URL (null if the icon was removed)
|
|
1418
|
+
*/
|
|
1419
|
+
new_value?: string | null;
|
|
1420
|
+
|
|
1421
|
+
/**
|
|
1422
|
+
* Previous icon URL (null if no previous icon)
|
|
1423
|
+
*/
|
|
1424
|
+
old_value?: string | null;
|
|
2911
1425
|
}
|
|
2912
1426
|
}
|
|
2913
1427
|
|
|
2914
1428
|
/**
|
|
2915
|
-
* Complete webhook payload for chat.
|
|
1429
|
+
* Complete webhook payload for chat.group_name_update_failed events
|
|
2916
1430
|
*/
|
|
2917
|
-
export interface
|
|
1431
|
+
export interface ChatGroupNameUpdateFailedWebhookEvent {
|
|
2918
1432
|
/**
|
|
2919
1433
|
* API version for the webhook payload format
|
|
2920
1434
|
*/
|
|
@@ -2926,11 +1440,11 @@ export interface ChatGroupIconUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2926
1440
|
created_at: string;
|
|
2927
1441
|
|
|
2928
1442
|
/**
|
|
2929
|
-
* Error details for chat.
|
|
1443
|
+
* Error details for chat.group_name_update_failed webhook events. See
|
|
2930
1444
|
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
2931
1445
|
* code reference.
|
|
2932
1446
|
*/
|
|
2933
|
-
data:
|
|
1447
|
+
data: ChatGroupNameUpdateFailedWebhookEvent.Data;
|
|
2934
1448
|
|
|
2935
1449
|
/**
|
|
2936
1450
|
* Unique identifier for this event (for deduplication)
|
|
@@ -2964,9 +1478,9 @@ export interface ChatGroupIconUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2964
1478
|
webhook_version: string;
|
|
2965
1479
|
}
|
|
2966
1480
|
|
|
2967
|
-
export namespace
|
|
1481
|
+
export namespace ChatGroupNameUpdateFailedWebhookEvent {
|
|
2968
1482
|
/**
|
|
2969
|
-
* Error details for chat.
|
|
1483
|
+
* Error details for chat.group_name_update_failed webhook events. See
|
|
2970
1484
|
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
2971
1485
|
* code reference.
|
|
2972
1486
|
*/
|
|
@@ -2989,9 +1503,9 @@ export namespace ChatGroupIconUpdateFailedV2025_01_01WebhookEvent {
|
|
|
2989
1503
|
}
|
|
2990
1504
|
|
|
2991
1505
|
/**
|
|
2992
|
-
* Complete webhook payload for chat.
|
|
1506
|
+
* Complete webhook payload for chat.group_icon_update_failed events
|
|
2993
1507
|
*/
|
|
2994
|
-
export interface
|
|
1508
|
+
export interface ChatGroupIconUpdateFailedWebhookEvent {
|
|
2995
1509
|
/**
|
|
2996
1510
|
* API version for the webhook payload format
|
|
2997
1511
|
*/
|
|
@@ -3003,10 +1517,11 @@ export interface ChatCreatedV2025_01_01WebhookEvent {
|
|
|
3003
1517
|
created_at: string;
|
|
3004
1518
|
|
|
3005
1519
|
/**
|
|
3006
|
-
*
|
|
3007
|
-
*
|
|
1520
|
+
* Error details for chat.group_icon_update_failed webhook events. See
|
|
1521
|
+
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1522
|
+
* code reference.
|
|
3008
1523
|
*/
|
|
3009
|
-
data:
|
|
1524
|
+
data: ChatGroupIconUpdateFailedWebhookEvent.Data;
|
|
3010
1525
|
|
|
3011
1526
|
/**
|
|
3012
1527
|
* Unique identifier for this event (for deduplication)
|
|
@@ -3040,55 +1555,34 @@ export interface ChatCreatedV2025_01_01WebhookEvent {
|
|
|
3040
1555
|
webhook_version: string;
|
|
3041
1556
|
}
|
|
3042
1557
|
|
|
3043
|
-
export namespace
|
|
1558
|
+
export namespace ChatGroupIconUpdateFailedWebhookEvent {
|
|
3044
1559
|
/**
|
|
3045
|
-
*
|
|
3046
|
-
*
|
|
1560
|
+
* Error details for chat.group_icon_update_failed webhook events. See
|
|
1561
|
+
* [WebhookErrorCode](#/components/schemas/WebhookErrorCode) for the full error
|
|
1562
|
+
* code reference.
|
|
3047
1563
|
*/
|
|
3048
1564
|
export interface Data {
|
|
3049
1565
|
/**
|
|
3050
|
-
*
|
|
3051
|
-
*/
|
|
3052
|
-
id: string;
|
|
3053
|
-
|
|
3054
|
-
/**
|
|
3055
|
-
* When the chat was created
|
|
3056
|
-
*/
|
|
3057
|
-
created_at: string;
|
|
3058
|
-
|
|
3059
|
-
/**
|
|
3060
|
-
* Display name for the chat. Defaults to a comma-separated list of recipient
|
|
3061
|
-
* handles. Can be updated for group chats.
|
|
3062
|
-
*/
|
|
3063
|
-
display_name: string | null;
|
|
3064
|
-
|
|
3065
|
-
/**
|
|
3066
|
-
* List of chat participants with full handle details. Always contains at least two
|
|
3067
|
-
* handles (your phone number and the other participant).
|
|
3068
|
-
*/
|
|
3069
|
-
handles: Array<Shared.ChatHandle>;
|
|
3070
|
-
|
|
3071
|
-
/**
|
|
3072
|
-
* Whether this is a group chat
|
|
1566
|
+
* Chat identifier (UUID) of the group chat
|
|
3073
1567
|
*/
|
|
3074
|
-
|
|
1568
|
+
chat_id: string;
|
|
3075
1569
|
|
|
3076
1570
|
/**
|
|
3077
|
-
*
|
|
1571
|
+
* Error codes in webhook failure events (3007, 4001).
|
|
3078
1572
|
*/
|
|
3079
|
-
|
|
1573
|
+
error_code: number;
|
|
3080
1574
|
|
|
3081
1575
|
/**
|
|
3082
|
-
*
|
|
1576
|
+
* When the failure was detected
|
|
3083
1577
|
*/
|
|
3084
|
-
|
|
1578
|
+
failed_at: string;
|
|
3085
1579
|
}
|
|
3086
1580
|
}
|
|
3087
1581
|
|
|
3088
1582
|
/**
|
|
3089
1583
|
* Complete webhook payload for chat.typing_indicator.started events
|
|
3090
1584
|
*/
|
|
3091
|
-
export interface
|
|
1585
|
+
export interface ChatTypingIndicatorStartedWebhookEvent {
|
|
3092
1586
|
/**
|
|
3093
1587
|
* API version for the webhook payload format
|
|
3094
1588
|
*/
|
|
@@ -3102,7 +1596,7 @@ export interface ChatTypingIndicatorStartedV2025_01_01WebhookEvent {
|
|
|
3102
1596
|
/**
|
|
3103
1597
|
* Payload for chat.typing_indicator.started webhook events
|
|
3104
1598
|
*/
|
|
3105
|
-
data:
|
|
1599
|
+
data: ChatTypingIndicatorStartedWebhookEvent.Data;
|
|
3106
1600
|
|
|
3107
1601
|
/**
|
|
3108
1602
|
* Unique identifier for this event (for deduplication)
|
|
@@ -3136,7 +1630,7 @@ export interface ChatTypingIndicatorStartedV2025_01_01WebhookEvent {
|
|
|
3136
1630
|
webhook_version: string;
|
|
3137
1631
|
}
|
|
3138
1632
|
|
|
3139
|
-
export namespace
|
|
1633
|
+
export namespace ChatTypingIndicatorStartedWebhookEvent {
|
|
3140
1634
|
/**
|
|
3141
1635
|
* Payload for chat.typing_indicator.started webhook events
|
|
3142
1636
|
*/
|
|
@@ -3151,7 +1645,7 @@ export namespace ChatTypingIndicatorStartedV2025_01_01WebhookEvent {
|
|
|
3151
1645
|
/**
|
|
3152
1646
|
* Complete webhook payload for chat.typing_indicator.stopped events
|
|
3153
1647
|
*/
|
|
3154
|
-
export interface
|
|
1648
|
+
export interface ChatTypingIndicatorStoppedWebhookEvent {
|
|
3155
1649
|
/**
|
|
3156
1650
|
* API version for the webhook payload format
|
|
3157
1651
|
*/
|
|
@@ -3165,7 +1659,7 @@ export interface ChatTypingIndicatorStoppedV2025_01_01WebhookEvent {
|
|
|
3165
1659
|
/**
|
|
3166
1660
|
* Payload for chat.typing_indicator.stopped webhook events
|
|
3167
1661
|
*/
|
|
3168
|
-
data:
|
|
1662
|
+
data: ChatTypingIndicatorStoppedWebhookEvent.Data;
|
|
3169
1663
|
|
|
3170
1664
|
/**
|
|
3171
1665
|
* Unique identifier for this event (for deduplication)
|
|
@@ -3199,7 +1693,7 @@ export interface ChatTypingIndicatorStoppedV2025_01_01WebhookEvent {
|
|
|
3199
1693
|
webhook_version: string;
|
|
3200
1694
|
}
|
|
3201
1695
|
|
|
3202
|
-
export namespace
|
|
1696
|
+
export namespace ChatTypingIndicatorStoppedWebhookEvent {
|
|
3203
1697
|
/**
|
|
3204
1698
|
* Payload for chat.typing_indicator.stopped webhook events
|
|
3205
1699
|
*/
|
|
@@ -3214,7 +1708,7 @@ export namespace ChatTypingIndicatorStoppedV2025_01_01WebhookEvent {
|
|
|
3214
1708
|
/**
|
|
3215
1709
|
* Complete webhook payload for phone_number.status_updated events
|
|
3216
1710
|
*/
|
|
3217
|
-
export interface
|
|
1711
|
+
export interface PhoneNumberStatusUpdatedWebhookEvent {
|
|
3218
1712
|
/**
|
|
3219
1713
|
* API version for the webhook payload format
|
|
3220
1714
|
*/
|
|
@@ -3228,7 +1722,7 @@ export interface PhoneNumberStatusUpdatedV2025_01_01WebhookEvent {
|
|
|
3228
1722
|
/**
|
|
3229
1723
|
* Payload for phone_number.status_updated webhook events
|
|
3230
1724
|
*/
|
|
3231
|
-
data:
|
|
1725
|
+
data: PhoneNumberStatusUpdatedWebhookEvent.Data;
|
|
3232
1726
|
|
|
3233
1727
|
/**
|
|
3234
1728
|
* Unique identifier for this event (for deduplication)
|
|
@@ -3283,7 +1777,7 @@ export interface PhoneNumberStatusUpdatedV2025_01_01WebhookEvent {
|
|
|
3283
1777
|
webhook_version: string;
|
|
3284
1778
|
}
|
|
3285
1779
|
|
|
3286
|
-
export namespace
|
|
1780
|
+
export namespace PhoneNumberStatusUpdatedWebhookEvent {
|
|
3287
1781
|
/**
|
|
3288
1782
|
* Payload for phone_number.status_updated webhook events
|
|
3289
1783
|
*/
|
|
@@ -3314,41 +1808,24 @@ export namespace PhoneNumberStatusUpdatedV2025_01_01WebhookEvent {
|
|
|
3314
1808
|
* Complete webhook payload for message.sent events (2026-02-03 format)
|
|
3315
1809
|
*/
|
|
3316
1810
|
export type EventsWebhookEvent =
|
|
3317
|
-
|
|
|
3318
|
-
|
|
|
3319
|
-
|
|
|
3320
|
-
|
|
|
3321
|
-
|
|
|
3322
|
-
|
|
|
3323
|
-
|
|
|
3324
|
-
|
|
|
3325
|
-
|
|
|
3326
|
-
|
|
|
3327
|
-
|
|
|
3328
|
-
|
|
|
3329
|
-
|
|
|
3330
|
-
|
|
|
3331
|
-
|
|
|
3332
|
-
|
|
|
3333
|
-
|
|
|
3334
|
-
|
|
|
3335
|
-
| MessageSentV2025_01_01WebhookEvent
|
|
3336
|
-
| MessageReceivedV2025_01_01WebhookEvent
|
|
3337
|
-
| MessageReadV2025_01_01WebhookEvent
|
|
3338
|
-
| MessageDeliveredV2025_01_01WebhookEvent
|
|
3339
|
-
| MessageFailedV2025_01_01WebhookEvent
|
|
3340
|
-
| ReactionAddedV2025_01_01WebhookEvent
|
|
3341
|
-
| ReactionRemovedV2025_01_01WebhookEvent
|
|
3342
|
-
| ParticipantAddedV2025_01_01WebhookEvent
|
|
3343
|
-
| ParticipantRemovedV2025_01_01WebhookEvent
|
|
3344
|
-
| ChatGroupNameUpdatedV2025_01_01WebhookEvent
|
|
3345
|
-
| ChatGroupIconUpdatedV2025_01_01WebhookEvent
|
|
3346
|
-
| ChatGroupNameUpdateFailedV2025_01_01WebhookEvent
|
|
3347
|
-
| ChatGroupIconUpdateFailedV2025_01_01WebhookEvent
|
|
3348
|
-
| ChatCreatedV2025_01_01WebhookEvent
|
|
3349
|
-
| ChatTypingIndicatorStartedV2025_01_01WebhookEvent
|
|
3350
|
-
| ChatTypingIndicatorStoppedV2025_01_01WebhookEvent
|
|
3351
|
-
| PhoneNumberStatusUpdatedV2025_01_01WebhookEvent;
|
|
1811
|
+
| MessageSentWebhookEvent
|
|
1812
|
+
| MessageReceivedWebhookEvent
|
|
1813
|
+
| MessageReadWebhookEvent
|
|
1814
|
+
| MessageDeliveredWebhookEvent
|
|
1815
|
+
| MessageFailedWebhookEvent
|
|
1816
|
+
| MessageEditedWebhookEvent
|
|
1817
|
+
| ReactionAddedWebhookEvent
|
|
1818
|
+
| ReactionRemovedWebhookEvent
|
|
1819
|
+
| ParticipantAddedWebhookEvent
|
|
1820
|
+
| ParticipantRemovedWebhookEvent
|
|
1821
|
+
| ChatCreatedWebhookEvent
|
|
1822
|
+
| ChatGroupNameUpdatedWebhookEvent
|
|
1823
|
+
| ChatGroupIconUpdatedWebhookEvent
|
|
1824
|
+
| ChatGroupNameUpdateFailedWebhookEvent
|
|
1825
|
+
| ChatGroupIconUpdateFailedWebhookEvent
|
|
1826
|
+
| ChatTypingIndicatorStartedWebhookEvent
|
|
1827
|
+
| ChatTypingIndicatorStoppedWebhookEvent
|
|
1828
|
+
| PhoneNumberStatusUpdatedWebhookEvent;
|
|
3352
1829
|
|
|
3353
1830
|
export declare namespace Webhooks {
|
|
3354
1831
|
export {
|
|
@@ -3358,41 +1835,24 @@ export declare namespace Webhooks {
|
|
|
3358
1835
|
type SchemasMediaPartResponse as SchemasMediaPartResponse,
|
|
3359
1836
|
type SchemasMessageEffect as SchemasMessageEffect,
|
|
3360
1837
|
type SchemasTextPartResponse as SchemasTextPartResponse,
|
|
3361
|
-
type
|
|
3362
|
-
type
|
|
3363
|
-
type
|
|
3364
|
-
type
|
|
3365
|
-
type
|
|
3366
|
-
type
|
|
3367
|
-
type
|
|
3368
|
-
type
|
|
3369
|
-
type
|
|
3370
|
-
type
|
|
3371
|
-
type
|
|
3372
|
-
type
|
|
3373
|
-
type
|
|
3374
|
-
type
|
|
3375
|
-
type
|
|
3376
|
-
type
|
|
3377
|
-
type
|
|
3378
|
-
type
|
|
3379
|
-
type MessageSentV2025_01_01WebhookEvent as MessageSentV2025_01_01WebhookEvent,
|
|
3380
|
-
type MessageReceivedV2025_01_01WebhookEvent as MessageReceivedV2025_01_01WebhookEvent,
|
|
3381
|
-
type MessageReadV2025_01_01WebhookEvent as MessageReadV2025_01_01WebhookEvent,
|
|
3382
|
-
type MessageDeliveredV2025_01_01WebhookEvent as MessageDeliveredV2025_01_01WebhookEvent,
|
|
3383
|
-
type MessageFailedV2025_01_01WebhookEvent as MessageFailedV2025_01_01WebhookEvent,
|
|
3384
|
-
type ReactionAddedV2025_01_01WebhookEvent as ReactionAddedV2025_01_01WebhookEvent,
|
|
3385
|
-
type ReactionRemovedV2025_01_01WebhookEvent as ReactionRemovedV2025_01_01WebhookEvent,
|
|
3386
|
-
type ParticipantAddedV2025_01_01WebhookEvent as ParticipantAddedV2025_01_01WebhookEvent,
|
|
3387
|
-
type ParticipantRemovedV2025_01_01WebhookEvent as ParticipantRemovedV2025_01_01WebhookEvent,
|
|
3388
|
-
type ChatGroupNameUpdatedV2025_01_01WebhookEvent as ChatGroupNameUpdatedV2025_01_01WebhookEvent,
|
|
3389
|
-
type ChatGroupIconUpdatedV2025_01_01WebhookEvent as ChatGroupIconUpdatedV2025_01_01WebhookEvent,
|
|
3390
|
-
type ChatGroupNameUpdateFailedV2025_01_01WebhookEvent as ChatGroupNameUpdateFailedV2025_01_01WebhookEvent,
|
|
3391
|
-
type ChatGroupIconUpdateFailedV2025_01_01WebhookEvent as ChatGroupIconUpdateFailedV2025_01_01WebhookEvent,
|
|
3392
|
-
type ChatCreatedV2025_01_01WebhookEvent as ChatCreatedV2025_01_01WebhookEvent,
|
|
3393
|
-
type ChatTypingIndicatorStartedV2025_01_01WebhookEvent as ChatTypingIndicatorStartedV2025_01_01WebhookEvent,
|
|
3394
|
-
type ChatTypingIndicatorStoppedV2025_01_01WebhookEvent as ChatTypingIndicatorStoppedV2025_01_01WebhookEvent,
|
|
3395
|
-
type PhoneNumberStatusUpdatedV2025_01_01WebhookEvent as PhoneNumberStatusUpdatedV2025_01_01WebhookEvent,
|
|
1838
|
+
type MessageSentWebhookEvent as MessageSentWebhookEvent,
|
|
1839
|
+
type MessageReceivedWebhookEvent as MessageReceivedWebhookEvent,
|
|
1840
|
+
type MessageReadWebhookEvent as MessageReadWebhookEvent,
|
|
1841
|
+
type MessageDeliveredWebhookEvent as MessageDeliveredWebhookEvent,
|
|
1842
|
+
type MessageFailedWebhookEvent as MessageFailedWebhookEvent,
|
|
1843
|
+
type MessageEditedWebhookEvent as MessageEditedWebhookEvent,
|
|
1844
|
+
type ReactionAddedWebhookEvent as ReactionAddedWebhookEvent,
|
|
1845
|
+
type ReactionRemovedWebhookEvent as ReactionRemovedWebhookEvent,
|
|
1846
|
+
type ParticipantAddedWebhookEvent as ParticipantAddedWebhookEvent,
|
|
1847
|
+
type ParticipantRemovedWebhookEvent as ParticipantRemovedWebhookEvent,
|
|
1848
|
+
type ChatCreatedWebhookEvent as ChatCreatedWebhookEvent,
|
|
1849
|
+
type ChatGroupNameUpdatedWebhookEvent as ChatGroupNameUpdatedWebhookEvent,
|
|
1850
|
+
type ChatGroupIconUpdatedWebhookEvent as ChatGroupIconUpdatedWebhookEvent,
|
|
1851
|
+
type ChatGroupNameUpdateFailedWebhookEvent as ChatGroupNameUpdateFailedWebhookEvent,
|
|
1852
|
+
type ChatGroupIconUpdateFailedWebhookEvent as ChatGroupIconUpdateFailedWebhookEvent,
|
|
1853
|
+
type ChatTypingIndicatorStartedWebhookEvent as ChatTypingIndicatorStartedWebhookEvent,
|
|
1854
|
+
type ChatTypingIndicatorStoppedWebhookEvent as ChatTypingIndicatorStoppedWebhookEvent,
|
|
1855
|
+
type PhoneNumberStatusUpdatedWebhookEvent as PhoneNumberStatusUpdatedWebhookEvent,
|
|
3396
1856
|
type EventsWebhookEvent as EventsWebhookEvent,
|
|
3397
1857
|
};
|
|
3398
1858
|
}
|