FB.login() popup. This provides a seamless in-app experience without full-page redirects.
This guide is for platform developers building applications on top of Chirp. If you just want to connect your own WhatsApp Business Account, use the dashboard method.
When to Use This Flow
Choose the popup flow when:- You want a seamless, in-app signup experience
- You’re building a single-page application (SPA)
- You need fine-grained control over the signup process
- You want to track signup attempts with custom metadata
- You’re building a multi-tenant platform where multiple end-users connect their accounts
How It Works
- Start Attempt - Create a tracking record with optional metadata
- Launch Popup - Open Meta’s Embedded Signup using
FB.login() - Handle Events - Process FINISH, CANCEL, or ERROR events from Meta
- Mark Interrupted - If the user completes signup, associate the WABA ID
- Claim Profile - Create the WhatsApp Business Profile from a recovered attempt
Starting a Signup Attempt
Before launching the Meta Embedded Signup popup, create a tracking record:Attempt Response
The
metadata field is optional but recommended for platforms with multiple end-users. Store your internal identifiers to later identify which user each recovered signup belongs to.Metadata Use Cases
Use metadata to store any information that helps you identify your users:Launching the Meta Popup
After creating the attempt, launch Meta’s Embedded Signup using the Facebook SDK:Launch Embedded Signup Popup
Handling Meta Events
Meta’s Embedded Signup fires different events based on user actions:FINISH Event
The user successfully completed the signup flow:Handle FINISH Event
CANCEL Event
The user closed the popup without completing:Handle CANCEL Event
ERROR Event
Meta encountered an error during signup:Handle ERROR Event
Marking an Interrupted Signup
When a user completes the Meta signup but something prevents the normal flow from completing (network error, browser tab closed, etc.), use the mark-interrupted endpoint to associate the WABA ID with the attempt:Handling Recovered Signups
If a user completes the Meta signup but doesn’t return to your application, the signup is marked for recovery. Query recovered attempts to show a “Continue Setup” UI:Recovered Attempts Response
Filtering by Your Users
Use the returnedmetadata to filter recovered attempts for specific users:
Filter Recovered Attempts
Claiming a Recovered Attempt
When a user is ready to complete their interrupted signup, claim the recovered attempt:Claim Response
Cancelling an Attempt
If a user abandons the signup flow before completing it on Meta’s side:Tracking Meta Errors
If Meta returns an error during the signup flow, track it separately for analytics:Error Tracking Fields
Distinguishing between user cancellations (
cancel-attempt) and Meta errors (fail-attempt) enables better analytics. You can track conversion rates, identify problematic steps, and correlate with Meta support tickets using the errorId.Complete Integration Example
Here’s a full example using the SDK:Complete Popup Integration with SDK
Timing and Expiration
Next Steps
API Reference
Full API documentation for signup attempt tracking
Redirect Flow
Alternative server-side redirect integration