paypal-sdk-core 0.2.5 → 0.2.6

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: 3ae30ef01b809a2b34d440a5799a3f064aab1147
4
- data.tar.gz: 1d809f538b42ebdaafcaabcf73eea8087cf435f2
3
+ metadata.gz: f5756a1dfda1dd82a085e6c97289a48d0a60bb99
4
+ data.tar.gz: b55a8713d8c4a7b13beeb9c723ed8e535292cba7
5
5
  SHA512:
6
- metadata.gz: 2dc5687b41463349af976f353bc66e88dca8234be5b9ddadb95d98220887a4206dc4511437c302a2ec77afdcf30c906157d1b9714dfded9ed042a684bcb7a27a
7
- data.tar.gz: 7858faa628589329cd1d898a901b7aa9d1588a700543ea701ca015edf9459f17f72d8680fa11609bc2bd81d16d8d1067b99dbecaec4c2c9ff8466678e0b9c806
6
+ metadata.gz: c49fabf85efddaf2774a719531ba6978d5bcd17c479d5509c6174192aca18f7cca024ec6b1bbc419595f118e4b50d0d4390f39fbf7b1577aa525471b6519fccd
7
+ data.tar.gz: 3d13c520c8a65f4e9705c7bf8739a7139644aa7c7f52306fe11a8ae18837e8be80cdded657d538efd4a4041b0e24aa0411edd632b5893c11c3aed34d38ca0437
data/CHANGELOG.txt CHANGED
@@ -1,3 +1,8 @@
1
+ Version 0.2.6 - Aug 30, 2013
2
+ - Added license name as "PayPal SDK License"
3
+ - Generate sandbox urls for openid connect
4
+ - Support Merchant API call without action/path
5
+
1
6
  Version 0.2.5 - Jun 27, 2013
2
7
  - Fix DateTime parser to support 0
3
8
  - Set content-type header for generate-token REST API
data/Gemfile CHANGED
@@ -8,4 +8,5 @@ gem 'rake', :require => false
8
8
  group :test do
9
9
  gem 'rspec'
10
10
  gem 'simplecov', :require => false
11
+ gem 'coveralls', :require => false
11
12
  end
data/LICENSE.txt ADDED
@@ -0,0 +1,41 @@
1
+ PAYPAL, INC.
2
+
3
+ SDK LICENSE
4
+
5
+ NOTICE TO USER: PayPal, Inc. is providing the Software and Documentation for use under the terms of this Agreement. Any use, reproduction, modification or distribution of the Software or Documentation, or any derivatives or portions hereof, constitutes your acceptance of this Agreement.
6
+
7
+ As used in this Agreement, "PayPal" means PayPal, Inc. "Software" means the software code accompanying this agreement. "Documentation" means the documents, specifications and all other items accompanying this Agreement other than the Software.
8
+
9
+ 1. LICENSE GRANT Subject to the terms of this Agreement, PayPal hereby grants you a non-exclusive, worldwide, royalty free license to use, reproduce, prepare derivative works from, publicly display, publicly perform, distribute and sublicense the Software for any purpose, provided the copyright notice below appears in a conspicuous location within the source code of the distributed Software and this license is distributed in the supporting documentation of the Software you distribute. Furthermore, you must comply with all third party licenses in order to use the third party software contained in the Software.
10
+
11
+ Subject to the terms of this Agreement, PayPal hereby grants you a non-exclusive, worldwide, royalty free license to use, reproduce, publicly display, publicly perform, distribute and sublicense the Documentation for any purpose. You may not modify the Documentation.
12
+
13
+ No title to the intellectual property in the Software or Documentation is transferred to you under the terms of this Agreement. You do not acquire any rights to the Software or the Documentation except as expressly set forth in this Agreement.
14
+
15
+ If you choose to distribute the Software in a commercial product, you do so with the understanding that you agree to defend, indemnify and hold harmless PayPal and its suppliers against any losses, damages and costs arising from the claims, lawsuits or other legal actions arising out of such distribution. You may distribute the Software in object code form under your own license, provided that your license agreement:
16
+
17
+ (a) complies with the terms and conditions of this license agreement;
18
+
19
+ (b) effectively disclaims all warranties and conditions, express or implied, on behalf of PayPal;
20
+
21
+ (c) effectively excludes all liability for damages on behalf of PayPal;
22
+
23
+ (d) states that any provisions that differ from this Agreement are offered by you alone and not PayPal; and
24
+
25
+ (e) states that the Software is available from you or PayPal and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.
26
+
27
+ 2. DISCLAIMER OF WARRANTY
28
+ PAYPAL LICENSES THE SOFTWARE AND DOCUMENTATION TO YOU ONLY ON AN "AS IS" BASIS WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. PAYPAL MAKES NO WARRANTY THAT THE SOFTWARE OR DOCUMENTATION WILL BE ERROR-FREE. Each user of the Software or Documentation is solely responsible for determining the appropriateness of using and distributing the Software and Documentation and assumes all risks associated with its exercise of rights under this Agreement, including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs, or equipment, and unavailability or interruption of operations. Use of the Software and Documentation is made with the understanding that PayPal will not provide you with any technical or customer support or maintenance. Some states or jurisdictions do not allow the exclusion of implied warranties or limitations on how long an implied warranty may last, so the above limitations may not apply to you. To the extent permissible, any implied warranties are limited to ninety (90) days.
29
+
30
+
31
+ 3. LIMITATION OF LIABILITY
32
+ PAYPAL AND ITS SUPPLIERS SHALL NOT BE LIABLE FOR LOSS OR DAMAGE ARISING OUT OF THIS AGREEMENT OR FROM THE USE OF THE SOFTWARE OR DOCUMENTATION. IN NO EVENT WILL PAYPAL OR ITS SUPPLIERS BE LIABLE TO YOU OR ANY THIRD PARTY FOR ANY DIRECT, INDIRECT, CONSEQUENTIAL, INCIDENTAL, OR SPECIAL DAMAGES INCLUDING LOST PROFITS, LOST SAVINGS, COSTS, FEES, OR EXPENSES OF ANY KIND ARISING OUT OF ANY PROVISION OF THIS AGREEMENT OR THE USE OR THE INABILITY TO USE THE SOFTWARE OR DOCUMENTATION, HOWEVER CAUSED AND UNDER ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR TORT INCLUDING NEGLIGENCE OR OTHERWISE), EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. PAYPAL'S AGGREGATE LIABILITY AND THAT OF ITS SUPPLIERS UNDER OR IN CONNECTION WITH THIS AGREEMENT SHALL BE LIMITED TO THE AMOUNT PAID BY YOU FOR THE SOFTWARE AND DOCUMENTATION.
33
+
34
+ 4. TRADEMARK USAGE
35
+ PayPal is a trademark PayPal, Inc. in the United States and other countries. Such trademarks may not be used to endorse or promote any product unless expressly permitted under separate agreement with PayPal.
36
+
37
+ 5. TERM
38
+ Your rights under this Agreement shall terminate if you fail to comply with any of the material terms or conditions of this Agreement and do not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all your rights under this Agreement terminate, you agree to cease use and distribution of the Software and Documentation as soon as reasonably practicable.
39
+
40
+ 6. GOVERNING LAW AND JURISDICTION. This Agreement is governed by the statutes and laws of the State of California, without regard to the conflicts of law principles thereof. If any part of this Agreement is found void and unenforceable, it will not affect the validity of the balance of the Agreement, which shall remain valid and enforceable according to its terms. Any dispute arising out of or related to this Agreement shall be brought in the courts of Santa Clara County, California, USA.
41
+
@@ -92,23 +92,28 @@ module PayPal::SDK::Core
92
92
  # * <tt>params</tt> -- (Optional) Parameters for the action
