amazon_pay 2.3.1 → 2.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/LICENSE +0 -0
- data/NOTICE +0 -0
- data/README.md +22 -0
- data/{CHANGES.txt → lib/CHANGES.txt} +4 -0
- data/lib/amazon_pay/client.rb +10 -2
- data/lib/amazon_pay/ipn_handler.rb +0 -0
- data/lib/amazon_pay/login.rb +0 -0
- data/lib/amazon_pay/request.rb +0 -0
- data/lib/amazon_pay/response.rb +0 -0
- data/lib/amazon_pay/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 608eb867ed536d6409ad4c5d454ad489d6c34168
|
4
|
+
data.tar.gz: ade1f627a5fc56580ddc5b7922a725914ae0df6a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 49a3d78cc72650945c2d081417b81d99a970b06d99e09a8e938b9436ba941a3210ddc980c6e7dcbb7181366d04153e5cd9dd75a92b81367d506e251b48208706
|
7
|
+
data.tar.gz: bb0e83f78b3d340db12a3a86be126f9d13bc5beb2be74a1dbc20765f9b3fb68bd366a9eb11fa105355f07fb9584eb633d86a8214082ef19a8210206aa4403680
|
data/LICENSE
CHANGED
File without changes
|
data/NOTICE
CHANGED
File without changes
|
data/README.md
CHANGED
@@ -155,6 +155,28 @@ response = client.list_order_reference(
|
|
155
155
|
|
156
156
|
```
|
157
157
|
|
158
|
+
Below is an example on how to GetMerchantAccountStatus
|
159
|
+
API call:
|
160
|
+
|
161
|
+
```ruby
|
162
|
+
require 'amazon_pay'
|
163
|
+
|
164
|
+
# Your Amazon Pay keys are
|
165
|
+
# available in your Seller Central account
|
166
|
+
merchant_id = 'YOUR_MERCHANT_ID'
|
167
|
+
access_key = 'YOUR_ACCESS_KEY'
|
168
|
+
secret_key = 'YOUR_SECRET_KEY'
|
169
|
+
|
170
|
+
client = AmazonPay::Client.new(
|
171
|
+
merchant_id,
|
172
|
+
access_key,
|
173
|
+
secret_key
|
174
|
+
)
|
175
|
+
|
176
|
+
response = client.client.get_merchant_account_status
|
177
|
+
|
178
|
+
```
|
179
|
+
|
158
180
|
Below is an example on how to query using the next token received
|
159
181
|
from ListOrderReference using the ListOrderReferenceByNextToken
|
160
182
|
API call:
|
data/lib/amazon_pay/client.rb
CHANGED
@@ -171,11 +171,13 @@ module AmazonPay
|
|
171
171
|
# @see https://pay.amazon.com/documentation/apireference/201751630#201751690
|
172
172
|
# @param amazon_billing_agreement_id [String]
|
173
173
|
# @optional address_consent_token [String]
|
174
|
+
# @optional access_token [String]
|
174
175
|
# @optional merchant_id [String]
|
175
176
|
# @optional mws_auth_token [String]
|
176
177
|
def get_billing_agreement_details(
|
177
178
|
amazon_billing_agreement_id,
|
178
179
|
address_consent_token: nil,
|
180
|
+
access_token: nil,
|
179
181
|
merchant_id: @merchant_id,
|
180
182
|
mws_auth_token: nil
|
181
183
|
)
|
@@ -187,7 +189,9 @@ module AmazonPay
|
|
187
189
|
}
|
188
190
|
|
189
191
|
optional = {
|
190
|
-
|
192
|
+
# Preseving address_consent_token for backwards compatibility
|
193
|
+
# AccessToken returns all data in AddressConsentToken plus new data
|
194
|
+
'AccessToken' => access_token || address_consent_token,
|
191
195
|
'MWSAuthToken' => mws_auth_token
|
192
196
|
}
|
193
197
|
|
@@ -467,11 +471,13 @@ module AmazonPay
|
|
467
471
|
# @see https://pay.amazon.com/documentation/apireference/201751630#201751970
|
468
472
|
# @param amazon_order_reference_id [String]
|
469
473
|
# @optional address_consent_token [String]
|
474
|
+
# @optional access_token [String]
|
470
475
|
# @optional merchant_id [String]
|
471
476
|
# @optional mws_auth_token [String]
|
472
477
|
def get_order_reference_details(
|
473
478
|
amazon_order_reference_id,
|
474
479
|
address_consent_token: nil,
|
480
|
+
access_token: nil,
|
475
481
|
merchant_id: @merchant_id,
|
476
482
|
mws_auth_token: nil
|
477
483
|
)
|
@@ -483,7 +489,9 @@ module AmazonPay
|
|
483
489
|
}
|
484
490
|
|
485
491
|
optional = {
|
486
|
-
|
492
|
+
# Preseving address_consent_token for backwards compatibility
|
493
|
+
# AccessToken returns all data in AddressConsentToken plus new data
|
494
|
+
'AccessToken' => access_token || address_consent_token,
|
487
495
|
'MWSAuthToken' => mws_auth_token
|
488
496
|
}
|
489
497
|
|
File without changes
|
data/lib/amazon_pay/login.rb
CHANGED
File without changes
|
data/lib/amazon_pay/request.rb
CHANGED
File without changes
|
data/lib/amazon_pay/response.rb
CHANGED
File without changes
|
data/lib/amazon_pay/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: amazon_pay
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- AmazonPay
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-05-
|
11
|
+
date: 2018-05-23 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: AmazonPay Ruby SDK
|
14
14
|
email: amazon-pay-sdk@amazon.com
|
@@ -16,10 +16,10 @@ executables: []
|
|
16
16
|
extensions: []
|
17
17
|
extra_rdoc_files: []
|
18
18
|
files:
|
19
|
-
- CHANGES.txt
|
20
19
|
- LICENSE
|
21
20
|
- NOTICE
|
22
21
|
- README.md
|
22
|
+
- lib/CHANGES.txt
|
23
23
|
- lib/amazon_pay.rb
|
24
24
|
- lib/amazon_pay/client.rb
|
25
25
|
- lib/amazon_pay/client_helper.rb
|
@@ -32,12 +32,12 @@ files:
|
|
32
32
|
- lib/amazon_pay/version.rb
|
33
33
|
homepage: https://github.com/amzn/amazon-pay-sdk-ruby
|
34
34
|
licenses:
|
35
|
-
- Apache
|
35
|
+
- Apache License, Version 2.0
|
36
36
|
metadata: {}
|
37
37
|
post_install_message:
|
38
38
|
rdoc_options: []
|
39
39
|
require_paths:
|
40
|
-
- lib
|
40
|
+
- - lib
|
41
41
|
required_ruby_version: !ruby/object:Gem::Requirement
|
42
42
|
requirements:
|
43
43
|
- - ">="
|
@@ -50,7 +50,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
50
50
|
version: '0'
|
51
51
|
requirements: []
|
52
52
|
rubyforge_project:
|
53
|
-
rubygems_version: 2.
|
53
|
+
rubygems_version: 2.2.5
|
54
54
|
signing_key:
|
55
55
|
specification_version: 4
|
56
56
|
summary: AmazonPay Ruby SDK
|