Skip to main content
POST
/
prompts
Create Prompt
curl --request POST \
  --url https://api.example.com/prompts/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "<string>",
  "content": "<string>",
  "category_name": "<string>",
  "tags": [
    "<string>"
  ],
  "prompt_type": "user"
}
'
{
  "id": "<string>",
  "email": "<string>",
  "prompt_type": "<string>",
  "title": "<string>",
  "content": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "category_name": "<string>",
  "icon": "<string>",
  "tags": [
    "<string>"
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Request model for creating a new prompt.

title
string
required

Prompt title

Required string length: 1 - 200
content
string
required

Prompt content

Required string length: 1 - 50000
category_name
string | null

Category name

Maximum string length: 100
tags
string[] | null

List of tags for display

prompt_type
string
default:user

Prompt type: 'user' or 'system'

Response

Successful Response

Response model for a single prompt.

id
string
required
email
string
required
prompt_type
string
required
title
string
required
content
string
required
created_at
string<date-time>
required
updated_at
string<date-time>
required
category_name
string | null
icon
string | null
tags
string[] | null