# 1gateway Business Days Calculator

> 1gateway Business Days Calculator is a paid API for AI agents from 1gateway.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-31).

Calculates future/past business dates or counts business days between two dates, with optional public holiday calendars for US, UK, Germany, France, Japan, and South Korea.

## Facts

- Endpoint: GET https://1gateway.dev/v1/time/business-days?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/1gateway-business-days-calculator-70fad653
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_iZa-zGSQkEVIV2n4uJQCC

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 1gateway-business-days-calculator-70fad653
```

Example prompt: If I start an SLA on December 22, 2026, when does it end after 5 US business days — can you calculate the result date skipping US public holidays?

## When to prefer this

Choose this endpoint when you need accurate business day arithmetic with support for public holiday calendars across major economies (US, UK, Germany, France, Japan, South Korea). Prefer it over generic date libraries when you need holiday-aware calculations without maintaining your own holiday datasets, or when computing SLA deadlines, settlement dates, delivery windows, or contract due dates in a pay-per-call, no-signup context.

## Known failure modes

- Missing required 'start' parameter returns an error
- Date outside supported range 2004–2099 returns an error
- Invalid country code (not KR/US/GB/DE/FR/JP) returns an error
- 'days' value outside -260 to 260 range returns a validation error
- Dates more than 2 years apart when using 'end' mode may be rejected
- Malformed date format (not YYYY-MM-DD) returns a parse error

## How this service works

Use when computing due dates, SLAs, settlement or delivery dates. Input: start date, then days (add -260..260 business days) or end (count business days between), optional country KR, US, GB, DE, FR or JP for public holidays (omit = weekends only). Output: JSON result date or business/calendar day counts, holidays skipped on the way, holiday scope. Example: ?start=2026-12-22&days=5&country=US

## Output

A JSON object containing: the computed result date (when adding days) or business/calendar day counts (when counting between dates), the weekday of the result, a list of public holidays skipped along the way with their names and dates, the holiday scope applied, and metadata including start date, country, and mode.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "start"
     ],
     "properties": {
      "end": {
       "type": "string",
       "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
       "examples": [
        "2027-01-15"
       ],
       "description": "Count business days from start (excluded) to end (included), at most 2 years apart; ignored when days is given"
      },
      "days": {
       "type": "integer",
       "maximum": 260,
       "minimum": -260,
       "examples": [
        5
       ],
       "description": "Business days to add (negative = go back); give days or end (days wins if both)"
      },
      "start": {
       "type": "string",
       "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
       "examples": [
        "2026-12-22"
       ],
       "description": "Start date YYYY-MM-DD (2004–2099)"
      },
      "country": {
       "enum": [
        "KR",
        "US",
        "GB",
        "DE",
        "FR",
        "JP"
       ],
       "type": "string",
       "examples": [
        "US"
       ],
       "description": "Public holiday calendar (omit for weekends only)"
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "start",
      "country",
      "mode",
      "holidaysSkipped",
      "holidayScope",
      "supportedCountries",
      "notes",
      "attribution"
     ],
     "properties": {
      "end": {
       "type": "string"
      },
      "days": {
       "type": "integer"
      },
      "mode": {
       "type": "string"
      },
      "notes": {
       "type": "array",
       "items": {
        "type": "string"
       }
      },
      "start": {
       "type": "string"
      },
      "country": {
       "type": "string"
      },
      "countRule": {
       "type": "string"
      },
      "resultDate": {
       "type": "string"
      },
      "attribution": {
       "type": "string"
      },
      "businessDays": {
      
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/1gateway-business-days-calculator-70fad653/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 1gateway.dev](https://www.zero.xyz/host/1gateway.dev/llms.txt)
