{"openapi":"3.1.0","info":{"title":"TravelCheck x402 API","version":"0.1.0","description":"Pay-per-call airport disruption and missed-connection risk assessments for AI agents and automation.","guidance":"Use airport-risk to assess near-term disruption risk for a supported U.S. commercial airport. Use connection-risk when evaluating a specific connection window. Scores are relative operational risk from 0 to 100, not calibrated probabilities. Paid routes use x402 on the configured network and return structured JSON.","x-guidance":"Use airport-risk to assess near-term disruption risk for a supported U.S. commercial airport. Use connection-risk when evaluating a specific connection window. Scores are relative operational risk from 0 to 100, not calibrated probabilities. Paid routes use x402 on the configured network and return structured JSON."},"servers":[{"url":"https://travelcheck-x402.fly.dev"}],"paths":{"/v1/airport-risk":{"post":{"operationId":"assessAirportRisk","summary":"Assess airport disruption risk","description":"Returns a deterministic 0-100 relative risk assessment from live FAA operational status plus METAR/TAF weather for a supported U.S. scheduled-service airport.","tags":["travel","aviation","risk"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"airport":{"type":"string","pattern":"^[A-Z0-9]{3,4}$"},"targetTime":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"direction":{"default":"both","type":"string","enum":["arrivals","departures","both"]}},"required":["airport","targetTime","direction"],"additionalProperties":false},"example":{"airport":"ORD","targetTime":"2026-08-14T22:00:00.000Z","direction":"both"}}}},"responses":{"200":{"description":"Airport risk assessment","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"airport":{"type":"object","properties":{"icaoId":{"type":"string","pattern":"^[A-Z0-9]{4}$"},"iataId":{"anyOf":[{"type":"string","pattern":"^[A-Z0-9]{3}$"},{"type":"null"}]},"faaId":{"anyOf":[{"type":"string","minLength":2,"maxLength":8},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":300}},"required":["icaoId","iataId","faaId","name"],"additionalProperties":false},"assessedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"targetTime":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"direction":{"type":"string","enum":["arrivals","departures","both"]},"riskScore":{"type":"integer","minimum":0,"maximum":100},"riskBand":{"type":"string","enum":["low","moderate","high","severe"]},"recommendedAction":{"type":"string","enum":["proceed","monitor","add_buffer","avoid_or_rebook"]},"components":{"type":"object","properties":{"operations":{"type":"integer","minimum":0,"maximum":60},"weather":{"type":"integer","minimum":0,"maximum":40}},"required":["operations","weather"],"additionalProperties":false},"signals":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"code":{"type":"string","minLength":1,"maxLength":80},"source":{"type":"string","enum":["faa","metar","taf","itinerary"]},"impact":{"type":"integer","minimum":0,"maximum":100},"summary":{"type":"string","minLength":1,"maxLength":500}},"required":["code","source","impact","summary"],"additionalProperties":false}},"sourceTimes":{"type":"object","properties":{"faaUpdatedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"metarObservedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]},"tafIssuedAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}},"required":["faaUpdatedAt","metarObservedAt","tafIssuedAt"],"additionalProperties":false},"scoringVersion":{"type":"string","const":"airport-v1"}},"required":["airport","assessedAt","targetTime","direction","riskScore","riskBand","recommendedAction","components","signals","sourceTimes","scoringVersion"],"additionalProperties":false}}}},"400":{"description":"Invalid or unsupported request"},"402":{"description":"Payment Required"},"503":{"description":"Required live source temporarily unavailable"}},"x-payment-info":{"protocols":[{"x402":{}}],"price":{"mode":"fixed","currency":"USD","amount":"0.01"}}}},"/v1/connection-risk":{"post":{"operationId":"assessConnectionRisk","summary":"Assess missed-connection risk","description":"Returns a deterministic missed-connection risk assessment from itinerary timing, caller-supplied minimum connection time, and live airport conditions.","tags":["travel","aviation","connection","risk"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"connectionAirport":{"type":"string","pattern":"^[A-Z0-9]{3,4}$"},"inbound":{"type":"object","properties":{"flight":{"type":"string","minLength":2,"maxLength":16,"pattern":"^[A-Za-z0-9 -]+$"},"scheduled":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"estimated":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}},"required":["scheduled"],"additionalProperties":false},"outbound":{"type":"object","properties":{"flight":{"type":"string","minLength":2,"maxLength":16,"pattern":"^[A-Za-z0-9 -]+$"},"scheduled":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"estimated":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}},"required":["scheduled"],"additionalProperties":false},"minimumConnectionMinutes":{"type":"integer","minimum":10,"maximum":300}},"required":["connectionAirport","inbound","outbound","minimumConnectionMinutes"],"additionalProperties":false},"example":{"connectionAirport":"ORD","inbound":{"flight":"UA123","scheduled":"2026-08-14T21:05:00.000Z","estimated":"2026-08-14T21:24:00.000Z"},"outbound":{"flight":"UA456","scheduled":"2026-08-14T22:20:00.000Z"},"minimumConnectionMinutes":45}}}},"responses":{"200":{"description":"Connection risk assessment","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"connectionAirport":{"type":"string","pattern":"^[A-Z0-9]{3,4}$"},"inboundFlight":{"anyOf":[{"type":"string","minLength":1,"maxLength":16},{"type":"null"}]},"outboundFlight":{"anyOf":[{"type":"string","minLength":1,"maxLength":16},{"type":"null"}]},"assessedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"arrivalTimeUsed":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"departureTimeUsed":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"effectiveConnectionMinutes":{"type":"integer","minimum":-1440,"maximum":2880},"minimumConnectionMinutes":{"type":"integer","minimum":10,"maximum":300},"remainingBufferMinutes":{"type":"integer","minimum":-1740,"maximum":2870},"riskScore":{"type":"integer","minimum":0,"maximum":100},"riskBand":{"type":"string","enum":["low","moderate","high","severe"]},"recommendedAction":{"type":"string","enum":["proceed","monitor","add_buffer","avoid_or_rebook"]},"assessmentQuality":{"type":"string","enum":["schedule_only","live_arrival_estimate","live_departure_estimate","live_estimates"]},"components":{"type":"object","properties":{"connectionWindow":{"type":"integer","minimum":0,"maximum":100},"airportAdjustment":{"type":"integer","minimum":0,"maximum":100},"airportRiskScore":{"type":"integer","minimum":0,"maximum":100},"airportExposure":{"type":"number","minimum":0,"maximum":1}},"required":["connectionWindow","airportAdjustment","airportRiskScore","airportExposure"],"additionalProperties":false},"signals":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"code":{"type":"string","minLength":1,"maxLength":80},"source":{"type":"string","enum":["faa","metar","taf","itinerary"]},"impact":{"type":"integer","minimum":0,"maximum":100},"summary":{"type":"string","minLength":1,"maxLength":500}},"required":["code","source","impact","summary"],"additionalProperties":false}},"scoringVersion":{"type":"string","const":"connection-v1"}},"required":["connectionAirport","inboundFlight","outboundFlight","assessedAt","arrivalTimeUsed","departureTimeUsed","effectiveConnectionMinutes","minimumConnectionMinutes","remainingBufferMinutes","riskScore","riskBand","recommendedAction","assessmentQuality","components","signals","scoringVersion"],"additionalProperties":false}}}},"400":{"description":"Invalid or unsupported request"},"402":{"description":"Payment Required"},"503":{"description":"Required live source temporarily unavailable"}},"x-payment-info":{"protocols":[{"x402":{}}],"price":{"mode":"fixed","currency":"USD","amount":"0.05"}}}}}}