Aigency icon

Aigency

Interact with Aigency API

Overview

This node integrates with the Aigency API, allowing users to perform various operations related to user management, messaging, subscriptions, capabilities, and more. Specifically, the Logout operation logs out a user by their User ID from the Aigency system.

Common scenarios for this node include managing user sessions, sending or deleting messages, handling subscriptions, and querying user-related data within the Aigency platform. The Logout operation is useful when you want to programmatically end a user's session or invalidate their access.

Example use case: After completing a workflow that involves user interaction or data processing, you might want to log out the user to ensure security and session cleanup.

Properties

Name Meaning
User ID The unique numeric identifier of the user to log out. This is required for the operation.

Output

The output JSON contains the result returned by the Aigency API for the logout operation. Typically, it will confirm whether the logout was successful or provide an error message if it failed.

Example output structure:

{
  "result": {
    // API-specific response details about the logout operation
  }
}

If an error occurs, the output will contain an error field describing the issue.

Dependencies

  • Requires an API key credential and API URL for authenticating requests to the Aigency API.
  • These credentials can be configured in the n8n credentials interface or provided via environment variables AIGENCY_API_KEY and AIGENCY_API_URL.
  • The node uses HTTP POST requests with JSON-RPC 2.0 format to communicate with the API.

Troubleshooting

  • Missing Credentials: If the API key or URL is not set either in credentials or environment variables, the node will throw an error indicating missing credentials.
  • API Errors: If the API returns an error (e.g., invalid user ID, network issues), the node will either stop execution or continue based on the "Continue On Fail" setting, returning the error details in the output.
  • Invalid User ID: Providing a non-existent or incorrect User ID may cause the API to return an error.
  • Network Issues: Ensure the API URL is reachable from the n8n instance.

Links and References

Discussion