{"openapi":"3.1.0","info":{"title":"ResRobot (BYOK) API","version":"0.1.0","description":"ResRobot (BYOK) lets an AI assistant read your own ResRobot data through the ResRobot API with a key you supply (Trafiklab ResRobot v2.1 API key). Read-only: 5 tools (search_stops, nearby_stops, plan_trip, departures, arrivals). The BYOK key travels with each request, is used for that one call only and is never stored, logged or cached; it is only ever sent to api.resrobot.se. Unofficial...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-resrobot.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-resrobot/docs"},"termsOfService":"https://connectorbay.com/byok-resrobot/terms"},"servers":[{"url":"https://byok-resrobot.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-resrobot/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/search_stops":{"post":{"operationId":"search_stops","summary":"Search stops, stations and addresses in Sweden by name, optionally within a radius of a coordinate. Returns names and st","description":"Search stops, stations and addresses in Sweden by name, optionally within a radius of a coordinate. Returns names and stop ids for the other tools. Use for \"What is the ResRobot stop id of Goteborg Central\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"input":{"description":"Name or part of a name of the stop, for example 'Goteborg Central'.","maxLength":100,"title":"Input","type":"string"},"max_results":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Maximum number of matches (1 to 1000).","title":"Max Results"},"location_type":{"anyOf":[{"enum":["ALL","S","A","P","SA","SP","AP"],"type":"string"},{"type":"null"}],"default":"S","description":"Search pool: ALL, S (stops), A (addresses), P (points of interest) or a combination.","title":"Location Type"},"radius_m":{"anyOf":[{"maximum":10000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Only with latitude and longitude: radius in metres (up to 10000).","title":"Radius M"},"latitude":{"anyOf":[{"maxLength":20,"type":"string"},{"type":"null"}],"default":null,"description":"Latitude of a centre point, used with longitude and radius_m.","title":"Latitude"},"longitude":{"anyOf":[{"maxLength":20,"type":"string"},{"type":"null"}],"default":null,"description":"Longitude of a centre point, used with latitude and radius_m.","title":"Longitude"},"lang":{"anyOf":[{"enum":["sv","en","de"],"type":"string"},{"type":"null"}],"default":"sv","description":"Language of texts: sv, en or de.","title":"Lang"},"format":{"anyOf":[{"const":"json","type":"string"},{"type":"null"}],"default":"json","description":"Response format; only json is offered here.","title":"Format"}},"required":["input"],"title":"search_stopsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/nearby_stops":{"post":{"operationId":"nearby_stops","summary":"List stops near a coordinate in Sweden, with ids and distance, within a radius of up to 10 km. Use for \"Which public tra","description":"List stops near a coordinate in Sweden, with ids and distance, within a radius of up to 10 km. Use for \"Which public transport stops are near 57.7089, 11.9746 in Goteborg\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"latitude":{"description":"Latitude in decimal degrees (WGS84).","maximum":180,"minimum":-180,"title":"Latitude","type":"number"},"longitude":{"description":"Longitude in decimal degrees (WGS84).","maximum":180,"minimum":-180,"title":"Longitude","type":"number"},"radius_m":{"anyOf":[{"maximum":10000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1000,"description":"Search radius in metres (up to 10000).","title":"Radius M"},"max_results":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Maximum number of stops (1 to 1000).","title":"Max Results"},"lang":{"anyOf":[{"enum":["sv","en","de"],"type":"string"},{"type":"null"}],"default":"sv","description":"Language of texts: sv, en or de.","title":"Lang"},"format":{"anyOf":[{"const":"json","type":"string"},{"type":"null"}],"default":"json","description":"Response format; only json is offered here.","title":"Format"}},"required":["latitude","longitude"],"title":"nearby_stopsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/plan_trip":{"post":{"operationId":"plan_trip","summary":"Plan journeys between two stop ids across Sweden using all public transport, for a given date and time, as departures or","description":"Plan journeys between two stop ids across Sweden using all public transport, for a given date and time, as departures or arrivals. Use for \"How do I get from Stockholm Central to Goteborg Central tomorrow morning\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"origin_id":{"description":"Stop id of the start, for example 740000001 (from search_stops).","minimum":1,"title":"Origin Id","type":"integer"},"destination_id":{"description":"Stop id of the destination, for example 740000002 (from search_stops).","minimum":1,"title":"Destination Id","type":"integer"},"date":{"anyOf":[{"maxLength":10,"type":"string"},{"type":"null"}],"default":null,"description":"Date as YYYY-MM-DD within the timetable period; empty means today.","title":"Date"},"time":{"anyOf":[{"maxLength":5,"type":"string"},{"type":"null"}],"default":null,"description":"Time as HH:MM; empty means now.","title":"Time"},"search_for_arrival":{"anyOf":[{"maximum":1,"minimum":0,"type":"integer"},{"type":"null"}],"default":0,"description":"0 to treat date and time as departure, 1 as arrival time.","title":"Search For Arrival"},"trips_after":{"anyOf":[{"maximum":6,"minimum":1,"type":"integer"},{"type":"null"}],"default":5,"description":"Minimum number of journeys after the given time (1 to 6).","title":"Trips After"},"trips_before":{"anyOf":[{"maximum":5,"minimum":0,"type":"integer"},{"type":"null"}],"default":0,"description":"Minimum number of journeys before the given time (0 to 5).","title":"Trips Before"},"max_changes":{"anyOf":[{"maximum":11,"minimum":1,"type":"integer"},{"type":"null"}],"default":11,"description":"Maximum number of changes (1 to 11).","title":"Max Changes"},"lang":{"anyOf":[{"enum":["sv","en","de"],"type":"string"},{"type":"null"}],"default":"sv","description":"Language of texts: sv, en or de.","title":"Lang"},"format":{"anyOf":[{"const":"json","type":"string"},{"type":"null"}],"default":"json","description":"Response format; only json is offered here.","title":"Format"}},"required":["origin_id","destination_id"],"title":"plan_tripArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/departures":{"post":{"operationId":"departures","summary":"Get the departure board of one stop id: line, direction and times, with realtime data where available. Use for \"What lea","description":"Get the departure board of one stop id: line, direction and times, with realtime data where available. Use for \"What leaves Goteborg Central in the next hour\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Stop id, for example 740000002 (from search_stops).","minimum":1,"title":"Id","type":"integer"},"date":{"anyOf":[{"maxLength":10,"type":"string"},{"type":"null"}],"default":null,"description":"Date as YYYY-MM-DD within the timetable period; empty means today.","title":"Date"},"time":{"anyOf":[{"maxLength":5,"type":"string"},{"type":"null"}],"default":null,"description":"Time as HH:MM; empty means now.","title":"Time"},"duration_min":{"anyOf":[{"maximum":1439,"minimum":0,"type":"integer"},{"type":"null"}],"default":60,"description":"Length of the time window in minutes (0 to 1439).","title":"Duration Min"},"max_journeys":{"anyOf":[{"maximum":500,"minimum":-1,"type":"integer"},{"type":"null"}],"default":-1,"description":"Maximum number of departures; -1 means no limit.","title":"Max Journeys"},"direction_id":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Only vehicles heading towards this stop id.","title":"Direction Id"},"lang":{"anyOf":[{"enum":["sv","en","de"],"type":"string"},{"type":"null"}],"default":"sv","description":"Language of texts: sv, en or de.","title":"Lang"},"format":{"anyOf":[{"const":"json","type":"string"},{"type":"null"}],"default":"json","description":"Response format; only json is offered here.","title":"Format"}},"required":["id"],"title":"departuresArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/arrivals":{"post":{"operationId":"arrivals","summary":"Get the arrival board of one stop id: line, origin and times, with realtime data where available. Use for \"What arrives ","description":"Get the arrival board of one stop id: line, origin and times, with realtime data where available. Use for \"What arrives at Stockholm Central in the next 30 minutes\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Stop id, for example 740000001 (from search_stops).","minimum":1,"title":"Id","type":"integer"},"date":{"anyOf":[{"maxLength":10,"type":"string"},{"type":"null"}],"default":null,"description":"Date as YYYY-MM-DD within the timetable period; empty means today.","title":"Date"},"time":{"anyOf":[{"maxLength":5,"type":"string"},{"type":"null"}],"default":null,"description":"Time as HH:MM; empty means now.","title":"Time"},"duration_min":{"anyOf":[{"maximum":1439,"minimum":0,"type":"integer"},{"type":"null"}],"default":60,"description":"Length of the time window in minutes (0 to 1439).","title":"Duration Min"},"max_journeys":{"anyOf":[{"maximum":500,"minimum":-1,"type":"integer"},{"type":"null"}],"default":-1,"description":"Maximum number of arrivals; -1 means no limit.","title":"Max Journeys"},"lang":{"anyOf":[{"enum":["sv","en","de"],"type":"string"},{"type":"null"}],"default":"sv","description":"Language of texts: sv, en or de.","title":"Lang"},"format":{"anyOf":[{"const":"json","type":"string"},{"type":"null"}],"default":"json","description":"Response format; only json is offered here.","title":"Format"}},"required":["id"],"title":"arrivalsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}