verifalia 2.0.0 → 2.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (31) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +1 -1
  3. data/README.md +134 -47
  4. data/lib/verifalia/client.rb +31 -2
  5. data/lib/verifalia/credits/balance.rb +29 -0
  6. data/lib/verifalia/credits/client.rb +29 -0
  7. data/lib/verifalia/email_validation/client.rb +33 -3
  8. data/lib/verifalia/email_validation/completion_callback.rb +29 -0
  9. data/lib/verifalia/email_validation/entry.rb +40 -5
  10. data/lib/verifalia/email_validation/entry_classification.rb +49 -0
  11. data/lib/verifalia/email_validation/entry_status.rb +181 -0
  12. data/lib/verifalia/email_validation/exported_entries_format.rb +46 -0
  13. data/lib/verifalia/email_validation/job.rb +37 -5
  14. data/lib/verifalia/email_validation/job_status.rb +49 -0
  15. data/lib/verifalia/email_validation/overview.rb +39 -7
  16. data/lib/verifalia/email_validation/progress.rb +29 -0
  17. data/lib/verifalia/email_validation/request.rb +29 -0
  18. data/lib/verifalia/email_validation/request_entry.rb +29 -0
  19. data/lib/verifalia/email_validation/wait_options.rb +29 -0
  20. data/lib/verifalia/rest/client.rb +31 -2
  21. data/lib/verifalia/security/certificate_authenticator.rb +29 -0
  22. data/lib/verifalia/security/username_password_authenticator.rb +29 -0
  23. data/lib/verifalia.rb +46 -3
  24. data/sig/verifalia/email_validations/entry.rbs +2 -0
  25. data/sig/verifalia/email_validations/entry_classification.rbs +10 -0
  26. data/sig/verifalia/email_validations/entry_status.rbs +50 -0
  27. data/sig/verifalia/email_validations/exported_entries_format.rbs +9 -0
  28. data/sig/verifalia/email_validations/job_status.rbs +10 -0
  29. data/sig/verifalia/security/certificate_authenticator.rbs +8 -0
  30. data/verifalia.gemspec +1 -1
  31. metadata +19 -10
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 14650c8b1a2409f0c037e1e5348c445434fcf22930bb465f78e548c7fb42b4ca
4
- data.tar.gz: ceb6552a4935d73b4488558d8e11ae1de15de1b740a92811eb9240984497e446
3
+ metadata.gz: 44ed994694aed8628bc1b148b0cb244a9c980a62df4ec4cc22146a0b45dd9de8
4
+ data.tar.gz: 4ad8bf1d5a27d1a9fa5dab24af73e309a31c42562f0bafa47d53ecb1883b945a
5
5
  SHA512:
