@sinch/conversation 0.0.3 → 0.0.5

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.
Files changed (191) hide show
  1. package/README.md +7 -9
  2. package/dist/index.d.ts +1 -1
  3. package/dist/index.js +14 -1
  4. package/dist/index.js.map +1 -1
  5. package/dist/models/v1/app-message/app-message.d.ts +18 -10
  6. package/dist/models/v1/app-message/index.d.ts +1 -1
  7. package/dist/models/v1/channel-specific-contact-message/channel-specific-contact-message.d.ts +21 -0
  8. package/dist/models/v1/channel-specific-contact-message/channel-specific-contact-message.js +3 -0
  9. package/dist/models/v1/channel-specific-contact-message/channel-specific-contact-message.js.map +1 -0
  10. package/dist/models/v1/channel-specific-contact-message/index.d.ts +1 -0
  11. package/dist/models/v1/channel-specific-contact-message/index.js.map +1 -0
  12. package/dist/models/v1/channel-specific-message/channel-specific-message.d.ts +11 -0
  13. package/dist/models/v1/channel-specific-message/channel-specific-message.js +3 -0
  14. package/dist/models/v1/channel-specific-message/channel-specific-message.js.map +1 -0
  15. package/dist/models/v1/channel-specific-message/index.d.ts +1 -0
  16. package/dist/{rest/v1/enums.js → models/v1/channel-specific-message/index.js} +1 -1
  17. package/dist/models/v1/channel-specific-message/index.js.map +1 -0
  18. package/dist/models/v1/choice-item/choice-item.d.ts +1 -0
  19. package/dist/models/v1/contact-info-message/contact-info-message.d.ts +1 -1
  20. package/dist/models/v1/contact-message/contact-message.d.ts +37 -1
  21. package/dist/models/v1/delivery-report-based-fallback/delivery-report-based-fallback.d.ts +8 -2
  22. package/dist/models/v1/enums.d.ts +5 -1
  23. package/dist/models/v1/flow-channel-specific-message/flow-channel-specific-message.d.ts +37 -0
  24. package/dist/models/v1/flow-channel-specific-message/flow-channel-specific-message.js +3 -0
  25. package/dist/models/v1/flow-channel-specific-message/flow-channel-specific-message.js.map +1 -0
  26. package/dist/models/v1/flow-channel-specific-message/index.d.ts +1 -0
  27. package/dist/models/v1/{app-message-message/app-message-message.js → flow-channel-specific-message/index.js} +1 -1
  28. package/dist/models/v1/flow-channel-specific-message/index.js.map +1 -0
  29. package/dist/models/v1/helper.d.ts +1 -1
  30. package/dist/models/v1/index.d.ts +13 -1
  31. package/dist/models/v1/index.js +13 -1
  32. package/dist/models/v1/index.js.map +1 -1
  33. package/dist/models/v1/list-section/list-section.d.ts +1 -1
  34. package/dist/models/v1/message-retry-settings/message-retry-settings.d.ts +1 -1
  35. package/dist/models/v1/product/index.d.ts +1 -1
  36. package/dist/models/v1/product-response-message/index.d.ts +1 -0
  37. package/dist/models/v1/product-response-message/index.js +3 -0
  38. package/dist/models/v1/product-response-message/index.js.map +1 -0
  39. package/dist/models/v1/product-response-message/product-response-message.d.ts +12 -0
  40. package/dist/models/v1/product-response-message/product-response-message.js +3 -0
  41. package/dist/models/v1/product-response-message/product-response-message.js.map +1 -0
  42. package/dist/models/v1/requests/app/app-request-data.d.ts +24 -0
  43. package/dist/models/v1/requests/app/app-request-data.js +3 -0
  44. package/dist/models/v1/requests/app/app-request-data.js.map +1 -0
  45. package/dist/models/v1/requests/capability/capability-request-data.d.ts +6 -0
  46. package/dist/models/v1/requests/capability/capability-request-data.js +3 -0
  47. package/dist/models/v1/requests/capability/capability-request-data.js.map +1 -0
  48. package/dist/models/v1/requests/contact/contact-request-data.d.ts +48 -0
  49. package/dist/models/v1/requests/contact/contact-request-data.js +3 -0
  50. package/dist/models/v1/requests/contact/contact-request-data.js.map +1 -0
  51. package/dist/models/v1/requests/conversation/conversation-request-data.d.ts +71 -0
  52. package/dist/models/v1/requests/conversation/conversation-request-data.js +3 -0
  53. package/dist/models/v1/requests/conversation/conversation-request-data.js.map +1 -0
  54. package/dist/models/v1/requests/events/events-request-data.d.ts +49 -0
  55. package/dist/models/v1/requests/events/events-request-data.js +3 -0
  56. package/dist/models/v1/requests/events/events-request-data.js.map +1 -0
  57. package/dist/models/v1/requests/index.d.ts +10 -0
  58. package/dist/models/v1/requests/index.js +27 -0
  59. package/dist/models/v1/requests/index.js.map +1 -0
  60. package/dist/models/v1/requests/messages/messages-request-data.d.ts +91 -0
  61. package/dist/models/v1/requests/messages/messages-request-data.js +3 -0
  62. package/dist/models/v1/requests/messages/messages-request-data.js.map +1 -0
  63. package/dist/models/v1/requests/templates-v1/templates-v1-request-data.d.ts +23 -0
  64. package/dist/models/v1/requests/templates-v1/templates-v1-request-data.js +3 -0
  65. package/dist/models/v1/requests/templates-v1/templates-v1-request-data.js.map +1 -0
  66. package/dist/models/v1/requests/templates-v2/templates-v2-request-data.d.ts +29 -0
  67. package/dist/models/v1/requests/templates-v2/templates-v2-request-data.js +3 -0
  68. package/dist/models/v1/requests/templates-v2/templates-v2-request-data.js.map +1 -0
  69. package/dist/models/v1/requests/transcoding/transcoding-request-data.d.ts +5 -0
  70. package/dist/models/v1/requests/transcoding/transcoding-request-data.js +3 -0
  71. package/dist/models/v1/requests/transcoding/transcoding-request-data.js.map +1 -0
  72. package/dist/models/v1/requests/webhooks/webhooks-request-data.d.ts +25 -0
  73. package/dist/models/v1/requests/webhooks/webhooks-request-data.js +3 -0
  74. package/dist/models/v1/requests/webhooks/webhooks-request-data.js.map +1 -0
  75. package/dist/models/v1/send-message-request/send-message-request.d.ts +28 -33
  76. package/dist/models/v1/transcode-message-request/transcode-message-request.d.ts +3 -3
  77. package/dist/models/v1/whatsapp-interactive-body/index.d.ts +1 -0
  78. package/dist/models/v1/whatsapp-interactive-body/index.js +3 -0
  79. package/dist/models/v1/whatsapp-interactive-body/index.js.map +1 -0
  80. package/dist/models/v1/whatsapp-interactive-body/whatsapp-interactive-body.d.ts +7 -0
  81. package/dist/models/v1/whatsapp-interactive-body/whatsapp-interactive-body.js +3 -0
  82. package/dist/models/v1/whatsapp-interactive-body/whatsapp-interactive-body.js.map +1 -0
  83. package/dist/models/v1/whatsapp-interactive-document-header/index.d.ts +1 -0
  84. package/dist/models/v1/whatsapp-interactive-document-header/index.js +3 -0
  85. package/dist/models/v1/whatsapp-interactive-document-header/index.js.map +1 -0
  86. package/dist/models/v1/whatsapp-interactive-document-header/whatsapp-interactive-document-header.d.ts +10 -0
  87. package/dist/models/v1/whatsapp-interactive-document-header/whatsapp-interactive-document-header.js +3 -0
  88. package/dist/models/v1/whatsapp-interactive-document-header/whatsapp-interactive-document-header.js.map +1 -0
  89. package/dist/models/v1/whatsapp-interactive-footer/index.d.ts +1 -0
  90. package/dist/models/v1/whatsapp-interactive-footer/index.js +3 -0
  91. package/dist/models/v1/whatsapp-interactive-footer/index.js.map +1 -0
  92. package/dist/models/v1/whatsapp-interactive-footer/whatsapp-interactive-footer.d.ts +7 -0
  93. package/dist/models/v1/whatsapp-interactive-footer/whatsapp-interactive-footer.js +3 -0
  94. package/dist/models/v1/whatsapp-interactive-footer/whatsapp-interactive-footer.js.map +1 -0
  95. package/dist/models/v1/whatsapp-interactive-header-media/index.d.ts +1 -0
  96. package/dist/models/v1/whatsapp-interactive-header-media/index.js +3 -0
  97. package/dist/models/v1/whatsapp-interactive-header-media/index.js.map +1 -0
  98. package/dist/models/v1/whatsapp-interactive-header-media/whatsapp-interactive-header-media.d.ts +7 -0
  99. package/dist/models/v1/whatsapp-interactive-header-media/whatsapp-interactive-header-media.js +3 -0
  100. package/dist/models/v1/whatsapp-interactive-header-media/whatsapp-interactive-header-media.js.map +1 -0
  101. package/dist/models/v1/whatsapp-interactive-image-header/index.d.ts +1 -0
  102. package/dist/models/v1/whatsapp-interactive-image-header/index.js +3 -0
  103. package/dist/models/v1/whatsapp-interactive-image-header/index.js.map +1 -0
  104. package/dist/models/v1/whatsapp-interactive-image-header/whatsapp-interactive-image-header.d.ts +10 -0
  105. package/dist/models/v1/whatsapp-interactive-image-header/whatsapp-interactive-image-header.js +3 -0
  106. package/dist/models/v1/whatsapp-interactive-image-header/whatsapp-interactive-image-header.js.map +1 -0
  107. package/dist/models/v1/whatsapp-interactive-nfm-reply/index.d.ts +1 -0
  108. package/dist/models/v1/whatsapp-interactive-nfm-reply/index.js +3 -0
  109. package/dist/models/v1/whatsapp-interactive-nfm-reply/index.js.map +1 -0
  110. package/dist/models/v1/whatsapp-interactive-nfm-reply/whatsapp-interactive-nfm-reply.d.ts +11 -0
  111. package/dist/models/v1/whatsapp-interactive-nfm-reply/whatsapp-interactive-nfm-reply.js +3 -0
  112. package/dist/models/v1/whatsapp-interactive-nfm-reply/whatsapp-interactive-nfm-reply.js.map +1 -0
  113. package/dist/models/v1/whatsapp-interactive-text-header/index.d.ts +1 -0
  114. package/dist/models/v1/whatsapp-interactive-text-header/index.js +3 -0
  115. package/dist/models/v1/whatsapp-interactive-text-header/index.js.map +1 -0
  116. package/dist/models/v1/whatsapp-interactive-text-header/whatsapp-interactive-text-header.d.ts +9 -0
  117. package/dist/models/v1/whatsapp-interactive-text-header/whatsapp-interactive-text-header.js +3 -0
  118. package/dist/models/v1/whatsapp-interactive-text-header/whatsapp-interactive-text-header.js.map +1 -0
  119. package/dist/models/v1/whatsapp-interactive-video-header/index.d.ts +1 -0
  120. package/dist/models/v1/whatsapp-interactive-video-header/index.js +3 -0
  121. package/dist/models/v1/whatsapp-interactive-video-header/index.js.map +1 -0
  122. package/dist/models/v1/whatsapp-interactive-video-header/whatsapp-interactive-video-header.d.ts +10 -0
  123. package/dist/models/v1/whatsapp-interactive-video-header/whatsapp-interactive-video-header.js +3 -0
  124. package/dist/models/v1/whatsapp-interactive-video-header/whatsapp-interactive-video-header.js.map +1 -0
  125. package/dist/rest/v1/app/app-api.d.ts +1 -23
  126. package/dist/rest/v1/app/app-api.jest.fixture.d.ts +2 -3
  127. package/dist/rest/v1/app/app-api.jest.fixture.js.map +1 -1
  128. package/dist/rest/v1/app/app-api.js +10 -10
  129. package/dist/rest/v1/app/app-api.js.map +1 -1
  130. package/dist/rest/v1/capability/capability-api.d.ts +1 -5
  131. package/dist/rest/v1/capability/capability-api.jest.fixture.d.ts +2 -2
  132. package/dist/rest/v1/capability/capability-api.jest.fixture.js.map +1 -1
  133. package/dist/rest/v1/capability/capability-api.js +2 -2
  134. package/dist/rest/v1/capability/capability-api.js.map +1 -1
  135. package/dist/rest/v1/contact/contact-api.d.ts +4 -44
  136. package/dist/rest/v1/contact/contact-api.jest.fixture.d.ts +2 -3
  137. package/dist/rest/v1/contact/contact-api.jest.fixture.js.map +1 -1
  138. package/dist/rest/v1/contact/contact-api.js +16 -14
  139. package/dist/rest/v1/contact/contact-api.js.map +1 -1
  140. package/dist/rest/v1/conversation/conversation-api.d.ts +2 -66
  141. package/dist/rest/v1/conversation/conversation-api.jest.fixture.d.ts +2 -2
  142. package/dist/rest/v1/conversation/conversation-api.jest.fixture.js.map +1 -1
  143. package/dist/rest/v1/conversation/conversation-api.js +17 -17
  144. package/dist/rest/v1/conversation/conversation-api.js.map +1 -1
  145. package/dist/rest/v1/conversation-domain-api.d.ts +7 -8
  146. package/dist/rest/v1/conversation-domain-api.js +17 -27
  147. package/dist/rest/v1/conversation-domain-api.js.map +1 -1
  148. package/dist/rest/v1/conversation-service.d.ts +39 -5
  149. package/dist/rest/v1/conversation-service.js +60 -14
  150. package/dist/rest/v1/conversation-service.js.map +1 -1
  151. package/dist/rest/v1/events/events-api.d.ts +1 -47
  152. package/dist/rest/v1/events/events-api.jest.fixture.d.ts +2 -2
  153. package/dist/rest/v1/events/events-api.jest.fixture.js.map +1 -1
  154. package/dist/rest/v1/events/events-api.js +7 -7
  155. package/dist/rest/v1/events/events-api.js.map +1 -1
  156. package/dist/rest/v1/index.d.ts +0 -1
  157. package/dist/rest/v1/index.js +0 -1
  158. package/dist/rest/v1/index.js.map +1 -1
  159. package/dist/rest/v1/messages/messages-api.d.ts +2 -88
  160. package/dist/rest/v1/messages/messages-api.jest.fixture.d.ts +2 -2
  161. package/dist/rest/v1/messages/messages-api.jest.fixture.js.map +1 -1
  162. package/dist/rest/v1/messages/messages-api.js +24 -11
  163. package/dist/rest/v1/messages/messages-api.js.map +1 -1
  164. package/dist/rest/v1/templates-v1/templates-v1-api.d.ts +1 -23
  165. package/dist/rest/v1/templates-v1/templates-v1-api.jest.fixture.d.ts +2 -2
  166. package/dist/rest/v1/templates-v1/templates-v1-api.jest.fixture.js.map +1 -1
  167. package/dist/rest/v1/templates-v1/templates-v1-api.js +10 -10
  168. package/dist/rest/v1/templates-v1/templates-v1-api.js.map +1 -1
  169. package/dist/rest/v1/templates-v2/templates-v2-api.d.ts +1 -29
  170. package/dist/rest/v1/templates-v2/templates-v2-api.jest.fixture.d.ts +2 -2
  171. package/dist/rest/v1/templates-v2/templates-v2-api.jest.fixture.js.map +1 -1
  172. package/dist/rest/v1/templates-v2/templates-v2-api.js +12 -12
  173. package/dist/rest/v1/templates-v2/templates-v2-api.js.map +1 -1
  174. package/dist/rest/v1/transcoding/transcoding-api.d.ts +1 -5
  175. package/dist/rest/v1/transcoding/transcoding-api.jest.fixture.d.ts +2 -2
  176. package/dist/rest/v1/transcoding/transcoding-api.jest.fixture.js.map +1 -1
  177. package/dist/rest/v1/transcoding/transcoding-api.js +2 -2
  178. package/dist/rest/v1/transcoding/transcoding-api.js.map +1 -1
  179. package/dist/rest/v1/webhooks/webhooks-api.d.ts +1 -25
  180. package/dist/rest/v1/webhooks/webhooks-api.jest.fixture.d.ts +2 -3
  181. package/dist/rest/v1/webhooks/webhooks-api.jest.fixture.js.map +1 -1
  182. package/dist/rest/v1/webhooks/webhooks-api.js +10 -10
  183. package/dist/rest/v1/webhooks/webhooks-api.js.map +1 -1
  184. package/package.json +2 -2
  185. package/dist/models/v1/app-message-message/app-message-message.d.ts +0 -102
  186. package/dist/models/v1/app-message-message/app-message-message.js.map +0 -1
  187. package/dist/models/v1/app-message-message/index.d.ts +0 -1
  188. package/dist/models/v1/app-message-message/index.js.map +0 -1
  189. package/dist/rest/v1/enums.d.ts +0 -1
  190. package/dist/rest/v1/enums.js.map +0 -1
  191. /package/dist/models/v1/{app-message-message → channel-specific-contact-message}/index.js +0 -0
