POST
/
v1
/
runs
/
ingest
curl --request POST \
  --url https://api.lunary.ai/v1/runs/ingest \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "events": [
    {
      "type": "llm",
      "event": "start",
      "runId": "some-unique-id",
      "name": "gpt-4",
      "timestamp": "2022-01-01T00:00:00Z",
      "input": [
        {
          "role": "user",
          "content": "Hello world!"
        }
      ],
      "tags": [
        "tag1"
      ],
      "extra": {
        "temperature": 0.5,
        "max_tokens": 100
      }
    }
  ]
}'
{
  "results": [
    {
      "id": "some-unique-id",
      "success": true
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Body

application/json
events

Represents an event in the Lunary API for tracking LLM calls and related operations.

Example:
{
  "type": "llm",
  "event": "start",
  "runId": "some-unique-id",
  "name": "gpt-4",
  "timestamp": "2022-01-01T00:00:00Z",
  "input": [
    { "role": "user", "content": "Hello world!" }
  ],
  "tags": ["tag1"],
  "extra": { "temperature": 0.5, "max_tokens": 100 }
}

Response

200
application/json
Successful ingestion

The response from the ingestion API.

results
object[]