mailslurp_client 11.5.10 → 11.5.22

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3dd4611ba63105c0e944fe7776c94abef65dcf662d474f0dabd3569f7131f40b
4
- data.tar.gz: 6bb63c76f8e3ae0390753a5cdd09797ec4e4659d6b8aeafcff0bbd0b27cdd45a
3
+ metadata.gz: 827d6abc269eec3a1b01c95fbd2858769b83b59fcb0ac06e15cbb2e01e214d6c
4
+ data.tar.gz: d9766f4ba5bf59f75bec870f4dfcadc4e8966a051b8d3b51b85382775133025e
5
5
  SHA512:
6
- metadata.gz: 1fe8816ff49ea7d8e2f7c01ebe98d118718c5cd6179f868bb6e5446d26cba17bfb6de5dbcf3a749f7c422034b80ae20733ecde717c0cf77b0b2c361cf26d6843
7
- data.tar.gz: 99c21481fa8b37b1cd0136a27e30a6450d9dd5359af0872a587bbe2c7bdbcee8c21336a305448672730fbbd6110b4abfe1b3b11d97e9080f0f3774c70e09ce5e
6
+ metadata.gz: 35a99f168743c1d4c5e52a3c240d0a776b295a76492a58fdeaffc516f5158dd12d3bff652550539f1bd74dbfdaa3194cbf4860cd0285330d3e98e0d8c016c98d
7
+ data.tar.gz: 5cbcc36a39990f4276409f03c52871b55946755bb7f45a65088d2e5f9f62d5878ac58ec56e09b4c60c50801d41d7eb4e48f2417c346db569b573a69d45644597
data/README.md CHANGED
@@ -24,7 +24,7 @@ First you'll need an API Key. [Create a free account](https://app.mailslurp.com)
24
24
 
25
25
  ### Ruby requirements
26
26
 
27
- The MailSlurp client requires Ruby 2.x and the ruby-dev package. You most likely have these packages but if not:
27
+ The MailSlurp client requires Ruby 2.x or 3.x and the ruby-dev package. You most likely have these packages but if not:
28
28
 
29
29
  `sudo apt-get install ruby-dev`
30
30
 
@@ -47,6 +47,9 @@ gem install bundler
47
47
  bundle install
48
48
  ```
49
49
 
50
+ #### Libcurl requirements
51
+ You may need to install `typhoeus` if you encounter libcurl errors.
52
+
50
53
 
51
54
  ### Configure the client
52
55
 
@@ -191,6 +194,24 @@ expect(email.subject).to include("Test")
191
194
  expect(email.body).to include("Your email body")
192
195
  ```
193
196
 
197
+ ### Extract email content
198
+ To parse an email and extract content use regex patterns like so:
199
+
200
+ ```ruby
201
+ wait_controller = MailSlurpClient::WaitForControllerApi.new
202
+ email = wait_controller.wait_for_latest_email({ inbox_id: inbox.id, unread_only: true, timeout: 30_000 })
203
+
204
+ # assert the email is a confirmation
205
+ expect(email.subject).to include("Please confirm your email address")
206
+
207
+ # extract a 6 digit code from the email body
208
+ match = email.body.match(/code is ([0-9]{6})/)
209
+ if match == nil then
210
+ raise "Could not find match in body #{email.body}"
211
+ end
212
+ code, * = match.captures
213
+ ```
214
+
194
215
  ### Attachments
195
216
 
196
217
  You can send attachments by first uploading files with the `AttachmentControllerApi` then using the returned attachment IDs in the send email method.
@@ -122,6 +122,10 @@ module MailSlurpClient
122
122
  invalid_properties.push('invalid value for "id", id cannot be nil.')
123
123
  end
124
124
 
125
+ if @team_access.nil?
126
+ invalid_properties.push('invalid value for "team_access", team_access cannot be nil.')
127
+ end
128
+
125
129
  invalid_properties
126
130
  end
127
131
 
@@ -131,6 +135,7 @@ module MailSlurpClient
131
135
  return false if @created_at.nil?
132
136
  return false if @favourite.nil?
133
137
  return false if @id.nil?
138
+ return false if @team_access.nil?
134
139
  true
135
140
  end
136
141
 
@@ -11,5 +11,5 @@ OpenAPI Generator version: 4.3.1
11
11
  =end
12
12
 
13
13
  module MailSlurpClient
14
- VERSION = '11.5.10'
14
+ VERSION = '11.5.22'
15
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mailslurp_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 11.5.10
4
+ version: 11.5.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - mailslurp
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-29 00:00:00.000000000 Z
11
+ date: 2021-04-07 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Create emails addresses in Ruby then send and receive real emails and
14
14
  attachments. See https://www.mailslurp.com/docs/ruby/ for full Ruby documentation.