Skip to main content
Templates use named variables. Categories are MARKETING, UTILITY, and AUTHENTICATION. The assistant calls get_limits and validate_template before create_template.

Tools

validate_template and create_template use the same fields as the create-template form: name, category, language, header, body, sample content, footer, and buttons. If the customer has not chosen one, the tool returns needsInput and the assistant asks. It does not apply Marketing, English (US), a text header, or “Reply STOP to unsubscribe” unless the customer accepts that choice. Header choices are None, Text, Image, Video, and Document. Pass header.format NONE or headerFormat NONE for no header. A body cannot start or end with a variable. Button choices are URL, phone, copy code, Flow, catalog, single product, multi product, and quick reply. An empty buttons array means no buttons. An empty footer means no footer. Every over-limit field and every body rule comes back in one LIMIT_EXCEEDED result. generate_template reads confirmed and brandSite from the top level or from inside answers. get_template returns category, body, and buttons with the status.

Header images

The assistant creates a new header image only with generate_template. It does not use Canva or any other image service, and it does not upload an image that was made somewhere else. upload_media is for a file you already have. See Media.
1

Ask for the website

The assistant asks for the brand website before it generates, even when you did not mention a site. It does not invent a URL. It passes your URL as brandSite. GreenTick fetches the logo file from that site and places that file on the header. It does not draw a lookalike. The assistant does not fetch the site itself, search for a logo, or claim a redirect loop unless the tool result says the website redirected too many times.
2

Send only the prompt

The first call sends prompt and omits answers and confirmed. The tool checks the plan and image credits before any image work. It returns the same follow-up questions the dashboard asks, with suggestions.
3

Ask every question

The assistant asks each question, shows the suggestion, and waits. If the next call returns more questions, it asks those too. It sets brandSite to skip only when your reply says skip or no website, and it includes that reply in the prompt. It does not fill in answers for you. A phone number, copy code, website button, or WhatsApp Flow question is optional. Skipping one sends skip and does not add that button. A Flow question lists the published Flows on the account. Each option value is the numeric Flow id. When that list is empty, the assistant says there is no published Flow and you can continue without one. An opt-out line, or a line that tells you to tap a button, is the template footer, directly above the buttons.
4

Confirm, then generate

Before confirmed: true, the assistant tells you that creating the header image takes a few minutes. It sends that message before the tool call. The confirmed call uses a new idempotencyKey.
5

Show the image

When the result includes headerImageUrl, the assistant fetches that public URL, shows the image in the reply, and includes the link. The tool result does not include image bytes. A blocked prompt is rewritten and called again with a new idempotencyKey. A blocked prompt does not go to create_template.

After submit

create_template sends the template to Meta. A PENDING result blocks send_message, create_broadcast, and publish_workflow until get_template returns APPROVED. A Meta error stays on create_template. The assistant fixes that tool. It does not send or broadcast the template. A template belongs to the WhatsApp Business account. The assistant does not say it sends from a phone number.