sendgrid-ruby 4.0.0 → 4.0.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
  SHA1:
3
- metadata.gz: 58e24c0cfd83197efded57156c9b03e9426669cd
4
- data.tar.gz: 50fcc1d3309165332a3abd6834e5076e862bbbe9
3
+ metadata.gz: 1577f622dc1139887c7bf0e70e48af93a902e4f4
4
+ data.tar.gz: 4be15a9ae9f75ef61ea292572fa1735686bc6777
5
5
  SHA512:
6
- metadata.gz: 64b4d83d8c7d4d2a0720902442f991d277c8570d5f30f70873fe9fb1a65d57063432ca76f378ac434d7425c0009c2280399b27e5249da6e32af564158ea713d8
7
- data.tar.gz: bc15d4aa204006ba4b2c3ad52566c4bb8a2c08b06b8f4a46d7fd23749b7ffc49f836d70f59faed22ada7ca8754372594b113e5ec4cc7242ddacd7fae8a9076fc
6
+ metadata.gz: cc058748afd2ea184df9ad8ea88bdee864332914d80651c9aa3c3c8cbc00476dd28bcacc2e7afcad823e46307608e522f9bb6d6dbeb92f0e1767d90b80bed5af
7
+ data.tar.gz: e622f4208a1795bf5d63233688392d68c11395a2a5b08c413805224674c0ee21f2b108c7913b80bdc3d565edcbbeb4c823aedad46fbec45769f5d729e65f1571
@@ -2,7 +2,7 @@
2
2
  All notable changes to this project will be documented in this file.
3
3
 
4
4
  ## [4.0.0] - 2016-07-23 ##
