Test Invoices

You can use the PayPal sandbox to complete an end-to-end test of your invoicing integration, including creating, sending, managing, and paying invoices. For details, see the PayPal Sandbox Testing Guide.

To create test accounts in the sandbox, see create sandbox accounts.

1. Manage invoices

To practice creating, sending, and managing invoices, use the PayPal website or the PayPal Invoicing API.

Web UI

To test managing invoices through the PayPal website:

  1. Log in to the merchant sandbox account on sandbox.paypal.com/invoice/.
  2. Send an invoice to the customer sandbox account. To send a link to the invoice in your own email, use the share link feature when you create the invoice.

    Note: This action also appears on the invoice management page.

  3. Log in to the customer sandbox account on sandbox.paypal.com.
  4. On either the home page or activity page, view the invoice to see how it appears to the customer.

Invoicing API

To test managing invoices through the PayPal Invoicing REST API:

  1. Log into the Developer Dashboard with your PayPal account credentials.
  2. On My Apps & Credentials, toggle to the Sandbox tab, navigate to the REST API apps section, and select the sandbox app you use for testing.

    Note: If you don't have an existing sandbox app to test with, create one.

  3. Use the API credentials for your test account to make calls to the Invoicing REST API to create, send, and manage invoices in the sandbox.

For more information about using REST APIs refer to Get Started.

2. View invoice emails

After the merchant sends an invoice, an email appears in both the merchant account and recipient account. Emails can take a few minutes to appear.

In the merchant sandbox account:

  1. Log in to the merchant sandbox account on sandbox.paypal.com/invoice/.

  2. Send an invoice to the customer sandbox account.

  3. In the search box, enter a partial or full invoice number or email and tap the Enter key.

    You can also click Advanced Search and enter one or more filters:

    • Email
    • Recipient name
    • Business name
    • Invoice number
    • Reference
    • Status
    • Amount
    • Currency
    • Memo
    • Creation, invoice, due, or payment date range

    For example, to find an invoice with an ID containing 567 that was generated during the first half of May, select Invoice Number and enter 567. Then, select Create Date and enter a start date of May 1 and an end date of May 15.

In the customer sandbox account:

  1. Log in to the customer sandbox account on sandbox.paypal.com.

  2. Under Selling tools, click the Manage invoices link.

  3. In the search box, enter a partial or full invoice number or email and tap the Enter key.

    You can also click Advanced Search and enter an email, recipient name, business name, invoice number, reference, status, amount, currency, or memo, and a creation, invoice, due, or payment date range.

    For example, select invoice number and enter a partial invoice number and select creation date and enter the start and end date of the range.

3. Pay invoices

To pay an invoice:

  1. In the customer email about the invoice, click View and Pay Invoice.
  2. Click Pay.
  3. Log in to the customer sandbox account on sandbox.paypal.com.
  4. Pay with the funding source in that account.

Note: You can also access the payer’s view of the invoice through either:

  • The share link action within the web experience.
  • The response when you create or show details for an invoice.

Next