paypal-payment 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (245) hide show
  1. data/.gitignore +19 -0
  2. data/.rspec +1 -0
  3. data/Gemfile +18 -0
  4. data/Guardfile +24 -0
  5. data/README.rdoc +107 -0
  6. data/Rakefile +5 -0
  7. data/docs/AdaptivePayments.rdoc +84 -0
  8. data/docs/PP_NVPAPI_DeveloperGuide.pdf +0 -0
  9. data/docs/PP_WPP_IntegrationGuide.pdf +0 -0
  10. data/docs/adaptive_payments.md +55 -0
  11. data/docs/api.txt +67 -0
  12. data/docs/design.txt +38 -0
  13. data/docs/express_checkout.md +172 -0
  14. data/docs/requirements.txt +32 -0
  15. data/lib/paypal-payment.rb +10 -0
  16. data/lib/paypal/adaptive_payments.rb +31 -0
  17. data/lib/paypal/adaptive_payments/api.rb +51 -0
  18. data/lib/paypal/adaptive_payments/base.rb +11 -0
  19. data/lib/paypal/adaptive_payments/client_details.rb +14 -0
  20. data/lib/paypal/adaptive_payments/display_options.rb +10 -0
  21. data/lib/paypal/adaptive_payments/funding_constraint.rb +11 -0
  22. data/lib/paypal/adaptive_payments/funding_type_info.rb +8 -0
  23. data/lib/paypal/adaptive_payments/funding_type_list.rb +11 -0
  24. data/lib/paypal/adaptive_payments/initiating_entity.rb +11 -0
  25. data/lib/paypal/adaptive_payments/institution_customer.rb +13 -0
  26. data/lib/paypal/adaptive_payments/invoice_data.rb +13 -0
  27. data/lib/paypal/adaptive_payments/invoice_item.rb +11 -0
  28. data/lib/paypal/adaptive_payments/payment.rb +105 -0
  29. data/lib/paypal/adaptive_payments/payment_info.rb +18 -0
  30. data/lib/paypal/adaptive_payments/payment_info_list.rb +11 -0
  31. data/lib/paypal/adaptive_payments/payment_options.rb +39 -0
  32. data/lib/paypal/adaptive_payments/phone.rb +9 -0
  33. data/lib/paypal/adaptive_payments/preapproval.rb +52 -0
  34. data/lib/paypal/adaptive_payments/receiver.rb +17 -0
  35. data/lib/paypal/adaptive_payments/receiver_list.rb +49 -0
  36. data/lib/paypal/adaptive_payments/receiver_options.rb +19 -0
  37. data/lib/paypal/adaptive_payments/request.rb +51 -0
  38. data/lib/paypal/adaptive_payments/response.rb +38 -0
  39. data/lib/paypal/adaptive_payments/response/address.rb +13 -0
  40. data/lib/paypal/adaptive_payments/response/address_list.rb +11 -0
  41. data/lib/paypal/adaptive_payments/response/base_address.rb +13 -0
  42. data/lib/paypal/adaptive_payments/response/details.rb +19 -0
  43. data/lib/paypal/adaptive_payments/response/error_list.rb +15 -0
  44. data/lib/paypal/adaptive_payments/response/pay.rb +31 -0
  45. data/lib/paypal/adaptive_payments/response/pay_error.rb +16 -0
  46. data/lib/paypal/adaptive_payments/response/pay_error_list.rb +15 -0
  47. data/lib/paypal/adaptive_payments/response/pay_options.rb +7 -0
  48. data/lib/paypal/adaptive_payments/response/preapproval.rb +47 -0
  49. data/lib/paypal/adaptive_payments/response/refund.rb +16 -0
  50. data/lib/paypal/adaptive_payments/response/refund_info.rb +24 -0
  51. data/lib/paypal/adaptive_payments/response/refund_info_list.rb +11 -0
  52. data/lib/paypal/adaptive_payments/response/shipping_address.rb +11 -0
  53. data/lib/paypal/adaptive_payments/sender_identifier.rb +7 -0
  54. data/lib/paypal/adaptive_payments/sender_options.rb +8 -0
  55. data/lib/paypal/api.rb +94 -0
  56. data/lib/paypal/cacert.pem +3987 -0
  57. data/lib/paypal/common.rb +11 -0
  58. data/lib/paypal/common/base.rb +83 -0
  59. data/lib/paypal/common/error_data.rb +15 -0
  60. data/lib/paypal/common/request.rb +45 -0
  61. data/lib/paypal/common/request_envelope.rb +13 -0
  62. data/lib/paypal/common/response.rb +34 -0
  63. data/lib/paypal/common/response_envelope.rb +19 -0
  64. data/lib/paypal/express_checkout.rb +19 -0
  65. data/lib/paypal/express_checkout/account.rb +16 -0
  66. data/lib/paypal/express_checkout/api.rb +43 -0
  67. data/lib/paypal/express_checkout/base.rb +37 -0
  68. data/lib/paypal/express_checkout/billing.rb +7 -0
  69. data/lib/paypal/express_checkout/callback.rb +17 -0
  70. data/lib/paypal/express_checkout/checkout.rb +144 -0
  71. data/lib/paypal/express_checkout/fields.rb +449 -0
  72. data/lib/paypal/express_checkout/fmf.rb +7 -0
  73. data/lib/paypal/express_checkout/payment.rb +76 -0
  74. data/lib/paypal/express_checkout/payment_item.rb +7 -0
  75. data/lib/paypal/express_checkout/recurring.rb +131 -0
  76. data/lib/paypal/express_checkout/request.rb +212 -0
  77. data/lib/paypal/express_checkout/response.rb +52 -0
  78. data/lib/paypal/express_checkout/response/account.rb +30 -0
  79. data/lib/paypal/express_checkout/response/address.rb +29 -0
  80. data/lib/paypal/express_checkout/response/authorization.rb +25 -0
  81. data/lib/paypal/express_checkout/response/base.rb +125 -0
  82. data/lib/paypal/express_checkout/response/callback_request.rb +10 -0
  83. data/lib/paypal/express_checkout/response/callback_response.rb +8 -0
  84. data/lib/paypal/express_checkout/response/capture.rb +14 -0
  85. data/lib/paypal/express_checkout/response/checkout.rb +11 -0
  86. data/lib/paypal/express_checkout/response/details.rb +35 -0
  87. data/lib/paypal/express_checkout/response/manage_profile.rb +9 -0
  88. data/lib/paypal/express_checkout/response/notification.rb +85 -0
  89. data/lib/paypal/express_checkout/response/payment.rb +24 -0
  90. data/lib/paypal/express_checkout/response/profile.rb +58 -0
  91. data/lib/paypal/express_checkout/response/reference.rb +11 -0
  92. data/lib/paypal/express_checkout/response/refund.rb +13 -0
  93. data/lib/paypal/express_checkout/response/search.rb +33 -0
  94. data/lib/paypal/express_checkout/response/transaction_details.rb +11 -0
  95. data/lib/paypal/express_checkout/shipping_option.rb +7 -0
  96. data/lib/paypal/express_checkout/utils.rb +26 -0
  97. data/lib/paypal/express_checkout/version.rb +10 -0
  98. data/lib/paypal/invoice.rb +22 -0
  99. data/lib/paypal/invoice/api.rb +51 -0
  100. data/lib/paypal/invoice/base.rb +11 -0
  101. data/lib/paypal/invoice/base_address.rb +11 -0
  102. data/lib/paypal/invoice/business_info.rb +17 -0
  103. data/lib/paypal/invoice/date_range.rb +8 -0
  104. data/lib/paypal/invoice/invoice.rb +117 -0
  105. data/lib/paypal/invoice/invoice_details.rb +38 -0
  106. data/lib/paypal/invoice/invoice_item.rb +13 -0
  107. data/lib/paypal/invoice/invoice_item_list.rb +10 -0
  108. data/lib/paypal/invoice/invoice_summary.rb +22 -0
  109. data/lib/paypal/invoice/invoice_summary_list.rb +10 -0
  110. data/lib/paypal/invoice/other_payment_details.rb +13 -0
  111. data/lib/paypal/invoice/payment_details.rb +16 -0
  112. data/lib/paypal/invoice/paypal_payment_details.rb +11 -0
  113. data/lib/paypal/invoice/request.rb +43 -0
  114. data/lib/paypal/invoice/response.rb +27 -0
  115. data/lib/paypal/invoice/response/details.rb +23 -0
  116. data/lib/paypal/invoice/response/invoice.rb +10 -0
  117. data/lib/paypal/invoice/response/search.rb +15 -0
  118. data/lib/paypal/invoice/search.rb +19 -0
  119. data/lib/paypal/invoice/search_parameters.rb +20 -0
  120. data/lib/paypal/permissions.rb +12 -0
  121. data/lib/paypal/permissions/api.rb +60 -0
  122. data/lib/paypal/permissions/base.rb +11 -0
  123. data/lib/paypal/permissions/permission.rb +33 -0
  124. data/lib/paypal/permissions/personal_data.rb +17 -0
  125. data/lib/paypal/permissions/request.rb +52 -0
  126. data/lib/paypal/permissions/response.rb +24 -0
  127. data/lib/paypal/permissions/response/permission.rb +14 -0
  128. data/lib/paypal/permissions/response/personal_data.rb +8 -0
  129. data/lib/paypal/permissions/response/token.rb +10 -0
  130. data/lib/paypal/permissions/token.rb +13 -0
  131. data/lib/paypal/recurring.rb +110 -0
  132. data/lib/paypal/request.rb +82 -0
  133. data/lib/paypal/version.rb +8 -0
  134. data/paypal-payment.gemspec +30 -0
  135. data/spec/fixtures/adaptive_payments/payment/create/failure.yml +62 -0
  136. data/spec/fixtures/adaptive_payments/payment/create/success.yml +58 -0
  137. data/spec/fixtures/adaptive_payments/payment/details/success.yml +113 -0
  138. data/spec/fixtures/adaptive_payments/payment/pay/failure.yml +62 -0
  139. data/spec/fixtures/adaptive_payments/payment/pay/preapproval.yml +58 -0
  140. data/spec/fixtures/adaptive_payments/payment/pay/success.yml +58 -0
  141. data/spec/fixtures/adaptive_payments/payment/pay/with_pay_key.yml +58 -0
  142. data/spec/fixtures/adaptive_payments/payment/refund/failure.yml +62 -0
  143. data/spec/fixtures/adaptive_payments/payment/refund/success.yml +58 -0
  144. data/spec/fixtures/adaptive_payments/payment/shipping_addresses/success.yml +113 -0
  145. data/spec/fixtures/adaptive_payments/payment_options/get/success.yml +174 -0
  146. data/spec/fixtures/adaptive_payments/payment_options/set/success.yml +113 -0
  147. data/spec/fixtures/adaptive_payments/preapproval/create/success.yml +58 -0
  148. data/spec/fixtures/adaptive_payments/preapproval/details/success.yml +168 -0
  149. data/spec/fixtures/express_checkout/account/balance/success.yml +32 -0
  150. data/spec/fixtures/express_checkout/account/pal_details/success.yml +32 -0
  151. data/spec/fixtures/express_checkout/checkout/checkout/sales/success.yml +61 -0
  152. data/spec/fixtures/express_checkout/checkout/checkout/success.yml +32 -0
  153. data/spec/fixtures/express_checkout/checkout/details/failure.yml +32 -0
  154. data/spec/fixtures/express_checkout/checkout/details/success.yml +61 -0
  155. data/spec/fixtures/express_checkout/checkout/pay/sales/success.yml +61 -0
  156. data/spec/fixtures/express_checkout/checkout/pay/success.yml +61 -0
  157. data/spec/fixtures/express_checkout/payment/details/failure.yml +32 -0
  158. data/spec/fixtures/express_checkout/payment/details/success.yml +32 -0
  159. data/spec/fixtures/express_checkout/payment/refund/failure.yml +32 -0
  160. data/spec/fixtures/express_checkout/payment/refund/success.yml +32 -0
  161. data/spec/fixtures/express_checkout/payment/search/success.yml +32 -0
  162. data/spec/fixtures/express_checkout/recurring/cancel/failure.yml +32 -0
  163. data/spec/fixtures/express_checkout/recurring/cancel/success.yml +32 -0
  164. data/spec/fixtures/express_checkout/recurring/checkout/success.yml +32 -0
  165. data/spec/fixtures/express_checkout/recurring/create_profile/failure.yml +32 -0
  166. data/spec/fixtures/express_checkout/recurring/create_profile/success.yml +61 -0
  167. data/spec/fixtures/express_checkout/recurring/profile/failure.yml +32 -0
  168. data/spec/fixtures/express_checkout/recurring/profile/success.yml +32 -0
  169. data/spec/fixtures/express_checkout/recurring/reactivate/failure.yml +32 -0
  170. data/spec/fixtures/express_checkout/recurring/reactivate/success.yml +32 -0
  171. data/spec/fixtures/express_checkout/recurring/suspend/failure.yml +32 -0
  172. data/spec/fixtures/express_checkout/recurring/suspend/success.yml +32 -0
  173. data/spec/fixtures/express_checkout/recurring/update_profile/failure.yml +32 -0
  174. data/spec/fixtures/express_checkout/recurring/update_profile/profile.yml +32 -0
  175. data/spec/fixtures/express_checkout/recurring/update_profile/success.yml +32 -0
  176. data/spec/fixtures/invoice/cancel/success.yml +174 -0
  177. data/spec/fixtures/invoice/create/failure.yml +62 -0
  178. data/spec/fixtures/invoice/create/success.yml +60 -0
  179. data/spec/fixtures/invoice/create_and_send/failure.yml +62 -0
  180. data/spec/fixtures/invoice/create_and_send/success.yml +60 -0
  181. data/spec/fixtures/invoice/details/success.yml +117 -0
  182. data/spec/fixtures/invoice/mark_as_paid/failure.yml +180 -0
  183. data/spec/fixtures/invoice/mark_as_paid/success.yml +174 -0
  184. data/spec/fixtures/invoice/mark_as_refunded/success.yml +174 -0
  185. data/spec/fixtures/invoice/mark_as_unpaid/success.yml +231 -0
  186. data/spec/fixtures/invoice/search/success.yml +174 -0
  187. data/spec/fixtures/invoice/send/success.yml +117 -0
  188. data/spec/fixtures/invoice/update/failure.yml +119 -0
  189. data/spec/fixtures/invoice/update/success.yml +117 -0
  190. data/spec/fixtures/ipn/express_checkout.json +35 -0
  191. data/spec/fixtures/ipn/recurring_payment.json +44 -0
  192. data/spec/fixtures/ipn/recurring_payment_profile_created.json +31 -0
  193. data/spec/fixtures/ipn/recurring_payment_profile_created_with_initial_amount.json +33 -0
  194. data/spec/fixtures/ipn/recurring_payment_skipped.json +30 -0
  195. data/spec/fixtures/ipn/recurring_payment_with_initial_amount.json +44 -0
  196. data/spec/fixtures/notification/failure.yml +50 -0
  197. data/spec/fixtures/notification/success.yml +50 -0
  198. data/spec/paypal/adaptive_payments/api_spec.rb +20 -0
  199. data/spec/paypal/adaptive_payments/payment/base_spec.rb +28 -0
  200. data/spec/paypal/adaptive_payments/payment/create_spec.rb +63 -0
  201. data/spec/paypal/adaptive_payments/payment/details_spec.rb +34 -0
  202. data/spec/paypal/adaptive_payments/payment/pay_spec.rb +97 -0
  203. data/spec/paypal/adaptive_payments/payment/refund_spec.rb +49 -0
  204. data/spec/paypal/adaptive_payments/payment/shipping_addresses_spec.rb +30 -0
  205. data/spec/paypal/adaptive_payments/payment_options/get_spec.rb +33 -0
  206. data/spec/paypal/adaptive_payments/payment_options/set_spec.rb +66 -0
  207. data/spec/paypal/adaptive_payments/preapproval/cancel_spec.rb +34 -0
  208. data/spec/paypal/adaptive_payments/preapproval/create_spec.rb +39 -0
  209. data/spec/paypal/adaptive_payments/preapproval/details_spec.rb +34 -0
  210. data/spec/paypal/adaptive_payments/request_spec.rb +48 -0
  211. data/spec/paypal/api_spec.rb +78 -0
  212. data/spec/paypal/common/base_spec.rb +157 -0
  213. data/spec/paypal/common/error_data_spec.rb +0 -0
  214. data/spec/paypal/common/request_envelope_spec.rb +6 -0
  215. data/spec/paypal/common/response_spec.rb +0 -0
  216. data/spec/paypal/express_checkout/account/balance_spec.rb +25 -0
  217. data/spec/paypal/express_checkout/account/pal_details_spec.rb +20 -0
  218. data/spec/paypal/express_checkout/checkout/checkout_spec.rb +73 -0
  219. data/spec/paypal/express_checkout/checkout/details_spec.rb +70 -0
  220. data/spec/paypal/express_checkout/checkout/pay_spec.rb +68 -0
  221. data/spec/paypal/express_checkout/fields_spec.rb +138 -0
  222. data/spec/paypal/express_checkout/payment/refund_spec.rb +34 -0
  223. data/spec/paypal/express_checkout/payment/search_spec.rb +24 -0
  224. data/spec/paypal/express_checkout/payment/transaction_details_spec.rb +30 -0
  225. data/spec/paypal/express_checkout/payment_spec.rb +13 -0
  226. data/spec/paypal/express_checkout/recurring/create_profile_spec.rb +50 -0
  227. data/spec/paypal/express_checkout/recurring/manage_profile_spec.rb +62 -0
  228. data/spec/paypal/express_checkout/recurring/profile_spec.rb +44 -0
  229. data/spec/paypal/express_checkout/recurring/update_profile_spec.rb +50 -0
  230. data/spec/paypal/express_checkout/request_spec.rb +221 -0
  231. data/spec/paypal/express_checkout/response/account_spec.rb +33 -0
  232. data/spec/paypal/express_checkout/response/base_spec.rb +253 -0
  233. data/spec/paypal/invoice/cancel_spec.rb +38 -0
  234. data/spec/paypal/invoice/create_and_send_spec.rb +58 -0
  235. data/spec/paypal/invoice/create_spec.rb +58 -0
  236. data/spec/paypal/invoice/details_spec.rb +39 -0
  237. data/spec/paypal/invoice/mark_as_paid_spec.rb +75 -0
  238. data/spec/paypal/invoice/mark_as_refunded_spec.rb +47 -0
  239. data/spec/paypal/invoice/mark_as_unpaid_spec.rb +43 -0
  240. data/spec/paypal/invoice/search_spec.rb +70 -0
  241. data/spec/paypal/invoice/send_spec.rb +48 -0
  242. data/spec/paypal/invoice/update_spec.rb +72 -0
  243. data/spec/paypal/request_spec.rb +45 -0
  244. data/spec/spec_helper.rb +35 -0
  245. metadata +546 -0
