dwolla_v2 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -0
- data/lib/dwolla_v2.rb +1 -0
- data/lib/dwolla_v2/client.rb +1 -0
- data/lib/dwolla_v2/middleware/set_user_agent.rb +16 -0
- data/lib/dwolla_v2/token.rb +1 -0
- data/lib/dwolla_v2/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6908dcf033e8318ff41ebb772bbb4b456ceae2f3
|
4
|
+
data.tar.gz: 60cd8e1e175535f91e219b5b081b79db5b561c23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4de8e933017b9576d7ca96569ae53c5db2950ddd10117e6e704aa3fefa6fbffdd5143d9aa1a264b61cba3776428837602746ac32ca3abb131c6ac1ab9021543
|
7
|
+
data.tar.gz: e089126a0030e5524cb4d94d3d958318f69480e52236a8e7033d5db3e7e1ed9ec390b67b31840c3a177507e9d516e4d707545dd795dd313b670475b97351fbfb
|
data/README.md
CHANGED
@@ -26,6 +26,12 @@ Or install it yourself as:
|
|
26
26
|
|
27
27
|
### Basic usage
|
28
28
|
|
29
|
+
Create a client using your application's consumer key and secret found on the applications page
|
30
|
+
([UAT][apuat], [Production][approd]).
|
31
|
+
|
32
|
+
[apuat]: https://uat.dwolla.com/applications
|
33
|
+
[approd]: https://www.dwolla.com/applications
|
34
|
+
|
29
35
|
```ruby
|
30
36
|
# config/initializers/dwolla.rb
|
31
37
|
$dwolla = DwollaV2::Client.new(id: ENV["DWOLLA_ID"], secret: ENV["DWOLLA_SECRET"])
|
@@ -304,6 +310,7 @@ The gem is available as open source under the terms of the [MIT License](https:/
|
|
304
310
|
|
305
311
|
## Changelog
|
306
312
|
|
313
|
+
- **1.0.1** - Set user agent header.
|
307
314
|
- **1.0.0** - Refactor `Error` class to be more like response, add ability to access keys using methods.
|
308
315
|
- **0.4.0** - Refactor and document how `DwollaV2::Response` works
|
309
316
|
- **0.3.1** - better `DwollaV2::Error` error messages
|
data/lib/dwolla_v2.rb
CHANGED
@@ -19,6 +19,7 @@ require "dwolla_v2/error"
|
|
19
19
|
require "dwolla_v2/util"
|
20
20
|
require "dwolla_v2/super_hash"
|
21
21
|
|
22
|
+
require "dwolla_v2/middleware/set_user_agent"
|
22
23
|
require "dwolla_v2/middleware/deep_parse_iso8601_response_body"
|
23
24
|
require "dwolla_v2/middleware/deep_super_hasherize_response_body"
|
24
25
|
require "dwolla_v2/middleware/handle_errors"
|
data/lib/dwolla_v2/client.rb
CHANGED
@@ -0,0 +1,16 @@
|
|
1
|
+
module DwollaV2
|
2
|
+
class SetUserAgent
|
3
|
+
HEADERS = {
|
4
|
+
:"user-agent" => "dwolla-v2-ruby #{VERSION}"
|
5
|
+
}
|
6
|
+
|
7
|
+
def initialize app
|
8
|
+
@app = app
|
9
|
+
end
|
10
|
+
|
11
|
+
def call request_env
|
12
|
+
request_env[:request_headers].merge! HEADERS
|
13
|
+
@app.call(request_env)
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
data/lib/dwolla_v2/token.rb
CHANGED
data/lib/dwolla_v2/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dwolla_v2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stephen Ausman
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -156,6 +156,7 @@ files:
|
|
156
156
|
- lib/dwolla_v2/middleware/deep_parse_iso8601_response_body.rb
|
157
157
|
- lib/dwolla_v2/middleware/deep_super_hasherize_response_body.rb
|
158
158
|
- lib/dwolla_v2/middleware/handle_errors.rb
|
159
|
+
- lib/dwolla_v2/middleware/set_user_agent.rb
|
159
160
|
- lib/dwolla_v2/portal.rb
|
160
161
|
- lib/dwolla_v2/response.rb
|
161
162
|
- lib/dwolla_v2/super_hash.rb
|