93
93
  # * <tt>initheader</tt> -- (Optional) HTTP header
94
94
  def post(action, params = {}, header = {})
95
+ action, params, header = "", action, params if action.is_a? Hash
95
96
  api_call(:method => :post, :action => action, :params => params, :header => header)
96
97
  end
97
98
  alias_method :request, :post
98
99
 
99
100
  def get(action, params = {}, header = {})
101
+ action, params, header = "", action, params if action.is_a? Hash
100
102
  api_call(:method => :get, :action => action, :query => params, :params => nil, :header => header)
101
103
  end
102
104
 
103
105
  def patch(action, params = {}, header = {})
106
+ action, params, header = "", action, params if action.is_a? Hash
104
107
  api_call(:method => :patch, :action => action, :params => params, :header => header)
105
108
  end
106
109
 
107
110
  def put(action, params = {}, header = {})
111
+ action, params, header = "", action, params if action.is_a? Hash
108
112
  api_call(:method => :put, :action => action, :params => params, :header => header)
109
113
  end
110
114
 
111
115
  def delete(action, params = {}, header = {})
116
+ action, params, header = "", action, params if action.is_a? Hash
112
117
  api_call(:method => :delete, :action => action, :params => params, :header => header)
113
118
  end
114
119
 
@@ -98,7 +98,7 @@ module PayPal::SDK::Core
98
98
 
99
99
  # Log additional information
100
100
  def log_http_call(payload)
101
- logger.info "Action: #{payload[:action]}" if payload[:action]
101
+ logger.info "Action: #{payload[:action]}" if payload[:action] and payload[:action] != ""
102
102
  super
103
103
  end
104
104
 
@@ -109,7 +109,11 @@ module PayPal::SDK::Core
109
109
  # * <tt>action</tt> -- Request Action name
110
110
  # * <tt>params</tt> -- Parameters for the action.
111
111
  def request_body(action, params = {})
112
- { "ns:#{action}Req" => { "ns:#{action}Request" => DEFAULT_PARAMS.merge(params) } }
112
+ if action and action != ""
113
+ { "ns:#{action}Req" => { "ns:#{action}Request" => DEFAULT_PARAMS.merge(params) } }
114
+ else
115
+ params
116
+ end
113
117
  end
114
118
 
115
119
  # Remove specified attributes from the given Hash
@@ -20,12 +20,12 @@ module PayPal::SDK
20
20
  end
21
21
  alias_method :config=, :set_config
22
22
 
23
- AUTHORIZATION_URL = "https://www.paypal.com/webapps/auth/protocol/openidconnect/v1/authorize"
24
- ENDSESSION_URL = "https://www.paypal.com/webapps/auth/protocol/openidconnect/v1/endsession"
23
+ AUTHORIZATION_URL = "paypal.com/webapps/auth/protocol/openidconnect/v1/authorize"
24
+ ENDSESSION_URL = "paypal.com/webapps/auth/protocol/openidconnect/v1/endsession"
25
25
  DEFAULT_SCOPE = "openid"
26
26
 
27
27
  def authorize_url(params = {})
