/calendar • v1.2.0

ContextAPI Business Calendar, ISDA Roll & SLA API

Replaces brittle local holiday tables and LLM date guesswork. Deterministic working-day arithmetic across 150+ countries, state subdivisions, municipal UN/LOCODEs, and financial exchanges (XNYS, XLON, XECB, BVC, XSIF), paired with ISDA date rolling, Day-Count Fractions, and cryptographic decree provenance.

150+ Statutory JurisdictionsTARGET2 & FED ReconciledUp to 1,000 Batch Ops / Call

Core REST Endpoints

Authenticate with X-API-Key. Canonical base: https://api.contextapi.dev/calendar (root /v1/* alias also supported).

1 Credit / Call
Method Path Cost Capabilities
GET /v1/business-days/add 1 credit Add or subtract working days honoring national, state, UN/LOCODE city, and exchange closures.
GET /v1/business-days/diff 1 credit Count business days between two ISO dates with skipped holidays and China tiaoxiu make-up workdays.
POST /v1/business-days/joint 1 credit Evaluate up to 25 jurisdictions simultaneously (settlement_condition: "all" | "any").
POST/GET /v1/financial/roll-date 1 credit ISDA conventions (modified_following, following, preceding, modified_preceding, nearest, EOM).
GET /v1/financial/day-count 1 credit Institutional accrual fractions: ACT/360, ACT/365, ACT/ACT, 30/360, 30E/360.
POST /v1/business-days/batch ceil(ops / 10) Execute up to 1,000 heterogeneous operations in a single HTTP request.
POST /v1/sla/calculate 1 credit Working-hours SLA breach timestamps with split shifts, half-days, GCC Ramadan caps, and IANA DST.
GET /v1/provenance/reconcile 1 credit Central bank clearing alignment audit for TARGET2 and FED.

Quickstart & Hosted MCP Integration

Call directly over HTTPS or connect AI agents to https://api.contextapi.dev/calendar/mcp.

Quickstart — Joint Cross-Border Settlement

curl -X POST "https://api.contextapi.dev/calendar/v1/business-days/joint" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "start_date": "2026-04-02",
    "days": 2,
    "settlement_condition": "all",
    "jurisdictions": [
      {"country": "US", "market": "XNYS"},
      {"country": "GB", "market": "XLON"},
      {"country": "JP"}
    ]
  }'
→ {"target_date": "2026-04-08", "skipped_holidays": ["Good Friday", "Easter Monday"], "provenance": {"sha256": "..."}}

Hosted Streamable HTTP MCP (11 Tools + Resource)

Register in .cursor/mcp.json (or use npx -y mcp-remote for Claude Desktop):

{
  "mcpServers": {
    "contextapi-calendar": {
      "url": "https://api.contextapi.dev/calendar/mcp",
      "headers": { "X-API-Key": "${CONTEXTAPI_API_KEY}" }
    }
  }
}
  • context_add_business_daysTool

    Adds or subtracts business days across 150+ statutory and exchange calendars so agents never miscalculate settlement or delivery dates.

  • context_count_business_daysTool

    Counts exact working days between two dates for accurate billing, interest, and compliance windows.

  • context_joint_business_daysTool

    Finds days open across multiple countries or exchanges simultaneously for cross-border settlement.

  • context_roll_financial_dateTool

    Applies ISDA roll conventions (Following, Modified Following, Preceding) for deterministic financial schedules.

  • context_day_count_fractionTool

    Computes exact ACT/360, ACT/365, and 30/360 year fractions for interest and coupon calculations.

  • context_calculate_sla_deadlineTool

    Calculates exact SLA breach deadlines respecting business hours, weekends, and local public holidays.

  • context_convert_timezoneTool

    Converts timestamps cleanly across IANA timezones without LLM date-math errors.

  • context_detect_dst_shiftsTool

    Detects Daylight Saving Time transitions so scheduled jobs and SLAs handle 23- and 25-hour days safely.

  • context_list_holidaysTool

    Lists statutory and market holidays for any supported jurisdiction or exchange.

  • context_batch_calculateTool

    Runs multiple calendar calculations in a single call for bulk schedule generation.

  • context_reconcile_clearing_calendarTool

    Reconciles clearing dates across counterparties and settlement venues.

  • contextcalendar://provenance/statusResource

    Exposes calendar data provenance, version, and service readiness for agent verification.