{"openapi":"3.1.0","info":{"title":"Trafiklab Realtime (BYOK) API","version":"0.1.0","description":"Trafiklab Realtime (BYOK) lets an AI assistant read your own Trafiklab Realtime data through the Trafiklab Realtime API with a key you supply (Trafiklab Realtime APIs key). Read-only: 6 tools (search_stops, get_departures, get_departures_at_time, get_arrivals, get_arrivals_at_time, get_trip_details). The BYOK key travels with each request, is used for that one call only and is never stored,...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-trafiklabrealtime.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-trafiklabrealtime/docs"},"termsOfService":"https://connectorbay.com/byok-trafiklabrealtime/terms"},"servers":[{"url":"https://byok-trafiklabrealtime.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-trafiklabrealtime/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 Swedish stop groups by name; returns group id, name, type, transport modes and the individual stops with coordina","description":"Search Swedish stop groups by name; returns group id, name, type, transport modes and the individual stops with coordinates. Use for \"Find the stop groups named Odenplan\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"search_value":{"description":"Stop name or part of it, for example 'Odenplan'.","maxLength":100,"title":"Search Value","type":"string"}},"required":["search_value"],"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/get_departures":{"post":{"operationId":"get_departures","summary":"Get the upcoming departures from a stop right now, with scheduled and real-time times, delay, line, destination, platfor","description":"Get the upcoming departures from a stop right now, with scheduled and real-time times, delay, line, destination, platform and alerts. Use for \"What leaves from stop 740020101 in the next while\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"stop_id":{"description":"Stop identifier from search_stops, for example 740020101.","maxLength":200,"title":"Stop Id","type":"string"}},"required":["stop_id"],"title":"get_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/get_departures_at_time":{"post":{"operationId":"get_departures_at_time","summary":"Get departures from a stop for a given local date and time (planned timetable and real time where available). Use for \"W","description":"Get departures from a stop for a given local date and time (planned timetable and real time where available). Use for \"What leaves from stop 740020101 on 2026-10-16 at 16:30\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"stop_id":{"description":"Stop identifier from search_stops, for example 740020101.","maxLength":200,"title":"Stop Id","type":"string"},"date_time":{"description":"Local date and time in ISO 8601, for example 2026-10-16T16:30.","maxLength":200,"title":"Date Time","type":"string"}},"required":["stop_id","date_time"],"title":"get_departures_at_timeArguments","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/get_arrivals":{"post":{"operationId":"get_arrivals","summary":"Get the upcoming arrivals at a stop right now, with scheduled and real-time times, delay, line, origin and platform. Use","description":"Get the upcoming arrivals at a stop right now, with scheduled and real-time times, delay, line, origin and platform. Use for \"What arrives at stop 740020101 soon\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"stop_id":{"description":"Stop identifier from search_stops, for example 740020101.","maxLength":200,"title":"Stop Id","type":"string"}},"required":["stop_id"],"title":"get_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}},"/v1/tools/get_arrivals_at_time":{"post":{"operationId":"get_arrivals_at_time","summary":"Get arrivals at a stop for a given local date and time. Use for \"What arrives at stop 740020101 on 2026-10-16 at 16:30\".","description":"Get arrivals at a stop for a given local date and time. Use for \"What arrives at stop 740020101 on 2026-10-16 at 16:30\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"stop_id":{"description":"Stop identifier from search_stops, for example 740020101.","maxLength":200,"title":"Stop Id","type":"string"},"date_time":{"description":"Local date and time in ISO 8601, for example 2026-10-16T16:30.","maxLength":200,"title":"Date Time","type":"string"}},"required":["stop_id","date_time"],"title":"get_arrivals_at_timeArguments","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/get_trip_details":{"post":{"operationId":"get_trip_details","summary":"Get every stop call of one trip with scheduled and real-time arrival and departure, delays, platforms and alerts. Use fo","description":"Get every stop call of one trip with scheduled and real-time arrival and departure, delays, platforms and alerts. Use for \"Show all stops and delays of trip 121120000386193630 on 2026-10-16\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"trip_id":{"description":"Trip id from a departures or arrivals answer, for example 121120000386193630.","maxLength":200,"title":"Trip Id","type":"string"},"start_date":{"description":"Trip start date, yyyy-MM-dd or yyyyMMdd.","maxLength":200,"title":"Start Date","type":"string"}},"required":["trip_id","start_date"],"title":"get_trip_detailsArguments","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}}}}