Skip to main content

Sync WABA Templates

Agent Skill

Automate this endpoint with an AI agent using the 2chat-whatsapp-waba skill:

npx skills add 2ChatCo/agent-skills -s 2chat-whatsapp-waba

Trigger a background synchronization of WhatsApp Business API (WABA) message templates for a given phone number. This fetches the latest templates from Meta and updates your 2Chat account so that new, modified, or removed templates are reflected when you call Get WABA Templates.

info

Requires a WABA channel connected to your 2Chat account. See How to connect WABA to 2Chat.

Query parameters

ParameterDescriptionExample
phone_numberYour WABA number in E.164 format: no spaces, with leading plus sign. Required.+5215512345432

Invocation

curl --request POST \
--url 'https://api.p.2chat.io/open/waba/templates/sync?phone_number=+5215512345432' \
--header 'Content-Type: application/json' \
--header 'X-User-API-Key: your_api_key_here'

Response

The endpoint returns immediately while the synchronization runs in the background.

{
"success": true,
"is_syncing": true,
"start_time_syncing": "2026-04-10T12:08:02.318000",
"message": "Template sync is already in progress. Please wait."
}
FieldDescription
successtrue when the request was accepted
is_syncingtrue indicates a sync is running (either already in progress or just kicked off by this request)
start_time_syncingISO 8601 timestamp generated when this response was built. Use it as a reference time for polling Get WABA Templates. Present whenever is_syncing is true.
messageHuman-readable status message

If the endpoint could not start a sync (for example, the WABA number does not have a Gupshup app linked to it), the response is:

{
"success": true,
"is_syncing": false,
"message": "Template sync could not be started."
}

In that case no background work was scheduled and a follow-up call to Get WABA Templates will return the same list as before.

caution

The synchronization runs in the background. Updated templates will be available after a few seconds when you call Get WABA Templates. If you have a large number of templates, the sync may take longer.