6
- metadata.gz: 346075e83859afee3fa6c24b696d889973634eef9bab43febf7c60742b992f08d80035457c6c334f06e8995ac78016ff5b7300cd179a6299804755650fa18691
7
- data.tar.gz: 8e5b6be8fe6528bd04b605ff61e39289017a114f31322229595bfd90964f1d6ac596d1aeb0a2eac4317752e367002d68f278a8aae0519e3fc4797beb6a6d8130
6
+ metadata.gz: bef360e74489bda543cc8120a043ac3d573d2e868da611217e094fe1be9ce23ce9c973017bc2dd0d03f0484ff7999814a8bf6d50d83a9c940412997d4e36ce0a
7
+ data.tar.gz: efc315ccf5a5c98f4144597c3307f594b79740d7e0aed16f3566d62ba90b46a5161158e43be89742700b5da45042aee17ababfa27433a472cc7b65b417655a76
data/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2014-2023 Cobisi Research - https://verifalia.com/
3
+ Copyright (c) 2014-2024 Cobisi Research - https://verifalia.com/
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/README.md CHANGED
@@ -1,40 +1,59 @@
1
- ![Verifalia API](https://img.shields.io/badge/Verifalia%20API-v2.4-green)
1
+ ![Verifalia API](https://img.shields.io/badge/Verifalia%20API-v2.5-green)
2
2
  [![Gem Version](https://badge.fury.io/rb/verifalia.svg)](https://badge.fury.io/rb/verifalia)
3
3
 
4
- # Verifalia - Ruby gem
4
+ # Verifalia API - Ruby gem
5
5
 
6
- [Verifalia](https://verifalia.com/) provides a simple HTTPS-based API for **validating email addresses in
7
- real-time** and checking whether they are deliverable or not; this SDK library integrates with Verifalia
8
- and allows to [verify email addresses](https://verifalia.com/) in **Ruby 2.6.0 or higher**.
6
+ This SDK library integrates with Verifalia and allows to [verify email addresses](https://verifalia.com/) in **Ruby 2.6.0 or higher**.
7
+
8
+ [Verifalia](https://verifalia.com/) is an online service that provides email verification and mailing list cleaning; it helps businesses reduce
9
+ their bounce rate, protect their sender reputation, and ensure their email campaigns reach the intended recipients.
10
+ Verifalia can [verify email addresses](https://verifalia.com/) in real-time or in bulk, using its API or client area; it also
11
+ offers various features and settings to customize the verification process according to the user’s needs.
12
+
13
+ Verifalia's email verification process consists of several steps, each taking fractions of a second: it checks the **formatting
14
+ and syntax** (RFC 1123, RFC 2821, RFC 2822, RFC 3490, RFC 3696, RFC 4291, RFC 5321, RFC 5322, and RFC 5336) of each email address,
15
+ the **domain and DNS records**, the **mail exchangers**, and the **mailbox existence**, with support for internationalized domains
16
+ and mailboxes. It also detects risky email types, such as **catch-all**, **disposable**, or **spam traps** / **honeypots**.
17
+
18
+ Verifalia provides detailed and **accurate reports** for each email verification: it categorizes each email address as `Deliverable`,
19
+ `Undeliverable`, `Risky`, or `Unknown`, and assigns one of its exclusive set of over 40 [status codes](https://verifalia.com/developers#email-validations-status-codes).
20
+ It also explains the undeliverability reason and provides **comprehensive verification details**. The service allows the user to choose the desired
21
+ quality level, the waiting timeout, the deduplication preferences, the data retention settings, and the callback preferences
22
+ for each verification.
23
+
24
+ Of course, Verifalia never sends emails to the contacts or shares the user's data with anyone.
9
25
 
10
26
  To learn more about Verifalia please see [https://verifalia.com](https://verifalia.com/)
11
27
 
12
28
  ## Table of contents
13
29
 
14
- - [Adding Verifalia to your Ruby app](#adding-verifalia-to-your-ruby-app)
30
+ * [Adding Verifalia to your Ruby app](#adding-verifalia-to-your-ruby-app)
15
31
  * [Authentication](#authentication)
16
- + [Authenticating via X.509 client certificate (TLS mutual authentication)](#authenticating-via-x509-client-certificate--tls-mutual-authentication-)
17
- - [Validating email addresses](#validating-email-addresses)
18
- * [How to validate an email address](#how-to-validate-an-email-address)
19
- * [How to validate a list of email addresses](#how-to-validate-a-list-of-email-addresses)
32
+ * [Authenticating via Basic Auth](#authenticating-via-basic-auth)
33
+ * [Authenticating via X.509 client certificate (TLS mutual authentication)](#authenticating-via-x509-client-certificate-tls-mutual-authentication)
34
+ * [Verifying email addresses](#verifying-email-addresses)
35
+ * [How to verify an email address](#how-to-verify-an-email-address)
36
+ * [How to verify a list of email addresses](#how-to-verify-a-list-of-email-addresses)
20
37
  * [Processing options](#processing-options)
21
- + [Quality level](#quality-level)
22
- + [Deduplication mode](#deduplication-mode)
23
- + [Data retention](#data-retention)
38
+ * [Quality level](#quality-level)
39
+ * [Deduplication mode](#deduplication-mode)
40
+ * [Data retention](#data-retention)
24
41
  * [Wait options](#wait-options)
25
- + [Avoid waiting](#avoid-waiting)
26
- + [Progress tracking](#progress-tracking)
42
+ * [Avoid waiting](#avoid-waiting)
43
+ * [Progress tracking](#progress-tracking)
27
44
  * [Completion callbacks](#completion-callbacks)
28
45
  * [Retrieving jobs](#retrieving-jobs)
29
46
  * [Exporting email verification results in different output formats](#exporting-email-verification-results-in-different-output-formats)
30
- * [Don't forget to clean up, when you are done](#don-t-forget-to-clean-up--when-you-are-done)
31
- - [Managing credits](#managing-credits)
47
+ * [Don't forget to clean up, when you are done](#dont-forget-to-clean-up-when-you-are-done)
48
+ * [Managing credits](#managing-credits)
32
49
  * [Getting the credits balance](#getting-the-credits-balance)
33
- - [Changelog / What's new](#changelog---what-s-new)
50
+ * [Changelog / What's new](#changelog--whats-new)
51
+ * [v2.1](#v21)
52
+ * [v2.0](#v20)
34
53
 
35
54
  ## Adding Verifalia to your Ruby app
36
55
 
37
- To install using [Bundler](https://bundler.io/) grab the latest version:
56
+ Easily include Verifalia in your Ruby application using [Bundler](https://bundler.io/); just add the following line to your Gemfile to get the latest version:
38
57
 
39
58
  ```ruby
40
59
  gem 'verifalia'
@@ -46,7 +65,7 @@ To manually install `verifalia` via Rubygems simply run `gem install`:
46
65
  gem install verifalia
47
66
  ```
48
67
 
49
- ### Authentication ###
68
+ ### Authentication
50
69
 
51
70
  First things first: authentication to the Verifalia API is performed by way of either the credentials
52
71
  of your root Verifalia account or of one of its users (previously known as sub-accounts): if you don't
@@ -56,10 +75,12 @@ for accessing the API, as doing so will allow to assign only the specific needed
56
75
 
57
76
  Learn more about authenticating to the Verifalia API at [https://verifalia.com/developers#authentication](https://verifalia.com/developers#authentication)
58
77
 
59
- Once you have your Verifalia credentials at hand, use them while creating a new instance of the
60
- `Verifalia::Client` class, which will be the starting point to every other operation against the
61
- Verifalia API: the supplied credentials will be automatically provided to the API using the HTTP
62
- Basic Auth method.
78
+ #### Authenticating via Basic Auth
79
+
80
+ The most straightforward method for authenticating against the Verifalia API involves using a username and password pair.
81
+ These credentials can be applied during the creation of a new instance of the `Verifalia::Client` class, serving as the
82
+ initial step for all interactions with the Verifalia API: the provided username and password will be automatically
83
+ transmitted to the API using the HTTP Basic Auth method.
63
84
 
64
85
  ```ruby
65
86
  require 'verifalia'
@@ -88,26 +109,27 @@ verifalia = Verifalia::Client.new ssl_client_cert: './my-cert.pem',
88
109
  See [how to create a self-signed X.509 client certificate for TLS mutual authentication](https://verifalia.com/help/sub-accounts/how-to-create-self-signed-client-certificate-for-tls-mutual-authentication)
89
110
  on the Verifalia website, for more information on creating your own certificates for the Verifalia API.
90
111
 
91
- ## Validating email addresses ##
112
+ ## Verifying email addresses
92
113
 
93
114
  Every operation related to verifying / validating email addresses is performed through the
94
- `email_validations` property exposed by the `Verifalia::Client` instance you created above, which
95
- exposes some useful functions: in the next few paragraphs we are looking at the most used ones, so
115
+ `email_validations` attribute exposed by the `Verifalia::Client` instance you created above, which
116
+ exposes some useful methods: in the next few paragraphs we are looking at the most used ones, so
96
117
  it is strongly advisable to explore the library and look at the embedded help for other opportunities.
97
118
 
98
119
  **The library automatically waits for the completion of email verification jobs**: if needed, it is possible
99
120
  to adjust the wait options and have more control over the entire underlying polling process. Please refer to
100
121
  the [Wait options](#wait-options) section below for additional details.
101
122
 
102
- ### How to validate an email address ###
123
+ ### How to verify an email address
103
124
 
104
125
  To validate an email address from a Ruby application you can invoke the `submit()` method: it
105
126
  accepts one or more email addresses and any eventual verification options you wish to pass to Verifalia,
106
127
  including the expected results quality, deduplication preferences, processing priority.
107
128
 
108
- In the following example, we verify an email address with this library, using the default options:
129
+ In the following example, we check an email address with this library, using the default options:
109
130
 
110
131
  ```ruby
132
+ # verifalia = Verifalia::Client.new ...
111
133
  job = verifalia.email_validations.submit 'batman@gmail.com'
112
134
 
113
135
  # At this point the address has been validated: let's print its validation
@@ -119,13 +141,61 @@ puts "Classification: #{entry.classification} (status: #{entry.status})"
119
141
  # Classification: Deliverable (status: Success)
120
142
  ```
121
143
 
122
- ### How to validate a list of email addresses ###
144
+ As you may expect, each entry may include various additional details about the verified email address:
145
+
146
+ | Attribute | Description |
147
+ |-----------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
148
+ | `ascii_email_address_domain_part` | Gets the domain part of the email address, converted to ASCII if needed and with comments and folding white spaces stripped off. |
149
+ | `classification` | A string with the classification for this entry; see `Verifalia::EmailValidations::EntryClassification` for a list of the values supported at the time this SDK has been released. |
150
+ | `completed_on` | The date this entry has been completed, if available. |
151
+ | `custom` | A custom, optional string which is passed back upon completing the validation. To pass back and forth a custom value, use the `custom` attribute of `Verifalia::EmailValidations::RequestEntry`. |
152
+ | `duplicate_of` | The zero-based index of the first occurrence of this email address in the parent `Job`, in the event the `status` for this entry is `Duplicate`; duplicated items do not expose any result detail apart from this and the eventual `custom` values. |
153
+ | `index` | The index of this entry within its `Job` container; this property is mostly useful in the event the API returns a filtered view of the items. |
154
+ | `input_data` | The input string being validated. |
155
+ | `email_address` | Gets the email address, without any eventual comment or folding white space. Returns null if the input data is not a syntactically invalid e-mail address. |
156
+ | `email_address_domain_part` | Gets the domain part of the email address, without comments and folding white spaces. |
157
+ | `email_address_local_part` | Gets the local part of the email address, without comments and folding white spaces. |
158
+ | `has_international_domain_name` | If true, the email address has an international domain name. |
159
+ | `has_international_mailbox_name` | If true, the email address has an international mailbox name. |
160
+ | `is_disposable_email_address` | If true, the email address comes from a disposable email address (DEA) provider. <a href="https://verifalia.com/help/email-validations/what-is-a-disposable-email-address-dea">What is a disposable email address?</a> |
161
+ | `is_free_email_address` | If true, the email address comes from a free email address provider (e.g. gmail, yahoo, outlook / hotmail, ...). |
162
+ | `is_role_account` | If true, the local part of the email address is a well-known role account. |
163
+ | `status` | The status for this entry; see `Verifalia::EmailValidations::EntryStatus` for a list of the values supported at the time this SDK has been released. |
164
+ | `suggestions` | The potential corrections for the input data, in the event Verifalia identified potential typos during the verification process. |
165
+ | `syntax_failure_index` | The position of the character in the email address that eventually caused the syntax validation to fail. |
166
+
167
+ Here is another example, showing some of the additional result details provided by Verifalia:
168
+
169
+ ```ruby
170
+ # verifalia = Verifalia::Client.new ...
171
+ job = verifalia.email_validations.submit 'bat[man@gmal.com'
172
+
173
+ entry = job.entries[0]
174
+ puts "Classification: #{entry.classification}"
175
+ puts "Status: #{entry.status}"
176
+ puts "Syntax failure index: #{entry.syntax_failure_index}"
177
+
178
+ puts "Suggestions:"
179
+
180
+ entry.suggestions.each do |suggestion|
181
+ puts "- #{suggestion}"
182
+ end
183
+
184
+ # Classification: Undeliverable
185
+ # Status: InvalidCharacterInSequence
186
+ # Syntax failure index: 3
187
+ # Suggestions:
188
+ # - batman@gmail.com
189
+ ```
190
+
191
+ ### How to verify a list of email addresses
123
192
 
124
- To verify a list of email addresses - instead of a single address - it is possible to pass an array of strings with the
125
- emails to verify to the `submit()` method; here is an example showing how to verify an array with some
193
+ To check a list of email addresses - instead of a single address - it is possible to pass an array of strings with the
194
+ emails to verify to the `submit()` method; here is an example showing how to validate an array with some
126
195
  email addresses:
127
196
 
128
197
  ```ruby
198
+ # verifalia = Verifalia::Client.new ...
129
199
  job = verifalia.email_validations.submit ['batman@gmail.com', 'samantha42@yahoo.it']
130
200
 
131
201
  job.entries.each do |entry|
@@ -152,6 +222,7 @@ to specify the desired quality level; here is an example showing how to verify a
152
222
  the _High_ quality level:
153
223
 
154
224
  ```ruby
225
+ # verifalia = Verifalia::Client.new ...
155
226
  job = verifalia.email_validations.submit 'batman@gmail.com', quality: 'High'
156
227
  ```
157
228
 
@@ -172,6 +243,7 @@ emails = [
172
243
  'samantha42@yahoo.it'
173
244
  ]
174
245
 
246
+ # verifalia = Verifalia::Client.new ...
175
247
  job = verifalia.email_validations.submit entries, deduplication: 'Relaxed'
176
248
  ```
177
249
 
@@ -189,6 +261,7 @@ Here is how, for instance, one can set a data retention policy of 10 minutes whi
189
261
  an email address:
190
262
 
191
263
  ```ruby
264
+ # verifalia = Verifalia::Client.new ...
192
265
  job = verifalia.email_validations.submit 'batman@gmail.com', retention: '0:10:0'
193
266
  ```
194
267
 
@@ -216,6 +289,8 @@ for the `wait_options` keyword argument of the `submit()` method, as shown in th
216
289
 
217
290
  ```ruby
218
291
  wait_options = Verifalia::EmailValidations::WaitOptions.no_wait
292
+
293
+ # verifalia = Verifalia::Client.new ...
219
294
  job = verifalia.email_validations.submit 'elon.musk@tesla.com', wait_options: wait_options
220
295
 
221
296
  puts "Status: #{job.overview.status}"
@@ -227,19 +302,18 @@ puts "Status: #{job.overview.status}"
227
302
  For jobs with a large number of email addresses, it could be useful to track progress as they are processed
228
303
  by the Verifalia email verification engine; to do that, it is possible to create an instance of the
229
304
  `Verifalia::EmailValidations::WaitOptions` class and provide a lambda which eventually receives progress notifications through the
230
- `progress` property.
305
+ `progress` attribute.
231
306
 
232
307
  Here is how to define a progress notification handler which displays the progress percentage of a submitted
233
308
  job to the console window:
234
309
 
235
310
  ```ruby
236
- WaitOptions = Verifalia::EmailValidations::WaitOptions
237
-
238
311
  progress = ->(overview) do
239
312
  puts "Progress: #{(overview.progress&.percentage || 0) * 100}%..."
240
313
  end
241
314
 
242
- wait_options = WaitOptions.new 30 * 1000, 30 * 1000, progress: progress
315
+ wait_options = Verifalia::EmailValidations::WaitOptions.new 30 * 1000, 30 * 1000,
316
+ progress: progress
243
317
 
244
318
  emails = [
245
319
  'alice@example.com',
@@ -247,6 +321,7 @@ emails = [
247
321
  'charlie@example.org'
248
322
  ]
249
323
 
324
+ # verifalia = Verifalia::Client.new ...
250
325
  job = verifalia.email_validations.submit emails, wait_options: wait_options
251
326
  ```
252
327
 
@@ -261,6 +336,7 @@ To specify a completion callback URL, specify the `completion_callback` keyword
261
336
  invoking the `submit()` method, as shown in the example below:
262
337
 
263
338
  ```ruby
339
+ # verifalia = Verifalia::Client.new ...
264
340
  verifalia.email_validations.submit 'batman@gmail.com',
265
341
  completion_callback: {
266
342
  'url' => 'https://your-website-here/foo/bar'
@@ -282,8 +358,8 @@ please see the [Wait options](#wait-options) section for additional details.
282
358
  Here is an example showing how to retrieve a job, given its identifier:
283
359
 
284
360
  ```ruby
285
- job_id = 'ec415ecd-0d0b-49c4-a5f0-f35c182e40ea'
286
- job = verifalia.email_validations.get job_id
361
+ # verifalia = Verifalia::Client.new ...
362
+ job = verifalia.email_validations.get 'ec415ecd-0d0b-49c4-a5f0-f35c182e40ea'
287
363
  ```
288
364
 
289
365
  ### Exporting email verification results in different output formats
@@ -297,13 +373,12 @@ generating a human-readable representation of the verification results.
297
373
  > method instead if you need to rely on a stable output schema.
298
374
 
299
375
  Here is an example showing how to export a given email verification job as an
300
- Excel (xslx) file:
376
+ Excel (.xslx) file:
301
377
 
302
378
  ```ruby
303
- job_id = 'ec415ecd-0d0b-49c4-a5f0-f35c182e40ea'
304
- format = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
305
-
306
- data = verifalia.email_validations.export job_id, format
379
+ # verifalia = Verifalia::Client.new ...
380
+ data = verifalia.email_validations.export 'ec415ecd-0d0b-49c4-a5f0-f35c182e40ea',
381
+ Verifalia::EmailValidations::ExportedEntriesFormat::EXCEL_XLSX
307
382
 
308
383
  File.open('./export.xlsx', 'wb') do |fp|
309
384
  fp.write(data)
@@ -318,25 +393,27 @@ you delete your completed jobs as soon as possible, for privacy and security rea
318
393
  To do that, you can invoke the `delete()` method passing the job Id you wish to get rid of:
319
394
 
320
395
  ```ruby
321
- verifalia.email_validations.delete job_id
396
+ # verifalia = Verifalia::Client.new ...
397
+ verifalia.email_validations.delete 'ec415ecd-0d0b-49c4-a5f0-f35c182e40ea'
322
398
  ```
323
399
 
324
400
  Once deleted, a job is gone and there is no way to retrieve its email validation results.
325
401
 
326
- ## Managing credits ##
402
+ ## Managing credits
327
403
 
328
- To manage the Verifalia credits for your account you can use the `credits` property exposed
404
+ To manage the Verifalia credits for your account you can use the `credits` attribute exposed
329
405
  by the `Verifalia::Client` instance created above. Like for the previous topic, in the next
330
406
  few paragraphs we are looking at the most used operations, so it is strongly advisable to
331
407
  explore the library and look at the embedded documentation for other opportunities.
332
408
 
333
- ### Getting the credits balance ###
409
+ ### Getting the credits balance
334
410
 
335
411
  One of the most common tasks you may need to perform on your account is retrieving the available
336
412
  number of free daily credits and credit packs. To do that, you can use the `get_balance()` method,
337
413
  which returns a `Verifalia::Credits::Balance` object, as shown in the next example:
338
414
 
339
415
  ```ruby
416
+ # verifalia = Verifalia::Client.new ...
340
417
  balance = verifalia.credits.get_balance
341
418
 
342
419
  puts "Credit packs: #{balance.credit_packs}"
@@ -353,6 +430,16 @@ To add credit packs to your Verifalia account visit [https://verifalia.com/clien
353
430
  This section lists the changelog for the current major version of the library: for older versions,
354
431
  please see the [project releases](https://github.com/verifalia/verifalia-ruby-sdk/releases).
355
432
 
433
+ ### v2.1
434
+
435
+ Released on January 18<sup>th</sup>, 2024
436
+
437
+ - Added support for API v2.5
438
+ - Added support for [classification overrides](https://verifalia.com/help/email-validations/what-are-classification-overrides)
439
+ - Added support for AI-powered suggestions
440
+ - Added `EntryClassification`, `EntryStatus`, `ExportedEntriesFormat` and `JobStatus` module constants
441
+ - Improved documentation
442
+
356
443
  ### v2.0
357
444
 
358
445
  Released on March 12<sup>th</sup>, 2023
@@ -1,5 +1,34 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # Verifalia - Email list cleaning and real-time email verification service
4
+ # https://verifalia.com/
5
+ # support@verifalia.com
6
+ #
7
+ # Copyright (c) 2005-2024 Cobisi Research
8
+ #
9
+ # Cobisi Research
10
+ # Via Della Costituzione, 31
11
+ # 35010 Vigonza
12
+ # Italy - European Union
13
+ #
14
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
15
+ # of this software and associated documentation files (the "Software"), to deal
16
+ # in the Software without restriction, including without limitation the rights
17
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
18
+ # copies of the Software, and to permit persons to whom the Software is
19
+ # furnished to do so, subject to the following conditions:
20
+ #
21
+ # The above copyright notice and this permission notice shall be included in
22
+ # all copies or substantial portions of the Software.
23
+ #
24
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
25
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
27
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
30
+ # THE SOFTWARE.
31
+
3
32
  require 'openssl/x509'
4
33
  require_relative './rest/client'
5
34
 
@@ -7,7 +36,7 @@ module Verifalia
7
36
  # HTTPS-based REST client for Verifalia.
8
37
  class Client
9
38
  # The version of the Verifalia SDK for Ruby.
10
- VERSION = '2.0.0'
39
+ VERSION = '2.1.0'
11
40
 
12
41
  # Allows to verify email addresses and manage email verification jobs using the Verifalia service.
13
42
  attr_reader :email_validations
@@ -46,7 +75,7 @@ module Verifalia
46
75
 
47
76
  @base_urls ||= Verifalia::Rest::BASE_URLS
48
77
  @rest_client = Verifalia::Rest::Client.new(@authenticator,
49
- "verifalia-rest-client/ruby/#{RUBY_VERSION}-p#{RUBY_PATCHLEVEL}",
78
+ "verifalia-rest-client/ruby/#{RUBY_VERSION}-p#{RUBY_PATCHLEVEL}/#{VERSION}",
50
79
  @base_urls)
51
80
 
52
81
  @rest_client.logger = logger
@@ -1,5 +1,34 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # Verifalia - Email list cleaning and real-time email verification service
4
+ # https://verifalia.com/
5
+ # support@verifalia.com
6
+ #
7
+ # Copyright (c) 2005-2024 Cobisi Research
8
+ #
9
+ # Cobisi Research
10
+ # Via Della Costituzione, 31
11
+ # 35010 Vigonza
12
+ # Italy - European Union
13
+ #
14
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
15
+ # of this software and associated documentation files (the "Software"), to deal
16
+ # in the Software without restriction, including without limitation the rights
17
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
18
+ # copies of the Software, and to permit persons to whom the Software is
19
+ # furnished to do so, subject to the following conditions:
20
+ #
21
+ # The above copyright notice and this permission notice shall be included in
22
+ # all copies or substantial portions of the Software.
23
+ #
24
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
25
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
27
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
30
+ # THE SOFTWARE.
31
+
3
32
  module Verifalia
4
33
  module Credits
5
34
  # The credits balance for the Verifalia account.
@@ -1,5 +1,34 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # Verifalia - Email list cleaning and real-time email verification service
4
+ # https://verifalia.com/
5
+ # support@verifalia.com
6
+ #
7
+ # Copyright (c) 2005-2024 Cobisi Research
8
+ #
9
+ # Cobisi Research
10
+ # Via Della Costituzione, 31
11
+ # 35010 Vigonza
12
+ # Italy - European Union
13
+ #
14
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
15
+ # of this software and associated documentation files (the "Software"), to deal
16
+ # in the Software without restriction, including without limitation the rights
17
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
18
+ # copies of the Software, and to permit persons to whom the Software is
19
+ # furnished to do so, subject to the following conditions:
20
+ #
21
+ # The above copyright notice and this permission notice shall be included in
22
+ # all copies or substantial portions of the Software.
23
+ #
24
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
25
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
27
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
30
+ # THE SOFTWARE.
31
+
3
32
  require_relative 'balance'
4
33
 
5
34
  module Verifalia
@@ -1,5 +1,34 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # Verifalia - Email list cleaning and real-time email verification service
4
+ # https://verifalia.com/
5
+ # support@verifalia.com
6
+ #
7
+ # Copyright (c) 2005-2024 Cobisi Research
8
+ #
9
+ # Cobisi Research
10
+ # Via Della Costituzione, 31
11
+ # 35010 Vigonza
12
+ # Italy - European Union
13
+ #
14
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
15
+ # of this software and associated documentation files (the "Software"), to deal
16
+ # in the Software without restriction, including without limitation the rights
17
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
18
+ # copies of the Software, and to permit persons to whom the Software is
19
+ # furnished to do so, subject to the following conditions:
20
+ #
21
+ # The above copyright notice and this permission notice shall be included in
22
+ # all copies or substantial portions of the Software.
23
+ #
24
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
25
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
27
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
30
+ # THE SOFTWARE.
31
+
3
32
  require 'net/http'
4
33
  require_relative 'job'
5
34
  require_relative 'overview'
@@ -167,11 +196,12 @@ module Verifalia
167
196
  end
168
197
 
169
198
  # Exports the validated entries for a completed email validation job, using the specified output format.
199
+ # See +ExportedEntriesFormat+ for a list of the values supported at the time this SDK has been released.
170
200
  #
171
201
  # Supported formats:
172
- # - +text/csv+: Comma-Separated Values (CSV)
173
- # - +application/vnd.openxmlformats-officedocument.spreadsheetml.sheet+: Microsoft Excel (.xlsx)
174
- # - +application/vnd.ms-excel+: Microsoft Excel 97-2003 (.xls)
202
+ # - Comma-Separated Values (CSV)
203
+ # - Microsoft Excel (.xlsx)
204
+ # - Microsoft Excel 97-2003 (.xls)
175
205
  #
176
206
  # @param [String] id The ID of the email validation job to retrieve.
177
207
  # @param [String] format The MIME content type of the desired output file format.
@@ -1,5 +1,34 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # Verifalia - Email list cleaning and real-time email verification service
4
+ # https://verifalia.com/
5
+ # support@verifalia.com
6
+ #
7
+ # Copyright (c) 2005-2024 Cobisi Research
8
+ #
9
+ # Cobisi Research
10
+ # Via Della Costituzione, 31
11
+ # 35010 Vigonza
12
+ # Italy - European Union
13
+ #
14
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
15
+ # of this software and associated documentation files (the "Software"), to deal
16
+ # in the Software without restriction, including without limitation the rights
17
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
18
+ # copies of the Software, and to permit persons to whom the Software is
19
+ # furnished to do so, subject to the following conditions:
20
+ #
21
+ # The above copyright notice and this permission notice shall be included in
22
+ # all copies or substantial portions of the Software.
23
+ #
24
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
25
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
27
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
30
+ # THE SOFTWARE.
31
+
3
32
  module Verifalia
4
33
  module EmailValidations
5
34
  class CompletionCallback