The right business
Make the sender identity clear before anyone starts writing a reply.
A clear place for your application experience, and a clear boundary for the platform connection.
Fans APIPlan your application workflow | WhatsAppConfirm the connection |
|---|---|
Business identityKeep the selected business visible throughout the conversation. | Business identityCheck account eligibility, phone-number setup and required permissions. |
Message preparationBring recipient context, message copy and review into one flow. | Message preparationConfirm supported message types and any template requirements. |
Conversation stateMake drafts, pending requests and delivery updates easy to distinguish. | Conversation stateUse the documented response and event contract for each operation. |
CredentialsLet your interface work through your own backend. | CredentialsKeep tokens private and confirm the access your integration requires. |
FansAPI WhatsApp availability is under review. This page describes a proposed workflow, not a live messaging connection.
Three moments that keep a conversation clear, from the first selection to the next action.
Start with the right business identity. Keep the destination visible as your team prepares a conversation.
Bring recipient context and message copy together. Review the content and applicable messaging requirements.
Keep each reply in context. Once connected, use actual API responses to show what needs attention next.
A focused interface for the people, messages and next steps in your WhatsApp workflow.
Make the sender identity clear before anyone starts writing a reply.
Give your team space to write, check and refine a message before sending.
Keep the latest message close to the reply so the conversation stays easy to follow.
Check the recipient and message together. Keep drafts separate from submitted requests.
Design distinct pending, delivered and failed states, driven by confirmed API results.
Keep secrets on your server and expose only the information your interface needs.
const response = await fetch(process.env.WHATSAPP_API_URL, {
headers: {
[process.env.WHATSAPP_AUTH_HEADER_NAME]:
process.env.WHATSAPP_AUTH_HEADER_VALUE
}
});
const data = await response.json();
console.log(data);import os
import requests
response = requests.get(
os.environ["WHATSAPP_API_URL"],
headers={
os.environ["WHATSAPP_AUTH_HEADER_NAME"]:
os.environ["WHATSAPP_AUTH_HEADER_VALUE"]
},
timeout=30,
)
print(response.json())<?php
$request = curl_init(getenv('WHATSAPP_API_URL'));
curl_setopt_array($request, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
getenv('WHATSAPP_AUTH_HEADER_NAME') . ': ' .
getenv('WHATSAPP_AUTH_HEADER_VALUE'),
],
]);
$response = curl_exec($request);
curl_close($request);
echo $response;require "net/http"
require "json"
uri = URI(ENV.fetch("WHATSAPP_API_URL"))
request = Net::HTTP::Get.new(uri)
request[ENV.fetch("WHATSAPP_AUTH_HEADER_NAME")] =
ENV.fetch("WHATSAPP_AUTH_HEADER_VALUE")
response = Net::HTTP.start(uri.host, uri.port,
use_ssl: uri.scheme == "https", read_timeout: 30
) { |http| http.request(request) }
puts JSON.parse(response.body)var request = HttpRequest.newBuilder()
.uri(URI.create(System.getenv("WHATSAPP_API_URL")))
.header(
System.getenv("WHATSAPP_AUTH_HEADER_NAME"),
System.getenv("WHATSAPP_AUTH_HEADER_VALUE"))
.timeout(Duration.ofSeconds(30))
.GET().build();
var response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());curl --fail-with-body --max-time 30 \
"$WHATSAPP_API_URL" \
-H "$WHATSAPP_AUTH_HEADER_NAME: $WHATSAPP_AUTH_HEADER_VALUE"WHATSAPP_API_URL · server environmentSeparate the state of your interface from the result of a network request.
| Moment | Interface state | What it means |
|---|---|---|
| Writing a reply | Draft | The message is being prepared. No request has been sent. |
| Reviewing content | Ready for review | The recipient and message are ready for a final check. |
| Awaiting a result | Pending | A request was submitted. Wait for the actual response or event. |
| Handling an update | Delivery update | Show the reported result and a useful next action if attention is needed. |
These are interface labels, not WhatsApp or FansAPI response-field names.
Confirm availability and account requirements before connecting a business or choosing a plan.
Meta’s Cloud API uses a business portfolio, WhatsApp Business Account and business phone number. Confirm the requirements for your intended integration.
Ask our team about WhatsApp access, authentication, supported operations and event delivery before implementation.
Store credentials securely and handle authenticated requests on the server. Keep the frontend focused on the conversation.
The essentials before your first request.