Skip to main content
POST
/
api
/
v1
/
usage
/
billable_metrics
/
create
Billable Metric Create Api
curl --request POST \
  --url https://api.justpaid.io/api/v1/usage/billable_metrics/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "<string>",
  "description": "<string>",
  "event_name": "<string>",
  "aggregation_type": 0
}'
{
  "uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "created_at": "2023-11-07T05:31:56Z",
  "name": "<string>",
  "description": "<string>",
  "event_name": "<string>",
  "aggregation_type": 0
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required
Maximum length: 255
description
string | null
event_name
string | null
Maximum length: 255
aggregation_type
integer
default:0

Response

200 - application/json

OK

name
string
required
Maximum length: 255
uuid
string<uuid>
created_at
string<date-time>
description
string | null
event_name
string | null
Maximum length: 255
aggregation_type
integer
default:0