28
- uri = URI(AUTHORIZATION_URL)
28
+ uri = URI(url_for_mode(AUTHORIZATION_URL))
29
29
  uri.query = api.encode_www_form({
30
30
  :response_type => "code",
31
31
  :scope => DEFAULT_SCOPE,
@@ -36,13 +36,19 @@ module PayPal::SDK
36
36
  end
37
37
 
38
38
  def logout_url(params = {})
39
- uri = URI(ENDSESSION_URL)
39
+ uri = URI(url_for_mode(ENDSESSION_URL))
40
40
  uri.query = api.encode_www_form({
41
41
  :logout => "true",
42
42
  :redirect_uri => api.config.openid_redirect_uri
43
43
  }.merge(params))
44
44
  uri.to_s
45
45
  end
46
+
47
+ private
48
+
49
+ def url_for_mode(url)
50
+ "https://www.#{"sandbox." if api.api_mode == :sandbox}#{url}"
51
+ end
46
52
  end
47
53
 
48
54
  module DataTypes
@@ -5,14 +5,16 @@ module PayPal::SDK
5
5
  module OpenIDConnect
6
6
  class API < Core::API::Base
7
7
 
8
- DEFAULT_OPENID_ENDPOINT ="https://api.paypal.com"
8
+ DEFAULT_OPENID_ENDPOINT = {
9
+ :sandbox => "https://api.sandbox.paypal.com",
10
+ :live => "https://api.paypal.com" }
9
11
 
10
12
  def initialize(environment = nil, options = {})
11
13
  super("", environment, options)
12
14
  end
13
15
 
14
16
  def service_endpoint
15
- self.config.openid_endpoint || DEFAULT_OPENID_ENDPOINT
17
+ self.config.openid_endpoint || DEFAULT_OPENID_ENDPOINT[self.api_mode] || DEFAULT_OPENID_ENDPOINT[:sandbox]
16
18
  end
17
19
 
18
20
  def format_request(payload)
@@ -1,7 +1,7 @@
1
1
  module PayPal
2
2
  module SDK
3
3
  module Core
4
- VERSION = "0.2.5"
4
+ VERSION = "0.2.6"
5
5
  end
6
6
  end
7
7
  end
@@ -69,6 +69,15 @@ describe PayPal::SDK::Core::API::Merchant do
69
69
  response = client.request("TransactionSearch", TransactionSearchParams)
70
70
  response["Ack"].should eql "Success"
71
71
  end
72
+
73
+ it "with raw request" do
74
+ client = Merchant.new
75
+ response = client.request({
76
+ "ns:TransactionSearchReq" => {
77
+ "ns:TransactionSearchRequest" => TransactionSearchParams.merge("ebl:Version" => "94")
78
+ } } )
79
+ response["Ack"].should eql "Success"
80
+ end
72
81
  end
73
82
 
74
83
  describe "Format request" do
@@ -11,11 +11,25 @@ describe PayPal::SDK::OpenIDConnect do
11
11
  OpenIDConnect::API.user_agent.should match "PayPalSDK/openid-connect-ruby"
12
12
  end
13
13
 
14
- it "generate autorize_url" do
15
- url = OpenIDConnect::Tokeninfo.authorize_url
16
- url.should match "client_id=client_id"
17
- url.should match Regexp.escape("redirect_uri=#{CGI.escape("http://google.com")}")
18
- url.should match "scope=openid"
14
+ describe "generate_authorize_url" do
15
+
16
+ it "generate autorize_url" do
17
+ url = OpenIDConnect::Tokeninfo.authorize_url
18
+ url.should match "client_id=client_id"
19
+ url.should match Regexp.escape("redirect_uri=#{CGI.escape("http://google.com")}")
20
+ url.should match "scope=openid"
21
+ end
22
+
23
+ describe "sandbox" do
24
+ before do
25
+ PayPal::SDK.configure(:mode => "sandbox")
26
+ end
27
+
28
+ it "generates a sandbox authorize url" do
29
+ url = OpenIDConnect::Tokeninfo.authorize_url
30
+ url.should match "sandbox.paypal.com"
31
+ end
32
+ end
19
33
  end
20
34
 
21
35
  it "Override authorize_url params" do
@@ -91,11 +105,24 @@ describe PayPal::SDK::OpenIDConnect do
91
105
  userinfo.name.should eql "Testing"
92
106
  end
93
107
 
94
- it "Generate logout_url" do
95
- url = @tokeninfo.logout_url
96
- url.should match "id_token=test_id_token"
97
- url.should match "logout=true"
98
- url.should match Regexp.escape("redirect_uri=#{CGI.escape("http://google.com")}")
108
+ describe "logout_url" do
109
+ it "Generate logout_url" do
110
+ url = @tokeninfo.logout_url
111
+ url.should match "id_token=test_id_token"
112
+ url.should match "logout=true"
113
+ url.should match Regexp.escape("redirect_uri=#{CGI.escape("http://google.com")}")
114
+ end
115
+
116
+ describe "sandbox" do
117
+ before do
118
+ PayPal::SDK.configure(:mode => "sandbox")
119
+ end
120
+
121
+ it "generates a sandbox logout url" do
122
+ url = @tokeninfo.logout_url
123
+ url.should match "sandbox.paypal.com"
124
+ end
125
+ end
99
126
  end
100
127
  end
101
128
 
@@ -2,43 +2,43 @@ opening connection to api.sandbox.paypal.com:443...
2
2
  opened
3
3
  starting SSL for api.sandbox.paypal.com:443...
4
4
  SSL established
5
- <- "POST /v1/payments/payment HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Osw2KQ0OeYElPQAtMeRH7b5Q7l-qh.xjSd7hQSOwib8\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 286\r\n\r\n"
5
+ <- "POST /v1/payments/payment HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer jHPsUnuwb9F1xzqb8f0CYGhfpus5tv5cGtoJXbrQRo0\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 286\r\n\r\n"
6
6
  <- "{\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"4417119669820331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"}}]}"
7
7
  -> "HTTP/1.1 201 Created\r\n"
8
8
  -> "Server: Apache-Coyote/1.1\r\n"
9
- -> "Date: Thu, 27 Jun 2013 10:49:48 GMT\r\n"
10
- -> "PayPal-Debug-Id: 8f71eea801269\r\n"
9
+ -> "Date: Fri, 30 Aug 2013 04:58:46 GMT\r\n"
10
+ -> "PayPal-Debug-Id: 589de4de60393\r\n"
11
11
  -> "Content-Type: application/json\r\n"
12
12
  -> "Content-Length: 1176\r\n"
13
13
  -> "\r\n"
14
14
  reading 1176 bytes...
15
- -> "{\"id\":\"PAY-6R435442DX602315LKHGBRSA\",\"create_time\":\"2013-06-27T10:49:44Z\",\"update_time\":\"2013-06-27T10:49:47Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"08G45707W1331934G\",\"create_time\":\"2013-06-27T10:49:44Z\",\"update_time\":\"2013-06-27T10:49:47Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-6R435442DX602315LKHGBRSA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/08G45707W1331934G\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/08G45707W1331934G/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-6R435442DX602315LKHGBRSA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-6R435442DX602315LKHGBRSA\",\"rel\":\"self\",\"method\":\"GET\"}]}"
15
+ -> "{\"id\":\"PAY-0DS51393N4328690CKIQCNAA\",\"create_time\":\"2013-08-30T04:58:40Z\",\"update_time\":\"2013-08-30T04:58:46Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"74E51272GK930880A\",\"create_time\":\"2013-08-30T04:58:40Z\",\"update_time\":\"2013-08-30T04:58:46Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-0DS51393N4328690CKIQCNAA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/74E51272GK930880A\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/74E51272GK930880A/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0DS51393N4328690CKIQCNAA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0DS51393N4328690CKIQCNAA\",\"rel\":\"self\",\"method\":\"GET\"}]}"
16
16
  read 1176 bytes
17
17
  Conn keep-alive
18
18
  opening connection to api.sandbox.paypal.com:443...
19
19
  opened
20
20
  starting SSL for api.sandbox.paypal.com:443...
21
21
  SSL established
22
- <- "GET /v1/payments/payment?count=10 HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Osw2KQ0OeYElPQAtMeRH7b5Q7l-qh.xjSd7hQSOwib8\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
22
+ <- "GET /v1/payments/payment?count=10 HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer jHPsUnuwb9F1xzqb8f0CYGhfpus5tv5cGtoJXbrQRo0\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
23
23
  -> "HTTP/1.1 200 OK\r\n"
24
24
  -> "Server: Apache-Coyote/1.1\r\n"
25
- -> "Date: Thu, 27 Jun 2013 10:49:53 GMT\r\n"
26
- -> "PayPal-Debug-Id: 28b616ef0015a\r\n"
25
+ -> "Date: Fri, 30 Aug 2013 04:58:52 GMT\r\n"
26
+ -> "PayPal-Debug-Id: e55d5eb26e410\r\n"
27
27
  -> "Content-Type: application/json\r\n"
28
28
  -> "Transfer-Encoding: chunked\r\n"
29
29
  -> "\r\n"
30
30
  -> "2000\r\n"
31
31
  reading 8192 bytes...
32
- -> "{\"payments\":[{\"id\":\"PAY-6R435442DX602315LKHGBRSA\",\"create_time\":\"2013-06-27T10:49:44Z\",\"update_time\":\"2013-06-27T10:49:47Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"08G45707W1331934G\",\"create_time\":\"2013-06-27T10:49:44Z\",\"update_time\":\"2013-06-27T10:49:47Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-6R435442DX602315LKHGBRSA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/08G45707W1331934G\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/08G45707W1331934G/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-6R435442DX602315LKHGBRSA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-6R435442DX602315LKHGBRSA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-7PD39680C9122543SKHGBPRA\",\"create_time\":\"2013-06-27T10:45:24Z\",\"update_time\":\"2013-06-27T10:45:28Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"billing_address\":{\"line1\":\"52 N Main ST\",\"city\":\"Johnstown\",\"state\":\"OH\",\"postal_code\":\"43210\",\"country_code\":\"US\"}}}]},\"transactions\":[{\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"5.00\",\"tax\":\"1.00\",\"shipping\":\"1.00\"}},\"description\":\"This is the payment transaction description.\",\"related_resources\":[{\"sale\":{\"id\":\"2GJ76156TA988933J\",\"create_time\":\"2013-06-27T10:45:24Z\",\"update_time\":\"2013-06-27T10:45:28Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-7PD39680C9122543SKHGBPRA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/2GJ76156TA988933J\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/2GJ76156TA988933J/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7PD39680C9122543SKHGBPRA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7PD39680C9122543SKHGBPRA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-22515132VH274140GKHGBPQA\",\"create_time\":\"2013-06-27T10:45:20Z\",\"update_time\":\"2013-06-27T10:45:24Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"billing_address\":{\"line1\":\"52 N Main ST\",\"city\":\"Johnstown\",\"state\":\"OH\",\"postal_code\":\"43210\",\"country_code\":\"US\"}}}]},\"transactions\":[{\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"5.00\",\"tax\":\"1.00\",\"shipping\":\"1.00\"}},\"description\":\"This is the payment transaction description.\",\"related_resources\":[{\"sale\":{\"id\":\"09T93827PG559415A\",\"create_time\":\"2013-06-27T10:45:20Z\",\"update_time\":\"2013-06-27T10:45:24Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-22515132VH274140GKHGBPQA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/09T93827PG559415A\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/09T93827PG559415A/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-22515132VH274140GKHGBPQA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-22515132VH274140GKHGBPQA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-5K936359MK810191GKHGBPPA\",\"create_time\":\"2013-06-27T10:45:16Z\",\"update_time\":\"2013-06-27T10:45:21Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"billing_address\":{\"line1\":\"52 N Main ST\",\"city\":\"Johnstown\",\"state\":\"OH\",\"postal_code\":\"43210\",\"country_code\":\"US\"}}}]},\"transactions\":[{\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"5.00\",\"tax\":\"1.00\",\"shipping\":\"1.00\"}},\"description\":\"This is the payment transaction description.\",\"related_resources\":[{\"sale\":{\"id\":\"9EH93163B3020071R\",\"create_time\":\"2013-06-27T10:45:17Z\",\"update_time\":\"2013-06-27T10:45:21Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.00\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-5K936359MK810191GKHGBPPA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/9EH93163B3020071R\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/9EH93163B3020071R/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-5K936359MK810191GKHGBPPA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-5K936359MK810191GKHGBPPA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-7PP823390X6821541KHGBLOA\",\"create_time\":\"2013-06-27T10:36:40Z\",\"update_time\":\"2013-06-27T10:36:43Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"39331137VY325843E\",\"create_time\":\"2013-06-27T10:36:40Z\",\"update_time\":\"2013-06-27T10:36:43Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-7PP823390X6821541KHGBLOA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/39331137VY325843E\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/39331137VY325843E/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7PP823390X6821541KHGBLOA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7PP823390X6821541KHGBLOA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-2YJ70530VD763064EKHGBLNA\",\"create_time\":\"2013-06-27T10:36:36Z\",\"update_time\":\"2013-06-27T10:36:47Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"618561790K762980R\",\"create_time\":\"2013-06-27T10:36:36Z\",\"update_time\":\"2013-06-27T10:36:47Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-2YJ70530VD763064EKHGBLNA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/618561790K762980R\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/618561790K762980R/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-2YJ70530VD763064EKHGBLNA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-2YJ70530VD763064EKHGBLNA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-6YY86361R9880232RKHGBLGA\",\"create_time\":\"2013-06-27T10:36:08Z\",\"update_time\":\"2013-06-27T10:36:18Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"87Y07698L80"
32
+ -> "{\"payments\":[{\"id\":\"PAY-0DS51393N4328690CKIQCNAA\",\"create_time\":\"2013-08-30T04:58:40Z\",\"update_time\":\"2013-08-30T04:58:46Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"74E51272GK930880A\",\"create_time\":\"2013-08-30T04:58:40Z\",\"update_time\":\"2013-08-30T04:58:46Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-0DS51393N4328690CKIQCNAA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/74E51272GK930880A\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/74E51272GK930880A/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0DS51393N4328690CKIQCNAA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0DS51393N4328690CKIQCNAA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-8R3930959K916330AKIQCHTI\",\"create_time\":\"2013-08-30T04:47:09Z\",\"update_time\":\"2013-08-30T04:47:11Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx5786\",\"expire_month\":\"6\",\"expire_year\":\"2018\",\"first_name\":\"sdfsd\",\"last_name\":\"dsfds\",\"billing_address\":{\"line1\":\"fdgg\",\"line2\":\".\",\"city\":\"dfgdf\",\"state\":\"Alabama\",\"postal_code\":\"65755\",\"country_code\":\"US\"}}}]},\"transactions\":[{\"amount\":{\"total\":\"10.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"10.00\"}},\"description\":\"Registration Fee\",\"related_resources\":[{\"sale\":{\"id\":\"69109919WG6952913\",\"create_time\":\"2013-08-30T04:47:09Z\",\"update_time\":\"2013-08-30T04:47:11Z\",\"state\":\"completed\",\"amount\":{\"total\":\"10.00\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-8R3930959K916330AKIQCHTI\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/69109919WG6952913\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/69109919WG6952913/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8R3930959K916330AKIQCHTI\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8R3930959K916330AKIQCHTI\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-7V779851CS505440NKIQCEZA\",\"create_time\":\"2013-08-30T04:41:08Z\",\"update_time\":\"2013-08-30T04:41:13Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"96F496368T369135V\",\"create_time\":\"2013-08-30T04:41:08Z\",\"update_time\":\"2013-08-30T04:41:13Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-7V779851CS505440NKIQCEZA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/96F496368T369135V\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/96F496368T369135V/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7V779851CS505440NKIQCEZA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-7V779851CS505440NKIQCEZA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-8EB278863A474793XKIQCEUY\",\"create_time\":\"2013-08-30T04:40:51Z\",\"update_time\":\"2013-08-30T04:40:56Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"85S03372X92215335\",\"create_time\":\"2013-08-30T04:40:51Z\",\"update_time\":\"2013-08-30T04:40:56Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-8EB278863A474793XKIQCEUY\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/85S03372X92215335\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/85S03372X92215335/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8EB278863A474793XKIQCEUY\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8EB278863A474793XKIQCEUY\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-0V627461U2870004WKIQCEJQ\",\"create_time\":\"2013-08-30T04:40:06Z\",\"update_time\":\"2013-08-30T04:40:11Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"0KG78962BM6495242\",\"create_time\":\"2013-08-30T04:40:06Z\",\"update_time\":\"2013-08-30T04:40:11Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-0V627461U2870004WKIQCEJQ\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/0KG78962BM6495242\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/0KG78962BM6495242/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0V627461U2870004WKIQCEJQ\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0V627461U2870004WKIQCEJQ\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-90X56842U2631360MKIQCEGA\",\"create_time\":\"2013-08-30T04:39:52Z\",\"update_time\":\"2013-08-30T04:39:57Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"9J7951070U078951M\",\"create_time\":\"2013-08-30T04:39:52Z\",\"update_time\":\"2013-08-30T04:39:57Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-90X56842U2631360MKIQCEGA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/9J7951070U078951M\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/9J7951070U078951M/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-90X56842U2631360MKIQCEGA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-90X56842U2631360MKIQCEGA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-68T340036C311945NKIQCEEI\",\"create_time\":\"2013-08-30T04:39:45Z\",\"update_time\":\"2013-08-30T04:39:50Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"4NR050459C704525B\",\"create_time\":\"2013-08-30T04:39:45Z\",\"update_time\":\"2013-08-30T04:39:50Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-68T340036C311945NKIQCEEI\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/4NR050459C704525B\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/4NR050459C704525B/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payme"
33
33
  read 8192 bytes
34
34
  reading 2 bytes...
35
35
  -> "\r\n"
36
36
  read 2 bytes
37
- -> "118f\r\n"
38
- reading 4495 bytes...
39
- -> "11580Y\",\"create_time\":\"2013-06-27T10:36:08Z\",\"update_time\":\"2013-06-27T10:36:18Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-6YY86361R9880232RKHGBLGA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/87Y07698L8011580Y\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/87Y07698L8011580Y/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-6YY86361R9880232RKHGBLGA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/p"
40
- -> "ayment/PAY-6YY86361R9880232RKHGBLGA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-42M481275G922871RKHGBLBI\",\"create_time\":\"2013-06-27T10:35:49Z\",\"update_time\":\"2013-06-27T10:35:52Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"1YA69791VT797374Y\",\"create_time\":\"2013-06-27T10:35:49Z\",\"update_time\":\"2013-06-27T10:35:52Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-42M481275G922871RKHGBLBI\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/1YA69791VT797374Y\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/1YA69791VT797374Y/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-42M481275G922871RKHGBLBI\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-42M481275G922871RKHGBLBI\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-0WJ66480WL8629433KHGBLAA\",\"create_time\":\"2013-06-27T10:35:44Z\",\"update_time\":\"2013-06-27T10:35:47Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"0JY12013S10208212\",\"create_time\":\"2013-06-27T10:35:44Z\",\"update_time\":\"2013-06-27T10:35:47Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-0WJ66480WL8629433KHGBLAA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/0JY12013S10208212\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/0JY12013S10208212/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0WJ66480WL8629433KHGBLAA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-0WJ66480WL8629433KHGBLAA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-5RD87290YJ9215428KHGBBPA\",\"create_time\":\"2013-06-27T10:15:24Z\",\"update_time\":\"2013-06-27T10:15:47Z\",\"state\":\"approved\",\"intent\":\"authorize\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx4242\",\"expire_month\":\"8\",\"expire_year\":\"2014\",\"first_name\":\"Bob\",\"last_name\":\"Bobsen\"}}]},\"transactions\":[{\"amount\":{\"total\":\"10.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"10.00\"}},\"related_resources\":[{\"authorization\":{\"id\":\"3J36875921801272L\",\"create_time\":\"2013-06-27T10:15:24Z\",\"update_time\":\"2013-06-27T10:15:47Z\",\"state\":\"authorized\",\"amount\":{\"total\":\"10.00\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"10.00\"}},\"parent_payment\":\"PAY-5RD87290YJ9215428KHGBBPA\",\"valid_until\":\"2013-07-26T10:15:24Z\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/authorization/3J36875921801272L\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/authorization/3J36875921801272L/capture\",\"rel\":\"capture\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/authorization/3J36875921801272L/void\",\"rel\":\"void\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-5RD87290YJ9215428KHGBBPA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-5RD87290YJ9215428KHGBBPA\",\"rel\":\"self\",\"method\":\"GET\"}]}],\"count\":10,\"next_id\":\"PAY-518680051W174184RKHGBBHI\"}"
41
- read 4495 bytes
37
+ -> "ed9\r\n"
38
+ reading 3801 bytes...
39
+ -> "nts/payment/PAY-68T340036C311945NKIQCEEI\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-68T340036C311945NKIQCEEI\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-8W452026L3042713WKIQCDVI\",\"create_time\":\"2013-08-30T04:38:45Z\",\"update_time\":\"2013-08-30T04:38:50Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currenc"
40
+ -> "y\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"8SG27240ED024224W\",\"create_time\":\"2013-08-30T04:38:45Z\",\"update_time\":\"2013-08-30T04:38:50Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-8W452026L3042713WKIQCDVI\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/8SG27240ED024224W\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/8SG27240ED024224W/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8W452026L3042713WKIQCDVI\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-8W452026L3042713WKIQCDVI\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-1XX53492EH793494JKIQCDTA\",\"create_time\":\"2013-08-30T04:38:36Z\",\"update_time\":\"2013-08-30T04:38:41Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"2FS37015N20643941\",\"create_time\":\"2013-08-30T04:38:36Z\",\"update_time\":\"2013-08-30T04:38:41Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-1XX53492EH793494JKIQCDTA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/2FS37015N20643941\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/2FS37015N20643941/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-1XX53492EH793494JKIQCDTA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-1XX53492EH793494JKIQCDTA\",\"rel\":\"self\",\"method\":\"GET\"}]},{\"id\":\"PAY-41M589147A160374TKIQCDMA\",\"create_time\":\"2013-08-30T04:38:08Z\",\"update_time\":\"2013-08-30T04:38:14Z\",\"state\":\"approved\",\"intent\":\"sale\",\"payer\":{\"payment_method\":\"credit_card\",\"funding_instruments\":[{\"credit_card\":{\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx0331\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}}]},\"transactions\":[{\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\",\"details\":{\"subtotal\":\"7.47\"}},\"related_resources\":[{\"sale\":{\"id\":\"1W104578DK030142W\",\"create_time\":\"2013-08-30T04:38:09Z\",\"update_time\":\"2013-08-30T04:38:14Z\",\"state\":\"completed\",\"amount\":{\"total\":\"7.47\",\"currency\":\"USD\"},\"parent_payment\":\"PAY-41M589147A160374TKIQCDMA\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/1W104578DK030142W\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/sale/1W104578DK030142W/refund\",\"rel\":\"refund\",\"method\":\"POST\"},{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-41M589147A160374TKIQCDMA\",\"rel\":\"parent_payment\",\"method\":\"GET\"}]}}]}],\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/payments/payment/PAY-41M589147A160374TKIQCDMA\",\"rel\":\"self\",\"method\":\"GET\"}]}],\"count\":10,\"next_id\":\"PAY-3NC28630H79858423KIQCDAY\"}"
41
+ read 3801 bytes
42
42
  reading 2 bytes...
43
43
  -> "\r\n"
44
44
  read 2 bytes
@@ -49,67 +49,67 @@ opening connection to api.sandbox.paypal.com:443...
49
49
  opened
50
50
  starting SSL for api.sandbox.paypal.com:443...
51
51
  SSL established
52
- <- "POST /v1/vault/credit-card HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Qonrr9ZAKBIPK9xMfZQwRS85Qbg7aYkMCJBBe0jcuQU\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 138\r\n\r\n"
52
+ <- "POST /v1/vault/credit-card HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer eGvOXNxkr0DrEnUV2ZhTYcO9Y2Ia1RLD2ePY19KadEk\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 138\r\n\r\n"
53
53
  <- "{\"type\":\"visa\",\"number\":\"4111111111111111\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"cvv2\":\"874\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\"}"
54
54
  -> "HTTP/1.1 201 Created\r\n"
55
55
  -> "Server: Apache-Coyote/1.1\r\n"
56
- -> "Date: Thu, 27 Jun 2013 10:49:58 GMT\r\n"
57
- -> "PayPal-Debug-Id: 34d470281e387\r\n"
56
+ -> "Date: Fri, 30 Aug 2013 04:58:57 GMT\r\n"
57
+ -> "PayPal-Debug-Id: a7f585b46c1a2\r\n"
58
58
  -> "Content-Type: application/json\r\n"
59
59
  -> "Content-Length: 469\r\n"
60
60
  -> "\r\n"
61
61
  reading 469 bytes...
62
- -> "{\"id\":\"CARD-0PW70831N6509050PKHGBRVQ\",\"valid_until\":\"2016-06-26T00:00:00Z\",\"state\":\"ok\",\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx1111\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-0PW70831N6509050PKHGBRVQ\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-0PW70831N6509050PKHGBRVQ\",\"rel\":\"delete\",\"method\":\"DELETE\"}]}"
62
+ -> "{\"id\":\"CARD-8T334038NM032805UKIQCNEI\",\"valid_until\":\"2016-08-29T00:00:00Z\",\"state\":\"ok\",\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx1111\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-8T334038NM032805UKIQCNEI\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-8T334038NM032805UKIQCNEI\",\"rel\":\"delete\",\"method\":\"DELETE\"}]}"
63
63
  read 469 bytes
64
64
  Conn keep-alive
65
65
  opening connection to api.sandbox.paypal.com:443...
66
66
  opened
67
67
  starting SSL for api.sandbox.paypal.com:443...
68
68
  SSL established
69
- <- "GET /v1/vault/credit-card/CARD-0PW70831N6509050PKHGBRVQ HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Qonrr9ZAKBIPK9xMfZQwRS85Qbg7aYkMCJBBe0jcuQU\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
69
+ <- "GET /v1/vault/credit-card/CARD-8T334038NM032805UKIQCNEI HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer eGvOXNxkr0DrEnUV2ZhTYcO9Y2Ia1RLD2ePY19KadEk\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
70
70
  -> "HTTP/1.1 200 OK\r\n"
71
71
  -> "Server: Apache-Coyote/1.1\r\n"
72
- -> "Date: Thu, 27 Jun 2013 10:49:59 GMT\r\n"
73
- -> "PayPal-Debug-Id: ec22a5e91d773\r\n"
72
+ -> "Date: Fri, 30 Aug 2013 04:58:59 GMT\r\n"
73
+ -> "PayPal-Debug-Id: 39a50b626c81f\r\n"
74
74
  -> "Content-Type: application/json\r\n"
75
75
  -> "Content-Length: 469\r\n"
76
76
  -> "\r\n"
77
77
  reading 469 bytes...
78
- -> "{\"id\":\"CARD-0PW70831N6509050PKHGBRVQ\",\"valid_until\":\"2016-06-26T00:00:00Z\",\"state\":\"ok\",\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx1111\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-0PW70831N6509050PKHGBRVQ\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-0PW70831N6509050PKHGBRVQ\",\"rel\":\"delete\",\"method\":\"DELETE\"}]}"
78
+ -> "{\"id\":\"CARD-8T334038NM032805UKIQCNEI\",\"valid_until\":\"2016-08-29T00:00:00Z\",\"state\":\"ok\",\"type\":\"visa\",\"number\":\"xxxxxxxxxxxx1111\",\"expire_month\":\"11\",\"expire_year\":\"2018\",\"first_name\":\"Joe\",\"last_name\":\"Shopper\",\"links\":[{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-8T334038NM032805UKIQCNEI\",\"rel\":\"self\",\"method\":\"GET\"},{\"href\":\"https://api.sandbox.paypal.com/v1/vault/credit-card/CARD-8T334038NM032805UKIQCNEI\",\"rel\":\"delete\",\"method\":\"DELETE\"}]}"
79
79
  read 469 bytes
80
80
  Conn keep-alive
81
81
  opening connection to api.sandbox.paypal.com:443...
82
82
  opened
83
83
  starting SSL for api.sandbox.paypal.com:443...
84
84
  SSL established
85
- <- "GET /v1/payments/payment/PAY-1234 HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Osw2KQ0OeYElPQAtMeRH7b5Q7l-qh.xjSd7hQSOwib8\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
85
+ <- "GET /v1/payments/payment/PAY-1234 HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer jHPsUnuwb9F1xzqb8f0CYGhfpus5tv5cGtoJXbrQRo0\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\n\r\n"
86
86
  -> "HTTP/1.1 404 Not Found\r\n"
87
87
  -> "Server: Apache-Coyote/1.1\r\n"
88
- -> "Date: Thu, 27 Jun 2013 10:50:01 GMT\r\n"
89
- -> "PayPal-Debug-Id: 9b82e21b1d168\r\n"
88
+ -> "Date: Fri, 30 Aug 2013 04:59:00 GMT\r\n"
89
+ -> "PayPal-Debug-Id: 05e0d1dd6d5ea\r\n"
90
90
  -> "Content-Type: application/json\r\n"
91
91
  -> "Content-Length: 207\r\n"
92
92
  -> "\r\n"
93
93
  reading 207 bytes...
94
- -> "{\"name\":\"INVALID_RESOURCE_ID\",\"message\":\"The requested resource ID was not found\",\"information_link\":\"https://developer.paypal.com/webapps/developer/docs/api/#INVALID_RESOURCE_ID\",\"debug_id\":\"9b82e21b1d168\"}"
94
+ -> "{\"name\":\"INVALID_RESOURCE_ID\",\"message\":\"The requested resource ID was not found\",\"information_link\":\"https://developer.paypal.com/webapps/developer/docs/api/#INVALID_RESOURCE_ID\",\"debug_id\":\"05e0d1dd6d5ea\"}"
95
95
  read 207 bytes
96
96
  Conn keep-alive
97
97
  opening connection to api.sandbox.paypal.com:443...
98
98
  opened
99
99
  starting SSL for api.sandbox.paypal.com:443...
100
100
  SSL established
101
- <- "POST /v1/payments/payment HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer Osw2KQ0OeYElPQAtMeRH7b5Q7l-qh.xjSd7hQSOwib8\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.5 (paypal-sdk-core 0.2.5; ruby 2.0.0p0-x86_64-darwin12.3.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 2\r\n\r\n"
101
+ <- "POST /v1/payments/payment HTTP/1.1\r\nX-Paypal-Sandbox-Email-Address: Platform.sdk.seller@gmail.com\r\nAuthorization: Bearer jHPsUnuwb9F1xzqb8f0CYGhfpus5tv5cGtoJXbrQRo0\r\nContent-Type: application/json\r\nUser-Agent: PayPalSDK/sdk-core-ruby 0.2.6 (paypal-sdk-core 0.2.6; ruby 2.0.0p247-x86_64-darwin12.4.0)\r\nAccept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3\r\nAccept: */*\r\nHost: api.sandbox.paypal.com\r\nContent-Length: 2\r\n\r\n"
102
102
  <- "{}"
103
103
  -> "HTTP/1.1 400 Bad Request\r\n"
104
104
  -> "Server: Apache-Coyote/1.1\r\n"
105
- -> "Date: Thu, 27 Jun 2013 10:50:02 GMT\r\n"
105
+ -> "Date: Fri, 30 Aug 2013 04:59:03 GMT\r\n"
106
106
  -> "Connection: close\r\n"
107
- -> "PayPal-Debug-Id: f2db159e1f6ba\r\n"
107
+ -> "PayPal-Debug-Id: 989f8c126df6d\r\n"
108
108
  -> "Content-Type: application/json\r\n"
109
109
  -> "Content-Length: 364\r\n"
110
110
  -> "Connection: close\r\n"
111
111
  -> "\r\n"
112
112
  reading 364 bytes...
113
- -> "{\"name\":\"VALIDATION_ERROR\",\"details\":[{\"field\":\"payer\",\"issue\":\"Required field missing\"},{\"field\":\"transactions\",\"issue\":\"Required field missing\"},{\"field\":\"intent\",\"issue\":\"Required field missing\"}],\"message\":\"Invalid request - see details\",\"information_link\":\"https://developer.paypal.com/webapps/developer/docs/api/#VALIDATION_ERROR\",\"debug_id\":\"f2db159e1f6ba\"}"
113
+ -> "{\"name\":\"VALIDATION_ERROR\",\"details\":[{\"field\":\"transactions\",\"issue\":\"Required field missing\"},{\"field\":\"payer\",\"issue\":\"Required field missing\"},{\"field\":\"intent\",\"issue\":\"Required field missing\"}],\"message\":\"Invalid request - see details\",\"information_link\":\"https://developer.paypal.com/webapps/developer/docs/api/#VALIDATION_ERROR\",\"debug_id\":\"989f8c126df6d\"}"
114
114
  read 364 bytes
115
115
  Conn close
data/spec/spec_helper.rb CHANGED
@@ -8,8 +8,11 @@ if ENV['COVERAGE']
8
8
  end
9
9
 
10
10
  Bundler.require :default, :test
11
- require 'logger'
12
11
 
12
+ require 'coveralls'
13
+ Coveralls.wear!
14
+
15
+ require 'logger'
13
16
  PayPal::SDK.load('spec/config/paypal.yml', 'test')
14
17
  PayPal::SDK.logger = Logger.new(STDERR)
15
18
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paypal-sdk-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - PayPal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-06-27 00:00:00.000000000 Z
11
+ date: 2013-08-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: xml-simple
@@ -101,8 +101,10 @@ files:
101
101
  - README.md
102
102
  - Gemfile
103
103
  - CHANGELOG.txt
104
+ - LICENSE.txt
104
105
  homepage: https://developer.paypal.com
105
- licenses: []
106
+ licenses:
107
+ - PayPal SDK License
106
108
  metadata: {}
107
109
  post_install_message:
108
110
  rdoc_options: []
@@ -120,7 +122,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
122
  version: '0'
121
123
  requirements: []
122
124
  rubyforge_project:
123
- rubygems_version: 2.0.3
125
+ rubygems_version: 2.0.4
124
126
  signing_key:
125
127
  specification_version: 4
126
128
  summary: Core library for PayPal ruby SDKs