Skip to content
Fourohtwo

Date Math

date-math.datemath.workers.dev/v1/stay

Date Math: Rolling stay-limit math such as the Schengen 90/180 rule: days used in the window, days left, overstay check, the longest stay allowed from a planned entry date, and the next date a full stay is possible. Entry and exit days both count. Custom rules via max_days/window_days. Use for travel planning, visa-free stays and "can I enter on".

BaseAnswering
POSThttps://date-math.datemath.workers.dev/v1/stay

Uptime100% of 1 check in 30 days

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain,
// inside the spending rules you set on Fourohtwo.
const pay = createPayer({ privateKey: process.env.AGENT_KEY });
const res = await pay("https://date-math.datemath.workers.dev/v1/stay", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"date":"2026-10-01","entry":"2026-11-01","trips":[{"entry":"2026-06-01","exit":"2026-07-15"},{"entry":"2026-09-10","exit":"2026-09-30"}]}),
});
console.log(await res.json());

Example input

{
  "date": "2026-10-01",
  "entry": "2026-11-01",
  "trips": [
    {
      "entry": "2026-06-01",
      "exit": "2026-07-15"
    },
    {
      "entry": "2026-09-10",
      "exit": "2026-09-30"
    }
  ]
}

More from Date Math