Catalog/datetime-business-days-between

Date & Time

Business days between dates API

Counts working days between two ISO dates honoring a custom weekend mask and explicit holiday list, returning a breakdown of calendar days, weekend days and holidays skipped, with signed direction. Answers 'How many business days between two dates?', 'Net working days excluding my holidays?'.

Price$0.04per request
MethodPOST
Route/v1/datetime/business-days-between
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
datetimebusiness-daysworking-daysbetweenholidaysweekenddate-mathnetworkdays
API URLhttps://x402.hexl.dev/v1/datetime/business-days-between
Integration docs
Example request
{
  "start": "2026-01-01",
  "end": "2026-01-15",
  "holidays": [
    "2026-01-01"
  ]
}
Example response
{
  "start": "2026-01-01",
  "end": "2026-01-15",
  "inclusive": false,
  "businessDays": 9,
  "calendarDays": 14,
  "weekendDays": 4,
  "holidaysSkipped": 1,
  "direction": "forward",
  "interpretation": "9 business day(s) between 2026-01-01 and 2026-01-15 (exclusive of end); skipped 4 weekend + 1 holiday day(s)."
}
Input schema
{
  "type": "object",
  "required": [
    "start",
    "end"
  ],
  "properties": {
    "start": {
      "type": "string",
      "examples": [
        "2026-01-01"
      ]
    },
    "end": {
      "type": "string",
      "examples": [
        "2026-01-15"
      ]
    },
    "weekendDays": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    },
    "holidays": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "examples": [
        [
          "2026-01-01"
        ]
      ]
    },
    "inclusive": {
      "type": "boolean",
      "examples": [
        false
      ]
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}