Portal Community

When to Use

Configuration

Connection

FieldRequiredDescription
accessTokenRequiredPermanent System User access token from Meta Business Manager. Store in BizFirst Credentials Manager.
phoneNumberIdRequiredWhatsApp Business phone number ID associated with the account owning the template.
apiVersionOptionalMeta Graph API version, e.g. v18.0. Defaults to v18.0.

Operation

FieldRequiredDescription
templateIdRequiredThe numeric ID of the template to retrieve. Obtained from the output of template/create or template/getMany.

Sample Configuration

{
  "resource": "template",
  "operation": "get",
  "accessToken": "{{ $credentials.whatsAppToken }}",
  "phoneNumberId": "123456789012345",
  "templateId": "{{ $input.templateId }}"
}

Validation Errors

ErrorCause
accessToken is requiredThe accessToken field is empty or missing.
phoneNumberId is requiredThe phoneNumberId field is empty or missing.
templateId is requiredThe templateId field is empty or missing.
100 (Meta)Template ID does not exist or belongs to a different business account.
190 (Meta)Access token expired or invalid.
200 (Meta)Insufficient permissions. The token requires whatsapp_business_management scope.

Output

Success Port

Fires when the template details are successfully retrieved from Meta.

FieldTypeDescription
idstringThe template ID.
namestringThe template name (e.g. order_shipped_notification).
languagestringThe language code (e.g. en_US).
templateStatusstringCurrent approval status: APPROVED, PENDING, or REJECTED.
categorystringTemplate category: UTILITY, MARKETING, or AUTHENTICATION.
componentsJsonstringJSON string of the template's component array (HEADER, BODY, FOOTER, BUTTONS).
statusstring"success" on success.
errorCodestringEmpty on success.
errorMessagestringEmpty on success.
rawResponsestringFull raw JSON response from Meta.

Error Port

Fires when Meta cannot locate the template or authentication fails.

FieldTypeDescription
statusstring"failed" or "error".
errorCodestringMeta error code.
errorMessagestringHuman-readable description.
rawResponsestringRaw API error JSON for diagnostics.

Sample Output

{
  "id": "987654321098765",
  "name": "order_shipped_notification",
  "language": "en_US",
  "templateStatus": "APPROVED",
  "category": "UTILITY",
  "componentsJson": "[{\"type\":\"HEADER\",\"format\":\"TEXT\",\"text\":\"Your Order Has Shipped\"},{\"type\":\"BODY\",\"text\":\"Hi {{1}}, your order #{{2}} has been shipped.\"}]",
  "status": "success",
  "errorCode": null,
  "errorMessage": null,
  "rawResponse": "{\"id\":\"987654321098765\",\"name\":\"order_shipped_notification\",\"language\":\"en_US\",\"status\":\"APPROVED\",\"category\":\"UTILITY\",\"components\":[...]}"
}

Expression Reference

ValueExpressionNotes
Template ID{{ $output.getTemplate.id }}Echoed ID for chaining to other template operations.
Approval status{{ $output.getTemplate.templateStatus }}Use in an IfCondition: branch on "APPROVED" to proceed with send, "REJECTED" to notify owner.
Template name{{ $output.getTemplate.name }}Human-readable name for logging and notifications.
Components JSON{{ $output.getTemplate.componentsJson }}Parse with JsonTransform to extract body text or variable count.
Category{{ $output.getTemplate.category }}Use to validate the template type matches the intended use case before sending.

Node Policies & GuardRails

Policy AreaRecommendation
Polling frequencyWhen waiting for approval, poll no more than once every 4 hours. Excessive polling can trigger rate limits. Use a scheduled trigger with an appropriate interval.
Status-based branchingAlways check templateStatus before using a template in a send operation. A PENDING or REJECTED template will cause message send failures.
Credential storageStore the access token in BizFirst Credentials Manager. Never paste it into node configuration as plain text.
Error port handlingAlways connect the error port. A 100 error (not found) should trigger a workflow alert — a template that was previously working may have been deleted.
Caching approved templatesOnce a template reaches APPROVED status, cache the result in a workflow variable for 24 hours to avoid unnecessary API calls before each send.

Examples

Poll for Approval After Creation

{
  "resource": "template",
  "operation": "get",
  "accessToken": "{{ $credentials.whatsAppToken }}",
  "phoneNumberId": "123456789012345",
  "templateId": "{{ $session.createdTemplateId }}"
}

A scheduled workflow fires every 4 hours. It retrieves the template and checks templateStatus in a Switch node: APPROVED routes to an update-database node and stops the scheduler; REJECTED routes to a Slack notification node; PENDING re-schedules the next check.

Pre-Send Validation Gate

{
  "resource": "template",
  "operation": "get",
  "accessToken": "{{ $credentials.whatsAppToken }}",
  "phoneNumberId": "123456789012345",
  "templateId": "{{ $input.campaignTemplateId }}"
}

Before launching a bulk send campaign, this node retrieves the template. An IfCondition node checks that templateStatus == "APPROVED". If true, the workflow proceeds to the send loop. If false, the workflow aborts and sends an alert email to the campaign manager with the current status and rejection reason if available.

Component Audit for Compliance

{
  "resource": "template",
  "operation": "get",
  "accessToken": "{{ $credentials.whatsAppToken }}",
  "phoneNumberId": "123456789012345",
  "templateId": "{{ $input.auditTemplateId }}"
}

A weekly compliance audit workflow retrieves every active template, compares the componentsJson against the version stored in the compliance database, and flags any discrepancies. This detects unauthorised template modifications that may have been made directly in Meta Business Manager.