---
title: "Asks the build agent to build something"
method: POST
path: "/builds/"
tags: ["Builds"]
---

# Asks the build agent to build something

`POST /builds/`

## Request

- Base URL: `https://genhttp.dev/api/v1`
- URL: `https://genhttp.dev/api/v1/builds/`
- Auth: none declared

The build is queued and runs in the background; `GET /builds/{id}` follows it. The prompt is logged in full, so the
operator knows what people ask for - put nothing into it that should not be read. It is cut past 2000 characters.

## Request body

- BuildRequest: What should be built.
  - `Prompt` string, nullable: What to build, in the words of whoever wants it, in any language - at least three characters, cut past 2000
  - `Model` string, nullable: Which of the offered models builds it: left out or `opus` for the default one, `fable` for the second, where one is offered
  - `Password` string, nullable: The password for the second model

## Response `202`

The build was taken on. Follow it by its `id`.

- BuildStarted: A build the agent has taken on.
  - `Id` string: What to follow it by: `GET /builds/{id}`
  - `Queued` integer: How many builds are waiting ahead of it

## Other responses

- `400`: The prompt says too little, or there is no such model.
- `403`: The password for the second model is not right.
- `404`: This installation builds nothing: it has no agent, or the operator switched building off.
- `429`: This address asked for as many builds today as one may.
- `503`: The agent is not answering. Nothing was counted.

---

[API](https://skmtc.dev/genhttp/apis/genhttp-lambda-api.md) · [All operations](https://skmtc.dev/genhttp/apis/genhttp-lambda-api/llms.txt) · [OpenAPI document](https://skmtc.dev/genhttp/apis/genhttp-lambda-api/revisions/8b36699e03df?raw)
