# Business Day Calculator API

> Business Day Calculator API is a paid API for AI agents from x402-ja-api.onrender.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-14).

Calculates business days for a given country and date, with support for holidays, custom weekends, and adding/subtracting business days.

## Facts

- Endpoint: GET https://x402-ja-api.onrender.com/v1/business-day
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/business-day-calculator-api-705318c2
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_L3t0lMHLu5VkaZltIKepG

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 business-day-calculator-api-705318c2
```

Example prompt: What date is 5 business days after December 24, 2026 in Germany? Use the standard calendar.

## When to prefer this

Choose this endpoint when you need to calculate business days across 200+ countries with accurate public holiday data, custom weekend configurations, or banking holiday support — especially when you need to add or subtract a specific number of business days from a date. It is ideal for scheduling, SLA tracking, financial settlement calculations, and delivery date estimation globally, and requires no API key (pay-per-call in USDC via x402).

## Known failure modes

- Missing required 'country' query parameter returns an error
- Invalid country code (not ISO 3166-1 alpha-2) causes a validation failure
- Date format not in YYYY-MM-DD format returns a parse error
- 'add' value outside -2000 to 2000 range is rejected
- Payment not provided or insufficient USDC balance results in 402 Payment Required
- Invalid region/subdivision code may return an error or be silently ignored

## How this service works

Calendar and Japan data APIs for AI agents: worldwide holidays and business days (200+ countries), plus Japanese text-to-structure (address, name, bank, company normalization). Pay per call in USDC via x402, no API key.

## Output

A JSON object containing the resolved result date after adding/subtracting business days, the weekday name, whether the base date is a business day or weekend, the next and previous business days, the weekend days for that country, and any public holidays on or between dates.

## 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": [
      "country"
     ],
     "properties": {
      "add": {
       "type": "integer",
       "default": 0,
       "maximum": 2000,
       "minimum": -2000,
       "description": "Business days to add (negative = go back)"
      },
      "date": {
       "type": "string",
       "format": "date",
       "description": "Base date YYYY-MM-DD (default: today UTC)"
      },
      "region": {
       "type": "string",
       "maxLength": 10,
       "description": "Optional subdivision code"
      },
      "country": {
       "type": "string",
       "pattern": "^[A-Za-z]{2}$",
       "description": "ISO 3166-1 alpha-2 country code"
      },
      "weekend": {
       "type": "string",
       "description": "Override weekend as weekday numbers, 0=Sunday (e.g. 5,6 for Fri-Sat). Default: the country's customary weekend"
      },
      "calendar": {
       "enum": [
        "standard",
        "bank"
       ],
       "type": "string",
       "default": "standard",
       "description": "bank = also treat bank holidays as closed"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "add": 1,
  "date": "2026-12-24",
  "region": null,
  "result": "2026-12-28",
  "country": "DE",
  "weekday": "Thursday",
  "weekend": [
   6,
   0
  ],
  "holidays": [],
  "isWeekend": false,
  "isBusinessDay": true,
  "nextBusinessDay": "2026-12-28",
  "previousBusinessDay": "2026-12-23"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/business-day-calculator-api-705318c2/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-ja-api.onrender.com](https://www.zero.xyz/host/x402-ja-api.onrender.com/llms.txt)
