Skip to main content
Glama

check_session

Read-only

Verifies saved Amazon sessions are still valid, checks a specified site or all saved sites, and shows the default site and saved accounts.

Instructions

Check with Amazon whether the user's saved sessions still work: on site, or else on their default site and every other Amazon site they have a saved session for. Also says which site is the default, and lists the user's accounts.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "check_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteNoThe Amazon site to check, e.g. `amazon.de`. By default, the default site and every other site with a saved session are checked.
accountNoThe Amazon account to check, e.g. `spouse`. By default, the default account.

Output Schema

NameRequiredDescriptionDefault
siteYesThe Amazon site, as `site` accepts it.
errorNoWhy the session couldn't be checked, if it couldn't. `signed_in` is null then.
sitesYesEvery site checked: the one asked about, or else the default site and every other site with a saved session.
accountYesThe Amazon account checked, as `account` accepts it.
defaultYesWhether it's the user's default site, which tools read when they aren't given `site`.
sign_inNoWhat to do to sign in, if the user isn't.
accountsYesEvery Amazon account with a saved session, the default one first.
signed_inYesWhether Amazon still accepts the user's saved session for the site. If Amazon answers the check with an error page, a saved session is assumed to still work. Null if the session couldn't be checked at all.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv2.4.0
    • addedInput schema / properties / account
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "The Amazon account to check, e.g. `spouse`. By default, the default account."
      +}
    • addedOutput schema / properties / account
      Added value: +{
      +  "description": "The Amazon account checked, as `account` accepts it.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / accounts
      Added value: +{
      +  "description": "Every Amazon account with a saved session, the default one first.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "signed_in",
      -  "site",
      -  "default",
      -  "sites"
      -]New value: +[
      +  "signed_in",
      +  "site",
      +  "default",
      +  "sites",
      +  "account",
      +  "accounts"
      +]
  2. Changed14 schema fields changedv2.1.2
    • removedInput schema / properties / site / title
      Removed value: -"Site"
    • removedOutput schema / $defs
      Removed value: -{
      -  "SiteSessionStatus": {
      -    "description": "The user's session status on an Amazon site.",
      -    "properties": {
      -      "default": {
      -        "description": "Whether it's the user's default site, which tools read when they aren't given `site`.",
      -        "title": "Default",
      -        "type": "boolean"
      -      },
      -      "error": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "description": "Why the session couldn't be checked, if it couldn't. `signed_in` is null then.",
      -        "title": "Error"
      -      },
      -      "sign_in": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "description": "What to do to sign in, if the user isn't.",
      -        "title": "Sign In"
      -      },
      -      "signed_in": {
      -        "anyOf": [
      -          {
      -            "type": "boolean"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Whether Amazon still accepts the user's saved session for the site. If Amazon answers the check with an error page, a saved session is assumed to still work. Null if the session couldn't be checked at all.",
      -        "title": "Signed In"
      -      },
      -      "site": {
      -        "description": "The Amazon site, as `site` accepts it.",
      -        "title": "Site",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "signed_in",
      -      "site",
      -      "default"
      -    ],
      -    "title": "SiteSessionStatus",
      -    "type": "object"
      -  }
      -}
    • removedOutput schema / properties / default / title
      Removed value: -"Default"
    • removedOutput schema / properties / error / title
      Removed value: -"Error"
    • removedOutput schema / properties / sign_in / title
      Removed value: -"Sign In"
    • removedOutput schema / properties / signed_in / title
      Removed value: -"Signed In"
    • removedOutput schema / properties / site / title
      Removed value: -"Site"
    • removedOutput schema / properties / sites / items / $ref
      Removed value: -"#/$defs/SiteSessionStatus"
    • addedOutput schema / properties / sites / items / description
      Added value: +"The user's session status on an Amazon site."
    • addedOutput schema / properties / sites / items / properties
      Added value: +{
      +  "default": {
      +    "description": "Whether it's the user's default site, which tools read when they aren't given `site`.",
      +    "type": "boolean"
      +  },
      +  "error": {
      +    "anyOf": [
      +      {
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ],
      +    "default": null,
      +    "description": "Why the session couldn't be checked, if it couldn't. `signed_in` is null then."
      +  },
      +  "sign_in": {
      +    "anyOf": [
      +      {
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ],
      +    "default": null,
      +    "description": "What to do to sign in, if the user isn't."
      +  },
      +  "signed_in": {
      +    "anyOf": [
      +      {
      +        "type": "boolean"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ],
      +    "description": "Whether Amazon still accepts the user's saved session for the site. If Amazon answers the check with an error page, a saved session is assumed to still work. Null if the session couldn't be checked at all."
      +  },
      +  "site": {
      +    "description": "The Amazon site, as `site` accepts it.",
      +    "type": "string"
      +  }
      +}
    • addedOutput schema / properties / sites / items / required
      Added value: +[
      +  "signed_in",
      +  "site",
      +  "default"
      +]
    • addedOutput schema / properties / sites / items / title
      Added value: +"SiteSessionStatus"
    • addedOutput schema / properties / sites / items / type
      Added value: +"object"
    • removedOutput schema / properties / sites / title
      Removed value: -"Sites"
  3. Changed11 schema fields changedv1.4.2
    • addedInput schema / properties / site
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "The Amazon site to check, e.g. `amazon.de`. By default, the default site and every other site with a saved session are checked.",
      +  "title": "Site"
      +}
    • addedOutput schema / $defs
      Added value: +{
      +  "SiteSessionStatus": {
      +    "description": "The user's session status on an Amazon site.",
      +    "properties": {
      +      "default": {
      +        "description": "Whether it's the user's default site, which tools read when they aren't given `site`.",
      +        "title": "Default",
      +        "type": "boolean"
      +      },
      +      "error": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "default": null,
      +        "description": "Why the session couldn't be checked, if it couldn't. `signed_in` is null then.",
      +        "title": "Error"
      +      },
      +      "sign_in": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "default": null,
      +        "description": "What to do to sign in, if the user isn't.",
      +        "title": "Sign In"
      +      },
      +      "signed_in": {
      +        "anyOf": [
      +          {
      +            "type": "boolean"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "description": "Whether Amazon still accepts the user's saved session for the site. If Amazon answers the check with an error page, a saved session is assumed to still work. Null if the session couldn't be checked at all.",
      +        "title": "Signed In"
      +      },
      +      "site": {
      +        "description": "The Amazon site, as `site` accepts it.",
      +        "title": "Site",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "signed_in",
      +      "site",
      +      "default"
      +    ],
      +    "title": "SiteSessionStatus",
      +    "type": "object"
      +  }
      +}
    • changedOutput schema / description
      Previous value: -"The user's Amazon session status, returned by the ``check_session`` tool."New value: +"The user's Amazon session status, returned by the ``check_session`` and ``sign_in`` tools: for the site asked\nabout, or else the default site, and for every site checked."
    • addedOutput schema / properties / default
      Added value: +{
      +  "description": "Whether it's the user's default site, which tools read when they aren't given `site`.",
      +  "title": "Default",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / error
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Why the session couldn't be checked, if it couldn't. `signed_in` is null then.",
      +  "title": "Error"
      +}
    • addedOutput schema / properties / signed_in / anyOf
      Added value: +[
      +  {
      +    "type": "boolean"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / properties / signed_in / description
      Previous value: -"Whether Amazon still accepts the user's saved session. If Amazon couldn't be reached to check, a saved session is assumed to still work."New value: +"Whether Amazon still accepts the user's saved session for the site. If Amazon answers the check with an error page, a saved session is assumed to still work. Null if the session couldn't be checked at all."
    • removedOutput schema / properties / signed_in / type
      Removed value: -"boolean"
    • changedOutput schema / properties / site / description
      Previous value: -"The Amazon site the server is set to read."New value: +"The Amazon site, as `site` accepts it."
    • addedOutput schema / properties / sites
      Added value: +{
      +  "description": "Every site checked: the one asked about, or else the default site and every other site with a saved session.",
      +  "items": {
      +    "$ref": "#/$defs/SiteSessionStatus"
      +  },
      +  "title": "Sites",
      +  "type": "array"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "signed_in",
      -  "site"
      -]New value: +[
      +  "signed_in",
      +  "site",
      +  "default",
      +  "sites"
      +]
  4. First observedv1.2.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and openWorldHint, so the safety profile is covered. The description adds meaningful context beyond that: it reaches out to Amazon, it cascades across the default site and all sites with saved sessions, and it returns the default site plus the account list. It stops short of saying what a failed/invalid session looks like in the response.

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?

Two sentences, front-loaded with the core action and immediately followed by the scoping rule and the extra outputs. No filler, though the clause structure ('on `site`, or else...') takes a moment to parse.

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

Completeness4/5

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

For a read-only, two-optional-parameter tool with a full output schema, the description covers scope, fallback behavior, and the nature of the returned data. The only gap is failure semantics: whether an expired session raises an error or is reported as a status per site.

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 100% and both optional parameters are already documented with their defaults in the schema. The description's phrasing about falling back to the default site and all other saved-session sites largely restates the schema, adding no syntax or edge-case detail about the account parameter.

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 names a specific verb+resource: verifying whether saved Amazon sessions still work, plus reporting the default site and account list. An agent can tell this apart from data-fetching siblings like get_orders or get_config, though it never explicitly contrasts itself with sign_in, the most plausible adjacent tool.

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?

Usage is implied rather than stated: you'd call this to validate session health or discover the default site/accounts. The description explains the default fallback behavior but gives no when-not guidance (e.g. use sign_in instead when no session exists) and doesn't say what to do with a failed check result.

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