PayPal Adaptive Payments - 2012 Podręcznik Użytkownika Strona 102

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 298
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 101
Pay API Operation
Pay Examples Using NVP and CURL
102 August 7, 2012 Adaptive Payments Developer Guide
curl -s --insecure
-H "X-PAYPAL-SECURITY-USERID: api_username"
-H "X-PAYPAL-SECURITY-PASSWORD: api_password"
-H "X-PAYPAL-SECURITY-SIGNATURE: api_signature"
-H "X-PAYPAL-REQUEST-DATA-FORMAT: NV"
-H "X-PAYPAL-RESPONSE-DATA-FORMAT: NV"
-H "X-PAYPAL-APPLICATION-ID: app_id"
https://svcs.sandbox.paypal.com/AdaptivePayments/Pay -d
"actionType=PAY
&cancelUrl=http://your_cancel_url
&clientDetails.applicationId=fitnesse
&clientDetails.ipAddress=127.0.0.1
&currencyCode=USD
&feesPayer=EACHRECEIVER
&memo=Parallel-payment-example
&receiverList.receiver(0).amount=100.00
&receiverList.receiver(0).email=receiver1@domain
&receiverList.receiver(0).primary=true
&receiverList.receiver(1).amount=50.00
&receiverList.receiver(1).email=receiver2@domain
&receiverList.receiver(1).primary=false
&requestEnvelope.errorLanguage=en_US
&returnUrl=http://your_return_url
&senderEmail=sender@domain
Response:
responseEnvelope.timestamp=2009-07-13T12%3A34%3A29.316-07%3A00
&responseEnvelope.ack=Success
&responseEnvelope.correlationId=d615a365bed61
&responseEnvelope.build=DEV
&payKey=AP-7AF63289GN043650D
&paymentExecStatus=CREATED
Preapproved payment example
In this example, the sender has a valid preapproval agreement with you and makes a payment
of $100 to a PayPal-registered receiver and $50 to another PayPal-registered receiver. The
payment is completed without the sender logging in to paypal.com.
NOTE: The sample code below uses the insecure setting to work around the certificate for
testing in a sandbox environment. For actual implementations, you must specify the
location of the certificate.
Request:
Przeglądanie stron 101
1 2 ... 97 98 99 100 101 102 103 104 105 106 107 ... 297 298

Komentarze do niniejszej Instrukcji

Brak uwag