API Reference v1.0

Templates

Retrieve your approved WhatsApp message templates. Templates are pre-approved message formats required for initiating conversations outside the 24-hour customer service window.

List Templates

GET /api/wpbox/getTemplates

Returns all approved message templates associated with your account. Use this endpoint to discover available templates before sending template messages.

Query Parameters

Parameter Type Description
token Required string Your API authentication token. Found in your dashboard under Settings > API.

Example Request

cURL
curl -G "https://whatsbizapi.com/api/wpbox/getTemplates?token=your-api-token"

Example Response

Response — 200 OK
[ { "id": 1, "name": "order_confirmation", "category": "UTILITY", "language": "en", "status": "APPROVED", "components": [ { "type": "HEADER", "format": "TEXT", "text": "Order #1" }, { "type": "BODY", "text": "Hi 1, your order has been confirmed. Estimated delivery: 2." }, { "type": "FOOTER", "text": "Thank you for shopping with us!" } ] }, { "id": 2, "name": "summer_sale_promo", "category": "MARKETING", "language": "en", "status": "APPROVED", "components": [ { "type": "HEADER", "format": "IMAGE" }, { "type": "BODY", "text": "Hi 1, don't miss our Summer Sale! Get up to 2% off on selected items. Shop now!" }, { "type": "BUTTONS", "buttons": [ { "type": "URL", "text": "Shop Now", "url": "https://example.com/sale" } ] } ] } ]

Template Categories

Every WhatsApp template belongs to one of three categories. The category affects pricing and determines what type of content you can send.

Category Description Use Cases
MARKETING Promotional content designed to drive engagement, sales, or brand awareness. Product announcements, seasonal offers, newsletters, discount codes
UTILITY Transactional or informational messages that relate to an existing customer action or request. Order confirmations, shipping updates, appointment reminders, payment receipts
AUTHENTICATION Security-related messages containing one-time passcodes for verifying user identity. OTP delivery, login verification, account confirmation

Pricing by category: Marketing templates typically cost more per conversation than Utility or Authentication templates. Check the Meta pricing page for current rates by country.

Template Statuses

Templates go through a review process before they can be used. The status field indicates where a template is in its lifecycle.

Status Description
APPROVED Template has been reviewed and approved by Meta. It is ready to use for sending messages.
PENDING Template has been submitted and is awaiting review. It cannot be used until approved.
REJECTED Template was rejected during review. Check Meta's template guidelines and resubmit with corrections.
PAUSED Template has been temporarily paused by Meta, usually due to low quality ratings or high block rates.
DISABLED Template has been permanently disabled and cannot be used. You will need to create a new template.

Only APPROVED templates can be sent. Attempting to send a message with a template in any other status will result in an error. Always verify the template status before sending.

Response Fields

Field Type Description
id integer Unique identifier for the template in WhatsBizAPI.
name string Template name as registered with Meta. Used when sending template messages via the API.
category string One of MARKETING, UTILITY, or AUTHENTICATION.
language string Language code of the template (e.g., en, es, pt_BR).
status string Current approval status. See Template Statuses above.
components array JSON array of template components (HEADER, BODY, FOOTER, BUTTONS). Defines the structure and content of the template.