mailinator_client 1.0.3 → 1.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.
- checksums.yaml +4 -4
- data/LICENSE +1 -1
- data/README.md +13 -1
- data/docs/authenticators.md +71 -0
- data/docs/domains.md +26 -0
- data/docs/messages.md +170 -14
- data/docs/webhooks.md +125 -0
- data/lib/mailinator_client/authenticators.rb +165 -0
- data/lib/mailinator_client/client.rb +12 -2
- data/lib/mailinator_client/domains.rb +60 -1
- data/lib/mailinator_client/error.rb +1 -1
- data/lib/mailinator_client/messages.rb +327 -16
- data/lib/mailinator_client/rules.rb +1 -1
- data/lib/mailinator_client/stats.rb +1 -1
- data/lib/mailinator_client/utils.rb +1 -1
- data/lib/mailinator_client/version.rb +2 -2
- data/lib/mailinator_client/webhooks.rb +281 -0
- data/lib/mailinator_client.rb +3 -1
- data/test/mailinator_client_api_test.rb +125 -25
- metadata +7 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 638fc40bb2a36464b2442cc9043ce1cc44f1c6698c40276535cc6d92261619d8
|
4
|
+
data.tar.gz: c734c8e2d2eddc30bae2460d4909fa7cc0182036ee57dc657eb4d1d180ef5d15
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 556e3cc614515b193e96ce8c1fcdaa45e290b7bed990ae28dd18885ae99127d1d24ee91cb81a0959c8a7685ea67b16386a505be6ec1bfc10377f14766f724749
|
7
|
+
data.tar.gz: e628f406a7276798b957d1481ddf90d00899f827d22a096ecf9d10724eaf83b6ea39c4292ca739162ed45c4a8f1e03284f363d950aa189bc65d3302dd7a7bb88
|
data/LICENSE
CHANGED
data/README.md
CHANGED
@@ -45,6 +45,9 @@ The ``Client()`` initializer takes the following arguments:
|
|
45
45
|
|
46
46
|
Each of the following is a method on the client object, and returns a wrapper for the actions against that particular resource. See each resource documentation file for more information.
|
47
47
|
|
48
|
+
* [authenticators](docs/authenticators.md)
|
49
|
+
Contains all of the actions that can be performed against the set of [Authenticators](https://manybrain.github.io/m8rdocs/#authenticators-api) that the currently authenticated user has access to - such as listing the authenticators.
|
50
|
+
|
48
51
|
* [domains](docs/domains.md)
|
49
52
|
Contains all of the actions that can be performed against the set of [Domains](https://manybrain.github.io/m8rdocs/#domains-api) that the currently authenticated user has access to - such as listing the domains.
|
50
53
|
|
@@ -56,6 +59,9 @@ Each of the following is a method on the client object, and returns a wrapper fo
|
|
56
59
|
|
57
60
|
* [messages](docs/messages.md)
|
58
61
|
Contains all of the actions that can be performed against the set of [Messages](https://manybrain.github.io/m8rdocs/#message-api) that the currently authenticated user has access to - such as listing the messages or injecting a new message.
|
62
|
+
|
63
|
+
* [webhooks](docs/webhooks.md)
|
64
|
+
Contains all of the actions that can be performed against the set of [Webhooks](https://manybrain.github.io/m8rdocs/#webhooks-api) that the currently user has access to - such as listing the webhooks.
|
59
65
|
|
60
66
|
<br/>
|
61
67
|
|
@@ -92,10 +98,16 @@ Most of the tests require env variables with valid values. Visit tests source co
|
|
92
98
|
* `MAILINATOR_TEST_MESSAGE_WITH_ATTACHMENT_ID` - existing message id within inbox (see above) within private domain (see above); see also https://manybrain.github.io/m8rdocs/#fetch-message
|
93
99
|
* `MAILINATOR_TEST_ATTACHMENT_ID` - existing message id within inbox (see above) within private domain (see above); see also https://manybrain.github.io/m8rdocs/#fetch-message
|
94
100
|
* `MAILINATOR_TEST_DELETE_DOMAIN` - don't use it unless you are 100% sure what you are doing
|
101
|
+
* `MAILINATOR_TEST_WEBHOOKTOKEN_PRIVATEDOMAIN` - private domain for webhook token
|
102
|
+
* `MAILINATOR_TEST_WEBHOOKTOKEN_CUSTOMSERVICE` - custom service for webhook token
|
103
|
+
* `MAILINATOR_TEST_AUTH_SECRET` - authenticator secret
|
104
|
+
* `MAILINATOR_TEST_AUTH_ID` - authenticator id
|
105
|
+
* `MAILINATOR_TEST_WEBHOOK_INBOX` - inbox for webhook
|
106
|
+
* `MAILINATOR_TEST_WEBHOOK_CUSTOMSERVICE` - custom service for webhook
|
95
107
|
|
96
108
|
|
97
109
|
*****
|
98
110
|
|
99
|
-
Copyright (c)
|
111
|
+
Copyright (c) 2024 Manybrain, Inc
|
100
112
|
|
101
113
|
<https://www.mailinator.com/>
|
@@ -0,0 +1,71 @@
|
|
1
|
+
# Authenticators Actions
|
2
|
+
|
3
|
+
Details on the various actions that can be performed on the Authenticators resource, including the expected parameters and the potential responses.
|
4
|
+
|
5
|
+
##### Contents
|
6
|
+
|
7
|
+
* [InstantTOTP2FACode](#instanttotp2facode)
|
8
|
+
* [GetAuthenticators](#getauthenticators)
|
9
|
+
* [GetAuthenticatorsById](#getauthenticatorsbyid)
|
10
|
+
* [GetAuthenticator](#getauthenticator)
|
11
|
+
* [GetAuthenticatorById](#getauthenticatorbyid)
|
12
|
+
|
13
|
+
<br/>
|
14
|
+
|
15
|
+
## InstantTOTP2FACode
|
16
|
+
|
17
|
+
Instant TOTP 2FA code
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
result = client.authenticators.instant_totp_2fa_code()
|
21
|
+
|
22
|
+
puts result
|
23
|
+
```
|
24
|
+
|
25
|
+
<br/>
|
26
|
+
|
27
|
+
## GetAuthenticators
|
28
|
+
|
29
|
+
Fetch Authenticators
|
30
|
+
|
31
|
+
```ruby
|
32
|
+
result = client.authenticators.get_authenticators()
|
33
|
+
|
34
|
+
puts result
|
35
|
+
```
|
36
|
+
|
37
|
+
<br/>
|
38
|
+
|
39
|
+
## GetAuthenticatorsById
|
40
|
+
|
41
|
+
Fetch the TOTP 2FA code from one of your saved Keys
|
42
|
+
|
43
|
+
```ruby
|
44
|
+
result = client.authenticators.get_authenticators_by_id()
|
45
|
+
|
46
|
+
puts result
|
47
|
+
```
|
48
|
+
|
49
|
+
<br/>
|
50
|
+
|
51
|
+
## GetAuthenticator
|
52
|
+
|
53
|
+
Fetch Authenticator
|
54
|
+
|
55
|
+
```ruby
|
56
|
+
result = client.authenticators.get_authenticator()
|
57
|
+
|
58
|
+
puts result
|
59
|
+
```
|
60
|
+
|
61
|
+
<br/>
|
62
|
+
|
63
|
+
## GetAuthenticatorById
|
64
|
+
|
65
|
+
Fetch Authenticator By Id
|
66
|
+
|
67
|
+
```ruby
|
68
|
+
result = client.authenticators.get_authenticator_by_id()
|
69
|
+
|
70
|
+
puts result
|
71
|
+
```
|
data/docs/domains.md
CHANGED
@@ -6,6 +6,8 @@ Details on the various actions that can be performed on the Domains resource, in
|
|
6
6
|
|
7
7
|
* [GetDomains](#getdomains)
|
8
8
|
* [GetDomain](#getdomain)
|
9
|
+
* [CreateDomain](#createdomain)
|
10
|
+
* [DeleteDomain](#deletedomain)
|
9
11
|
|
10
12
|
<br/>
|
11
13
|
|
@@ -30,3 +32,27 @@ result = client.domains.get_domain(domainId: my_domain_id)
|
|
30
32
|
|
31
33
|
puts result
|
32
34
|
```
|
35
|
+
|
36
|
+
<br/>
|
37
|
+
|
38
|
+
## CreateDomain
|
39
|
+
|
40
|
+
This endpoint creates a private domain attached to your account. Note, the domain must be unique to the system and you must have not reached your maximum number of Private Domains.
|
41
|
+
|
42
|
+
```ruby
|
43
|
+
result = client.domains.create_domain(domainId: my_domain_id)
|
44
|
+
|
45
|
+
puts result
|
46
|
+
```
|
47
|
+
|
48
|
+
<br/>
|
49
|
+
|
50
|
+
## DeleteDomain
|
51
|
+
|
52
|
+
This endpoint deletes a Private Domain
|
53
|
+
|
54
|
+
```ruby
|
55
|
+
result = client.domains.delete_domain(domainId: my_domain_id)
|
56
|
+
|
57
|
+
puts result
|
58
|
+
```
|
data/docs/messages.md
CHANGED
@@ -5,15 +5,25 @@ Details on the various actions that can be performed on the Messages resource, i
|
|
5
5
|
##### Contents
|
6
6
|
|
7
7
|
* [FetchInbox](#fetchinbox)
|
8
|
+
* [FetchInboxMessage](#fetchinboxmessage)
|
8
9
|
* [FetchMessage](#fetchmessage)
|
9
10
|
* [FetchSMSMessage](#fetchsmsmessage)
|
10
|
-
* [
|
11
|
-
* [
|
11
|
+
* [FetchInboxMessageAttachments](#fetchinboxmessageattachments)
|
12
|
+
* [FetchMessageAttachments](#fetchmessageattachments)
|
13
|
+
* [FetchInboxMessageAttachment](#fetchinboxmessageattachment)
|
14
|
+
* [FetchMessageAttachment](#fetchmessageattachment)
|
12
15
|
* [FetchMessageLinks](#fetchmessagelinks)
|
16
|
+
* [FetchInboxMessageLinks](#fetchinboxmessagelinks)
|
13
17
|
* [DeleteAllDomainMessages](#deletealldomainmessages)
|
14
18
|
* [DeleteAllInboxMessages](#deleteallinboxmessages)
|
15
19
|
* [DeleteMessage](#deletemessage)
|
16
|
-
* [
|
20
|
+
* [PostMessage](#postmessage)
|
21
|
+
* [FetchMessageSmtpLog](#fetchmessagesmtplog)
|
22
|
+
* [FetchInboxMessageSmtpLog](#fetchinboxmessagesmtplog)
|
23
|
+
* [FetchMessageRaw](#fetchmessageraw)
|
24
|
+
* [FetchInboxMessageRaw](#fetchinboxmessageraw)
|
25
|
+
* [FetchLatestMessages](#fetchlatestmessages)
|
26
|
+
* [FetchLatestInboxMessages](#fetchlatestinboxmessages)
|
17
27
|
|
18
28
|
<br/>
|
19
29
|
|
@@ -35,12 +45,12 @@ puts result
|
|
35
45
|
|
36
46
|
<br/>
|
37
47
|
|
38
|
-
##
|
48
|
+
## FetchInboxMessage
|
39
49
|
|
40
|
-
Retrieves a specific message by id
|
50
|
+
Retrieves a specific message by id for specific inbox
|
41
51
|
|
42
52
|
```ruby
|
43
|
-
result = client.messages.
|
53
|
+
result = client.messages.fetch_inbox_message(
|
44
54
|
domainId: my_domain_id
|
45
55
|
inbox: my_inbox
|
46
56
|
messageId: my_message_id)
|
@@ -50,6 +60,19 @@ puts result
|
|
50
60
|
|
51
61
|
<br/>
|
52
62
|
|
63
|
+
## FetchMessage
|
64
|
+
|
65
|
+
Retrieves a specific message by id
|
66
|
+
|
67
|
+
```ruby
|
68
|
+
result = client.messages.fetch_message(
|
69
|
+
domainId: my_domain_id
|
70
|
+
messageId: my_message_id)
|
71
|
+
|
72
|
+
puts result
|
73
|
+
```
|
74
|
+
|
75
|
+
<br/>
|
53
76
|
|
54
77
|
## FetchSMSMessage
|
55
78
|
|
@@ -67,12 +90,12 @@ puts result
|
|
67
90
|
<br/>
|
68
91
|
|
69
92
|
|
70
|
-
##
|
93
|
+
## FetchInboxMessageAttachments
|
71
94
|
|
72
|
-
Retrieves a list of attachments for a message
|
95
|
+
Retrieves a list of attachments for a message for specific inbox
|
73
96
|
|
74
97
|
```ruby
|
75
|
-
result = client.messages.
|
98
|
+
result = client.messages.fetch_inbox_message_attachments(
|
76
99
|
domainId: my_domain_id
|
77
100
|
inbox: my_inbox
|
78
101
|
messageId: my_message_id)
|
@@ -82,13 +105,27 @@ puts result
|
|
82
105
|
|
83
106
|
<br/>
|
84
107
|
|
108
|
+
## FetchMessageAttachments
|
85
109
|
|
86
|
-
|
110
|
+
Retrieves a list of attachments for a message
|
87
111
|
|
88
|
-
|
112
|
+
```ruby
|
113
|
+
result = client.messages.fetch_message_attachments(
|
114
|
+
domainId: my_domain_id
|
115
|
+
messageId: my_message_id)
|
116
|
+
|
117
|
+
puts result
|
118
|
+
```
|
119
|
+
|
120
|
+
<br/>
|
121
|
+
|
122
|
+
|
123
|
+
## FetchInboxMessageAttachment
|
124
|
+
|
125
|
+
Retrieves a specific attachment for specific inbox
|
89
126
|
|
90
127
|
```ruby
|
91
|
-
result = client.messages.
|
128
|
+
result = client.messages.fetch_inbox_message_attachment(
|
92
129
|
domainId: my_domain_id
|
93
130
|
inbox: my_inbox
|
94
131
|
messageId: my_message_id
|
@@ -99,6 +136,21 @@ puts result
|
|
99
136
|
|
100
137
|
<br/>
|
101
138
|
|
139
|
+
## FetchMessageAttachment
|
140
|
+
|
141
|
+
Retrieves a specific attachment
|
142
|
+
|
143
|
+
```ruby
|
144
|
+
result = client.messages.fetch_message_attachment(
|
145
|
+
domainId: my_domain_id
|
146
|
+
messageId: my_message_id
|
147
|
+
attachmentId: my_attachment_id)
|
148
|
+
|
149
|
+
puts result
|
150
|
+
```
|
151
|
+
|
152
|
+
<br/>
|
153
|
+
|
102
154
|
|
103
155
|
## FetchMessageLinks
|
104
156
|
|
@@ -106,6 +158,20 @@ Retrieves all links found within a given email
|
|
106
158
|
|
107
159
|
```ruby
|
108
160
|
result = client.messages.fetch_message_links(
|
161
|
+
domainId: my_domain_id
|
162
|
+
messageId: my_message_id)
|
163
|
+
|
164
|
+
puts result
|
165
|
+
```
|
166
|
+
|
167
|
+
<br/>
|
168
|
+
|
169
|
+
## FetchInboxMessageLinks
|
170
|
+
|
171
|
+
Retrieves all links found within a given email for specific inbox
|
172
|
+
|
173
|
+
```ruby
|
174
|
+
result = client.messages.fetch_inbox_message_links(
|
109
175
|
domainId: my_domain_id
|
110
176
|
inbox: my_inbox
|
111
177
|
messageId: my_message_id)
|
@@ -162,15 +228,105 @@ puts result
|
|
162
228
|
<br/>
|
163
229
|
|
164
230
|
|
165
|
-
##
|
231
|
+
## PostMessage
|
166
232
|
|
167
233
|
Deliver a JSON message into your private domain
|
168
234
|
|
169
235
|
```ruby
|
170
|
-
result = client.messages.
|
236
|
+
result = client.messages.post_message(
|
171
237
|
domainId: my_domain_id
|
172
238
|
inbox: my_inbox
|
173
239
|
messageToPost: my_message_to_post)
|
174
240
|
|
175
241
|
puts result
|
176
242
|
```
|
243
|
+
|
244
|
+
<br/>
|
245
|
+
|
246
|
+
|
247
|
+
## FetchMessageSmtpLog
|
248
|
+
|
249
|
+
Retrieves all smtp log found within a given email
|
250
|
+
|
251
|
+
```ruby
|
252
|
+
result = client.messages.fetch_message_smtp_log(
|
253
|
+
domainId: my_domain_id
|
254
|
+
messageId: my_message_id)
|
255
|
+
|
256
|
+
puts result
|
257
|
+
```
|
258
|
+
|
259
|
+
<br/>
|
260
|
+
|
261
|
+
## FetchInboxMessageSmtpLog
|
262
|
+
|
263
|
+
Retrieves all smtp log found within a given email for specific inbox
|
264
|
+
|
265
|
+
```ruby
|
266
|
+
result = client.messages.fetch_inbox_message_smtp_log(
|
267
|
+
domainId: my_domain_id
|
268
|
+
inbox: my_inbox
|
269
|
+
messageId: my_message_id)
|
270
|
+
|
271
|
+
puts result
|
272
|
+
```
|
273
|
+
|
274
|
+
<br/>
|
275
|
+
|
276
|
+
|
277
|
+
## FetchMessageRaw
|
278
|
+
|
279
|
+
Retrieves all raw data found within a given email
|
280
|
+
|
281
|
+
```ruby
|
282
|
+
result = client.messages.fetch_message_raw(
|
283
|
+
domainId: my_domain_id
|
284
|
+
messageId: my_message_id)
|
285
|
+
|
286
|
+
puts result
|
287
|
+
```
|
288
|
+
|
289
|
+
<br/>
|
290
|
+
|
291
|
+
## FetchInboxMessageLinks
|
292
|
+
|
293
|
+
Retrieves all raw data found within a given email for specific inbox
|
294
|
+
|
295
|
+
```ruby
|
296
|
+
result = client.messages.fetch_inbox_message_raw(
|
297
|
+
domainId: my_domain_id
|
298
|
+
inbox: my_inbox
|
299
|
+
messageId: my_message_id)
|
300
|
+
|
301
|
+
puts result
|
302
|
+
```
|
303
|
+
|
304
|
+
<br/>
|
305
|
+
|
306
|
+
|
307
|
+
## FetchLatestMessages
|
308
|
+
|
309
|
+
That fetches the latest 5 FULL messages
|
310
|
+
|
311
|
+
```ruby
|
312
|
+
result = client.messages.fetch_latest_messages(
|
313
|
+
domainId: my_domain_id
|
314
|
+
messageId: my_message_id)
|
315
|
+
|
316
|
+
puts result
|
317
|
+
```
|
318
|
+
|
319
|
+
<br/>
|
320
|
+
|
321
|
+
## FetchLatestInboxMessages
|
322
|
+
|
323
|
+
That fetches the latest 5 FULL messages for specific inbox
|
324
|
+
|
325
|
+
```ruby
|
326
|
+
result = client.messages.fetch_latest_inbox_messages(
|
327
|
+
domainId: my_domain_id
|
328
|
+
inbox: my_inbox
|
329
|
+
messageId: my_message_id)
|
330
|
+
|
331
|
+
puts result
|
332
|
+
```
|
data/docs/webhooks.md
ADDED
@@ -0,0 +1,125 @@
|
|
1
|
+
# Webhooks Actions
|
2
|
+
|
3
|
+
Details on the various actions that can be performed on the Webhooks resource, including the expected parameters and the potential responses.
|
4
|
+
|
5
|
+
##### Contents
|
6
|
+
|
7
|
+
* [PublicWebhook](#publicwebhook)
|
8
|
+
* [PublicInboxWebhook](#publicinboxwebhook)
|
9
|
+
* [PublicCustomServiceWebhook](#publiccustomservicewebhook)
|
10
|
+
* [PublicCustomServiceInboxWebhook](#publiccustomserviceinboxwebhook)
|
11
|
+
* [PrivateWebhook](#privatewebhook)
|
12
|
+
* [PrivateInboxWebhook](#privateinboxwebhook)
|
13
|
+
* [PrivateCustomServiceWebhook](#privatecustomservicewebhook)
|
14
|
+
* [PrivateCustomServiceInboxWebhook](#privatecustomserviceinboxwebhook)
|
15
|
+
|
16
|
+
<br/>
|
17
|
+
|
18
|
+
## PublicWebhook
|
19
|
+
|
20
|
+
This command will deliver the message to the :to inbox that was set into request object
|
21
|
+
|
22
|
+
```ruby
|
23
|
+
result = client.webhooks.public_webhook()
|
24
|
+
|
25
|
+
puts result
|
26
|
+
```
|
27
|
+
|
28
|
+
<br/>
|
29
|
+
|
30
|
+
## PublicInboxWebhook
|
31
|
+
|
32
|
+
This command will deliver the message to the :inbox inbox
|
33
|
+
Note that if the Mailinator system cannot determine the destination inbox via the URL or a "to" field in the payload, the message will be rejected.
|
34
|
+
If the message contains a "from" and "subject" field, these will be visible on the inbox page.
|
35
|
+
|
36
|
+
|
37
|
+
```ruby
|
38
|
+
result = client.webhooks.public_inbox_webhook()
|
39
|
+
|
40
|
+
puts result
|
41
|
+
```
|
42
|
+
|
43
|
+
<br/>
|
44
|
+
|
45
|
+
## PublicCustomServiceWebhook
|
46
|
+
|
47
|
+
If you have a Twilio account which receives incoming SMS messages. You may direct those messages through this facility to inject those messages into the Mailinator system.
|
48
|
+
|
49
|
+
```ruby
|
50
|
+
result = client.webhooks.public_custom_service_webhook()
|
51
|
+
|
52
|
+
puts result
|
53
|
+
```
|
54
|
+
|
55
|
+
<br/>
|
56
|
+
|
57
|
+
## PublicCustomServiceInboxWebhook
|
58
|
+
|
59
|
+
The SMS message will arrive in the Public Mailinator inbox corresponding to the Twilio Phone Number. (only the digits, if a plus sign precedes the number it will be removed)
|
60
|
+
If you wish the message to arrive in a different inbox, you may append the destination inbox to the URL.
|
61
|
+
|
62
|
+
```ruby
|
63
|
+
result = client.webhooks.public_custom_service_inbox_webhook()
|
64
|
+
|
65
|
+
puts result
|
66
|
+
```
|
67
|
+
|
68
|
+
<br/>
|
69
|
+
|
70
|
+
## PrivateWebhook
|
71
|
+
|
72
|
+
This command will Webhook messages into your Private Domain
|
73
|
+
The incoming Webhook will arrive in the inbox designated by the "to" field in the incoming request payload.
|
74
|
+
Webhooks into your Private System do NOT use your regular API Token.
|
75
|
+
This is because a typical use case is to enter the Webhook URL into 3rd-party systems(i.e.Twilio, Zapier, IFTTT, etc) and you should never give out your API Token.
|
76
|
+
Check your Team Settings where you can create "Webhook Tokens" designed for this purpose.
|
77
|
+
|
78
|
+
```ruby
|
79
|
+
result = client.webhooks.private_webhook()
|
80
|
+
|
81
|
+
puts result
|
82
|
+
```
|
83
|
+
|
84
|
+
<br/>
|
85
|
+
|
86
|
+
## PrivatePublicInboxWebhook
|
87
|
+
|
88
|
+
This command will deliver the message to the :inbox inbox
|
89
|
+
Incoming Webhooks are delivered to Mailinator inboxes and from that point onward are not notably different than other messages in the system (i.e. emails).
|
90
|
+
As normal, Mailinator will list all messages in the Inbox page and via the Inbox API calls.
|
91
|
+
If the incoming JSON payload does not contain a "from" or "subject", then dummy values will be inserted in these fields.
|
92
|
+
You may retrieve such messages via the Web Interface, the API, or the Rule System
|
93
|
+
|
94
|
+
```ruby
|
95
|
+
result = client.webhooks.private_inbox_webhook()
|
96
|
+
|
97
|
+
puts result
|
98
|
+
```
|
99
|
+
|
100
|
+
<br/>
|
101
|
+
|
102
|
+
## PrivateCustomServiceWebhook
|
103
|
+
|
104
|
+
If you have a Twilio account which receives incoming SMS messages. You may direct those messages through this facility to inject those messages into the Mailinator system.
|
105
|
+
Mailinator intends to apply specific mappings for certain services that commonly publish webhooks.
|
106
|
+
If you test incoming Messages to SMS numbers via Twilio, you may use this endpoint to correctly map "to", "from", and "subject" of those messages to the Mailinator system.By default, the destination inbox is the Twilio phone number.
|
107
|
+
|
108
|
+
```ruby
|
109
|
+
result = client.webhooks.private_custom_service_webhook()
|
110
|
+
|
111
|
+
puts result
|
112
|
+
```
|
113
|
+
|
114
|
+
<br/>
|
115
|
+
|
116
|
+
## PrivateCustomServiceInboxWebhook
|
117
|
+
|
118
|
+
The SMS message will arrive in the Private Mailinator inbox corresponding to the Twilio Phone Number. (only the digits, if a plus sign precedes the number it will be removed)
|
119
|
+
If you wish the message to arrive in a different inbox, you may append the destination inbox to the URL.
|
120
|
+
|
121
|
+
```ruby
|
122
|
+
result = client.webhooks.private_custom_service_inbox_webhook()
|
123
|
+
|
124
|
+
puts result
|
125
|
+
```
|