Pass in a APIContext
object to authenticate
the call and to send a unique request id
(that ensures idempotency). The SDK generates
a request id if you do not pass one explicitly.
See Configuration.cs to know more about APIContext.
A Payment Resource; create one with its intent set to sale
, authorize
, or order
A resource representing a Payer that funds a payment. Use the List of FundingInstrument
and the Payment Method as 'credit_card'
The Payment creation API requires a list of
FundingInstrument; add the created FundingInstrument
to a List
A resource representing a Payeer's funding instrument.
Use a Payer ID (A unique identifier of the payer generated
and provided by the facilitator. This is required when
creating or using a tokenized funding instrument)
and the CreditCardDetails
A resource representing a credit card that can be used to fund a payment.
The Payment creation API requires a list of transactions; add the created Transaction
to a List
A transaction defines the contract of a payment - what is the payment for and who is fulfilling it. Transaction is created with a Payee
and Amount
types
Let's you specify a payment amount.
Total must be equal to sum of shipping, tax and subtotal.
Create a payment by posting to the APIService using a valid APIContext
Once the payment with intent set to authorize
has been created, retrieve its authorization object.
Void the authorization
For more information, please visit PayPal Developer REST API Reference.
AuthorizationVoid Sample
The sample code demonstrates how to void an authorized payment. API used: POST /v1/payments/authorization/{authorization_id}/void