- Billing entities for regional tax requirements.
- Customers for customer-specific tax rates.
- Pricing plans and their components (base fees, usage charges, minimum commitments).
- Subscriptions through plan overrides.
1. Understand tax configuration
Before you create a tax, decide on these configuration details based on your business requirements and regional regulations. Then, you can make a POST call to the Create tax endpoint to send the information to PayPal. It is your responsibility to ensure the accuracy of the tax calculation and to remit such taxes to the appropriate tax authorities. Basic identification- Name: Set a descriptive name that identifies the tax.
- Code: Create a unique identifier to reference the tax in API calls.
- Description: Add a detailed description for the tax configuration.
2. Create tax
Use a valid access token and make a POST call to the/v1/commerce/billing/taxes endpoint with tax details. On successful tax creation, the PayPal server returns the created tax object with a unique identifier.
Request body parameters
| Parameter name | Description |
|---|---|
nameRequired, string | Name of the tax. |
codeRequired, string | Unique identifier to reference the tax in API calls. |
rateRequired, string | Percentage rate that the system applies to transactions. A decimal amount from 0.01 to 100.00, with exactly two decimal places. Example: 20.00. |
descriptionstring | Detailed description of the tax. |
Response parameters
This section documents only the response parameters relevant for the next step. For the exhaustive list of response parameters, see API reference.
| Parameter name | Description and further action |
|---|---|
codestring | Unique code for the tax configuration. Use this code in future operations, such as when applying taxes to billing entities, customers, pricing plans, or subscriptions. |
3. Apply taxes
After creating your tax configurations, you can apply them throughout your billing system:| Action | How to apply taxes |
|---|---|
| Apply to billing entities | After creating billing entities, update them to include tax_codes with the tax codes that apply to that entity. |
| Apply to customers | When registering customers, include tax_codes in your request body with the tax codes that apply to that customer. |
| Apply to pricing plans | When creating pricing plans: • Include tax_codes at the plan level for taxes on the base fee• Use usage_based_charges[].tax_codes for taxes on specific usage charges• Use minimum_commitment.tax_codes for taxes on minimum commitments |
| Apply to subscriptions | When creating subscriptions, use the plan_overrides object to customize tax codes:• plan_overrides.tax_codes for plan-level taxes• plan_overrides.charges[].tax_codes for charge-specific taxes• plan_overrides.minimum_commitment.tax_codes for minimum commitment taxes |
| Manage existing taxes | Use the tax management APIs to list all configured taxes, retrieve specific tax details, and update tax rates or descriptions as regulatory requirements change. For more information, see Manage taxes. |