Skip to main content
POST
/
metrics
Create metric
curl --request POST \
  --url https://api.example.com/metrics \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "project_id": "<string>",
  "description": "<string>",
  "collection_config": {},
  "sampling_rate": 123,
  "monitor_config": {},
  "agent_name": "<string>"
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.uselemma.ai/llms.txt

Use this file to discover all available pages before exploring further.

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
type
enum<string>
required
Available options:
SYNTHETIC,
OBSERVED
project_id
string
required
description
string | null
collection_type
enum<string> | null
Available options:
BINARY,
VALUE,
FLAG,
null
collection_config
object
sampling_rate
number | null
monitor_config
object
agent_name
string | null

Response

201 - application/json

Metric created