Actions148
- Chats Actions
- Chat Contacts Actions
- Chat Messages Actions
- Chat Files Actions
- Files Actions
- Team Actions
- Labels Actions
- Departments Actions
- Quick replies Actions
- Queue Actions
- WhatsApp session Actions
- WhatsApp profile Actions
- Business catalog Actions
- Campaigns Actions
- Meeting Links Actions
- User Status Actions
- Webhooks Actions
- Other Actions
- Send messages Actions
- Outbound Messages Actions
- WhatsApp Numbers Actions
- Groups Actions
- Channels Actions
Overview
This node interacts with the SparkBot WhatsApp API to update metadata and properties of outbound files previously uploaded or sent. It is useful when you need to modify details such as the filename, reference identifier, display format, tags, message caption, expiration time, or access permissions of a file that has already been created or shared.
Practical scenarios include:
- Renaming a file after upload to better reflect its content.
- Changing the visibility or permission level of a file (e.g., making it public or private).
- Adding or updating tags for easier categorization and search.
- Setting or extending the expiration time of a file to control how long it remains accessible.
- Updating the caption text associated with a media file.
Properties
| Name | Meaning |
|---|---|
| File ID | The unique identifier of the file to update. |
| Filename | New filename to assign to the file. |
| Reference | New reference identifier for the file. |
| Format | New display format of the file. Options: GIF, Voice Message, Native. |
| Tags | New tags to associate with the file. Multiple values allowed. |
| Message Caption | Text caption to attach to the media file. |
| Expiration | New expiration time for the file. Options range from 10 minutes up to 2 years. |
| Permission | New access permission level for the file. Options: Public, Read-only, Private. |
Output
The node outputs JSON data representing the updated file object returned by the SparkBot API. This typically includes the updated metadata fields such as filename, reference, format, tags, message caption, expiration, and permission status.
No binary data output is produced by this operation.
Dependencies
- Requires an API key credential for authenticating with the SparkBot WhatsApp API.
- The node depends on the SparkBot API service being available and reachable.
- No additional environment variables are explicitly required beyond the API key credential.
Troubleshooting
Common issues:
- Invalid or expired File ID: Ensure the File ID corresponds to an existing outbound file.
- Insufficient permissions: Verify that the API key used has rights to update files.
- Invalid property values: For example, setting an unsupported format or expiration value may cause errors.
- Network or API downtime: Connectivity issues can prevent successful updates.
Error messages:
"File not found": Check that the File ID is correct and the file exists."Unauthorized"or"Authentication failed": Confirm the API key credential is valid and active."Invalid parameter": Review the input properties for correctness and supported values.
Resolving these usually involves verifying input parameters, checking API credentials, and ensuring network connectivity.
Links and References
- SparkBot WhatsApp API Documentation (general reference for API capabilities)
- n8n Documentation on Creating Custom Nodes