Skip to main content
Glama

Get Time By Timezone

get_time_by_timezone
Read-onlyIdempotent

Get the current date and time in a specific IANA timezone (e.g. "America/New_York", "Europe/London", "Asia/Tokyo").

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "timezone": "America/New_York"
    },
    "name": "get_time_by_timezone"
  }
}

Input Schema

NameRequiredDescriptionDefault
timezoneYesIANA timezone string, e.g. "America/New_York"

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedOutput schema / oneOf
      Added value: +[
      +  {
      +    "properties": {
      +      "datetime": {
      +        "description": "ISO 8601 datetime in the requested timezone",
      +        "type": "string"
      +      },
      +      "day_of_week": {
      +        "description": "Day of week (0-6)",
      +        "type": "number"
      +      },
      +      "day_of_year": {
      +        "description": "Day of year (1-366)",
      +        "type": "number"
      +      },
      +      "found": {
      +        "description": "Present and true on an answer; a miss is the found:false branch.",
      +        "enum": [
      +          true
      +        ],
      +        "type": "boolean"
      +      },
      +      "is_dst": {
      +        "type": "boolean"
      +      },
      +      "timezone": {
      +        "description": "IANA timezone name",
      +        "type": "string"
      +      },
      +      "utc_offset": {
      +        "description": "UTC offset in ±HH:MM format",
      +        "type": "string"
      +      },
      +      "week_number": {
      +        "description": "Week number of the year",
      +        "type": "number"
      +      }
      +    },
      +    "required": [
      +      "datetime",
      +      "timezone",
      +      "utc_offset"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "description": "A miss or an unavailable upstream: found:false with a reason and a hint (the shape check-found-false-schemas.mjs expects).",
      +    "properties": {
      +      "found": {
      +        "enum": [
      +          false
      +        ],
      +        "type": "boolean"
      +      }
      +    },
      +    "required": [
      +      "found"
      +    ],
      +    "type": "object"
      +  }
      +]
    • removedOutput schema / properties
      Removed value: -{
      -  "datetime": {
      -    "description": "ISO 8601 datetime in the requested timezone",
      -    "type": "string"
      -  },
      -  "day_of_week": {
      -    "description": "Day of week (0-6)",
      -    "type": "number"
      -  },
      -  "day_of_year": {
      -    "description": "Day of year (1-366)",
      -    "type": "number"
      -  },
      -  "is_dst": {
      -    "type": "boolean"
      -  },
      -  "timezone": {
      -    "description": "IANA timezone name",
      -    "type": "string"
      -  },
      -  "utc_offset": {
      -    "description": "UTC offset in ±HH:MM format",
      -    "type": "string"
      -  },
      -  "week_number": {
      -    "description": "Week number of the year",
      -    "type": "number"
      -  }
      -}
    • removedOutput schema / required
      Removed value: -[
      -  "datetime",
      -  "timezone",
      -  "utc_offset"
      -]
  2. Changed2 schema fields changed
    • addedOutput schema / properties / is_dst
      Added value: +{
      +  "type": "boolean"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "datetime",
      -  "timezone",
      -  "utc_offset",
      -  "day_of_week",
      -  "day_of_year",
      -  "week_number"
      -]New value: +[
      +  "datetime",
      +  "timezone",
      +  "utc_offset"
      +]
  3. Added
  4. Removed
  5. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so safety is covered elsewhere. The description adds only the IANA-format expectation; it says nothing about output shape or how 'now' is resolved, though an output schema exists.

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?

One front-loaded sentence with the key constraint (IANA timezone) stated immediately and no padding. Slightly redundant examples cost it nothing meaningful, but it is thin on routing information.

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?

With one documented parameter, a full annotation set and an output schema, the definition is minimally sufficient to call correctly. It leaves an agent without a rule for choosing among the closely related time siblings, which is the main missing context.

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 the sole parameter is already documented with the same 'America/New_York' example. The parenthetical examples repeat rather than extend the schema, so this sits at the baseline for fully covered schemas.

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?

Specific verb plus resource: get the current date and time in a named IANA timezone, with concrete example values. It implicitly contrasts with get_time_by_ip and convert_time, but never names or distinguishes them explicitly.

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 only implied: supply a timezone you already know. It gives no guidance on when to prefer get_time_by_ip (timezone unknown, derived from IP) or convert_time (arithmetic rather than current time), and does not point at list_timezones for discovering valid IDs.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.