Actions5
- Message Actions
- Contact Actions
Overview
This node integrates with the Avisa App API to perform various WhatsApp-related actions. Specifically, for the Contact - Check Number operation, it verifies whether a given phone number is registered on WhatsApp. This can be useful in scenarios where you want to validate contacts before sending messages or performing other operations, ensuring that the number is active on WhatsApp.
Practical examples:
- Before sending marketing messages, check if the recipient's number is registered on WhatsApp.
- Validate user input in a contact form by confirming their WhatsApp registration status.
- Filter contact lists to include only WhatsApp-active numbers.
Properties
Name | Meaning |
---|---|
Phone Number | Phone number in international format to check |
Output
The output JSON object contains the result of the WhatsApp number check. It includes:
success
: Boolean indicating if the request was successful.isWhatsAppNumber
: Boolean indicating if the number is registered on WhatsApp.- Additional fields returned by the API response (e.g., status codes or metadata).
- In case of an invalid WhatsApp number (HTTP 400), the output will indicate
isWhatsAppNumber: false
and include the status code and any error details. - If an error occurs, the output will contain
success: false
,isWhatsAppNumber: false
, and anerror
message describing the issue.
Example output when number is valid:
{
"success": true,
"isWhatsAppNumber": true,
"...additionalApiResponseFields": "..."
}
Example output when number is invalid:
{
"success": true,
"isWhatsAppNumber": false,
"statusCode": 400,
"...additionalApiResponseFields": "..."
}
Example output on error:
{
"success": false,
"isWhatsAppNumber": false,
"error": "Error message here"
}
Dependencies
- Requires an API key credential for authenticating with the Avisa App API.
- The node uses the base URL from the credential configuration to make HTTP POST requests.
- No additional external dependencies are required beyond the configured API access.
Troubleshooting
Common issues:
- Invalid or missing API token: The node will return errors related to authorization (HTTP 401).
- Incorrect phone number format: The API may respond with HTTP 400 indicating invalid input.
- Network or connectivity issues: May cause request failures or timeouts.
Error messages and resolutions:
"Invalid WhatsApp number"
(HTTP 400): Indicates the number is not registered on WhatsApp; this is handled gracefully by returningisWhatsAppNumber: false
.- Authorization errors (HTTP 401): Verify that the API key credential is correctly set up and has proper permissions.
- Other HTTP errors: Review the error message included in the output and check network connectivity or API service status.
Links and References
- Avisa App API Documentation (hypothetical link as not provided in source)
- WhatsApp Business API overview: https://developers.facebook.com/docs/whatsapp
- n8n HTTP Request Node documentation: https://docs.n8n.io/nodes/n8n-nodes-base.httpRequest/