{"id":"iso-date-previous-weekday","version":"1.0.0","description":"Return the most recent date on or before a given date that falls on a specified ISO weekday.","supported_operations":["iso date previous weekday","last monday before date","preceding weekday"],"unsupported_operations":["timezones","locale weekday names","business day skip"],"semantics":["date is a strict YYYY-MM-DD proleptic Gregorian UTC calendar date with year 0001-9999.","weekday is a JSON integer 1-7 with Monday=1 .. Sunday=7.","inclusive is an optional boolean, default false. When true and date already falls on weekday, the result is date itself.","Otherwise the result is the latest date strictly before date whose ISO weekday equals weekday (at most 7 days earlier).","The call is rejected if the result would fall outside year 0001-9999."],"limits":{"year_min":1,"year_max":9999,"max_days_back":7},"pricing":{"status":"unpriced","charge_usd":null},"input_schema":{"type":"object","additionalProperties":false,"required":["date","weekday"],"properties":{"date":{"type":"string","minLength":10,"maxLength":10,"pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"weekday":{"type":"integer","minimum":1,"maximum":7},"inclusive":{"type":"boolean"}}},"output_schema":{"type":"object","additionalProperties":false,"required":["date"],"properties":{"date":{"type":"string","minLength":10,"maxLength":10}}},"examples":[{"input":{"date":"2026-09-15","weekday":5},"output":{"date":"2026-09-11"}},{"input":{"date":"2026-09-15","weekday":2,"inclusive":true},"output":{"date":"2026-09-15"}}],"execute_url":"/v1/tools/iso-date-previous-weekday/versions/1.0.0/execute"}