Skip to main content
Glama

Get Relative Time

relative_time

Calculates the relative time from now to a given time string.

Input Schema

NameRequiredDescriptionDefault
timeYesThe time to compare. Format: YYYY-MM-DD HH:mm:ss

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / time / description
      Previous value: -"The time to compare (format: YYYY-MM-DD HH:mm:ss)"New value: +"The time to compare. Format: YYYY-MM-DD HH:mm:ss"
    • changedOutput schema / (root)
      Previous value: -{
      -  "$schema": "http://json-schema.org/draft-07/schema#",
      -  "additionalProperties": false,
      -  "properties": {
      -    "relativeTime": {
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "relativeTime"
      -  ],
      -  "type": "object"
      -}New value: +null
  2. Changed4 schema fields changed
    • addedInput schema / $schema
      Added value: +"http://json-schema.org/draft-07/schema#"
    • addedInput schema / additionalProperties
      Added value: +false
    • changedInput schema / properties / time / description
      Previous value: -"The time to compare. Format: YYYY-MM-DD HH:mm:ss"New value: +"The time to compare (format: YYYY-MM-DD HH:mm:ss)"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "relativeTime": {
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "relativeTime"
      +  ],
      +  "type": "object"
      +}
  3. First observed

TDQS

B3.2/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. 'Calculates... from now' usefully signals a read-only, pure computation anchored to the current moment. However, it does not disclose the return format (e.g., '3 days ago' vs. a seconds count) or timezone assumptions for parsing the input string, which matter for a time tool with no output schema.

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 efficient sentence with the core operation front-loaded and no filler. It is quite terse, but nothing is wasted.

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 simple single-parameter tool this covers the input well, but with no output schema and no annotations the description should say what value comes back (human-readable string? duration?) and how the input timestamp's timezone is interpreted. Those omissions leave meaningful ambiguity for an agent.

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?

The single parameter has 100% schema description coverage including the exact format string, so the schema already does the heavy lifting. The description adds only that the time is compared against 'now', which is modest added value.

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?

States a specific verb ('Calculates') and resource ('relative time from now to a given time string'), which is enough to distinguish it from siblings like current_time and convert_time. It does not explicitly name those siblings, but the operation is unambiguous.

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

Usage Guidelines2/5

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

There is no guidance on when to use this tool versus convert_time or get_timestamp, and no mention of when not to use it. The agent must infer the use case from the verb alone.

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.