# HTTPay Timestamp API

> HTTPay Timestamp API is a paid API for AI agents from httpay.xyz, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Returns the current UTC timestamp in ISO 8601, Unix epoch, relative, or all formats; can also convert a given Unix timestamp to multiple formats

## Facts

- Endpoint: POST https://httpay.xyz/api/timestamp
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/httpay-timestamp-api-1297d9da
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_V63Sz-0MTRI--7hHmI6Wd

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability httpay-timestamp-api-1297d9da -d '<json body>'
```

Example prompt: What's the current UTC timestamp in all formats — ISO 8601, Unix, and relative?

## When to prefer this

Use this endpoint when you need a server-authoritative current UTC timestamp without setting up API keys or subscriptions, especially in agentic workflows requiring micropayment-based access. Prefer over client-side Date objects when you need a trusted, server-side time source. Also useful for quick Unix-to-ISO or Unix-to-relative timestamp conversions at minimal cost ($0.001 per call).

## Known failure modes

- Invalid format parameter returns an error or falls back to default 'all'
- Malformed ?ts value (non-numeric or out-of-range) may return an error or unexpected result
- Payment not included or invalid x402 USDC payment on Base returns 402 Payment Required
- Network timeout returns 5xx error

## How this service works

Get current UTC timestamp in multiple formats (ISO 8601, Unix, relative). Pass ?format=iso|unix|relative|all (default: all). Pass ?ts=<unix-seconds> to convert a specific Unix timestamp. Uses Node.js built-in Date.

## Output

A JSON object containing the current UTC time expressed in one or more formats: ISO 8601 string, Unix epoch integer (seconds), and/or relative time string (e.g. '5 seconds ago'), depending on the ?format parameter. If a ?ts Unix timestamp is provided, converts that specific moment instead of now.

## Example request

```json
{}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "description": "Get current UTC timestamp in multiple formats (ISO 8601, Unix, relative). Pass ?format=iso|unix|relative|all (default: all). Pass ?ts=<unix-seconds> to convert a specific Unix timestamp. Uses Node.js built-in Date."
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/httpay-timestamp-api-1297d9da/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from httpay.xyz](https://www.zero.xyz/host/httpay.xyz/llms.txt)
