DinastiAPI Admin icon

DinastiAPI Admin

Administrative operations for DinastiAPI WhatsApp API

Overview

This node, named "DinastiAPI Admin," provides administrative operations for managing users and global settings in the DinastiAPI WhatsApp API system. It is designed to facilitate user management tasks such as creating new users, deleting users, retrieving global configuration and statistics, and testing global systems.

The Create User operation allows you to add a new user with detailed configuration options including webhook subscriptions, event filtering, media handling preferences, proxy settings, S3 storage integration, and RabbitMQ messaging configurations. This is useful in scenarios where you want to programmatically onboard WhatsApp users into your system with customized event handling and storage options.

Practical examples:

  • Automatically create a new WhatsApp user with a specific authentication token and subscribe to message events via a webhook.
  • Configure a user to skip downloading media files or ignore group messages.
  • Enable S3 storage for media files associated with the user.
  • Set up RabbitMQ queues for real-time event processing per user.

Properties

Name Meaning
User Name The name of the user to be created (e.g., "John Doe").
User Token Authentication token for the user, used for secure access (input is masked).
Additional Options A collection of optional settings to customize the user's behavior and integrations:
- Webhook URL URL to receive event notifications for this user.
- Events Types of events to subscribe to (e.g., All, Message, Presence).
- Expiration Timestamp when the user expires; 0 means no expiration.
- Skip Media Download Whether to skip downloading media files (true/false).
- Skip Groups Whether to skip group messages (true/false).
- Skip Newsletters Whether to skip newsletter messages (true/false).
- Skip Broadcasts Whether to skip broadcast messages (true/false).
- Skip Own Messages Whether to skip messages sent by the user themselves (true/false).
- Skip Calls Whether to auto-reject incoming calls (true/false).
- Call Reject Message Message sent automatically when rejecting calls.
- Call Reject Type Type of call rejection: Busy, Declined, or Unavailable.
- Proxy Configuration Settings for using a proxy server, including enabling proxy and specifying the proxy URL (supports socks5:// or http://).
- S3 Configuration Settings for integrating S3 storage, including enabling S3, access keys, bucket name, endpoint URL, media delivery method (Base64, S3, Both), path style URLs, public URL, region, retention days, and secret key.
- RabbitMQ Configuration Settings for RabbitMQ messaging integration, including enabling RabbitMQ, connection URL, exchange details, queue naming patterns with placeholders, delivery mode, durability, exclusivity, and subscribed events.

Output

The node outputs JSON data representing the result of the performed operation:

  • For Create User, the output JSON contains the newly created user's details as returned by the API.
  • For other operations like listing users or getting global stats, the output JSON reflects the corresponding data retrieved from the API.
  • In case of errors, the output JSON includes an error field with the error message.

No binary data output is produced by this node.

Dependencies

  • Requires an API key credential for authenticating with the DinastiAPI WhatsApp API admin interface.
  • The node makes HTTP requests to the configured API endpoint using the provided admin token.
  • Optional dependencies based on configuration:
    • Webhook URL for receiving event callbacks.
    • S3-compatible storage service credentials and endpoint.
    • RabbitMQ messaging broker connection details.

Troubleshooting

  • Invalid JSON in Test Data: When sending a global test event, the "Test Data" must be valid JSON. Invalid JSON will cause an error with the message "Test Data must be valid JSON."
  • Authentication Errors: If the API key or admin token is incorrect or missing, HTTP requests will fail. Ensure the correct credentials are configured.
  • Missing Required Parameters: Operations like Create User require mandatory fields such as User Name and User Token. Omitting these will cause validation errors.
  • Proxy Misconfiguration: Incorrect proxy URLs or disabled proxy settings may prevent successful API communication.
  • S3 or RabbitMQ Misconfiguration: Enabling these features without proper credentials or connection details will lead to failures in media storage or event messaging.

Links and References

Discussion