API Commands

You can use commands to modfiy how the PAI requests function.

For example, you can add commmands to the first lines of your request body:
{
  "commands": {
    "executeTransaction": false,
    "calculateTaxExclusive": true,
    "calculateCustomDuties": true,
    "useShipping": "shippo",
    "getShippingRates": true
  },

These commands modify how the request is run. For example, you can use a command to distinguish between a quote and a final or full transaction. You can also use it to signal that an amount is tax inclusive or exclusive and to modify how shipping is calculated.

The following table lists the commands and associated request:

Table 1. Commands and Requests
Command Requests Use
executeTransaction Process transaction If you set this to true, the transaction will be processed (and your ePAL credits will be charged). If you set this to false, no transaction is create and there is no charge to your ePAL credits.
calculateTaxExclusive Process transaction If you set this to true, ePAL will assumes that the prices sent to it do not include tax. Tax is calculated based on this assumption.
calculateTaxInclusive Process transaction If you set this command to true. ePAL will assume that the prices sent to it include tax. ePAL will remove this before calculating tax.
calculateCustomDuties Process transaction If set to true, ePAL will calculate customs duties.
deniedParties Process transaction If set to true, ePAL will check for denied parties.
useShipping Process transaction To use Shippo for shipping rates, set to Shippo.
getShippingRates Process transaction If set to true, real-time carrier rates are returned from Shippo.