5
- - BREAKING CHANGE
5
+ ### BREAKING CHANGE
6
6
  - Update dependency to [ruby-http-client](https://github.com/sendgrid/ruby-http-client/releases/tag/v3.0.0)
7
7
  - Response headers now return a hash instead of a string
8
8
  - Thanks to [Chris France](https://github.com/hipsterelitist) for the pull request!
data/README.md CHANGED
@@ -157,6 +157,10 @@ We encourage contribution to our libraries (you might even score some nifty swag
157
157
  - [Sign the CLA to Create a Pull Request](https://github.com/sendgrid/sendgrid-ruby/tree/master/CONTRIBUTING.md#cla)
158
158
  - [Improvements to the Codebase](https://github.com/sendgrid/sendgrid-ruby/tree/master/CONTRIBUTING.md#improvements_to_the_codebase)
159
159
 
160
+ # Troubleshooting
161
+
162
+ Please see our [troubleshooting guide](https://github.com/sendgrid/sendgrid-ruby/blob/master/TROUBLESHOOTING.md) for common library issues.
163
+
160
164
  # About
161
165
 
162
166
  sendgrid-ruby is guided and supported by the SendGrid [Developer Experience Team](mailto:dx@sendgrid.com).
@@ -0,0 +1,111 @@
1
+ If you have a non-library SendGrid issue, please contact our [support team](https://support.sendgrid.com).
2
+
3
+ If you can't find a solution below, please open an [issue](https://github.com/sendgrid/sendgrid-ruby/issues).
4
+
5
+
6
+ ## Table of Contents
7
+
8
+ * [Migrating from v2 to v3](#migrating)
9
+ * [Continue Using v2](#v2)
10
+ * [Testing v3 /mail/send Calls Directly](#testing)
11
+ * [Error Messages](#error)
12
+ * [Versions](#versions)
13
+ * [Environment Variables and Your SendGrid API Key](#environment)
14
+ * [Using the Package Manager](#package-manager)
15
+
16
+ <a name="migrating"></a>
17
+ ## Migrating from v2 to v3
18
+
19
+ Please review [our guide](https://sendgrid.com/docs/Classroom/Send/v3_Mail_Send/how_to_migrate_from_v2_to_v3_mail_send.html) on how to migrate from v2 to v3.
20
+
21
+ <a name="v2"></a>
22
+ ## Continue Using v2
23
+
24
+ [Here](https://github.com/sendgrid/sendgrid-ruby/tree/0fbf579c0f7ed1dff87adc4957c4dc5a6b257068) is the last working version with v2 support.
25
+
26
+ Using rubygems:
27
+
28
+ Add this line to your application's Gemfile:
29
+
30
+ ```bash
31
+ gem 'sendgrid-ruby', '1.1.6'
32
+ ```
33
+
34
+ And then execute:
35
+
36
+ ```bash
37
+ bundle
38
+ ```
39
+
40
+ Or install it yourself using:
41
+
42
+ ```bash
43
+ gem install sendgrid-ruby -v 1.1.6
44
+ ```
45
+
46
+ Download:
47
+
48
+ Click the "Clone or download" green button in [GitHub](https://github.com/sendgrid/sendgrid-ruby/tree/0fbf579c0f7ed1dff87adc4957c4dc5a6b257068) and choose download.
49
+
50
+ <a name="testing"></a>
51
+ ## Testing v3 /mail/send Calls Directly
52
+
53
+ [Here](https://sendgrid.com/docs/Classroom/Send/v3_Mail_Send/curl_examples.html) are some cURL examples for common use cases.
54
+
55
+ <a name="error"></a>
56
+ ## Error Messages
57
+
58
+ To read the error message returned by SendGrid's API:
59
+
60
+ ```ruby
61
+ begin
62
+ response = sg.client.mail._("send").post(request_body: mail.to_json)
63
+ rescue Exception => e
64
+ puts e.message
65
+ end
66
+ ```
67
+
68
+ <a name="versions"></a>
69
+ ## Versions
70
+
71
+ We follow the MAJOR.MINOR.PATCH versioning scheme as described by [SemVer.org](http://semver.org). Therefore, we recommend that you always pin (or vendor) the particular version you are working with to your code and never auto-update to the latest version. Especially when there is a MAJOR point release, since that is guarenteed to be a breaking change. Changes are documented in the [CHANGELOG](https://github.com/sendgrid/sendgrid-ruby/blob/master/CHANGELOG.md) and [releases](https://github.com/sendgrid/sendgrid-ruby/releases) section.
72
+
73
+ <a name="environment"></a>
74
+ ## Environment Variables and Your SendGrid API Key
75
+
76
+ All of our examples assume you are using [environment variables](https://github.com/sendgrid/sendgrid-ruby#setup-environment-variables) to hold your SendGrid API key.
77
+
78
+ If you choose to add your SendGrid API key directly (not recommended):
79
+
80
+ `sg = SendGrid::API.new(api_key: ENV['SENDGRID_API_KEY'])`
81
+
82
+ becomes
83
+
84
+ `sg = SendGrid::API.new(api_key: 'SENDGRID_API_KEY')`
85
+
86
+ In the first case SENDGRID_API_KEY is in reference to the name of the environment variable, while the second case references the actual SendGrid API Key.
87
+
88
+ <a name="package-manager"></a>
89
+ ## Using the Package Manager
90
+
91
+ We upload this library to [RubyGems](https://rubygems.org/gems/sendgrid-ruby) whenever we make a release. This allows you to use [RubyGems](https://rubygems.org) for easy installation.
92
+
93
+ In most cases we recommend you download the latest version of the library, but if you need a different version, please use:
94
+
95
+ Add this line to your application's Gemfile:
96
+
97
+ ```bash
98
+ gem 'sendgrid-ruby', 'X.X.X'
99
+ ```
100
+
101
+ And then execute:
102
+
103
+ ```bash
104
+ bundle
105
+ ```
106
+
107
+ Or install it yourself using:
108
+
109
+ ```bash
110
+ gem install sendgrid-ruby -v X.X.X
111
+ ```
@@ -1,3 +1,3 @@
1
1
  module SendGrid
2
- VERSION = '4.0.0'
2
+ VERSION = '4.0.1'
3
3
  end
@@ -30,7 +30,7 @@ class TestAPI < Minitest::Test
30
30
  ')
31
31
  assert_equal(test_headers, sg.request_headers)
32
32
  assert_equal("v3", sg.version)
33
- assert_equal("4.0.0", SendGrid::VERSION)
33
+ assert_equal("4.0.1", SendGrid::VERSION)
34
34
  assert_instance_of(SendGrid::Client, sg.client)
35
35
  end
36
36
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sendgrid-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elmer Thomas
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-07-23 00:00:00.000000000 Z
13
+ date: 2016-07-26 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: ruby_http_client
@@ -55,6 +55,7 @@ files:
55
55
  - LICENSE.txt
56
56
  - README.md
57
57
  - Rakefile
58
+ - TROUBLESHOOTING.md
58
59
  - USAGE.md
59
60
  - examples/accesssettings/accesssettings.rb
60
61
  - examples/alerts/alerts.rb