Skip to content

Usage

API Documentation for POST /calculations

Description

The POST /calculations endpoint accepts transaction data with program supplier and participant information to determine potential earnings based on program configuration rules.

Required Headers

  • x-api-key - API access key for authentication
  • participant-key - Unique identifier for the participant

Query Params

  • program_supplier_key (Required) - The key of the program supplier.
  • time_frame (Required) - The time frame for which the calculations are requested.

CURL Request Example

curl --location POST 'https://dev.calc.ag/calculations?program_supplier_key=corteva&time_frame=2024' \
  --header 'participant-key: agtegra' \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: your-api-key' \
  --data @calculations/request.json