---
title: "Query Templates"
method: POST
path: "/agent-templates/query"
tags: ["Workflows"]
---

# Query Templates

`POST /agent-templates/query`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/agent-templates/query`
- Auth: API key in header `Authorization`

## Request body

- TemplatesQueryRequest
  - `search` string, nullable
  - `category` string, nullable
  - `author_id` string, nullable

## Response `200`

Successful Response

- TemplatesResponse
  - `count` integer, required
  - `templates` AgentTemplateEntry[], required
    - `key` string, required
    - `source` InternalTemplateSource, required
      - `kind` 'internal'
      - `key` string, required
    - `version` string, required
    - `latest` string, required
    - `versions` string[], required
    - `digest` string, required
    - `name` string, required
    - `summary` string, required
    - `description` string, required
    - `category` string, required
    - `tags` string[], required
    - `author` CatalogAuthor, required
      - `schema_version` 1, required
      - `id` string, required
      - `name` string, required
      - `bio` string, required
      - `avatar_url` string, nullable
      - `links` CatalogAuthorLink[]
        - `kind` string, required
        - `url` string, required
        - `label` string, nullable
    - `initials` string, required
    - `color` string, required
    - `instructions_summary` string, required
    - `trigger` string, required
    - `trigger_description` string, required
    - `seed_message` string, required
    - `builder_message` string, required
    - `model` string, required
    - `tools_summary` string, required
    - `connections` AgentTemplateConnection[], required
      - `key` string, required
      - `role` string, required
      - `required` boolean, required
      - `primary` AgentTemplateConnectionOption, required
        - `slug` string, required
        - `scope` string, nullable
        - `tools` CatalogTemplateTool[], nullable
          - `name` string, required
          - `description` string, required
      - `alternatives` string[]
    - `example` CatalogTemplateExample
      - `prompt` string, required
      - `steps` string[], required
      - `reply` string, required
      - `artifacts` string[], nullable
      - `status` string, nullable
    - `media` CatalogMedia[]
      - `kind` 'image' | 'video', required
      - `url` string, required
      - `alt` string, required
      - `caption` string, nullable
      - `poster_url` string, nullable

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-04** `c3a5d853c4a2`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/agenta-ai/apis/agenta-api/changes/agent-templates/query/post.md)

---

[API](https://skmtc.dev/agenta-ai/apis/agenta-api.md) - [All operations](https://skmtc.dev/agenta-ai/apis/agenta-api/llms.txt) - [OpenAPI document](https://skmtc.dev/agenta-ai/apis/agenta-api/revisions/ab601a2309da?raw)
