# agent402.tools Workday Count

> agent402.tools Workday Count is a paid API for AI agents from agent402.tools, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Counts business days (weekdays) between two dates, with optional exclusion of US federal holidays

## Facts

- Endpoint: GET https://agent402.tools/api/workday-count
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent402-tools-workday-count-4f01c0d6
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_h2_GlCW95uJSzpPfVR8me

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 agent402-tools-workday-count-4f01c0d6
```

Example prompt: How many business days are there between January 5, 2026 and March 31, 2026, not counting US federal holidays?

## When to prefer this

Use this endpoint when you need a precise count of business days between two dates, especially when US federal holiday exclusion matters. Ideal for financial deadline calculations, SLA tracking, payroll period counting, or any scheduling logic that requires weekday-only arithmetic. Prefer this over a general date-difference API when holiday-aware business day counting is required.

## Known failure modes

- Missing required start or end date parameters returns an error
- Dates provided in wrong format (not YYYY-MM-DD) may cause a parse error
- End date earlier than start date may return zero or an error
- Invalid date strings (e.g. 2026-13-01) will likely produce an error response
- Network or service unavailability returns a non-200 response

## How this service works

Count business days (weekdays) between two dates, optionally excluding US federal holidays (MLK, Presidents Day, Memorial Day, Juneteenth, Independence Day, Labor Day, Columbus Day, Veterans Day, Thanksgiving, Christmas, New Year). ?start=2026-01-...

## Output

Returns the count of weekdays (Monday–Friday) between the two provided dates, minus any US federal holidays if the holidays flag is set to true. The response is a numeric count of valid business days.

## 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",
      "end"
     ],
     "properties": {
      "end": {
       "type": "string",
       "description": "End date (YYYY-MM-DD)"
      },
      "start": {
       "type": "string",
       "description": "Start date (YYYY-MM-DD)"
      },
      "holidays": {
       "type": "string",
       "description": "Subtract US federal holidays: true or false (default false)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "end": "2026-12-31",
  "start": "2026-01-01",
  "totalDays": 365,
  "holidayDays": 11,
  "weekendDays": 104,
  "businessDays": 250,
  "holidaysExcluded": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent402-tools-workday-count-4f01c0d6/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402.tools](https://www.zero.xyz/host/agent402.tools/llms.txt)
