Skip to main content
Glama

Finish OAuth

immich_finish_o_auth

Complete OAuth callback for Immich by exchanging the authorization code for a session token.

Instructions

Finish OAuth

Complete the OAuth authorization process by exchanging the authorization code for a session token.

Immich operation: POST /oauth/callback · tag: Authentication

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesurl (request body)
stateNostate (request body)
codeVerifierNocodeVerifier (request body)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=false, idempotentHint=false and openWorldHint=true, so the safety profile is covered. The description adds real value beyond those flags by disclosing the mechanics and outcome: an authorization code is exchanged for a session token, which explains why the call is stateful and non-idempotent. It still omits error behavior and any auth/rate-limit considerations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The substance is a single front-loaded sentence and the operation metadata (POST /oauth/callback, tag) is compact provenance. The opening line repeats the title 'Finish OAuth' verbatim, which is minor waste, but overall the entry is tight.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 3-parameter auth endpoint with no output schema and no nested objects, the description is adequate on purpose but leaves gaps: it doesn't say how the resulting session token is returned or consumed, nor how it relates to start_o_auth/redirect_o_auth_to_mobile in the flow. Something more on the flow position and result would complete it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is nominally 100%, but the schema 'descriptions' are only bare names plus '(request body)' for url, state and codeVerifier, adding no semantics. The description's reference to exchanging an authorization code loosely maps to codeVerifier/state but does not genuinely clarify parameter roles, so the baseline 3 for high coverage applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource ('Complete the OAuth authorization process') and adds the mechanism ('exchanging the authorization code for a session token'), so the agent understands this is the callback/final step. It does not explicitly differentiate from the closest siblings such as immich_start_o_auth or immich_logout_o_auth, but the exchange framing makes the role reasonably clear.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'Complete the OAuth authorization process' implies this is invoked as the second step after starting OAuth, which is useful implied context. However, no alternative is named (e.g. start_o_auth vs. these callbacks), no prerequisites are stated, and there is no explicit when-not guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools