# Basic Utils Agent — Datetime Subtract

> Basic Utils Agent — Datetime Subtract is a paid API for AI agents from basic-utils-agent.up.railway.app, paid per call via x402, $0.0015/call, status unknown (last checked 2026-09-14).

Subtracts a specified number of days from a given datetime, returning the resulting datetime value.

## Facts

- Endpoint: POST https://basic-utils-agent.up.railway.app/datetime/subtract
- Price: $0.0015/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/basic-utils-agent-datetime-subtract-b363e64b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ebKLH9UNt_GvU6SH0VkZA

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 basic-utils-agent-datetime-subtract-b363e64b -d '<json body>'
```

Example prompt: What date and time is 45 days before 2025-03-15T00:00:00?

## When to prefer this

Use this endpoint when you need a lightweight, pay-per-call date arithmetic service to compute a past datetime by subtracting a whole number of days from a known base datetime. Prefer this over general-purpose libraries when operating inside an agent workflow that already uses the x402 micropayment stack, or when you need a remote stateless computation without local date handling dependencies.

## Known failure modes

- Missing required 'date' field returns an error or null result
- Missing required 'days' field returns an error or null result
- Invalid date format (non-ISO 8601) may cause a parse error
- Non-integer 'days' value may be rejected
- Extremely large day values may produce unexpected results

## How this service works

A versatile utility agent offering calculator, statistics, datetime, and unit conversion services.

## Output

A JSON object with a 'result' field containing the computed datetime string (ISO 8601 format) after subtracting the specified number of days from the base date, e.g. {"result": "2024-01-01T00:00:00"}.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "date": {
   "anyOf": [
    {
     "type": "string",
     "format": "date-time"
    },
    {
     "type": "null"
    }
   ],
   "default": null,
   "description": "The base date for the operation (required for add, subtract, difference, and day-of-week operations)"
  },
  "days": {
   "anyOf": [
    {
     "type": "integer"
    },
    {
     "type": "null"
    }
   ],
   "default": null,
   "description": "Number of days to add or subtract from the date (required for add and subtract operations)"
  },
  "date2": {
   "anyOf": [
    {
     "type": "string",
     "format": "date-time"
    },
    {
     "type": "null"
    }
   ],
   "default": null,
   "description": "The second date for difference calculation (required for difference operation)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "result": "2024-01-01T00:00:00"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/basic-utils-agent-datetime-subtract-b363e64b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from basic-utils-agent.up.railway.app](https://www.zero.xyz/host/basic-utils-agent.up.railway.app/llms.txt)
