Skip to main content
Glama

Unix Epoch Converter

epoch_convert
Read-onlyIdempotent

Convert between Unix timestamps and dates. Converts a Unix timestamp (seconds or milliseconds, detected by size) or an ISO 8601 date string to epoch seconds, epoch milliseconds, an ISO UTC time, the same moment in an optional IANA time zone, and the weekday there. A date string with no offset is read in the given zone, UTC by default. Pure standard-library rules, no network, model or clock.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tzNoOptional IANA time zone name such as America/New_York. Default UTC. Used for iso_in_tz and weekday, and as the zone of a date string that has no offset of its own.
unitNoOptional. Force a numeric value to be read as seconds (s) or milliseconds (ms) instead of auto-detecting.
valueYesRequired. A Unix timestamp (number or digits; seconds or milliseconds are detected by size) or an ISO 8601 date or date-time string such as 2024-03-10 or 2024-03-10T14:30:00-05:00.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already establish readOnly, idempotent, non-destructive, and closed-world behavior. The description adds genuinely beyond that: it discloses automatic unit detection by magnitude and that zone-less strings are interpreted in the supplied zone, plus the guarantee of no network/model/clock dependence. It stops short of describing output shape or error behavior.

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?

Three tight sentences with the core action front-loaded and details following in descending priority; no filler sentences. Dense but each clause (unit detection, zone defaults, output list) carries information.

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?

With no output schema, the description correctly enumerates the returned values (epoch seconds, epoch ms, ISO UTC, same moment in tz, weekday). Combined with the 100%-covered schema and affirmative annotations, an agent has everything needed to invoke it correctly.

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 coverage is 100%, so a 3 is the baseline, but the description adds real interpretive rules: numeric values are auto-detected as seconds or milliseconds by size, and the zone applies both to zone-less date strings and to the tz-relative outputs. That interaction between tz and value is the kind of semantics the schema only partially conveys.

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?

States a specific verb and resource ('Convert between Unix timestamps and dates') and enumerates the exact conversion direction and outputs. It is easily distinguished from neighbors like julian_day_convert, date_calculator, and hours_calculator without opening any schema.

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 description implies the use case (converting epoch <-> ISO dates) but never names when to prefer this over date_calculator or julian_day_convert, nor any exclusions. The 'Pure standard-library rules, no network, model or clock' note gives useful context about determinism but is not routing guidance.

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.

Resources