Mira Logout icon

Mira Logout

Logout from Mira App Server and revoke access token

Mira Logout

AI-generated

Overview

The "Mira Logout" node is designed to log out from the Mira App Server by revoking the current access token. This operation helps securely terminate a session and invalidate the token, preventing further use. It is particularly useful in workflows where you want to ensure that tokens are not left active after completing tasks, enhancing security and compliance.

Practical examples include:

  • Ending a user session after automated data processing.
  • Revoking tokens as part of cleanup steps in integration workflows.
  • Ensuring tokens are invalidated when switching between different user contexts.

Properties

Name Meaning
Token Source Choose where to get the access token from: "From Credentials" (use stored API credentials) or "From Input Data" (provide token directly or via input).
Server URL The URL of the Mira App Server to which the logout request will be sent. Required if token source is "From Input Data". Default is http://localhost:8081.
Access Token The access token used for authentication, either entered directly or taken from input data. Required if token source is "From Input Data". Supports expressions like {{ $json.accessToken }}.

Output

The node outputs JSON data indicating the result of the logout operation. The structure includes:

  • success: A boolean indicating whether the logout was successful.
  • message: A string message confirming the logout status, e.g., "Logged out successfully".

No binary data output is produced by this node.

Example output JSON:

{
  "success": true,
  "message": "Logged out successfully"
}

Dependencies

  • Requires an active connection to the Mira App Server.
  • Needs a valid access token, either provided via credentials or input data.
  • No additional external services or environment variables are required beyond the Mira server URL and token.

Troubleshooting

  • Invalid or expired token: If the token is invalid or already revoked, the logout may fail. Ensure the token is current and correctly provided.
  • Server URL incorrect or unreachable: Verify the Mira App Server URL is correct and accessible from the n8n instance.
  • Missing token: When using "From Input Data" as token source, ensure the access token property is set and correctly passed.
  • Network issues: Check network connectivity and firewall settings if requests time out or fail.

Common error messages might relate to authentication failures or connection errors. Resolving these typically involves verifying token validity and server accessibility.

Links and References

  • Mira App Server API documentation (for authentication endpoints)
  • n8n documentation on credential management and HTTP request nodes

Discussion