---
title: "Ingest log entries"
method: POST
path: "/v1/logs"
tags: ["Logs"]
---

# Ingest log entries

`POST /v1/logs`

## Request

- Base URL: `http://localhost:9998`
- URL: `http://localhost:9998/v1/logs`
- Auth: none required

Accepts a single log entry object or an array of entries on the
same path. Unauthenticated.

## Request body

- union
  - LogEntry
    - `source` string: Originating app or component
    - `level` 'error' | 'warn' | 'info' | 'debug'
    - `event` string: Event type (e.g. "http.request", "engine.load")
    - `data` object: Arbitrary event payload
    - `timestamp` string, date-time
  - LogEntry[]
    - `source` string: Originating app or component
    - `level` 'error' | 'warn' | 'info' | 'debug'
    - `event` string: Event type (e.g. "http.request", "engine.load")
    - `data` object: Arbitrary event payload
    - `timestamp` string, date-time

## Response `200`

Batch ingested

- object
  - `ok` true, required
  - `count` integer, required

---

[API](https://skmtc.dev/modelpiper/apis/toolpiper-api.md) · [All operations](https://skmtc.dev/modelpiper/apis/toolpiper-api/llms.txt) · [OpenAPI document](https://skmtc.dev/modelpiper/apis/toolpiper-api/revisions/6722bf56385c?raw)
