Getting Meta Credentials
Collect the four variables wacraft needs to talk to WhatsApp Cloud API:
META_APP_SECRET,WABA_ACCOUNT_ID,WABA_IDandWABA_ACCESS_TOKEN(permanent).
1 — Create a Business‑type Meta App & copy META_APP_SECRET
- Go to https://developers.facebook.com, click My Apps → Create App, select Business and finish the wizard.
- In the new app, open Settings → Basic. Hit Show next to App Secret, enter your Facebook password and copy the value.
META_APP_SECRET=PASTE_ME
2 — Enable WhatsApp & grab WABA_ACCOUNT_ID
- In the left menu choose WhatsApp → API Setup. Finish the sandbox step that verifies a personal number. (Facebook Developers)
- After verification, a blue panel shows your WhatsApp Business Account ID — copy this string. (Facebook Developers)
WABA_ACCOUNT_ID=PASTE_ME
(You can always find it again in Business Settings → Accounts → WhatsApp Accounts.)
3 — Find the Phone Number ID (WABA_ID)
Option A — Dashboard
Right below your sandbox number on the API Setup screen you’ll see Phone Number ID. Copy it. (Facebook Developers)
Option B — Graph API
curl -H "Authorization: Bearer <TEMP_OR_PERM_TOKEN>" \
"https://graph.facebook.com/v19.0/<WABA_ACCOUNT_ID>/phone_numbers?fields=id,display_phone_number"
The returned id is the Phone Number ID. (Facebook Developers)
WABA_ID=PASTE_ME
4 — Generate a Permanent WABA_ACCESS_TOKEN
Short‑lived sandbox tokens expire after 24 h; create a never‑expiring one via System Users.
- Open Business Settings (nine‑dot launcher → Business Settings). (Facebook Developers)
- Under Users, select System Users → Add → choose Admin. (Facebook Developers)
- With the new system user selected, click Add Assets and grant Full Control to both your App and your WhatsApp Business Account. (Facebook Developers)
- Press Generate Token, pick your app, tick scopes
whatsapp_business_messagingandwhatsapp_business_management, then generate. (Stack Overflow) - Copy the token shown once and store it safely as
WABA_ACCESS_TOKEN.
WABA_ACCESS_TOKEN=PASTE_ME # never expires
Keep it secret! Anyone with this token can message from your number. Rotate only via System Users. (Facebook Developers)
✅ Checklist
| Variable | Where you found it |
|---|---|
META_APP_SECRET |
App Dashboard → Settings → Basic → App Secret |
WABA_ACCOUNT_ID |
WhatsApp API Setup banner |
WABA_ID |
Phone Number ID line or Graph API call |
WABA_ACCESS_TOKEN |
Business Settings → System Users → Generate Token |
Next page: Env Vars Overview — configure all environment variables.