# Date Math – iCalendar RRULE Recurrence Expander

> Date Math – iCalendar RRULE Recurrence Expander is a paid API for AI agents from date-math.datemath.workers.dev, paid per call via x402, $0.001/call, status unknown (last checked 2026-11-21).

Expands an iCalendar RRULE string into a list of concrete, timezone-aware occurrence dates and times, with DST handling and optional excluded dates.

## Facts

- Endpoint: POST https://date-math.datemath.workers.dev/v1/recurrence?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-21
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/date-math-icalendar-rrule-recurrence-expander-ae7a43c4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_e0uoIo-eQ72NYEyAZMJ-W

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 date-math-icalendar-rrule-recurrence-expander-ae7a43c4 -d '<json body>'
```

Example prompt: Expand the RRULE 'FREQ=MONTHLY;BYDAY=2TU' starting from 2026-01-01T10:00 in the Asia/Manila timezone and give me the next 5 occurrences, excluding 2026-03-10.

## When to prefer this

Use this endpoint when you need to materialize a recurring schedule from an iCalendar RRULE into actual concrete dates — especially when DST-aware local times matter, you need to skip specific excluded dates, or you need a human-readable English description of the recurrence pattern alongside the dates. Prefer it over cron-based tools when the input is iCal-format recurrence rules (e.g. from calendar apps or CalDAV systems).

## Known failure modes

- Invalid or malformed RRULE string returns an error
- Unsupported timezone identifier causes rejection
- Count exceeds maximum of 200 results in validation error
- Excluded date format not in YYYY-MM-DD causes parsing failure
- Start date/time not parseable in the given timezone returns error
- Missing required fields (rrule, start) return 400-level errors

## How this service works

Date Math: Expand a recurring event or iCalendar RRULE ("every 2nd Tuesday", "Mon/Wed until June") into concrete dates and times in a time zone, DST-aware, with optional excluded dates. Use for repeating meetings, calendar invites and schedules.

## Output

Returns a JSON object with the RRULE string, start, timezone, a human-readable description of the recurrence pattern, and an array of occurrences each containing UTC ISO 8601 datetime, local datetime with offset, date string (YYYY-MM-DD), and weekday name. Also echoes back the count requested.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "count": {
   "type": "integer",
   "maximum": 200,
   "minimum": 1,
   "description": "Default 10"
  },
  "rrule": {
   "type": "string",
   "example": "FREQ=MONTHLY;BYDAY=2TU",
   "description": "iCalendar RRULE (no DTSTART/TZID inside)"
  },
  "start": {
   "type": "string",
   "description": "Local start date or datetime in timezone, e.g. 2026-01-01T10:00"
  },
  "exclude": {
   "type": "array",
   "items": {
    "type": "string"
   },
   "description": "Local dates (YYYY-MM-DD) to skip"
  },
  "timezone": {
   "type": "string",
   "description": "Default UTC"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 3,
  "rrule": "FREQ=MONTHLY;BYDAY=2TU",
  "start": "2026-01-01T10:00",
  "timezone": "Asia/Manila",
  "description": "every month on the 2nd Tuesday",
  "occurrences": [
   {
    "utc": "2026-01-13T02:00:00Z",
    "date": "2026-01-13",
    "local": "2026-01-13T10:00:00+08:00",
    "weekday": "Tuesday"
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/date-math-icalendar-rrule-recurrence-expander-ae7a43c4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from date-math.datemath.workers.dev](https://www.zero.xyz/host/date-math.datemath.workers.dev/llms.txt)
