logout_of_adeu_cloud
Clears the locally stored API key from the OS Keychain to log out of the cloud backend, ending the authenticated session.
Instructions
Logs out of the Adeu Cloud backend by clearing the local API key from the OS Keychain.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- Handler function for the logout_of_adeu_cloud tool. It clears the local API key from the OS Keychain via DesktopAuthManager.clear_api_key() and returns a success message.
@tool( description="Logs out of the Adeu Cloud backend by clearing the local API key from the OS Keychain.", annotations={"openWorldHint": True}, ) async def logout_of_adeu_cloud(ctx: Context) -> str: await ctx.info("Initiating cloud session logout") try: DesktopAuthManager.clear_api_key() await ctx.debug("API key cleared from OS Keychain successfully") return "Successfully logged out. The local API key has been removed from the Keychain." except Exception as e: await ctx.error("Failed to clear API key during logout", extra={"error": str(e)}) raise ToolError(f"Error during logout: {str(e)}") from e - src/adeu/mcp_components/tools/auth.py:67-70 (registration)The @tool decorator registers logout_of_adeu_cloud as an MCP tool with its description and openWorldHint annotation.
@tool( description="Logs out of the Adeu Cloud backend by clearing the local API key from the OS Keychain.", annotations={"openWorldHint": True}, ) - Calls DesktopAuthManager.clear_api_key() which is the helper that actually removes the API key from the OS Keychain.
DesktopAuthManager.clear_api_key() await ctx.debug("API key cleared from OS Keychain successfully") return "Successfully logged out. The local API key has been removed from the Keychain." except Exception as e: await ctx.error("Failed to clear API key during logout", extra={"error": str(e)}) raise ToolError(f"Error during logout: {str(e)}") from e - The function signature shows it takes a Context object and returns a string. No additional input schema is defined.
async def logout_of_adeu_cloud(ctx: Context) -> str: