---
title: "Compact Job Create Endpoint"
method: POST
path: "/v1/compact/jobs"
---

# Compact Job Create Endpoint

`POST /v1/compact/jobs`

## Request body

- CapsuleRequest
  - `lines` LineRecord[], required
    - `line_id` integer, required
    - `message` string, required
    - `level` string, nullable
    - `timestamp` string, nullable
    - `service` string, nullable
  - `metadata` object, nullable
  - `engine` 'auto' | 'inference' | 'deterministic', nullable

## Response `200`

Successful Response

- CompactJobCreateResponse
  - `job_id` string, required
  - `status` string, required
  - `poll_url` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/codag/apis/infra-logs-templater.md) · [All operations](https://skmtc.net/codag/apis/infra-logs-templater/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/codag/infra-logs-templater/revisions/e43028aaffe3/schema)
