getBrandTemplateMetadata

API reference for the getBrandTemplateMetadata method.

This API is a preview. Preview APIs are unstable and may change without warning. You can't release public apps using this API until it's stable.

Return metadata for a brand template given its ID.

Usage: Get brand template metadata

import { getBrandTemplateMetadata, BrandTemplateId } from "@canva/design";
const templateId = resolveToken(requestBrandTemplates()) as BrandTemplateId;
const metadata = await getBrandTemplateMetadata(templateId);
TYPESCRIPT

Parameters

idBrandTemplateId
Required

A unique identifier that references a brand template.

Returns

Metadata for a brand template. This is a Promise that resolves with the following object:

domainstring

The only valid value is "brand".

datasetDataField[]
Optional

Metadata for a data field in a brand template.

labelstring
typestring

Available values:

  • "image"
  • "text"
  • "chart"
keywordsstring[]

A list of keywords contained in a template.