Skip to main content
GET
/
prompts
/
{slug}
Get a prompt by its slug
curl --request GET \
  --url https://api.getbasalt.ai/prompts/{slug} \
  --header 'Authorization: Bearer <token>'
{
  "warning": "<string>",
  "prompt": {
    "text": "Hello, how are you?",
    "systemText": "You are a helpful assistant",
    "version": "1.0.0",
    "model": {
      "provider": "open-ai",
      "client": "open-ai",
      "model": "gpt-4o",
      "version": "latest",
      "parameters": {
        "maxLength": 100,
        "temperature": 0.5,
        "topP": 0.5,
        "responseFormat": "json_object"
      }
    }
  }
}

Authorizations

Authorization
string
header
required

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

Path Parameters

slug
string
required

The slug of the prompt to get

Example:

"my-slug"

Query Parameters

version
string

The version to filter prompts by

Example:

"1.0.0"

tag
string

The tag to filter prompts by

Example:

"latest"

Response

The prompt with all its parameters

prompt
object
required

The prompt

Example:
{
"text": "Hello, how are you?",
"systemText": "You are a helpful assistant",
"version": "1.0.0",
"model": {
"provider": "open-ai",
"client": "open-ai",
"model": "gpt-4o",
"version": "latest",
"parameters": {
"maxLength": 100,
"temperature": 0.5,
"topP": 0.5,
"responseFormat": "json_object"
}
}
}
warning
string

A warning message

I