@@ -0,0 +1,117 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://svcs.sandbox.paypal.com/Invoice/CreateInvoice
6
+ body:
7
+ encoding: UTF-8
8
+ string: "{\"invoice\":{\"merchantEmail\":\"chardy_1345003248_per@gmail.com\",\"payerEmail\":\"chardy_1345003165_per@gmail.com\",\"itemList\":{\"item\":[{\"name\":\"iPhone 5\",\"quantity\":1,\"unitPrice\":1000.0}]},\"currencyCode\":\"USD\",\"paymentTerms\":\"Net30\"},\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
9
+ headers:
10
+ User-Agent:
11
+ - PayPal::Payment/0.1.0
12
+ X-Paypal-Security-Userid:
13
+ - chardy_api1.gmail.com
14
+ X-Paypal-Security-Password:
15
+ - "8DTSWBZC7GDR3T4X"
16
+ X-Paypal-Security-Signature:
17
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
18
+ X-Paypal-Request-Data-Format:
19
+ - JSON
20
+ X-Paypal-Response-Data-Format:
21
+ - JSON
22
+ X-Paypal-Application-Id:
23
+ - APP-80W284485P519543T
24
+ response:
25
+ status:
26
+ code: 200
27
+ message: OK
28
+ headers:
29
+ Date:
30
+ - Sat, 26 Jan 2013 15:25:28 GMT
31
+ Server:
32
+ - Apache-Coyote/1.1
33
+ Cache-Control:
34
+ - no-cache
35
+ X-Paypal-Message-Protocol:
36
+ - NONE
37
+ X-Paypal-Response-Data-Format:
38
+ - JSON
39
+ X-Ebay-Soa-Request-Id:
40
+ - 13c77769-b4d0-a486-d637-6877ffffff78!Invoice!10.72.109.99![]
41
+ X-Paypal-Operation-Name:
42
+ - CreateInvoice
43
+ X-Paypal-Service-Name:
44
+ - "{http://svcs.paypal.com/types/pt}Invoice"
45
+ X-Paypal-Service-Version:
46
+ - 1.0.0
47
+ Content-Type:
48
+ - application/json;charset=UTF-8
49
+ Set-Cookie:
50
+ - Apache=10.72.109.11.1359213927237242; path=/; expires=Mon, 19-Jan-43 15:25:27 GMT
51
+ Vary:
52
+ - Accept-Encoding
53
+ Transfer-Encoding:
54
+ - chunked
55
+ body:
56
+ encoding: ASCII-8BIT
57
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-26T07:25:28.445-08:00\",\"ack\":\"Success\",\"correlationId\":\"0be0068f69bca\",\"build\":\"4120519\"},\"invoiceID\":\"INV2-3RB8-VEVH-38EV-ZQ27\",\"invoiceNumber\":\"0014\",\"invoiceURL\":\"https:\\/\\/www.sandbox.paypal.com\\/us\\/cgi-bin\\/?cmd=_inv-details&id=INV2-3RB8-VEVH-38EV-ZQ27\",\"totalAmount\":\"100000\"}"
58
+ http_version:
59
+ recorded_at: Sat, 26 Jan 2013 15:25:28 GMT
60
+ - request:
61
+ method: post
62
+ uri: https://svcs.sandbox.paypal.com/Invoice/SendInvoice
63
+ body:
64
+ encoding: UTF-8
65
+ string: "{\"invoiceID\":\"INV2-3RB8-VEVH-38EV-ZQ27\",\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
66
+ headers:
67
+ User-Agent:
68
+ - PayPal::Payment/0.1.0
69
+ X-Paypal-Security-Userid:
70
+ - chardy_api1.gmail.com
71
+ X-Paypal-Security-Password:
72
+ - "8DTSWBZC7GDR3T4X"
73
+ X-Paypal-Security-Signature:
74
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
75
+ X-Paypal-Request-Data-Format:
76
+ - JSON
77
+ X-Paypal-Response-Data-Format:
78
+ - JSON
79
+ X-Paypal-Application-Id:
80
+ - APP-80W284485P519543T
81
+ response:
82
+ status:
83
+ code: 200
84
+ message: OK
85
+ headers:
86
+ Date:
87
+ - Sat, 26 Jan 2013 15:25:31 GMT
88
+ Server:
89
+ - Apache-Coyote/1.1
90
+ Cache-Control:
91
+ - no-cache
92
+ X-Paypal-Message-Protocol:
93
+ - NONE
94
+ X-Paypal-Response-Data-Format:
95
+ - JSON
96
+ X-Ebay-Soa-Request-Id:
97
+ - 13c7776a-7890-a486-d637-6877ffffff77!Invoice!10.72.109.99![]
98
+ X-Paypal-Operation-Name:
99
+ - SendInvoice
100
+ X-Paypal-Service-Name:
101
+ - "{http://svcs.paypal.com/types/pt}Invoice"
102
+ X-Paypal-Service-Version:
103
+ - 1.0.0
104
+ Content-Type:
105
+ - application/json;charset=UTF-8
106
+ Set-Cookie:
107
+ - Apache=10.72.109.11.1359213930368997; path=/; expires=Mon, 19-Jan-43 15:25:30 GMT
108
+ Vary:
109
+ - Accept-Encoding
110
+ Transfer-Encoding:
111
+ - chunked
112
+ body:
113
+ encoding: ASCII-8BIT
114
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-26T07:25:31.295-08:00\",\"ack\":\"Success\",\"correlationId\":\"a8164d376a702\",\"build\":\"4120519\"},\"invoiceID\":\"INV2-3RB8-VEVH-38EV-ZQ27\",\"invoiceURL\":\"https:\\/\\/www.sandbox.paypal.com\\/us\\/cgi-bin\\/?cmd=_inv-details&id=INV2-3RB8-VEVH-38EV-ZQ27\"}"
115
+ http_version:
116
+ recorded_at: Sat, 26 Jan 2013 15:25:31 GMT
117
+ recorded_with: VCR 2.3.0
@@ -0,0 +1,119 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://svcs.sandbox.paypal.com/Invoice/CreateInvoice
6
+ body:
7
+ encoding: UTF-8
8
+ string: "{\"invoice\":{\"merchantEmail\":\"chardy_1345003248_per@gmail.com\",\"payerEmail\":\"chardy_1345003165_per@gmail.com\",\"itemList\":{\"item\":[{\"name\":\"iPhone 5\",\"quantity\":1,\"unitPrice\":1000.0}]},\"currencyCode\":\"USD\",\"paymentTerms\":\"Net30\"},\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
9
+ headers:
10
+ User-Agent:
11
+ - PayPal::Payment/0.1.0
12
+ X-Paypal-Security-Userid:
13
+ - chardy_api1.gmail.com
14
+ X-Paypal-Security-Password:
15
+ - "8DTSWBZC7GDR3T4X"
16
+ X-Paypal-Security-Signature:
17
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
18
+ X-Paypal-Request-Data-Format:
19
+ - JSON
20
+ X-Paypal-Response-Data-Format:
21
+ - JSON
22
+ X-Paypal-Application-Id:
23
+ - APP-80W284485P519543T
24
+ response:
25
+ status:
26
+ code: 200
27
+ message: OK
28
+ headers:
29
+ Date:
30
+ - Sun, 27 Jan 2013 15:06:24 GMT
31
+ Server:
32
+ - Apache-Coyote/1.1
33
+ Cache-Control:
34
+ - no-cache
35
+ X-Paypal-Message-Protocol:
36
+ - NONE
37
+ X-Paypal-Response-Data-Format:
38
+ - JSON
39
+ X-Ebay-Soa-Request-Id:
40
+ - 13c7c8b8-3790-a486-d637-6877fffffed8!Invoice!10.72.109.99![]
41
+ X-Paypal-Operation-Name:
42
+ - CreateInvoice
43
+ X-Paypal-Service-Name:
44
+ - "{http://svcs.paypal.com/types/pt}Invoice"
45
+ X-Paypal-Service-Version:
46
+ - 1.0.0
47
+ Content-Type:
48
+ - application/json;charset=UTF-8
49
+ Set-Cookie:
50
+ - Apache=10.72.109.11.1359299183474034; path=/; expires=Tue, 20-Jan-43 15:06:23 GMT
51
+ Vary:
52
+ - Accept-Encoding
53
+ Transfer-Encoding:
54
+ - chunked
55
+ body:
56
+ encoding: ASCII-8BIT
57
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T07:06:24.604-08:00\",\"ack\":\"Success\",\"correlationId\":\"d3046925b825d\",\"build\":\"4120519\"},\"invoiceID\":\"INV2-R5V3-4W37-YH3X-PX25\",\"invoiceNumber\":\"0022\",\"invoiceURL\":\"https:\\/\\/www.sandbox.paypal.com\\/us\\/cgi-bin\\/?cmd=_inv-details&id=INV2-R5V3-4W37-YH3X-PX25\",\"totalAmount\":\"100000\"}"
58
+ http_version:
59
+ recorded_at: Sun, 27 Jan 2013 15:06:24 GMT
60
+ - request:
61
+ method: post
62
+ uri: https://svcs.sandbox.paypal.com/Invoice/UpdateInvoice
63
+ body:
64
+ encoding: UTF-8
65
+ string: "{\"invoiceID\":\"INV2-R5V3-4W37-YH3X-PX25\",\"invoice\":{\"merchantEmail\":\"chardy_1345003248_per@gmail.com\",\"payerEmail\":\"chardy_1345003165_per@gmail.com\",\"itemList\":{\"item\":[{\"name\":\"iPhone 5\",\"quantity\":1,\"unitPrice\":1000.0}]},\"currencyCode\":\"USD\",\"paymentTerms\":null,\"response\":{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T07:06:24.604-08:00\",\"ack\":\"Success\",\"correlationId\":\"d3046925b825d\",\"build\":\"4120519\"},\"invoiceId\":\"INV2-R5V3-4W37-YH3X-PX25\",\"invoiceNumber\":\"0022\",\"invoiceUrl\":\"https://www.sandbox.paypal.com/us/cgi-bin/?cmd=_inv-details&id=INV2-R5V3-4W37-YH3X-PX25\",\"totalAmount\":\"100000\"},\"invoiceId\":\"INV2-R5V3-4W37-YH3X-PX25\"},\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
66
+ headers:
67
+ User-Agent:
68
+ - PayPal::Payment/0.1.0
69
+ X-Paypal-Security-Userid:
70
+ - chardy_api1.gmail.com
71
+ X-Paypal-Security-Password:
72
+ - "8DTSWBZC7GDR3T4X"
73
+ X-Paypal-Security-Signature:
74
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
75
+ X-Paypal-Request-Data-Format:
76
+ - JSON
77
+ X-Paypal-Response-Data-Format:
78
+ - JSON
79
+ X-Paypal-Application-Id:
80
+ - APP-80W284485P519543T
81
+ response:
82
+ status:
83
+ code: 200
84
+ message: OK
85
+ headers:
86
+ Date:
87
+ - Sun, 27 Jan 2013 15:06:26 GMT
88
+ Server:
89
+ - Apache-Coyote/1.1
90
+ Cache-Control:
91
+ - no-cache
92
+ X-Paypal-Message-Protocol:
93
+ - NONE
94
+ X-Paypal-Response-Data-Format:
95
+ - JSON
96
+ X-Ebay-Soa-Request-Id:
97
+ - 13c7c8b8-f110-a486-d637-6877fffffed7!Invoice!10.72.109.99![]
98
+ X-Paypal-Operation-Name:
99
+ - UpdateInvoice
100
+ X-Paypal-Service-Name:
101
+ - "{http://svcs.paypal.com/types/pt}Invoice"
102
+ X-Paypal-Service-Version:
103
+ - 1.0.0
104
+ X-Paypal-Error-Response:
105
+ - "TRUE"
106
+ Content-Type:
107
+ - application/json;charset=UTF-8
108
+ Set-Cookie:
109
+ - Apache=10.72.109.11.1359299186441526; path=/; expires=Tue, 20-Jan-43 15:06:26 GMT
110
+ Vary:
111
+ - Accept-Encoding
112
+ Transfer-Encoding:
113
+ - chunked
114
+ body:
115
+ encoding: ASCII-8BIT
116
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T07:06:26.727-08:00\",\"ack\":\"Failure\",\"correlationId\":\"28d0d8b4b8e39\",\"build\":\"4120519\"},\"error\":[{\"errorId\":\"580022\",\"domain\":\"PLATFORM\",\"subdomain\":\"Application\",\"severity\":\"Error\",\"category\":\"Application\",\"message\":\"Invalid request parameter: paymentTerms cannot be null\",\"parameter\":[\"paymentTerms\",\"null\"]}]}"
117
+ http_version:
118
+ recorded_at: Sun, 27 Jan 2013 15:06:26 GMT
119
+ recorded_with: VCR 2.3.0
@@ -0,0 +1,117 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://svcs.sandbox.paypal.com/Invoice/CreateInvoice
6
+ body:
7
+ encoding: UTF-8
8
+ string: "{\"invoice\":{\"merchantEmail\":\"chardy_1345003248_per@gmail.com\",\"payerEmail\":\"chardy_1345003165_per@gmail.com\",\"itemList\":{\"item\":[{\"name\":\"iPhone 5\",\"quantity\":1,\"unitPrice\":1000.0}]},\"currencyCode\":\"USD\",\"paymentTerms\":\"Net30\"},\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
9
+ headers:
10
+ User-Agent:
11
+ - PayPal::Payment/0.1.0
12
+ X-Paypal-Security-Userid:
13
+ - chardy_api1.gmail.com
14
+ X-Paypal-Security-Password:
15
+ - "8DTSWBZC7GDR3T4X"
16
+ X-Paypal-Security-Signature:
17
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
18
+ X-Paypal-Request-Data-Format:
19
+ - JSON
20
+ X-Paypal-Response-Data-Format:
21
+ - JSON
22
+ X-Paypal-Application-Id:
23
+ - APP-80W284485P519543T
24
+ response:
25
+ status:
26
+ code: 200
27
+ message: OK
28
+ headers:
29
+ Date:
30
+ - Sun, 27 Jan 2013 14:51:13 GMT
31
+ Server:
32
+ - Apache-Coyote/1.1
33
+ Cache-Control:
34
+ - no-cache
35
+ X-Paypal-Message-Protocol:
36
+ - NONE
37
+ X-Paypal-Response-Data-Format:
38
+ - JSON
39
+ X-Ebay-Soa-Request-Id:
40
+ - 13c7c7d9-a820-a486-d637-6877fffffedf!Invoice!10.72.109.99![]
41
+ X-Paypal-Operation-Name:
42
+ - CreateInvoice
43
+ X-Paypal-Service-Name:
44
+ - "{http://svcs.paypal.com/types/pt}Invoice"
45
+ X-Paypal-Service-Version:
46
+ - 1.0.0
47
+ Content-Type:
48
+ - application/json;charset=UTF-8
49
+ Set-Cookie:
50
+ - Apache=10.72.109.11.1359298271866457; path=/; expires=Tue, 20-Jan-43 14:51:11 GMT
51
+ Vary:
52
+ - Accept-Encoding
53
+ Transfer-Encoding:
54
+ - chunked
55
+ body:
56
+ encoding: ASCII-8BIT
57
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T06:51:13.080-08:00\",\"ack\":\"Success\",\"correlationId\":\"dbf18059d9ba2\",\"build\":\"4120519\"},\"invoiceID\":\"INV2-JZRK-UEZC-UPEN-Y5N7\",\"invoiceNumber\":\"0019\",\"invoiceURL\":\"https:\\/\\/www.sandbox.paypal.com\\/us\\/cgi-bin\\/?cmd=_inv-details&id=INV2-JZRK-UEZC-UPEN-Y5N7\",\"totalAmount\":\"100000\"}"
58
+ http_version:
59
+ recorded_at: Sun, 27 Jan 2013 14:51:13 GMT
60
+ - request:
61
+ method: post
62
+ uri: https://svcs.sandbox.paypal.com/Invoice/UpdateInvoice
63
+ body:
64
+ encoding: UTF-8
65
+ string: "{\"invoiceID\":\"INV2-JZRK-UEZC-UPEN-Y5N7\",\"invoice\":{\"merchantEmail\":\"chardy_1345003248_per@gmail.com\",\"payerEmail\":\"chardy_1345003165_per@gmail.com\",\"itemList\":{\"item\":[{\"name\":\"iPhone 5\",\"quantity\":1,\"unitPrice\":1000.0}]},\"currencyCode\":\"USD\",\"paymentTerms\":\"Net10\",\"response\":{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T06:51:13.080-08:00\",\"ack\":\"Success\",\"correlationId\":\"dbf18059d9ba2\",\"build\":\"4120519\"},\"invoiceId\":\"INV2-JZRK-UEZC-UPEN-Y5N7\",\"invoiceNumber\":\"0019\",\"invoiceUrl\":\"https://www.sandbox.paypal.com/us/cgi-bin/?cmd=_inv-details&id=INV2-JZRK-UEZC-UPEN-Y5N7\",\"totalAmount\":\"100000\"},\"invoiceId\":\"INV2-JZRK-UEZC-UPEN-Y5N7\"},\"requestEnvelope\":{\"errorLanguage\":\"en_US\",\"detailLevel\":\"ReturnAll\"}}"
66
+ headers:
67
+ User-Agent:
68
+ - PayPal::Payment/0.1.0
69
+ X-Paypal-Security-Userid:
70
+ - chardy_api1.gmail.com
71
+ X-Paypal-Security-Password:
72
+ - "8DTSWBZC7GDR3T4X"
73
+ X-Paypal-Security-Signature:
74
+ - AG-8mOpuFhFyFOYHlaTUYn3Syf15AWJKRnfHMVsmCtC3DK51-ENEPqLS
75
+ X-Paypal-Request-Data-Format:
76
+ - JSON
77
+ X-Paypal-Response-Data-Format:
78
+ - JSON
79
+ X-Paypal-Application-Id:
80
+ - APP-80W284485P519543T
81
+ response:
82
+ status:
83
+ code: 200
84
+ message: OK
85
+ headers:
86
+ Date:
87
+ - Sun, 27 Jan 2013 14:51:15 GMT
88
+ Server:
89
+ - Apache-Coyote/1.1
90
+ Cache-Control:
91
+ - no-cache
92
+ X-Paypal-Message-Protocol:
93
+ - NONE
94
+ X-Paypal-Response-Data-Format:
95
+ - JSON
96
+ X-Ebay-Soa-Request-Id:
97
+ - 13c7c7da-5800-a486-d637-6877fffffede!Invoice!10.72.109.99![]
98
+ X-Paypal-Operation-Name:
99
+ - UpdateInvoice
100
+ X-Paypal-Service-Name:
101
+ - "{http://svcs.paypal.com/types/pt}Invoice"
102
+ X-Paypal-Service-Version:
103
+ - 1.0.0
104
+ Content-Type:
105
+ - application/json;charset=UTF-8
106
+ Set-Cookie:
107
+ - Apache=10.72.109.11.1359298274680979; path=/; expires=Tue, 20-Jan-43 14:51:14 GMT
108
+ Vary:
109
+ - Accept-Encoding
110
+ Transfer-Encoding:
111
+ - chunked
112
+ body:
113
+ encoding: ASCII-8BIT
114
+ string: "{\"responseEnvelope\":{\"timestamp\":\"2013-01-27T06:51:15.869-08:00\",\"ack\":\"Success\",\"correlationId\":\"1dd6b2d7da4a0\",\"build\":\"4120519\"},\"invoiceID\":\"INV2-JZRK-UEZC-UPEN-Y5N7\",\"invoiceNumber\":\"0019\",\"invoiceURL\":\"https:\\/\\/www.sandbox.paypal.com\\/us\\/cgi-bin\\/?cmd=_inv-details&id=INV2-JZRK-UEZC-UPEN-Y5N7\",\"totalAmount\":\"100000\"}"
115
+ http_version:
116
+ recorded_at: Sun, 27 Jan 2013 14:51:16 GMT
117
+ recorded_with: VCR 2.3.0
@@ -0,0 +1,35 @@
1
+ {
2
+ "mc_gross":"9.00",
3
+ "invoice":"1234",
4
+ "protection_eligibility":"Ineligible",
5
+ "payer_id":"6KAQNBYBZ6KAC",
6
+ "tax":"0.00",
7
+ "payment_date":"20:37:01 Jul 04, 2011 PDT",
8
+ "payment_status":"Completed",
9
+ "charset":"windows-1252",
10
+ "first_name":"Test",
11
+ "mc_fee":"0.56",
12
+ "notify_version":"3.1",
13
+ "custom":"1234",
14
+ "payer_status":"verified",
15
+ "quantity":"1",
16
+ "verify_sign":"AZP9aUnslyCXgo2.9xWwtk8th8HXAnLqF6TgvmD3ME7fM.iCQhnQ0iRS",
17
+ "payer_email":"buyer_1309779460_per@simplesideias.com.br",
18
+ "txn_id":"8JD75017U43409907",
19
+ "payment_type":"instant",
20
+ "last_name":"User",
21
+ "receiver_email":"seller_1308793919_biz_api1.simplesideias.com.br",
22
+ "payment_fee":"0.56",
23
+ "receiver_id":"GSZCRUB62BL5L",
24
+ "txn_type":"express_checkout",
25
+ "item_name":"Awesome - Monthly Subscription",
26
+ "mc_currency":"USD",
27
+ "item_number":"",
28
+ "residence_country":"US",
29
+ "test_ipn":"1",
30
+ "handling_amount":"0.00",
31
+ "transaction_subject":"",
32
+ "payment_gross":"9.00",
33
+ "shipping":"0.00",
34
+ "ipn_track_id":"sAEWZiSm95ZxQfYHq-RE8w"
35
+ }
@@ -0,0 +1,44 @@
1
+ {
2
+ "mc_gross":"9.00",
3
+ "period_type":" Regular",
4
+ "outstanding_balance":"0.00",
5
+ "next_payment_date":"03:00:00 Jul 06, 2011 PDT",
6
+ "protection_eligibility":"Ineligible",
7
+ "payment_cycle":"Daily",
8
+ "tax":"0.00",
9
+ "payer_id":"6KAQNBYBZ6KAC",
10
+ "payment_date":"03:06:59 Jul 05, 2011 PDT",
11
+ "payment_status":"Completed",
12
+ "product_name":"Awesome - Monthly Subscription",
13
+ "charset":"windows-1252",
14
+ "rp_invoice_id":"1234",
15
+ "recurring_payment_id":"I-E9EJKE50EPPY",
16
+ "first_name":"Test",
17
+ "mc_fee":"0.56",
18
+ "notify_version":"3.1",
19
+ "amount_per_cycle":"9.00",
20
+ "payer_status":"verified",
21
+ "currency_code":"USD",
22
+ "business":"seller_1308793919_biz_api1.simplesideias.com.br",
23
+ "verify_sign":"A31F-vcNTWfrBDr18m0ZsQO28jDTAvPYHS7RmO4dZDD-ObUm6mgY-vS1",
24
+ "payer_email":"buyer_1309779460_per@simplesideias.com.br",
25
+ "initial_payment_amount":"0.00",
26
+ "profile_status":"Active",
27
+ "amount":"9.00",
28
+ "txn_id":"8UT11014H0627171P",
29
+ "payment_type":"instant",
30
+ "last_name":"User",
31
+ "receiver_email":"seller_1308793919_biz_api1.simplesideias.com.br",
32
+ "payment_fee":"0.56",
33
+ "receiver_id":"GSZCRUB62BL5L",
34
+ "txn_type":"recurring_payment",
35
+ "mc_currency":"USD",
36
+ "residence_country":"US",
37
+ "test_ipn":"1",
38
+ "transaction_subject":"",
39
+ "payment_gross":"9.00",
40
+ "shipping":"0.00",
41
+ "product_type":"1",
42
+ "time_created":"20:37:06 Jul 04, 2011 PDT",
43
+ "ipn_track_id":"ZuDCTZrTVSGEOmiIJmdZ8Q"
44
+ }
@@ -0,0 +1,31 @@
1
+ {
2
+ "payment_cycle":"Daily",
3
+ "txn_type":"recurring_payment_profile_created",
4
+ "last_name":"User",
5
+ "next_payment_date":"03:00:00 Jul 05, 2011 PDT",
6
+ "residence_country":"US",
7
+ "initial_payment_amount":"0.00",
8
+ "rp_invoice_id":"1234",
9
+ "currency_code":"USD",
10
+ "time_created":"20:37:06 Jul 04, 2011 PDT",
11
+ "verify_sign":"AKAZgvqH1r0IxFcG2KYlwYC.bd7rAhHiMcfsQu1D8ouxLCbt2THiAy6E",
12
+ "period_type":" Regular",
13
+ "payer_status":"verified",
14
+ "test_ipn":"1",
15
+ "tax":"0.00",
16
+ "payer_email":"buyer_1309779460_per@simplesideias.com.br",
17
+ "first_name":"Test",
18
+ "receiver_email":"seller_1308793919_biz_api1.simplesideias.com.br",
19
+ "payer_id":"6KAQNBYBZ6KAC",
20
+ "product_type":"1",
21
+ "shipping":"0.00",
22
+ "amount_per_cycle":"9.00",
23
+ "profile_status":"Active",
24
+ "charset":"windows-1252",
25
+ "notify_version":"3.1",
26
+ "amount":"9.00",
27
+ "outstanding_balance":"0.00",
28
+ "recurring_payment_id":"I-E9EJKE50EPPY",
29
+ "product_name":"Awesome - Monthly Subscription",
30
+ "ipn_track_id":"aWXcwC-7TDo7InmzVuuRrQ"
31
+ }