Fee models

Create fee model

Create fee model.

A fee model is a structure that defines a collection of fees with custom calculations. You can define the method used to calculate the fee, using a fixed value or a percentage. Fee models can be applied to organizations, programs, and accounts. For more information, see the Fee model guide.

An accumulator fee model requires you call the <a href="https://developers.pismo.io/pismo-docs/reference/post-v1-accumulator-config" target="_blank">Create accumulator configuration</a> endpoint first to define how transaction totals are kept.

Once the fee model is created, it needs to be <a href="https://developers.pismo.io/pismo-docs/reference/attachmentbyaccount">attached to an account</a>, <a href="https://developers.pismo.io/pismo-docs/reference/attachmentbyprogram">attached to a program</a> or <a href="https://developers.pismo.io/pismo-docs/reference/attachmentbytenant">attached to an org</a>.

post/v1/fee/models

Request

  • Base URL
    https://sandbox.pismolabs.io/rates
  • URL
    https://sandbox.pismolabs.io/rates/v1/fee/models
  • Auth
    HTTP bearer

Headers

Authorizationstring required

Access token, not an account-specific token. Tokens can expire quickly, which can result in an <b>401 Unauthorized</b> message

Request body

model_descriptionstring required

Model description.

Example request

{
  "model_description": "Fee model applied to org",
  "fees": [
    {
      "description": "Fee wdl",
      "id": "sellos_baires",
      "type": "sellos",
      "deduct_from_transaction_value": true,
      "calculation_basis": "PRINCIPAL_AMOUNT",
      "calculation": {
        "value": 2.5
      },
      "filters": {
        "processing_codes": [
          "02",
          "0040"
        ],
        "operation_types": [
          "authorization"
        ],
        "amount_range": {
          "minimum": 10,
          "maximum": 1000
        },
        "merchant_category": {
          "include": [
            "7995",
            "5411"
          ],
          "exclude": [
            "9999"
          ]
        }
      },
      "additional_fees": [
        {
          "description": "Foreign currency surchange.",
          "type": "sellos",
          "id": "sellos_baires",
          "calculation": {
            "value": 2.5
          }
        }
      ]
    }
  ]
}

Response

OK

model_idstring uuid

Pismo fee model ID

Example response

{
  "model_id": "d290f1ee-6c54-4b01-90e6-d701748f0851"
}

Changes

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