Overview
This node integrates with the SmileAPI WhatsApp service to manage WhatsApp instances and send messages. Specifically, the Instance - Get operation retrieves detailed information about a particular WhatsApp instance identified by its phone number ID. This is useful for monitoring the status or configuration of an existing WhatsApp instance managed via SmileAPI.
Common scenarios include:
- Checking the current state or metadata of a WhatsApp instance.
- Verifying that an instance is active before sending messages.
- Retrieving instance details for logging or auditing purposes.
Example: You have a WhatsApp business number registered with SmileAPI and want to fetch its current status or configuration programmatically within an n8n workflow.
Properties
| Name | Meaning |
|---|---|
| Phone Number ID | The unique identifier of the WhatsApp instance (phone number ID) to retrieve information for. Example format: 5511987654321. |
| Bearer Token | Your SmileAPI Bearer Token used for authenticating the API request. This token must be valid and authorized to access the instance data. |
Output
The node outputs JSON data representing the response from the SmileAPI endpoint for the requested instance. The structure typically includes details about the WhatsApp instance such as its status, configuration, and other metadata returned by SmileAPI.
If the API returns a string, the node attempts to parse it as JSON; otherwise, it outputs the raw response.
No binary data output is produced by this operation.
Dependencies
- Requires a valid SmileAPI account and an associated API key (Bearer Token) for authentication.
- The node uses HTTP requests to the SmileAPI endpoints at
https://api.smileapi.com.br. - The username part of the credentials is used as part of the URL path.
- Proper network connectivity to SmileAPI servers is necessary.
Troubleshooting
- Invalid Bearer Token: If authentication fails, ensure the Bearer Token is correct and has not expired.
- Incorrect Phone Number ID: Using an invalid or non-existent phone number ID will result in errors or empty responses.
- Network Issues: Connectivity problems can cause request failures; verify your network and firewall settings.
- API Rate Limits: Excessive requests may be throttled by SmileAPI; check API usage limits.
- Error Messages: Errors thrown by the node will include the message from the SmileAPI response. Review these messages to identify issues like unauthorized access or resource not found.
To resolve common errors:
- Double-check input parameters for correctness.
- Verify API credentials and permissions.
- Consult SmileAPI documentation or support if persistent errors occur.
Links and References
- SmileAPI Official Website
- SmileAPI WhatsApp API Documentation
- n8n Documentation on HTTP Request Node (for understanding underlying request mechanics)