1
+ /*
2
+ * MessageMediaMessages.PCL
3
+ *
4
+ * This file was automatically generated for MessageMedia by APIMATIC v2.0 ( https://apimatic.io )
5
+ */
6
+ using System ;
7
+ using System . Collections . Generic ;
8
+ using System . Dynamic ;
9
+ using System . IO ;
10
+ using System . Linq ;
11
+ using System . Text ;
12
+ using System . Threading . Tasks ;
13
+ using APIMATIC . SDK . Common ;
14
+ using APIMATIC . SDK . Http . Request ;
15
+ using APIMATIC . SDK . Http . Response ;
16
+ using APIMATIC . SDK . Http . Client ;
17
+
18
+ namespace MessageMedia . Messages . Controllers
19
+ {
20
+ public partial interface IDeliveryReportsController
21
+ {
22
+ /// <summary>
23
+ /// Check for any delivery reports that have been received.
24
+ /// Delivery reports are a notification of the change in status of a message as it is being processed.
25
+ /// Each request to the check delivery reports endpoint will return any delivery reports received that
26
+ /// have not yet been confirmed using the confirm delivery reports endpoint. A response from the check
27
+ /// delivery reports endpoint will have the following structure:
28
+ /// ```json
29
+ /// {
30
+ /// "delivery_reports": [
31
+ /// {
32
+ /// "callback_url": "https://my.callback.url.com",
33
+ /// "delivery_report_id": "01e1fa0a-6e27-4945-9cdb-18644b4de043",
34
+ /// "source_number": "+61491570157",
35
+ /// "date_received": "2017年05月20日T06:30:37.642Z",
36
+ /// "status": "enroute",
37
+ /// "delay": 0,
38
+ /// "submitted_date": "2017年05月20日T06:30:37.639Z",
39
+ /// "original_text": "My first message!",
40
+ /// "message_id": "d781dcab-d9d8-4fb2-9e03-872f07ae94ba",
41
+ /// "vendor_account_id": {
42
+ /// "vendor_id": "MessageMedia",
43
+ /// "account_id": "MyAccount"
44
+ /// },
45
+ /// "metadata": {
46
+ /// "key1": "value1",
47
+ /// "key2": "value2"
48
+ /// }
49
+ /// },
50
+ /// {
51
+ /// "callback_url": "https://my.callback.url.com",
52
+ /// "delivery_report_id": "0edf9022-7ccc-43e6-acab-480e93e98c1b",
53
+ /// "source_number": "+61491570158",
54
+ /// "date_received": "2017年05月21日T01:46:42.579Z",
55
+ /// "status": "enroute",
56
+ /// "delay": 0,
57
+ /// "submitted_date": "2017年05月21日T01:46:42.574Z",
58
+ /// "original_text": "My second message!",
59
+ /// "message_id": "fbb3b3f5-b702-4d8b-ab44-65b2ee39a281",
60
+ /// "vendor_account_id": {
61
+ /// "vendor_id": "MessageMedia",
62
+ /// "account_id": "MyAccount"
63
+ /// },
64
+ /// "metadata": {
65
+ /// "key1": "value1",
66
+ /// "key2": "value2"
67
+ /// }
68
+ /// }
69
+ /// ]
70
+ /// }
71
+ /// ```
72
+ /// Each delivery report will contain details about the message, including any metadata specified
73
+ /// and the new status of the message (as each delivery report indicates a change in status of a
74
+ /// message) and the timestamp at which the status changed. Every delivery report will have a
75
+ /// unique delivery report ID for use with the confirm delivery reports endpoint.
76
+ /// *Note: The source number and destination number properties in a delivery report are the inverse of
77
+ /// those specified in the message that the delivery report relates to. The source number of the
78
+ /// delivery report is the destination number of the original message.*
79
+ /// Subsequent requests to the check delivery reports endpoint will return the same delivery reports
80
+ /// and a maximum of 100 delivery reports will be returned in each request. Applications should use the
81
+ /// confirm delivery reports endpoint in the following pattern so that delivery reports that have been
82
+ /// processed are no longer returned in subsequent check delivery reports requests.
83
+ /// 1. Call check delivery reports endpoint
84
+ /// 2. Process each delivery report
85
+ /// 3. Confirm all processed delivery reports using the confirm delivery reports endpoint
86
+ /// *Note: It is recommended to use the Webhooks feature to receive reply messages rather than
87
+ /// polling the check delivery reports endpoint.*
88
+ /// </summary>
89
+ /// <return>Returns the Models.CheckDeliveryReportsResponse response from the API call</return>
90
+ Models . CheckDeliveryReportsResponse GetCheckDeliveryReports ( ) ;
91
+
92
+ /// <summary>
93
+ /// Check for any delivery reports that have been received.
94
+ /// Delivery reports are a notification of the change in status of a message as it is being processed.
95
+ /// Each request to the check delivery reports endpoint will return any delivery reports received that
96
+ /// have not yet been confirmed using the confirm delivery reports endpoint. A response from the check
97
+ /// delivery reports endpoint will have the following structure:
98
+ /// ```json
99
+ /// {
100
+ /// "delivery_reports": [
101
+ /// {
102
+ /// "callback_url": "https://my.callback.url.com",
103
+ /// "delivery_report_id": "01e1fa0a-6e27-4945-9cdb-18644b4de043",
104
+ /// "source_number": "+61491570157",
105
+ /// "date_received": "2017年05月20日T06:30:37.642Z",
106
+ /// "status": "enroute",
107
+ /// "delay": 0,
108
+ /// "submitted_date": "2017年05月20日T06:30:37.639Z",
109
+ /// "original_text": "My first message!",
110
+ /// "message_id": "d781dcab-d9d8-4fb2-9e03-872f07ae94ba",
111
+ /// "vendor_account_id": {
112
+ /// "vendor_id": "MessageMedia",
113
+ /// "account_id": "MyAccount"
114
+ /// },
115
+ /// "metadata": {
116
+ /// "key1": "value1",
117
+ /// "key2": "value2"
118
+ /// }
119
+ /// },
120
+ /// {
121
+ /// "callback_url": "https://my.callback.url.com",
122
+ /// "delivery_report_id": "0edf9022-7ccc-43e6-acab-480e93e98c1b",
123
+ /// "source_number": "+61491570158",
124
+ /// "date_received": "2017年05月21日T01:46:42.579Z",
125
+ /// "status": "enroute",
126
+ /// "delay": 0,
127
+ /// "submitted_date": "2017年05月21日T01:46:42.574Z",
128
+ /// "original_text": "My second message!",
129
+ /// "message_id": "fbb3b3f5-b702-4d8b-ab44-65b2ee39a281",
130
+ /// "vendor_account_id": {
131
+ /// "vendor_id": "MessageMedia",
132
+ /// "account_id": "MyAccount"
133
+ /// },
134
+ /// "metadata": {
135
+ /// "key1": "value1",
136
+ /// "key2": "value2"
137
+ /// }
138
+ /// }
139
+ /// ]
140
+ /// }
141
+ /// ```
142
+ /// Each delivery report will contain details about the message, including any metadata specified
143
+ /// and the new status of the message (as each delivery report indicates a change in status of a
144
+ /// message) and the timestamp at which the status changed. Every delivery report will have a
145
+ /// unique delivery report ID for use with the confirm delivery reports endpoint.
146
+ /// *Note: The source number and destination number properties in a delivery report are the inverse of
147
+ /// those specified in the message that the delivery report relates to. The source number of the
148
+ /// delivery report is the destination number of the original message.*
149
+ /// Subsequent requests to the check delivery reports endpoint will return the same delivery reports
150
+ /// and a maximum of 100 delivery reports will be returned in each request. Applications should use the
151
+ /// confirm delivery reports endpoint in the following pattern so that delivery reports that have been
152
+ /// processed are no longer returned in subsequent check delivery reports requests.
153
+ /// 1. Call check delivery reports endpoint
154
+ /// 2. Process each delivery report
155
+ /// 3. Confirm all processed delivery reports using the confirm delivery reports endpoint
156
+ /// *Note: It is recommended to use the Webhooks feature to receive reply messages rather than
157
+ /// polling the check delivery reports endpoint.*
158
+ /// </summary>
159
+ /// <return>Returns the Models.CheckDeliveryReportsResponse response from the API call</return>
160
+ Task < Models . CheckDeliveryReportsResponse > GetCheckDeliveryReportsAsync ( ) ;
161
+
162
+ /// <summary>
163
+ /// Mark a delivery report as confirmed so it is no longer return in check delivery reports requests.
164
+ /// The confirm delivery reports endpoint is intended to be used in conjunction with the check delivery
165
+ /// reports endpoint to allow for robust processing of delivery reports. Once one or more delivery
166
+ /// reports have been processed, they can then be confirmed using the confirm delivery reports endpoint so they
167
+ /// are no longer returned in subsequent check delivery reports requests.
168
+ /// The confirm delivery reports endpoint takes a list of delivery report IDs as follows:
169
+ /// ```json
170
+ /// {
171
+ /// "delivery_report_ids": [
172
+ /// "011dcead-6988-4ad6-a1c7-6b6c68ea628d",
173
+ /// "3487b3fa-6586-4979-a233-2d1b095c7718",
174
+ /// "ba28e94b-c83d-4759-98e7-ff9c7edb87a1"
175
+ /// ]
176
+ /// }
177
+ /// ```
178
+ /// Up to 100 delivery reports can be confirmed in a single confirm delivery reports request.
179
+ /// </summary>
180
+ /// <param name="body">Required parameter: Example: </param>
181
+ /// <return>Returns the dynamic response from the API call</return>
182
+ dynamic CreateConfirmDeliveryReportsAsReceived ( Models . ConfirmDeliveryReportsAsReceivedRequest body ) ;
183
+
184
+ /// <summary>
185
+ /// Mark a delivery report as confirmed so it is no longer return in check delivery reports requests.
186
+ /// The confirm delivery reports endpoint is intended to be used in conjunction with the check delivery
187
+ /// reports endpoint to allow for robust processing of delivery reports. Once one or more delivery
188
+ /// reports have been processed, they can then be confirmed using the confirm delivery reports endpoint so they
189
+ /// are no longer returned in subsequent check delivery reports requests.
190
+ /// The confirm delivery reports endpoint takes a list of delivery report IDs as follows:
191
+ /// ```json
192
+ /// {
193
+ /// "delivery_report_ids": [
194
+ /// "011dcead-6988-4ad6-a1c7-6b6c68ea628d",
195
+ /// "3487b3fa-6586-4979-a233-2d1b095c7718",
196
+ /// "ba28e94b-c83d-4759-98e7-ff9c7edb87a1"
197
+ /// ]
198
+ /// }
199
+ /// ```
200
+ /// Up to 100 delivery reports can be confirmed in a single confirm delivery reports request.
201
+ /// </summary>
202
+ /// <param name="body">Required parameter: Example: </param>
203
+ /// <return>Returns the dynamic response from the API call</return>
204
+ Task < dynamic > CreateConfirmDeliveryReportsAsReceivedAsync ( Models . ConfirmDeliveryReportsAsReceivedRequest body ) ;
205
+
206
+ }
207
+ }
0 commit comments