Prerequisites
Before you begin, ensure you have:- FlowIQ account at app.flowiq.live
- Bearer token (API Key)
- Your Tenant ID
- Active WhatsApp number connected to FlowIQ
If you don’t have a FlowIQ account yet, sign up at
app.flowiq.live and connect your WhatsApp number
first.
Getting Your Credentials
1. Obtain Your Bearer Token
1
Login to Dashboard
Navigate to app.flowiq.live and log in
2
Access API Settings
Go to Settings → API Keys or Developer Settings
3
Generate Token
Generate a new bearer token or copy your existing one
4
Secure Your Token
Store it securely - never expose it in client-side code
2. Find Your Tenant ID
Your Tenant ID is available in your FlowIQ dashboard under Settings or Account Information.Your First API Call
Retrieve Conversation Messages
Let’s fetch the last 10 messages from a WhatsApp conversation:Expected Response
Common Operations
1. List All Contacts
Retrieve all contacts with pagination:2. Search Contacts
Search for specific contacts by name or phone:3. Find Contact by Phone Number
Lookup a specific contact using their phone number:Working with Pagination
FlowIQ API returns paginated results for large datasets:Understanding Message Types
FlowIQ API returns different types of messages and senders:Sender Types
| Type | Description |
|---|---|
user-whatsapp | Message from the end user |
bot-whatsapp | Automated bot response |
human-whatsapp | Message from a human agent |
system | System notification |
Media Types
| Type | Description |
|---|---|
image | Image file |
video | Video file |
audio | Audio file or voice note |
document | Document file (PDF, DOCX, etc.) |
interactive | Interactive message (buttons, lists) |
null | Text-only message |
Message Status
| Status | Description |
|---|---|
sent | Message sent successfully |
delivered | Message delivered to recipient |
read | Message read by recipient |
failed | Message failed to send |
Error Handling
Implement proper error handling in your applications:Best Practices
Rate Limiting
Rate Limiting
- Implement exponential backoff for retries
- Cache responses when appropriate
- Use pagination effectively to avoid large requests
- Monitor 429 status codes
Security
Security
- Never expose your bearer token in client-side code - Use environment variables for credentials - Implement token rotation regularly - Use HTTPS for all API calls
Performance
Performance
- Request only the data you need using
limitparameter - Use appropriate page sizes (recommended: 20-50 items) - Implement caching for frequently accessed data - Use search filters to reduce response size
Error Handling
Error Handling
- Always check the
successfield in responses - Implement retry logic with exponential backoff
- Log errors for debugging
- Handle network timeouts gracefully
Next Steps
Conversations API
Complete endpoint documentation with all parameters
Contact API
Learn about contact management features
API Reference
Full API reference and authentication details
Dashboard
Access your FlowIQ dashboard
Troubleshooting
401 Unauthorized Error
401 Unauthorized Error
404 Not Found
404 Not Found
Cause: Invalid endpoint or missing required parameters Solution: -
Verify the API endpoint URL is correct - Ensure all required query parameters
are included - Check that the WhatsApp number format is correct (international
format without +)
Empty Messages Array
Empty Messages Array
Cause: No messages found for the specified conversation Solution: -
Verify the WhatsApp number is correct - Check that the number has active
conversations - Ensure the tenant ID matches your account - Try adjusting
pagination parameters
Rate Limit Exceeded (429)
Rate Limit Exceeded (429)
Cause: Too many requests in a short time periodSolution:
- Implement exponential backoff in your code
- Reduce request frequency
- Use pagination instead of requesting all data at once
- Contact support if you need higher rate limits

