Answer a WhatsApp Flow’s screens from your own API. Ringg AI handles WhatsApp’s encryption and sends your server plain, signed JSON for each screen.
Choose Server as a Flow’s Data source when its screens need data from your own systems, such as branches near a pincode, stock, prices, order status or availability from a system Ringg doesn’t connect to.WhatsApp normally requires every Flow endpoint to handle its RSA and AES encryption, key management and health checks. With this option, Ringg does all of that. Your server gets one plain JSON POST per screen change, signed so you can trust it, and returns the next screen as JSON.
"data_api_version": "3.0" and a routing_model listing which screen can lead to which.
A data_exchange action. Its payload is exactly what your server receives as data.
A data block on each screen that shows your server’s values, with an __example__ for Meta’s preview. Your response must match these types.
You can also create this Flow in Ringg: in the Flows tab, select Create Flow, then Paste JSON with the design above, and Save draft. After connecting your server below, publish it from its details instead of WhatsApp Manager.
Choosing Server as a Flow's data source, saving it, and copying the signing secret
1
Open the Flow
Go to Tools → WhatsApp Business, select the Flows tab and open the Flow.
2
Enter your server's URL
Under Data source, select Set up data source, choose Server and enter your endpoint’s URL in Server URL, for example https://api.example.com/whatsapp-flow. It must start with https://. Select Save.
Choosing Server as the data source and entering its URL
3
Copy the signing secret
Ringg shows a signing secret once. Copy it with the copy icon and store it on your server, for example as RINGG_FLOW_SIGNING_SECRET. It can’t be shown again. If it is lost, select Edit source, tick Issue a new signing secret and save.
The signing secret, shown once after saving
4
Check the endpoint
If Ringg says Meta kept this Flow’s own endpoint, the Flow was already published. Copy the URL shown, paste it as the Flow’s endpoint in WhatsApp Manager, and publish the Flow again. That URL is Ringg’s, not your server’s: WhatsApp calls Ringg, and Ringg calls you.
5
Finish in WhatsApp Manager
Open the Flow’s endpoint settings, connect the Meta app you use with Ringg, and run the health check. Ringg answers it, so it passes even before your server is live. Then Preview the Flow, which calls your server for real, and Publish it.
6
Add it to an assistant
Sync the Flows tab, then add the Flow to a WhatsApp assistant as described in WhatsApp Flows. Set Opens on to Loaded by the Flow’s endpoint, so your server is asked for the first screen.
The screen ID the request comes from. null for INIT.
data
What the Flow sent. For data_exchange, the action’s payload with the customer’s input filled in.
flow_token
WhatsApp’s token for this Flow session. Pass it back if you finish the Flow yourself. Treat it as opaque.
flow.id
Ringg’s ID for the Flow.
flow.meta_flow_id
Meta’s ID for the Flow, as shown in WhatsApp Manager.
flow.name
The Flow’s name.
context.chat_id
The Ringg chat the Flow was sent in. It is the same chat_id as in chat events and Logs → WhatsApp, so you can tie a Flow session to a conversation.
context.tool_id
The ID of the assistant’s Flow tool that sent it, which stays the same while the Flow is on the assistant. template when the customer opened it from a template’s Flow button.
context is {} when the Flow wasn’t sent by Ringg, for example in WhatsApp Manager’s preview. Don’t require it.Headers
Header
Value
Content-Type
application/json
X-Ringg-Signature
sha256= followed by the hex HMAC-SHA256 of the raw request body, keyed with your signing secret
Verify the signature against the exact bytes you received, before parsing them. Parsing the JSON and serialising it again changes the spacing, so the signature won’t match.
Return the screen the request came from, with error_message in data. WhatsApp shows the message at the bottom of the screen and keeps what the customer entered.
{ "screen": "PINCODE", "data": { "error_message": "No showroom near 560999 yet." } }
To close the Flow yourself, for example after you created an order, return WhatsApp’s SUCCESS screen with the request’s flow_token and anything you want to send back. You don’t need a SUCCESS screen in the Flow JSON.
The params reach the assistant as the customer’s submission, just like a Flow finished with a complete action: order_id=A-1042, showroom=MG Road. Use readable keys, since they are the labels the assistant sees.
Addresses on private or internal networks are refused, both when you save and before every request.
7 seconds
WhatsApp gives Ringg 10 seconds, so your server gets 7. There is one attempt and no retry.
No redirects
Answer at the URL you saved. Redirects aren’t followed.
HTTP 200
Any other status, a timeout, or a body without screen or data keeps the customer on the screen with This form can’t load right now. Please try again shortly.
One secret per Flow
Each Flow with live data has its own signing secret.
New secret takes effect at once
After Issue a new signing secret, requests are signed with the new secret straight away. Accept both secrets on your server while you switch.
Ringg sets its own encryption key on every number of the WhatsApp Business account when you save a data source. If you also run a WhatsApp Flow endpoint of your own on those numbers with a different key, it stops working. Move those Flows to a Server data source so Ringg handles the encryption for all of them.