---
title: "Create a prompt"
method: POST
path: "/api/prompts/"
tags: ["prompts"]
---

# Create a prompt

`POST /api/prompts/`

Create a new prompt template.

## Headers

- `Authorization` string, required

## Request body

- object
  - `name` string, required — Prompt name.
  - `description` string — Prompt description.

## Response `201`

Prompt created successfully.

- PromptsCreatePromptResponse201
  - `id` string — The unique prompt identifier.
  - `name` string
  - `description` string, nullable
  - `prompt_slug` string, nullable
  - `tags` ApiPromptsPostResponsesContentApplicationJsonSchemaTagsItems[]
    - `id` string
    - `name` string
    - `color` string
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `current_version` ApiPromptsPostResponsesContentApplicationJsonSchemaCurrentVersion
    - `version` integer
    - `model` string
    - `updated_at` string, date-time
  - `live_version` ApiPromptsPostResponsesContentApplicationJsonSchemaLiveVersion
    - `version` integer
    - `model` string
    - `updated_at` string, date-time
  - `created_at` string, date-time
  - `updated_at` string, date-time

## Other responses

- `400` — Bad Request
- `401` — Unauthorized - Missing/invalid authentication

---

[API](https://skmtc.net/keywordsai/apis/api-reference.md) · [All operations](https://skmtc.net/keywordsai/apis/api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/keywordsai/api-reference/revisions/4e064cf81dae/schema)
