curl --request POST \
  --url https://api.salesbricks.com/api/v2/usage \
  --header 'Content-Type: application/json' \
  --header 'X-SALESBRICKS-KEY: <api-key>' \
  --data '{
  "transaction_id": "12345",
  "subscription_id": "00000000-0000-0000-0000-000000000000",
  "brick_id": "00000000-0000-0000-0000-000000000000",
  "value": 1,
  "properties": {
    "source": "api",
    "notes": "This is a test entry",
    "region": "US"
  },
  "time": "2024-09-16T10:15:30Z"
}'
{
  "message": "Usage entry submitted successfully."
}

To use this endpoint, ensure that you are using the v2/usage API endpoint:

https://api.salesbricks.com/api/v2/usage

Authorizations

X-SALESBRICKS-KEY
string
header
required

Use your Salesbricks API key to authenticate requests.

Body

application/json

Response

201
application/json
Usage entry created successfully.

The response is of type object.