---
title: "List Campaign Templates"
method: GET
path: "/management/v1/projects/{projectId}/templates/campaigns"
tags: ["Management"]
---

# List Campaign Templates

`GET /management/v1/projects/{projectId}/templates/campaigns`

## Request

- Base URL: `https://api.voucherify.io`
- URL: `https://api.voucherify.io/management/v1/projects/{projectId}/templates/campaigns`
- Auth: API key in header `X-Management-Id` and API key in header `X-Management-Token`

Lists all campaign templates available in the project.

> 👍 List Campaign Templates
>
> This endpoint works in the same way as the [List Campaign Templates endpoint](/api-reference/templates/list-campaign-templates).

> 📘 Campaign Templates – Documentation
>
>Read the [Campaign Templates documentation](/build/campaign-templates) to learn more about this feature.

## Query parameters

- `limit` integer
- `starting_after_id` string
- `order` 'id' | '-id'
- `include_total` boolean
- `filters` ParameterFiltersListTemplates
  - `junction` 'and' | 'or': Logical Operator Between Filters. Filter by conditions set on the `junction` parameter indicating how the `conditions` should be accounted for in the query. An `AND` is an all-inclusive logical operator, meaning the `AND` operator displays a record if **ALL** the conditions separated by AND are TRUE, while an `OR` operator displays a record if **ANY** of the conditions separated by OR is TRUE.
  - `id` object: Unique template ID.
    - `conditions` FilterConditionsString: Data filters used to narrow down the data records to be returned in the result.
      - `$in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$not_in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$is` string: Value is exactly this value (single value).
      - `$is_not` string: Results omit this value (single value).
      - `$has_value` string: Value is NOT null. The value for this parameter is an empty string.
      - `$is_unknown` string: Value is null. The value for this parameter is an empty string.
      - `$starts_with` string: Value starts with the specified string.
      - `$ends_with` string: Value ends with the specified string.
      - `$contains` string: Value includes the specified string.
      - `$not_contain` string: Value does NOT include the specified string.
  - `name` object: Unique user-defined template name.
    - `conditions` FilterConditionsString: Data filters used to narrow down the data records to be returned in the result.
      - `$in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$not_in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$is` string: Value is exactly this value (single value).
      - `$is_not` string: Results omit this value (single value).
      - `$has_value` string: Value is NOT null. The value for this parameter is an empty string.
      - `$is_unknown` string: Value is null. The value for this parameter is an empty string.
      - `$starts_with` string: Value starts with the specified string.
      - `$ends_with` string: Value ends with the specified string.
      - `$contains` string: Value includes the specified string.
      - `$not_contain` string: Value does NOT include the specified string.
  - `campaign_type` object: Campaign template campaign type.
    - `conditions` object: Data filters used to narrow down the data records to be returned in the result.
      - `$in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$not_in` string[]: Array of resource values that should be included in the results (multiple values).
      - `$is` 'DISCOUNT_COUPONS' | 'GIFT_VOUCHERS': Value is exactly this value (single value).
      - `$is_not` 'DISCOUNT_COUPONS' | 'GIFT_VOUCHERS': Results omit this value (single value).
      - `$has_value` string: Value is NOT null. The value for this parameter is an empty string.
      - `$is_unknown` string: Value is null. The value for this parameter is an empty string.
      - `$starts_with` string: Value starts with the specified string.
      - `$ends_with` string: Value ends with the specified string.

## Response `200`

Returns a dictionary of campaign template objects. The templates are returned by creation date by default. The most recent objects appear last unless specified otherwise with the `order` parameter.

- ManagementProjectsTemplatesCampaignsListResponseBody: Response body schema for **GET** `/management/v1/projects/{projectId}/templates/campaigns`.
  - `object` 'list', required: The type of the object represented by JSON. This object stores information about campaign templates.
  - `data_ref` 'data', required: Identifies the name of the JSON property that contains the array of campaign templates.
  - `data` CampaignTemplate[]: Dictionary that contains an array of campaign templates.
    - `id` string, required: Unique identifier of the campaign template. It is assigned by Voucherify.
    - `name` string, required: User-defined name of the campaign template.
    - `description` string: User-defined description of the campaign template.
    - `campaign_type` 'DISCOUNT_COUPONS' | 'GIFT_VOUCHERS', required: Type of the campaign used to create the campaign template. Templates created from a promotion tier are converted to `DISCOUNT_COUPONS`.
    - `created_at` string, date-time, required: Timestamp representing the date and time when the campaign template was created. The value is shown in the ISO 8601 format.
    - `object` 'campaign_template', required: The type of the object represented by JSON.
    - `updated_at` string, date-time: Timestamp representing the date and time when the campaign template was last updated. The value is shown in the ISO 8601 format.
  - `total` integer: Total number of templates, regardless of the applied query parameters. Displayed only if the `include_total` query paremeter is set to `true`.
  - `has_more` boolean, required: As query results are always limited (by the limit parameter), the `has_more` flag indicates if there are more records for given filter parameters. This lets you know if you can run another request to get more records returned in the results.
  - `more_starting_after` string: Returns an ID that can be used to return another page of results. Use the template ID in the `starting_after_id` query parameter to display another page of the results starting after the template with that ID.

## Other responses

- `401`: Returns an error if an invalid token was provided.
- `402`: Returns an error if the current plan does not include the Management API feature.
- `404`: Returns an error when a resource could not be found.

---

[API](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions.md) - [All operations](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions/llms.txt) - [OpenAPI document](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions/revisions/4982266e0494?raw)
