Lectful icon

Lectful

Interact with the VIPay Lectful API

Overview

The "Logout" operation of the "Authentication" resource in this Lectful node invalidates the current authentication token for the user. This effectively logs the user out from the Lectful API session, ensuring that subsequent requests require re-authentication.

This operation is useful in scenarios where you want to programmatically end a user's session, such as:

  • Logging out users after completing certain workflows.
  • Ensuring security by invalidating tokens when no longer needed.
  • Managing sessions in automated processes or integrations.

Example use case: After performing actions on behalf of a user, you can call the Logout operation to invalidate their token and prevent further API access without re-login.

Properties

Name Meaning
Authentication Mode Choose how to authenticate with the Lectful API:
- Use Stored Credentials
- Manual Configuration (provide base URL and API key manually)
Credentials Note Notice shown only if Manual Configuration is selected, explaining that credentials field can be left empty and overrides will be used instead.
Base URL Override Optional base URL to override the credential setting (without /api/v1). Used only in Manual Configuration mode.
API Key Override Optional API key to override the credential setting. Used only in Manual Configuration mode.

Output

The output JSON contains the response from the Lectful API after attempting to log out. Typically, this will be an object indicating success or failure of the logout request. The exact structure depends on the API's response but generally confirms that the token has been invalidated.

No binary data is output by this operation.

Example output JSON might look like:

{
  "message": "Successfully logged out"
}

or an error message if logout failed.

Dependencies

  • Requires valid API authentication either via stored credentials configured in n8n or manual configuration providing the base URL and API key.
  • The node uses HTTP POST request to the /auth/logout endpoint of the Lectful API.
  • No additional external dependencies beyond the Lectful API and proper authentication.

Troubleshooting

  • Missing or Invalid Credentials: If neither stored credentials nor manual overrides are provided correctly, the node will throw an error indicating missing or invalid credentials. Ensure credentials are set up properly or manual parameters are filled.
  • Base URL or API Key Missing in Manual Mode: When using Manual Configuration mode, both Base URL Override and API Key Override must be provided; otherwise, an error is thrown.
  • API Errors: If the API returns an error (e.g., token already invalidated or expired), the node will pass the error message in the output JSON. Check the API documentation for specific error codes.
  • Network Issues: Connectivity problems may cause request failures. Verify network access to the Lectful API endpoint.

Links and References


This summary focuses exclusively on the "Authentication" resource and "Logout" operation as requested.

Discussion