Pots
Overview
Pots are created within the account, and enable allocation of funds away from the main balance. They can be used to serve a variety of purposes, ranging from a sales and marketing budget, to a personal allowance, to office supply expenses.
Pots are ideal for keeping balances separately, and ensuring the right amount of funds are allocated as of when they are needed.
How to create Pots
The steps below demonstrate how to create a USD pot for a made up Marketing budget:
- Call the
POST - Create Pot Balance
endpoint. - In the path parameter
ccy
, assign the currency for the pot. This is a three letter currency code such as 'USD'. - Next, enter the
potPrefix
value to name the pot. Alphanumeric strings are allowed but they must not exceed 5 characters. - In the request body, a
FriendlyName
can be added to describe the pot being created. - In this instance, we are creating a pot and calling it "POT11-USD" with USD as the currency balance, and "Marketing Budget" as the description for the pot, thereby assigning the
CcyCode
,BaseCcyCode
andFriendlyName
values respectively.
REQUEST
curl --location 'https://caxapi-integration.azurewebsites.net/api/account/balances/balance/USD/POT11-USD' \
--header 'Content-Type: application/json' \
--header 'authorization: Bearer <access_token>' \
--header 'userapitoken: <userapitoken>' \
--data '{
"FriendlyName": "MarketingBudget"
}'
RESPONSE
A successful response is highlighted below:
{
"Content": {
"Model": {
"Balances": [
{
"Balance": 0.00,
"CcyCode": "POT11-USD",
"BaseCcyCode": "USD",
"FriendlyName": "Marketing_Budget",
"AlphabeticCode": "USD",
"Description": "US Dollar",
"NumericCode": "840",
"Symbol": "$",
"ApiStatusCode": 100,
"ApiStatus": "IsValid",
"ApiStatusDescription": "Valid Operation"
Retrieve Pot balances
There are two options to search for Pot balances:
Updated 11 months ago