> ## Documentation Index
> Fetch the complete documentation index at: https://docs.qoder.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List templates

> 現在のアカウントに属する Forward テンプレートを、カーソルページネーションで一覧表示します。

`GET /api/v1/forward/templates`

Forward テンプレートのベースラインを一覧表示します。アーカイブ済みのテンプレートは、明示的に要求しない限り除外されます。

## Headers

| Header          | Required | Description    |
| --------------- | -------- | -------------- |
| `Authorization` | Yes      | `Bearer <PAT>` |

## Query parameters

| Parameter   | Type    | Required | Default | Description                                              |
| ----------- | ------- | -------- | ------- | -------------------------------------------------------- |
| `status`    | string  | No       | -       | `active` または `archived` でフィルタします。                        |
| `limit`     | integer | No       | 20      | 1 ページあたりの件数。最大 100。                                      |
| `after_id`  | string  | No       | -       | 指定した Template ID より後のレコードを取得するカーソル。`before_id` と併用できません。 |
| `before_id` | string  | No       | -       | 指定した Template ID より前のレコードを取得するカーソル。`after_id` と併用できません。  |

## Example request

```bash theme={null}
curl -s -X GET 'https://api.qoder.com/api/v1/forward/templates?status=active&limit=20' \
  -H "Authorization: Bearer $QODER_PAT"
```

## Example response

**HTTP 200 OK**

```json theme={null}
{
  "data": [
    {
      "type": "template",
      "id": "tmpl_support",
      "name": "Support assistant",
      "description": "Handles pre-sales and after-sales support",
      "status": "active",
      "created_at": "2026-06-18T10:00:00Z",
      "updated_at": "2026-06-18T10:00:00Z"
    }
  ],
  "first_id": "tmpl_support",
  "last_id": "tmpl_support",
  "has_more": false
}
```

## Response fields

| Field      | Type         | Description              |
| ---------- | ------------ | ------------------------ |
| `data`     | array        | 現在のページの Template オブジェクト。 |
| `first_id` | string\|null | このページの最初のレコードの ID。       |
| `last_id`  | string\|null | このページの最後のレコードの ID。       |
| `has_more` | boolean      | さらにレコードが残っているかどうか。       |

## Errors

| HTTP | Type                    | Trigger                                    |
| ---- | ----------------------- | ------------------------------------------ |
| 400  | `invalid_request_error` | ページネーションパラメータが不正、または `limit` が 100 を超えている。 |
| 401  | `authentication_error`  | PAT が無効または期限切れ。                            |
| 403  | `permission_error`      | このリソースへのアクセス権がない。                          |

## Notes

* 結果は認証されたアカウントのスコープに限定されます。
* カーソルページネーションには `after_id` または `before_id` のいずれか一方を使用し、両方を同時に使用しないでください。

## Related

<CardGroup cols={2}>
  <Card title="テンプレートの作成" icon="plus" href="/cloud-agents/api/forward/templates/create" />

  <Card title="テンプレートの取得" icon="file-lines" href="/cloud-agents/api/forward/templates/get" />
</CardGroup>