@@ -0,0 +1 @@
1
+ export type { ProductResponseMessage } from './product-response-message';
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/product-response-message/index.ts"],"names":[],"mappings":""}
@@ -0,0 +1,12 @@
1
+ import { ProductItem } from '../product';
2
+ /**
3
+ * Represents an interactive WhatsApp message containing ProductItem objects
4
+ */
5
+ export interface ProductResponseMessage {
6
+ /** The selected products. */
7
+ products: ProductItem[];
8
+ /** Optional parameter. Text that may be sent with selected products. */
9
+ text?: string;
10
+ /** Optional parameter. The catalog id that the selected products belong to. */
11
+ catalog_id?: string;
12
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=product-response-message.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-response-message.js","sourceRoot":"","sources":["../../../../src/models/v1/product-response-message/product-response-message.ts"],"names":[],"mappings":""}
@@ -0,0 +1,24 @@
1
+ import { AppCreateRequest } from '../../app-create-request';
2
+ import { AppUpdateRequest } from '../../app-update-request';
3
+ export interface CreateAppRequestData {
4
+ /** The app to create. */
5
+ 'appCreateRequestBody': AppCreateRequest;
6
+ }
7
+ export interface DeleteAppRequestData {
8
+ /** The unique ID of the app. You can find this on the [Sinch Dashboard](https://dashboard.sinch.com/convapi/apps). */
9
+ 'app_id': string;
10
+ }
11
+ export interface GetAppRequestData {
12
+ /** The unique ID of the app. You can find this on the [Sinch Dashboard](https://dashboard.sinch.com/convapi/apps). */
13
+ 'app_id': string;
14
+ }
15
+ export interface ListAppsRequestData {
16
+ }
17
+ export interface UpdateAppRequestData {
18
+ /** The unique ID of the app. You can find this on the [Sinch Dashboard](https://dashboard.sinch.com/convapi/apps). */
19
+ 'app_id': string;
20
+ /** The updated app. */
21
+ 'appUpdateRequestBody': AppUpdateRequest;
22
+ /** The set of field mask paths. */
23
+ 'update_mask'?: Array<string>;
24
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=app-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"app-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/app/app-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,6 @@
1
+ import { Recipient } from '../../recipient';
2
+ import { LookupCapabilityRequest } from '../../lookup-capability-request';
3
+ export interface LookupCapabilityRequestData<T extends Recipient> {
4
+ /** The lookup capability request. */
5
+ 'lookupCapabilityRequestBody': LookupCapabilityRequest<T>;
6
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=capability-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"capability-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/capability/capability-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,48 @@
1
+ import { ContactCreateRequest } from '../../contact-create-request';
2
+ import { Recipient } from '../../recipient';
3
+ import { GetChannelProfileRequest } from '../../get-channel-profile-request';
4
+ import { ConversationChannel } from '../../conversation-channel';
5
+ import { MergeContactRequest } from '../../merge-contact-request';
6
+ import { Contact } from '../../contact';
7
+ export interface CreateContactRequestData {
8
+ /** The contact to create. */
9
+ 'contactCreateRequestBody': ContactCreateRequest;
10
+ }
11
+ export interface DeleteContactRequestData {
12
+ /** The unique ID of the contact. */
13
+ 'contact_id': string;
14
+ }
15
+ export interface GetChannelProfileRequestData<T extends Recipient> {
16
+ /** */
17
+ 'getChannelProfileRequestBody': GetChannelProfileRequest<T>;
18
+ }
19
+ export interface GetContactRequestData {
20
+ /** The unique ID of the contact. */
21
+ 'contact_id': string;
22
+ }
23
+ export interface ListContactsRequestData {
24
+ /** Optional. The maximum number of contacts to fetch. The default is 10 and the maximum is 20. */
25
+ 'page_size'?: number;
26
+ /** Optional. Next page token previously returned if any. */
27
+ 'page_token'?: string;
28
+ /** Optional. Contact identifier in an external system. If used, `channel` and `identity` query parameters can\'t be used. */
29
+ 'external_id'?: string;
30
+ /** Optional. Specifies a channel, and must be set to one of the enum values. If set, the `identity` parameter must be set and `external_id` can\'t be used. Used in conjunction with `identity` to uniquely identify the specified channel identity. */
31
+ 'channel'?: ConversationChannel;
32
+ /** Optional. If set, the `channel` parameter must be set and `external_id` can\'t be used. Used in conjunction with `channel` to uniquely identify the specified channel identity. This will differ from channel to channel. For example, a phone number for SMS, WhatsApp, and Viber Business. */
33
+ 'identity'?: string;
34
+ }
35
+ export interface MergeContactRequestData {
36
+ /** The unique ID of the contact that should be kept when merging two contacts. */
37
+ 'destination_id': string;
38
+ /** The contact to be removed. */
39
+ 'mergeContactRequestBody': MergeContactRequest;
40
+ }
41
+ export interface UpdateContactRequestData {
42
+ /** The unique ID of the contact. */
43
+ 'contact_id': string;
44
+ /** The updated contact. */
45
+ 'updateContactRequestBody': Contact;
46
+ /** The set of field mask paths. */
47
+ 'update_mask'?: Array<string>;
48
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=contact-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contact-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/contact/contact-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,71 @@
1
+ import { CreateConversationRequest } from '../../create-conversation-request';
2
+ import { InjectConversationEventRequest } from '../../inject-conversation-event-request';
3
+ import { InjectMessageRequest } from '../../inject-message-request';
4
+ import { ConversationChannel } from '../../conversation-channel';
5
+ import { Conversation } from '../../conversation';
6
+ import { ConversationMetadataUpdateStrategy } from '../../enums';
7
+ export interface CreateConversationRequestData {
8
+ /** The conversation to create. ID will be generated for the conversation and any ID in the given conversation will be ignored. */
9
+ 'createConversationRequestBody': CreateConversationRequest;
10
+ }
11
+ export interface DeleteConversationRequestData {
12
+ /** The unique ID of the conversation. This is generated by the system. */
13
+ 'conversation_id': string;
14
+ }
15
+ export interface GetConversationRequestData {
16
+ /** The unique ID of the conversation. This is generated by the system. */
17
+ 'conversation_id': string;
18
+ }
19
+ export interface InjectEventRequestData {
20
+ /** The unique ID of the conversation. This is generated by the system. */
21
+ 'conversation_id': string;
22
+ /** Inject event request */
23
+ 'injectConversationEventRequestBody': InjectConversationEventRequest;
24
+ }
25
+ export interface InjectMessageRequestData {
26
+ /** The ID of the conversation. */
27
+ 'conversation_id': string;
28
+ /** Message to be injected. */
29
+ 'injectMessageRequestBody': InjectMessageRequest;
30
+ }
31
+ export interface ListConversationsRequestData {
32
+ /** Required. True if only active conversations should be listed. */
33
+ 'only_active': boolean;
34
+ /** The ID of the app involved in the conversations. Note that either `app_id` or `contact_id` is required in order for the operation to function correctly. */
35
+ 'app_id'?: string;
36
+ /** Resource name (ID) of the contact. Note that either `app_id` or `contact_id` is required in order for the operation to function correctly. */
37
+ 'contact_id'?: string;
38
+ /** The maximum number of conversations to fetch. Defaults to 10 and the maximum is 20. */
39
+ 'page_size'?: number;
40
+ /** Next page token previously returned if any. */
41
+ 'page_token'?: string;
42
+ /** Only fetch conversations from the `active_channel` */
43
+ 'active_channel'?: ConversationChannel;
44
+ }
45
+ export interface ListRecentConversationsRequestData {
46
+ /** The application ID */
47
+ 'app_id': string;
48
+ /** True if only active conversations should be listed. Default is false. */
49
+ 'only_active'?: boolean;
50
+ /** The maximum number of conversations to fetch. Defaults to 10 and the maximum value is 50. */
51
+ 'page_size'?: number;
52
+ /** Next page token previously returned if any. When specifying this token, make sure to use the same values
53
+ * for the other parameters from the request that originated the token, otherwise the paged results may be inconsistent. */
54
+ 'page_token'?: string;
55
+ /** Whether to sort conversations by newest message first or oldest. Default is DESC (newest first) */
56
+ 'order'?: 'ASC' | 'DESC';
57
+ }
58
+ export interface StopActiveConversationRequestData {
59
+ /** The unique ID of the conversation. This is generated by the system. */
60
+ 'conversation_id': string;
61
+ }
62
+ export interface UpdateConversationRequestData {
63
+ /** The unique ID of the conversation. This is generated by the system. */
64
+ 'conversation_id': string;
65
+ /** The updated conversation. */
66
+ 'updateConversationRequestBody': Conversation;
67
+ /** The set of field mask paths. */
68
+ 'update_mask'?: Array<string>;
69
+ /** Update strategy for the `conversation_metadata` field. */
70
+ 'metadata_update_strategy'?: ConversationMetadataUpdateStrategy;
71
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=conversation-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conversation-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/conversation/conversation-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,49 @@
1
+ import { Recipient } from '../../recipient';
2
+ import { SendAgentJoinedEventRequest, SendAgentLeftEventRequest, SendCommentReplyEventRequest, SendComposingEndEventRequest, SendComposingEventRequest, SendEventRequest, SendGenericEventRequest } from '../../send-event-request';
3
+ export interface DeleteEventRequestData {
4
+ /** The unique ID of the event. */
5
+ 'event_id': string;
6
+ }
7
+ export interface GetEventRequestData {
8
+ /** The unique ID of the event. */
9
+ 'event_id': string;
10
+ }
11
+ export interface ListEventsRequestData {
12
+ /** Resource name (id) of the conversation. One of conversation_id or contact_id needs to be present. */
13
+ 'conversation_id'?: string;
14
+ /** Resource name (id) of the contact. One of conversation_id or contact_id needs to be present. */
15
+ 'contact_id'?: string;
16
+ /** Maximum number of events to fetch. Defaults to 10 and the maximum is 20. */
17
+ 'page_size'?: number;
18
+ /** Next page token previously returned if any. When specifying this token, make sure to use the same values
19
+ * for the other parameters from the request that originated the token, otherwise the paged results may be inconsistent. */
20
+ 'page_token'?: string;
21
+ }
22
+ export interface SendEventRequestData<T extends Recipient> {
23
+ /** The event to be sent. */
24
+ 'sendEventRequestBody': SendEventRequest<T>;
25
+ }
26
+ export interface SendComposingEventRequestData<T extends Recipient> {
27
+ /** The event to be sent. */
28
+ 'sendEventRequestBody': SendComposingEventRequest<T>;
29
+ }
30
+ export interface SendComposingEndEventRequestData<T extends Recipient> {
31
+ /** The event to be sent. */
32
+ 'sendEventRequestBody': SendComposingEndEventRequest<T>;
33
+ }
34
+ export interface SendCommentReplyEventRequestData<T extends Recipient> {
35
+ /** The event to be sent. */
36
+ 'sendEventRequestBody': SendCommentReplyEventRequest<T>;
37
+ }
38
+ export interface SendAgentJoinedEventRequestData<T extends Recipient> {
39
+ /** The event to be sent. */
40
+ 'sendEventRequestBody': SendAgentJoinedEventRequest<T>;
41
+ }
42
+ export interface SendAgentLeftEventRequestData<T extends Recipient> {
43
+ /** The event to be sent. */
44
+ 'sendEventRequestBody': SendAgentLeftEventRequest<T>;
45
+ }
46
+ export interface SendGenericEventRequestData<T extends Recipient> {
47
+ /** The event to be sent. */
48
+ 'sendEventRequestBody': SendGenericEventRequest<T>;
49
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=events-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/events/events-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,10 @@
1
+ export * from './app/app-request-data';
2
+ export * from './capability/capability-request-data';
3
+ export * from './contact/contact-request-data';
4
+ export * from './conversation/conversation-request-data';
5
+ export * from './events/events-request-data';
6
+ export * from './messages/messages-request-data';
7
+ export * from './templates-v1/templates-v1-request-data';
8
+ export * from './templates-v2/templates-v2-request-data';
9
+ export * from './transcoding/transcoding-request-data';
10
+ export * from './webhooks/webhooks-request-data';
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./app/app-request-data"), exports);
18
+ __exportStar(require("./capability/capability-request-data"), exports);
19
+ __exportStar(require("./contact/contact-request-data"), exports);
20
+ __exportStar(require("./conversation/conversation-request-data"), exports);
21
+ __exportStar(require("./events/events-request-data"), exports);
22
+ __exportStar(require("./messages/messages-request-data"), exports);
23
+ __exportStar(require("./templates-v1/templates-v1-request-data"), exports);
24
+ __exportStar(require("./templates-v2/templates-v2-request-data"), exports);
25
+ __exportStar(require("./transcoding/transcoding-request-data"), exports);
26
+ __exportStar(require("./webhooks/webhooks-request-data"), exports);
27
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/requests/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAuC;AACvC,uEAAqD;AACrD,iEAA+C;AAC/C,2EAAyD;AACzD,+DAA6C;AAC7C,mEAAiD;AACjD,2EAAyD;AACzD,2EAAyD;AACzD,yEAAuD;AACvD,mEAAiD"}
@@ -0,0 +1,91 @@
1
+ import { ConversationMessagesView, MessageSource } from '../../enums';
2
+ import { ConversationChannel } from '../../conversation-channel';
3
+ import { Recipient } from '../../recipient';
4
+ import { SendCardMessageRequest, SendCarouselMessageRequest, SendChoiceMessageRequest, SendContactInfoMessageRequest, SendListMessageRequest, SendLocationMessageRequest, SendMediaMessageRequest, SendMessageRequest, SendTemplateMessageRequest, SendTextMessageRequest } from '../../send-message-request';
5
+ import { UpdateMessageRequest } from '../../update-message-request';
6
+ export interface DeleteMessageRequestData {
7
+ /** The unique ID of the message. */
8
+ 'message_id': string;
9
+ /** Specifies the message source for which the request will be processed. Used for operations on messages in Dispatch Mode. For more information, see [Processing Modes](../../../../../conversation/processing-modes/). */
10
+ 'messages_source'?: MessageSource;
11
+ }
12
+ export interface GetMessageRequestData {
13
+ /** The unique ID of the message. */
14
+ 'message_id': string;
15
+ /** Specifies the message source for which the request will be processed. Used for operations on messages in Dispatch Mode. For more information, see [Processing Modes](../../../../../conversation/processing-modes/). */
16
+ 'messages_source'?: MessageSource;
17
+ }
18
+ export interface ListMessagesRequestData {
19
+ /** Resource name (ID) of the conversation. */
20
+ 'conversation_id'?: string;
21
+ /** Resource name (ID) of the contact. */
22
+ 'contact_id'?: string;
23
+ /** Id of the app. */
24
+ 'app_id'?: string;
25
+ /** Channel identity of the contact. */
26
+ 'channel_identity'?: string;
27
+ /** Filter messages with `accept_time` after this timestamp. Must be before `end_time` if that is specified. */
28
+ 'start_time'?: Date;
29
+ /** Filter messages with `accept_time` before this timestamp. */
30
+ 'end_time'?: Date;
31
+ /** Maximum number of messages to fetch. Defaults to 10 and the maximum is 1000. */
32
+ 'page_size'?: number;
33
+ /** Next page token previously returned if any. When specifying this token, make sure to use the same values for the other parameters from the request that originated the token, otherwise the paged results may be inconsistent. */
34
+ 'page_token'?: string;
35
+ /** */
36
+ 'view'?: ConversationMessagesView;
37
+ /** Specifies the message source for which the request will be processed. Used for operations on messages in Dispatch Mode. For more information, see [Processing Modes](../../../../../conversation/processing-modes/). */
38
+ 'messages_source'?: MessageSource;
39
+ /** If true, fetch only recipient originated messages. Available only when `messages_source` is `DISPATCH_SOURCE`. */
40
+ 'only_recipient_originated'?: boolean;
41
+ /** Only fetch messages from the `channel`. */
42
+ 'channel'?: ConversationChannel;
43
+ }
44
+ export interface SendMessageRequestData<T extends Recipient> {
45
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
46
+ 'sendMessageRequestBody': SendMessageRequest<T>;
47
+ }
48
+ export interface SendCardMessageRequestData<T extends Recipient> {
49
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
50
+ 'sendMessageRequestBody': SendCardMessageRequest<T>;
51
+ }
52
+ export interface SendCarouselMessageRequestData<T extends Recipient> {
53
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
54
+ 'sendMessageRequestBody': SendCarouselMessageRequest<T>;
55
+ }
56
+ export interface SendChoiceMessageRequestData<T extends Recipient> {
57
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
58
+ 'sendMessageRequestBody': SendChoiceMessageRequest<T>;
59
+ }
60
+ export interface SendContactInfoMessageRequestData<T extends Recipient> {
61
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
62
+ 'sendMessageRequestBody': SendContactInfoMessageRequest<T>;
63
+ }
64
+ export interface SendListMessageRequestData<T extends Recipient> {
65
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
66
+ 'sendMessageRequestBody': SendListMessageRequest<T>;
67
+ }
68
+ export interface SendLocationMessageRequestData<T extends Recipient> {
69
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
70
+ 'sendMessageRequestBody': SendLocationMessageRequest<T>;
71
+ }
72
+ export interface SendMediaMessageRequestData<T extends Recipient> {
73
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
74
+ 'sendMessageRequestBody': SendMediaMessageRequest<T>;
75
+ }
76
+ export interface SendTemplateMessageRequestData<T extends Recipient> {
77
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
78
+ 'sendMessageRequestBody': SendTemplateMessageRequest<T>;
79
+ }
80
+ export interface SendTextMessageRequestData<T extends Recipient> {
81
+ /** This is the request body for sending a message. `app_id`, `recipient`, and `message` are all required fields. */
82
+ 'sendMessageRequestBody': SendTextMessageRequest<T>;
83
+ }
84
+ export interface UpdateMessageRequestData {
85
+ /** The unique ID of the message. */
86
+ 'message_id': string;
87
+ /** Update message metadata request. */
88
+ 'updateMessageRequestBody': UpdateMessageRequest;
89
+ /** Specifies the message source for which the request will be processed. Used for operations on messages in Dispatch Mode. For more information, see [Processing Modes](../../../../../conversation/processing-modes/). */
90
+ 'messages_source'?: 'CONVERSATION_SOURCE' | 'DISPATCH_SOURCE';
91
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=messages-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"messages-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/messages/messages-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,23 @@
1
+ import { V1Template } from '../../v1-template';
2
+ export interface CreateTemplateRequestData {
3
+ /** Required. The template to create. */
4
+ 'createTemplateRequestBody': V1Template;
5
+ }
6
+ export interface DeleteTemplateRequestData {
7
+ /** Required. The ID of the template to fetch. */
8
+ 'template_id': string;
9
+ }
10
+ export interface GetTemplateRequestData {
11
+ /** Required. The ID of the template to fetch. */
12
+ 'template_id': string;
13
+ }
14
+ export interface ListTemplatesRequestData {
15
+ }
16
+ export interface UpdateTemplateRequestData {
17
+ /** The id of the template to be updated. Specified or automatically generated during template creation. Unique per project. */
18
+ 'template_id': string;
19
+ /** Required. The updated template. */
20
+ 'updateTemplateRequestBody': V1Template;
21
+ /** The set of field mask paths. */
22
+ 'update_mask'?: Array<string>;
23
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=templates-v1-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"templates-v1-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/templates-v1/templates-v1-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,29 @@
1
+ import { V2Template } from '../../v2-template';
2
+ export interface V2CreateTemplateRequestData {
3
+ /** Required. The template to create. */
4
+ 'createTemplateRequestBody': V2Template;
5
+ }
6
+ export interface V2DeleteTemplateRequestData {
7
+ /** Required. The ID of the template to delete. */
8
+ 'template_id': string;
9
+ }
10
+ export interface V2GetTemplateRequestData {
11
+ /** Required. The ID of the template to fetch. */
12
+ 'template_id': string;
13
+ }
14
+ export interface V2ListTemplatesRequestData {
15
+ }
16
+ export interface V2ListTranslationsRequestData {
17
+ /** Required. The template ID. */
18
+ 'template_id': string;
19
+ /** Optional. The translation's language code. */
20
+ 'language_code'?: string;
21
+ /** Optional. The translation's version. */
22
+ 'translation_version'?: string;
23
+ }
24
+ export interface V2UpdateTemplateRequestData {
25
+ /** The id of the template to be updated. Specified or automatically generated during template creation. Unique per project. */
26
+ 'template_id': string;
27
+ /** Required. The updated template. */
28
+ 'updateTemplateRequestBody': V2Template;
29
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=templates-v2-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"templates-v2-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/templates-v2/templates-v2-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,5 @@
1
+ import { TranscodeMessageRequest } from '../../transcode-message-request';
2
+ export interface TranscodeMessageRequestData {
3
+ /** The message to be transcoded, and the app and channels for which the message is to be transcoded. */
4
+ 'transcodeMessageRequestBody': TranscodeMessageRequest;
5
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=transcoding-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transcoding-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/transcoding/transcoding-request-data.ts"],"names":[],"mappings":""}
@@ -0,0 +1,25 @@
1
+ import { Webhook } from '../../webhook';
2
+ export interface CreateWebhookRequestData {
3
+ /** Required. The Webhook to create */
4
+ 'webhookCreateRequestBody': Webhook;
5
+ }
6
+ export interface DeleteWebhookRequestData {
7
+ /** The unique ID of the webhook. */
8
+ 'webhook_id': string;
9
+ }
10
+ export interface GetWebhookRequestData {
11
+ /** The unique ID of the webhook. */
12
+ 'webhook_id': string;
13
+ }
14
+ export interface ListWebhooksRequestData {
15
+ /** The unique ID of the app. You can find this on the [Sinch Dashboard](https://dashboard.sinch.com/convapi/apps). */
16
+ 'app_id': string;
17
+ }
18
+ export interface UpdateWebhookRequestData {
19
+ /** The unique ID of the webhook. */
20
+ 'webhook_id': string;
21
+ /** Required. The Webhook to update */
22
+ 'webhookUpdateRequestBody': Webhook;
23
+ /** The set of field mask paths. */
24
+ 'update_mask'?: Array<string>;
25
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=webhooks-request-data.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"webhooks-request-data.js","sourceRoot":"","sources":["../../../../../src/models/v1/requests/webhooks/webhooks-request-data.ts"],"names":[],"mappings":""}