Skip to main content
GET
/
template
List templates and folders
curl --request GET \
  --url https://api.promptmetrics.dev/template \
  --header 'Authorization: Bearer <token>'
{
  "folders": [
    {
      "_id": "<string>",
      "workspace_id": "<string>",
      "parent_id": "<string>",
      "name": "<string>",
      "description": "<string>",
      "is_folder": true,
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "prompts": [
    {
      "_id": "<string>",
      "workspace_id": "<string>",
      "parent_id": "<string>",
      "name": "<string>",
      "description": "<string>",
      "is_folder": true,
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Query Parameters

workspace_id
string
required
parent_id
string | null
sort_by
enum<string>
Available options:
name,
updated_at
sort_order
enum<string>
Available options:
asc,
desc

Response

200 - application/json

List of templates and folders

folders
object[]
prompts
object[]