---
title: "Create Agent Generation"
method: POST
path: "/v1/agents/generations"
tags: ["Agents"]
---

# Create Agent Generation

`POST /v1/agents/generations`

Create Agent Generation

## Cookies

- `token` string, nullable

## Request body

- union
  - CreateAgentGenerationRequest
    - `input_schema` object
    - `metadata` CreateAgentMetadata
      - `description` string, nullable
      - `display_name` string, nullable
      - `tags` string[]
    - `name` string, nullable
    - `output_schema` object
    - `prompt` string, required
    - `url` string, required
  - CreateAgentRefinementRequest
    - `from_agent` string, required
    - `prompt` string, required

## Response `201`

Successful Response

- AgentGenerationResponse
  - `agent_name` string, nullable
  - `completed_at` string, date-time, nullable
  - `created_at` string, date-time, nullable
  - `error` string, nullable
  - `generated_version` AgentVersionResponse
    - `agent_name` string, required
    - `created_at` string, date-time, required
    - `id` string, uuid, required
    - `input_schema` object, required
    - `metadata` AgentVersionMetadataPublic, required
      - `data_source` string, nullable
      - `description` string, nullable
      - `display_name` string, nullable
      - `domain` string, nullable
      - `entity_type` string, nullable
      - `tags` string[]
      - `vertical` string, nullable
    - `output_schema` object, required
    - `samples` Sample[], nullable
      - `input` unknown
      - `output` unknown
    - `version_number` integer, required
  - `generated_version_id` string, uuid, nullable
  - `id` string, uuid, required
  - `source_version_id` string, uuid, nullable
  - `started_at` string, date-time, nullable
  - `status` string, required
  - `summary` string, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-07-07** `ebe52c375b71` — 1 warning, 1 info
  - removed the request property `anyOf[subschema #1: CreateAgentGenerationRequest]/agent_name`
  - added the new optional request property `anyOf[subschema #1: CreateAgentGenerationRequest]/name`
- **2026-06-10** `421a9851d61b` — 3 breaking, 2 warning, 1 info
  - the `anyOf[subschema #1: CreateAgentGenerationRequest]/agent_name/anyOf[subschema #1]/` request property's minLength was increased from `0` to `1`
  - added the pattern `^[a-z0-9_]+$` to the request property `anyOf[subschema #1: CreateAgentGenerationRequest]/agent_name/anyOf[subschema #1]/`
  - removed the required property `generated_version/anyOf[subschema #1: AgentVersionResponse]/steps` from the response with the `201` status
  - the `anyOf[subschema #1: CreateAgentGenerationRequest]/agent_name/anyOf[subschema #1]/` request property's maxLength was set to `255`
  - …2 more
- …earlier changes not shown

[Full history](https://skmtc.dev/nimbleway/apis/api-gateway/changes/v1/agents/generations/post.md)

---

[API](https://skmtc.dev/nimbleway/apis/api-gateway.md) · [All operations](https://skmtc.dev/nimbleway/apis/api-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/nimbleway/apis/api-gateway/revisions/ebe52c375b71?raw)
