Authorize a payment and capture funds later
Last updated: Apr 10th, 9:14pm
The PayPal Checkout integration supports a 2-step authorize and capture payment model.
Authorize a buyer's funds before you capture them, then settle the purchase later. An authorization places a hold on the funds and is valid for 29 days. For example, use authorize and capture to complete a task before finalizing the payment, such as verifying that you have the item in stock.
How it works
- The payer checks out and provides a payment method.
- You authorize the payment.
- A hold is placed on the payment method until you are ready to capture payment.
- You finalize the transaction and capture the payment.
- The payer's payment method is charged.
Partner requirements
- You must be an approved partner to use this integration.
- You must complete seller onboarding before you use this integration.
- You must have an access token.
- This integration is a PCI Compliant - SAQ A solution for accepting credit card payments directly on your website.
Know before you code
PayPal Checkout
Complete the steps in Get started to get your sandbox account login information and access token from the Developer Dashboard.
This feature modifies an existing PayPal Checkout integration and uses the following:
- JavaScript SDK: Adds PayPal-supported payment methods.
- Orders REST API: Create, update, retrieve, authorize, and capture orders.
You need a developer account to get sandbox credentials
PayPal uses the following REST API credentials, which you can get from the developer dashboard:
- Client ID: Authenticates your account with PayPal and identifies an app in your sandbox.
- Client secret: Authorizes an app in your sandbox. Keep this secret safe and don't share it.
Explore PayPal APIs with Postman
You can use Postman to explore and test PayPal APIs. Learn more in our Postman guide.
Create order
Before you authorize funds, you must create an order with the intent
field set to AUTHORIZE
.
Use the purchase_units/payee
object to specify the end receiver of the funds.