Skip to main content
Glama

timestamp_convert

Convert Unix timestamps to ISO 8601 dates and vice versa. Auto-detects input type and direction, accepts seconds or milliseconds.

Instructions

Convert between Unix timestamps (seconds) and ISO 8601 date strings. Auto-detects direction: numeric input → ISO string, date string input → Unix seconds. Accepts Unix in seconds or milliseconds (auto-detected by magnitude). Returns an error if the input cannot be parsed as a timestamp or date. Has no side effects. Free. Use when you need to convert epoch values to human-readable dates or vice-versa.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toNo"iso" to force output as ISO 8601, "unix" to force output as Unix seconds. Omit to auto-detect.
inputYesThe value to convert. Either a Unix timestamp (as a number or numeric string, seconds or ms) or an ISO/date string like "2024-01-15T10:30:00Z".
Behavior4/5

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

With no annotations, the description covers key behaviors: auto-detection of direction and input format (seconds/milliseconds), error handling ('Returns an error if input cannot be parsed'), and side-effect-free operation ('Has no side effects. Free.'). It does not detail rate limits or return format, but the tool is simple.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is five sentences, each providing essential information. It is front-loaded with the main purpose, and every sentence earns its place—no fluff or redundancy.

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 simple two-parameter tool with no output schema, the description covers input formats, auto-detection, error handling, side effects, and cost. It is complete and leaves no ambiguity about how the tool behaves.

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%, but the description adds value beyond it by explaining auto-detection logic and that Unix timestamps can be in seconds or milliseconds, auto-detected by magnitude. This helps the agent understand how to use the 'input' parameter correctly.

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?

The description explicitly states 'Convert between Unix timestamps (seconds) and ISO 8601 date strings', using a specific verb and resource. It clearly distinguishes from sibling tools like base64_encode or json_format, which handle different conversions.

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

Usage Guidelines4/5

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

The description explains auto-detection of direction and input formats, and provides a clear use case: 'Use when you need to convert epoch values to human-readable dates or vice-versa.' However, it does not explicitly state when not to use or mention alternatives, though the tool's simplicity makes this less critical.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/icosaedro-git/toolsnap-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server