SparkBot icon

SparkBot

Interact with SparkBot WhatsApp API

Actions148

Overview

This node allows updating the WhatsApp profile information associated with a specific WhatsApp number (device). It is particularly useful for businesses or users who want to programmatically manage their WhatsApp public profile details such as the profile name, status message, and business-related information. This can help keep contact information up-to-date or reflect changes in business hours or categories without manual intervention.

Practical examples include:

  • Automatically updating the WhatsApp profile name and status during marketing campaigns.
  • Managing business profile details like address, description, email, websites, and categories for WhatsApp Business accounts.
  • Setting business hours with timezone support to inform customers about availability.

Properties

Name Meaning
WhatsApp Number The ID of the WhatsApp number (device) whose profile will be updated.
Profile Name The public name shown on the WhatsApp profile (maximum 25 characters).
Profile Status The public status description visible on the WhatsApp profile (maximum 130 characters).
Update Business Profile Boolean flag indicating whether to update the business profile information (only applicable for WhatsApp Business numbers).
Business Profile Collection of business-specific details to update if "Update Business Profile" is true:
- Business Address: Physical address (max 256 characters)
- Business Description: Activity description (max 256 chars)
- Business Email: Contact email (max 128 chars)
- Business Websites: Up to 2 website URLs
- Business Categories: Up to 3 selected from predefined categories such as Automotive Service, Education, Restaurant, etc.
Set Business Hours Boolean flag to specify whether to set business hours (only when updating business profile).
Business Hours Timezone Timezone string for business hours, e.g., "America/New_York", "Europe/London" (required if setting business hours).

Output

The node outputs an array of JSON objects corresponding to each input item processed. Each output JSON contains the result of the profile update operation for the specified WhatsApp number. The exact structure depends on the API response but generally includes confirmation of the updated fields or error details if the update failed.

No binary data output is produced by this node.

Dependencies

  • Requires an API key credential for authenticating with the SparkBot WhatsApp API service.
  • The node depends on the external SparkBot WhatsApp API to perform profile updates.
  • Proper configuration of the API key credential within n8n is necessary.
  • The WhatsApp number (device) must be registered and accessible via the connected SparkBot account.

Troubleshooting

  • Common Issues:

    • Invalid or missing WhatsApp number ID: Ensure the device ID corresponds to a valid WhatsApp number linked to your account.
    • Exceeding character limits for profile name or status may cause errors; adhere to max lengths (25 for name, 130 for status).
    • Attempting to update business profile fields on a non-Business WhatsApp number will not work.
    • Incorrect timezone format when setting business hours can lead to failures; use valid IANA timezone strings.
  • Error Messages:

    • "Invalid device ID": Verify the WhatsApp number ID is correct and active.
    • "Unauthorized" or authentication errors: Check that the API key credential is correctly configured and has required permissions.
    • "Field length exceeded": Shorten the input values to meet maximum allowed lengths.
    • "Business profile update not supported": Confirm the WhatsApp number is a Business account before enabling business profile updates.

Resolving these typically involves verifying input parameters, ensuring proper credentials, and respecting API constraints.

Links and References

Discussion