---
title: "Get All Orgunit Templates"
method: GET
path: "/orgunit/{orgunitId}/templates"
tags: ["Orgunit"]
---

# Get All Orgunit Templates

`GET /orgunit/{orgunitId}/templates`

## Request

- Base URL: `https://api-docs.ministrybytext.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api-docs.ministrybytext.com/orgunit/{orgunitId}/templates`
- Auth: none declared
- TypeScript: <https://skmtc.dev/ministrybytext/apis/pbt-api-documentation/docs/orgunit/:orgunitId/templates/get.ts> (a function with typed inputs; its response is checked against the schema)

Retrieves a paginated list of orgunit-level message templates.  Supports global search filtering by template name or body text,  sorting options, and direct lookup using a specific template ID.

## Path parameters

- `orgunitId` string, required

## Query parameters

- `search` string
- `pageNumber` integer
- `pageSize` integer
- `sorting` 'Ascending' | 'Descending'
- `templateId` string

## Response `200`

Success

- AppTemplatePaginatedResponse3ExternalApiResponseNew
  - `data` AppTemplatePaginatedResponse3
    - `pageNumber` integer
    - `pageSize` integer
    - `totalCount` integer
    - `totalPages` integer
    - `data` AppTemplate[]
      - `templateId` string
      - `name` string
      - `message` string
      - `status` string
      - `mediaDetails` MediaDetails
        - `mediaPath` MediaPath[], nullable
          - `fileName` string
          - `extension` string
          - `fileSaveId` string
          - `mimetype` string
          - `url` string
  - `appCode` string
  - `message` string
  - `isError` boolean

## Other responses

- `400`: Bad Request

---

[API](https://skmtc.dev/ministrybytext/apis/pbt-api-documentation.md) - [All operations](https://skmtc.dev/ministrybytext/apis/pbt-api-documentation/llms.txt) - [OpenAPI document](https://skmtc.dev/ministrybytext/apis/pbt-api-documentation/revisions/7d64a1f0b0c3?raw)
