On this page
No Headings
Last updated: June 26, 2026
Use a sandbox account to test purchases before going live in your live account. For example, when you initiate a purchase through a sandbox account, PayPal creates a test purchase that simulates a purchase in the live environment.
Note: Fill out this form to be an approved partner. You need to be an approved partner to go live. Calls to the PayPal Complete Payments Platform APIs without approval will return a 401 Unauthorized HTTP status code. You can call and test the PayPal Complete Payments Platform APIs with your sandbox credentials before you are approved.
Log in to your developer dashboard to create your platform REST app. A sandbox account is generated after you create your app. You can use an existing PayPal account or create a new PayPal account specifically for this PayPal Complete Payments Platform integration. Use your personal sandbox account to simulate a buyer making a payment and use your business sandbox account to simulate a seller receiving payment.
From your developer dashboard, select Apps & Credentials.
Select Create App.
Under Type, select Platform. A sandbox account named Platform Partner App is automatically created with the recommended platform settings.
Note: For Embedded integration, select Merchant. This allows you to choose your API caller account during setup.
After the app is created, you can select which features you'd like to have enabled for testing under Sandbox App Settings. Some settings are automatically selected, but you can turn on other options for your use case.
Note: After retrieving your sandbox Client ID, share it with your PayPal account manager to configure your sandbox environment and enable testing.
Log in to your sandbox to test the result of API calls. To get an email ID and password for a sandbox account:
Use the live account when you are done testing on sandbox and want to go live with your integration. You must be an approved partner to go live. Fill out this form to be an approved partner and a PayPal representative will contact you for your approval. When you are ready to go live, you'll need to reach out to your representative and configure the live account together.
Note: After retrieving your live Client ID (from Apps & Credentials), share it with your PayPal account manager to configure your production environment and enable live transactions.
Your access token authorizes you to use the PayPal REST API server. To call a REST API in your integration, exchange your client ID and client secret for an access token. You can make the API call in any programming language.
The following sections explain how to get your access token using cURL or Postman.
Note: If you're using the platform fee feature, you'll need to pass the permissions scope as part of the Partner Referral API when your sellers onboard to avoid your sellers having to onboard again. Our team will also need to configure this feature on your account.
Copy the following code and modify it:
CLIENT_ID to your client ID.CLIENT_SECRET to your client secret.curl -v POST https://api-m.sandbox.paypal.com/v1/oauth2/token -u "CLIENT_ID:CLIENT_SECRET" -H "Content-Type: application/x-www-form-urlencoded" -d "grant_type=client_credentials"To import the cURL command above to Postman:
CLIENT_ID to your client ID.CLIENT_SECRET to your client secret.PayPal returns an access token and the number of seconds the access token is valid. When you make calls to a REST API, include the access token in the Authorization header with the designation as Bearer. Reuse the access token until it expires.
When your token expires, call the v1/oauth2/token method again to request a new token.
{
"scope": "https://uri.paypal.com/services/invoicing https://uri.paypal.com/services/disputes/read-buyer https://uri.paypal.com/services/payments/realtimepayment https://uri.paypal.com/services/disputes/update-seller https://uri.paypal.com/services/payments/payment/authcapture openid https://uri.paypal.com/services/disputes/read-seller https://uri.paypal.com/services/payments/refund https://api-m.paypal.com/v1/vault/credit-card https://api-m.paypal.com/v1/payments/.* https://uri.paypal.com/payments/payouts https://api-m.paypal.com/v1/vault/credit-card/.* https://uri.paypal.com/services/subscriptions https://uri.paypal.com/services/applications/webhooks",
"access_token": "A21AAFEpH4PsADK7qSS7pSRsgzfENtu-Q1ysgEDVDESseMHBYXVJYE8ovjj68elIDy8nF26AwPhfXTIeWAZHSLIsQkSYz9ifg",
"token_type": "Bearer",
"app_id": "APP-80W284485P519543T",
"expires_in": 31668,
"nonce": "2020-04-03T15:35:36ZaYZlGvEkV4yVSz8g6bAKFoGSEzuy3CQcz3ljhibkOHg"
}The following credentials are used in integrating and testing REST APIs. The steps are the same for both sandbox and live. Make sure to toggle to the right environment that you are working in.
Used to generate the access token required to make PayPal API calls in sandbox and live.
To find it:
Identifies the caller as a PayPal partner. To receive revenue attribution, specify a unique build notation (BN) code. BN codes provide tracking on all transactions that originate or are associated with a particular partner. Required for PayPal reporting. See PayPal-Partner-Attribution-Id for more information.
To find it:
The partner merchant ID, or payer ID, is the account ID assigned to every PayPal account. The account ID is a unique identifier and doesn't change over the life of the PayPal account. Partners and sellers need their own PayPal accounts, and every account has its own account ID.
To find it:
Add more payment methods
Choose your payment method.