mailslurp_client 11.5.12 → 11.6.1

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: 0c81495895a837127a6082747e91465f8f25448b2b06bdab0203d359830ae218
4
- data.tar.gz: 46dd3dcedd667952e9f2990e3191734deac66ea830d39fab3fc8540964967ae6
3
+ metadata.gz: b42ddbaa3c00ec96e610e4cefb8921edfb3ef2a0086d6390d079ce0db46569b0
4
+ data.tar.gz: 8b3e8c84b3a0e21a1cabc737b9268baaf36ad5b35478a83f06175947dc95826b
5
5
  SHA512:
6
- metadata.gz: 7ff48a7a2f1b0ac2a92e3049394aec2de1bad71cd0e375a30ceeee49cd013ae5f654457943d12e4166e41eac1ada830ae4d9a49ee782a34f67c7f5a7289ac283
7
- data.tar.gz: b6f91968fe6c6c81da977ff807a9cbe6fc78ed670fb7ba5ff709f5e2c9bf4329da5bf7e66ea1e211ed965fb19997df18c2d18c03d3662a0eb23875731ec5a525
6
+ metadata.gz: 7e6651f3090e034e0105f957d840c5560243a6bd11bfb4f86cdfb9fc7b44cf27e1351bcee299636ae1029751ce51f9de143b836f52a11457aa30ba45aa8bf82f
7
+ data.tar.gz: f875a5dc851b1920a9d5bc1137ed3073435eb2675d763cf2d6baaa7080443e866a17f159c2c804494d449ffdf64e6e3254d278e03d11e9cb01970b5ca05f9517
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.12'
14
+ VERSION = '11.6.1'
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.12
4
+ version: 11.6.1
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-31 00:00:00.000000000 Z
11
+ date: 2021-04-08 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.