Fees and discounts

Calculate the fee on an amount

Works out the processing fee for an amount under the merchant's pricing model and returns the total the customer would be charged. Use it when fees are passed on to the customer, so your checkout can show the fee as its own line and the grand total before the payment is created.

get/v2/payment-fees/calculate

Request

  • Base URL: https://test-api.kashier.io
  • URL: https://test-api.kashier.io/v2/payment-fees/calculate
  • Auth: API key in header Authorization

Query parameters

amountstring required

The transaction amount to calculate the fee on. Example: 100.00

interactionSource'POS' | 'ECOMMERCE' required

Where the payment is being taken, since fees differ by channel.

apiVersionstring

API version to calculate against.

Response

The amount, the fee on it, and the total to charge.

amountnumber

The amount the fee was calculated on.

feesnumber

The processing fee for that amount.

totalAmountnumber

What the customer is charged — the amount plus the fee.

currencystring

Currency of the amounts, for example EGP.

interactionSourcestring

The channel the fee was calculated for.

Changes

No recorded changes to this operation across all 1 revision of this API.