CarbonAPI Documentation
API ReferenceExpense Categorisation

Submit a new batch of transactions for processing

POST
/transaction/batch
x-api-key<token>

In: header

Scope: api_key

transactionsarray<TransactionDTO>

The transactions to create a batch with

countryCodestring

The 3-letter ISO country code of the transactions, for example NZL

Value in"AUS" | "NZL" | "AUT" | "BEL" | "BGR" | "BRA" | "CAN" | "CHE" | "CHN" | "CYP" | "CZE" | "DEU" | "DNK" | "ESP" | "EST" | "FIN" | "FRA" | "GBR" | "GRC" | "HRV" | "HUN" | "IDN" | "IND" | "IRL" | "ITA" | "JPN" | "KOR" | "LTU" | "LUX" | "LVA" | "MEX" | "MLT" | "NLD" | "NOR" | "POL" | "PRT" | "ROU" | "RUS" | "SVK" | "SVN" | "SWE" | "TUR" | "TWN" | "USA" | "ZAF" | "AFG" | "AGO" | "ALB" | "ARE" | "ARG" | "ARM" | "AZE" | "BDI" | "BEN" | "BFA" | "BGD" | "BHR" | "BHS" | "BIH" | "BLR" | "BLZ" | "BOL" | "BRN" | "BTN" | "BWA" | "CAF" | "CHL" | "CIV" | "CMR" | "COD" | "COG" | "COL" | "CRI" | "CUB" | "DJI" | "DYE" | "DOM" | "DZA" | "ECU" | "EGY" | "ERI" | "ETH" | "GAB" | "GEO" | "GHA" | "GIN" | "GMB" | "GNQ" | "GTM" | "HND" | "HKG" | "HTI" | "IRN" | "IRQ" | "ISL" | "ISR" | "JAM" | "JOR" | "KAZ" | "KEN" | "KGZ" | "KHM" | "KWT" | "LAO" | "LBN" | "LBR" | "LBY" | "LKA" | "MAR" | "MDA" | "MDG" | "MKD" | "MLI" | "MMR" | "MNG" | "MOZ" | "MRT" | "MWI" | "MYS" | "NAM" | "NER" | "NGA" | "NIC" | "NPL" | "OMN" | "PAK" | "PSE" | "PAN" | "PER" | "PHL" | "PNG" | "PRY" | "QAT" | "RWA" | "SAU" | "SDS" | "SEN" | "SGP" | "SLE" | "SLV" | "SOM" | "SRB" | "SDN" | "SYR" | "TCD" | "TGO" | "THA" | "TJK" | "TKM" | "TUN" | "TZA" | "UGA" | "UKR" | "URY" | "UZB" | "VEN" | "VNM" | "YEM" | "ZMB" | "ZWE"
factorClass?string

The type of factors to use

Value in"commodity"
supplierFactorPolicy?string

Whether to require, prefer, or ignore supplier factors

Value in"REQUIRE_SUPPLIER_FACTOR" | "PREFER_SUPPLIER_FACTOR" | "IGNORE_SUPPLIER_FACTOR"
supplierFactorAssurancePolicy?string

Whether to require reasonable, require limited, or no assurance for supplier factors

Value in"REQUIRE_REASONABLE_ASSURANCE" | "REQUIRE_LIMITED_ASSURANCE" | "NO_ASSURANCE_PREFERENCE"

Response Body

curl -X POST "https://api.aws-au.carbonapi.io/transaction/batch" \  -H "Content-Type: application/json" \  -d '{    "transactions": [      {        "id": "11111111-1111-1111-1111-111111111111",        "date": "2021-01-01T00:00:00.000Z",        "subtotal": 100,        "tax": 10,        "total": 110,        "description": "Purchase of goods",        "supplierName": "Air New Zealand",        "sourceAccount": "Travel - International",        "currency": "NZD"      }    ],    "countryCode": "NZL"  }'
{
  "batchIds": [
    "string"
  ]
}