Skip to main content
Glama

Sign In with Google

horizon_signin_google

Signs an existing Google player in by exchanging a fresh OAuth authorization code for a player session; use after a known user completes consent.

Instructions

Signs an existing Google player in by exchanging one fresh authorization code for a player session. Use when: a known Google player completes OAuth and requests signin. Not for: an unknown/new player: use horizon_signup_google with signInIfExists=true for one-click registration/signin instead of probing with this tool. Side effects: exchanges the Google code once and creates a session; no automatic signup, retries or provider UI. Returns: user details, authStatus: AUTHENTICATED and accessToken, plus refreshToken and both expiry timestamps only with includeRefreshToken=true. Errors: 404 USER_NOT_FOUND requires a fresh OAuth code before signup. Never reuse this code after an error or lost response. 400 for invalid provider data, 403 for an unavailable user. Needs HORIZON_API_KEY. Every failure returns an error result (isError) with the HTTP status and body: a 401 that horizon_test_connection also returns means HORIZON_API_KEY is wrong, 429 means the account's per-minute rate limit was reached (wait a minute, then retry).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "googleAuthorizationCode": "<googleAuthorizationCode>",
      "googleRedirectUri": "<googleRedirectUri>"
    },
    "name": "horizon_signin_google"
  }
}

Input Schema

NameRequiredDescriptionDefault
googleRedirectUriYesExact redirect URI used to obtain the Google authorization code; empty string for configured native flows (max 500 characters)
includeRefreshTokenNoExplicit opt-in to a rotating 30-day refresh session; omitted or false preserves access-only behavior. Store refresh tokens in platform secure storage
googleAuthorizationCodeYesFresh single-use Google authorization code obtained by the player's OAuth consent flow (max 2000 characters)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.11.1

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare this as non-read-only, non-idempotent, open-world, and non-destructive. The description adds substantial context beyond them: the authorization code is single-use, must never be reused after an error or lost response, a 404 requires a fresh OAuth code before signup, there is no automatic signup or retry, and 401/429 error semantics (API key problem vs per-minute rate limit) are spelled out. This is exactly the behavioral disclosure the annotations cannot carry.

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 description is front-loaded with purpose, then cleanly labeled into Use when / Not for / Side effects / Returns / Errors. It is longer than most, but for an auth exchange with single-use codes and specific error recovery paths, nearly every sentence earns its place. Slightly dense but well-structured.

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

Completeness5/5

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

For a non-idempotent auth tool with no output schema, the description covers prerequisites (HORIZON_API_KEY), return values (AUTHENTICATED, accessToken, optional refresh token), side effects, and the critical error-recovery path (404 USER_NOT_FOUND, 401, 429). An agent has everything needed to call it correctly and recover from failures.

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

Parameters4/5

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

Schema description coverage is 100%, so the schema already documents all three parameters well. The description adds return-shape meaning for includeRefreshToken (refreshToken and both expiry timestamps are returned only when true) and reinforces the single-use lifecycle of googleAuthorizationCode, which goes slightly beyond the schema text.

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

Purpose5/5

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

First sentence states a specific verb (signs in), resource (existing Google player), and mechanism (exchanging a fresh authorization code for a session). It also implicitly distinguishes from horizon_signup_google, which the usage section names explicitly, so an agent can route between them without opening schemas.

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

Usage Guidelines5/5

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

Provides explicit 'Use when' (known Google player completes OAuth) and 'Not for' (unknown/new player should use horizon_signup_google with signInIfExists=true). This is a clear when/when-not with a named alternative and the condition that selects it.

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