The WhatsApp Cloud API is part of Meta's Graph API at https://graph.facebook.com/v26.0. You send from a business phone number id to a recipient's number in international format, without the plus.
Set up WhatsApp in a Meta developer app to get a phone number id and an access token (temporary for testing, or a system-user token). Send the token as Authorization: Bearer <token>. In the examples it's written {{WHATSAPP_TOKEN}}.
Full reference: https://developers.facebook.com/docs/whatsapp/cloud-api
Business-initiated messages must use an approved template; hello_world comes with every test number.
curl -X POST https://graph.facebook.com/v26.0/{{PHONE_NUMBER_ID}}/messages \
-H "Authorization: Bearer {{WHATSAPP_TOKEN}}" \
-H "Content-Type: application/json" \
-d '{"messaging_product": "whatsapp", "to": "{{TO_NUMBER}}", "type": "template", "template": {"name": "hello_world", "language": {"code": "en_US"}}}'
Free-form text only works within 24 hours of the user messaging you.
curl -X POST https://graph.facebook.com/v26.0/{{PHONE_NUMBER_ID}}/messages \
-H "Authorization: Bearer {{WHATSAPP_TOKEN}}" \
-H "Content-Type: application/json" \
-d '{"messaging_product": "whatsapp", "to": "{{TO_NUMBER}}", "type": "text", "text": {"body": "Hello from PostTaco"}}'