---
title: "getTemplateReferences"
method: GET
path: "/v1/email-template/templates/{id}:references"
tags: ["Email templates"]
---

# getTemplateReferences

`GET /v1/email-template/templates/{id}:references`

List the automation flows, workflows and customer portals that currently
reference this template, without modifying anything. Powers the template
settings "used by" view and the pre-migrate preview, and uses the same
discovery as `migrateAutomationsForTemplate` so the preview matches what a
migrate would touch.

## Path parameters

- `id` string, required

## Response `200`

Success

- TemplateReferencesResponse
  - `flows` TemplateReferenceItem[], required — Automation flows whose send-email/reply-email actions reference this template
    - `id` string, required
    - `name` string, nullable — Human-friendly name (flow_name / workflow name / portal name); may be absent.
  - `workflows` TemplateReferenceItem[], required — v2 workflows that own a referencing automation flow
    - `id` string, required
    - `name` string, nullable — Human-friendly name (flow_name / workflow name / portal name); may be absent.
  - `portals` TemplateReferenceItem[], required — Customer portals whose email-template config references this template
    - `id` string, required
    - `name` string, nullable — Human-friendly name (flow_name / workflow name / portal name); may be absent.
  - `portal_lookup_errored` boolean, required — True when the customer-portal lookup failed, so `portals` may be incomplete.

## Other responses

- `403` — Forbidden

---

[API](https://skmtc.dev/epilot/apis/email-template-api.md) · [All operations](https://skmtc.dev/epilot/apis/email-template-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/epilot/email-template-api/revisions/0c6165eaceb0/schema)
