{"files":{"SKILL.md":"---\nname: lh-public-api\ndescription: \"LH Public API skill. Use when working with LH Public for references, offers, operations. Covers 15 endpoints.\"\nversion: 1.0.0\ngenerator: lapsh\n---\n\n# LH Public API\nAPI version: 1.0\n\n## Auth\nOAuth2\n\n## Base URL\nhttps://api.lufthansa.com/v1\n\n## Setup\n1. Configure auth: OAuth2\n2. GET /references/countries/{countryCode} -- verify access\n\n## Endpoints\n\n15 endpoints across 4 groups. See references/api-spec.lap for full details.\n\n### references\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /references/countries/{countryCode} | Countries |\n| GET | /references/cities/{cityCode} | Cities |\n| GET | /references/airports/{airportCode} | Airports |\n| GET | /references/airports/nearest/{latitude},{longitude} | Nearest Airports |\n| GET | /references/airlines/{airlineCode} | Airlines |\n| GET | /references/aircraft/{aircraftCode} | Aircraft |\n\n### offers\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /offers/seatmaps/{flightNumber}/{origin}/{destination}/{date}/{cabinClass} | Seat Maps |\n| GET | /offers/lounges/{location} | Lounges |\n\n### operations\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /operations/flightstatus/{flightNumber}/{date} | Flight Status |\n| GET | /operations/flightstatus/route/{origin}/{destination}/{date} | Flight Status by Route |\n| GET | /operations/flightstatus/arrivals/{airportCode}/{fromDateTime} | Flight Status at Arrival Airport |\n| GET | /operations/flightstatus/departures/{airportCode}/{fromDateTime} | Flight Status at Departure Airport |\n| GET | /operations/schedules/{origin}/{destination}/{fromDateTime} | Flight Schedules |\n\n### cargo\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /cargo/shipmentTracking/{aWBPrefix}-{aWBNumber} | Shipment Tracking |\n| GET | /cargo/getRoute/{origin}-{destination}/{fromDate}/{productCode} | Retrieve all flights |\n\n## Common Questions\n\nMatch user requests to endpoints in references/api-spec.lap. Key patterns:\n- \"Get country details?\" -> GET /references/countries/{countryCode}\n- \"Get city details?\" -> GET /references/cities/{cityCode}\n- \"Get airport details?\" -> GET /references/airports/{airportCode}\n- \"Get nearest details?\" -> GET /references/airports/nearest/{latitude},{longitude}\n- \"Get airline details?\" -> GET /references/airlines/{airlineCode}\n- \"Get aircraft details?\" -> GET /references/aircraft/{aircraftCode}\n- \"Get seatmap details?\" -> GET /offers/seatmaps/{flightNumber}/{origin}/{destination}/{date}/{cabinClass}\n- \"Get lounge details?\" -> GET /offers/lounges/{location}\n- \"Get flightstatus details?\" -> GET /operations/flightstatus/{flightNumber}/{date}\n- \"Get route details?\" -> GET /operations/flightstatus/route/{origin}/{destination}/{date}\n- \"Get arrival details?\" -> GET /operations/flightstatus/arrivals/{airportCode}/{fromDateTime}\n- \"Get departure details?\" -> GET /operations/flightstatus/departures/{airportCode}/{fromDateTime}\n- \"Get schedule details?\" -> GET /operations/schedules/{origin}/{destination}/{fromDateTime}\n- \"Get shipmentTracking details?\" -> GET /cargo/shipmentTracking/{aWBPrefix}-{aWBNumber}\n- \"Get getRoute details?\" -> GET /cargo/getRoute/{origin}-{destination}/{fromDate}/{productCode}\n- \"How to authenticate?\" -> See Auth section\n\n## Response Tips\n- Check response schemas in references/api-spec.lap for field details\n- List endpoints may support pagination; check for limit, offset, or cursor params\n\n## CLI\n\n```bash\n# Update this spec to the latest version\nnpx @lap-platform/lapsh get lh-public-api -o references/api-spec.lap\n\n# Search for related APIs\nnpx @lap-platform/lapsh search lh-public-api\n```\n\n## References\n- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas\n\n> Generated from the official API spec by [LAP](https://lap.sh)\n","references/api-spec.lap":"@lap v0.3\n# Machine-readable API spec. Each @endpoint block is one API call.\n@api LH Public API\n@base https://api.lufthansa.com/v1\n@version 1.0\n@auth OAuth2\n@common_fields {Accept: any # http header: application/json or application/xml (Acceptable values are: \"application/json\", \"application/xml\")}\n@endpoints 15\n@toc references(6), offers(2), operations(5), cargo(2)\n\n@group references\n@endpoint GET /references/countries/{countryCode}\n@desc Countries\n@required {countryCode: any # 2-letter ISO 3166-1 country code}\n@optional {lang: any # 2 letter ISO 3166-1 language code, limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /references/cities/{cityCode}\n@desc Cities\n@required {cityCode: any # 3-letter IATA city code}\n@optional {lang: any # 2 letter ISO 3166-1 language code, limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /references/airports/{airportCode}\n@desc Airports\n@required {airportCode: any # 3-letter IATA airport code}\n@optional {lang: any # 2-letter ISO 3166-1 language code, limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0, LHoperated: any # Restrict the results to locations with flights operated by LH (false=0, true=1)}\n@returns(200)\n\n@endpoint GET /references/airports/nearest/{latitude},{longitude}\n@desc Nearest Airports\n@required {latitude: any # Latitude in decimal format to at most 3 decimal places, longitude: any # Longitude in decimal format to at most 3 decimal places}\n@optional {lang: any # 2 letter ISO 3166-1 language code}\n@returns(200)\n\n@endpoint GET /references/airlines/{airlineCode}\n@desc Airlines\n@required {airlineCode: any # 2-character IATA airline/carrier code}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /references/aircraft/{aircraftCode}\n@desc Aircraft\n@required {aircraftCode: any # 3-character IATA aircraft code}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endgroup\n\n@group offers\n@endpoint GET /offers/seatmaps/{flightNumber}/{origin}/{destination}/{date}/{cabinClass}\n@desc Seat Maps\n@required {flightNumber: any # Flight number including carrier code and any suffix (e.g. 'LH2037'), origin: any # Departure airport. 3-letter IATA airport code (e.g. 'TXL'), destination: any # Destination airport. 3-letter IATA airport code (e.g. 'MUC'), date: any # Departure date (YYYY-MM-DD), cabinClass: any # Cabin class: 'M', 'E', 'C', 'F'. Some flights have fewer classes (Acceptable values are: \"M\", \"E\", \"C\", \"F\")}\n@returns(200)\n\n@endpoint GET /offers/lounges/{location}\n@desc Lounges\n@required {location: any # 3-leter IATA airport or city code (e.g. 'ZRH')}\n@optional {cabinClass: any # Cabin class: 'M', 'E', 'C', 'F' (Acceptable values are: \"\", \"M\", \"E\", \"C\", \"F\"), tierCode: any # Frequent flyer level ('FTL', 'SGC', 'SEN', 'HON') (Acceptable values are: \"\", \"FTL\", \"SGC\", \"SEN\", \"HON\"), lang: any # Language code.}\n@returns(200)\n\n@endgroup\n\n@group operations\n@endpoint GET /operations/flightstatus/{flightNumber}/{date}\n@desc Flight Status\n@required {flightNumber: any # Flight number including carrier code and any suffix (e.g. 'LH400'), date: any # The departure date (YYYY-MM-DD) in the local time of the departure airport}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /operations/flightstatus/route/{origin}/{destination}/{date}\n@desc Flight Status by Route\n@required {origin: any # 3-letter IATA airport (e.g. 'FRA'), destination: any # 3-letter IATA airport code (e.g. 'JFK'), date: any # Departure date (YYYY-MM-DD) in local time of departure airport}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /operations/flightstatus/arrivals/{airportCode}/{fromDateTime}\n@desc Flight Status at Arrival Airport\n@required {airportCode: any # 3-letter IATA aiport code (e.g. 'ZRH'), fromDateTime: any # Start of time range in local time of arrival airport (YYYY-MM-DDTHH:mm)}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /operations/flightstatus/departures/{airportCode}/{fromDateTime}\n@desc Flight Status at Departure Airport\n@required {airportCode: any # Departure airport. 3-letter IATA airport code (e.g. 'HAM'), fromDateTime: any # Start of time range in local time of departure airport (YYYY-MM-DDTHH:mm)}\n@optional {limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endpoint GET /operations/schedules/{origin}/{destination}/{fromDateTime}\n@desc Flight Schedules\n@required {origin: any # Departure airport. 3-letter IATA airport code (e.g. 'ZRH'), destination: any # Destination airport. 3-letter IATA airport code (e.g. 'FRA'), fromDateTime: any # Local departure date and optionally departure time (YYYY-MM-DD or YYYY-MM-DDTHH:mm). When not provided, time is assumed to be 00:01}\n@optional {directFlights: any # Show only direct flights (false=0, true=1). Default is false, limit: any # Number of records returned per request. Defaults to 20, maximum is 100 (if a value bigger than 100 is given, 100 will be taken), offset: any # Number of records skipped. Defaults to 0}\n@returns(200)\n\n@endgroup\n\n@group cargo\n@endpoint GET /cargo/shipmentTracking/{aWBPrefix}-{aWBNumber}\n@desc Shipment Tracking\n@required {aWBPrefix: any # aWBPrefix : Represents the airline that is the owner of this AWB, i.e. \"020\" = Lufthansa Cargo, format : [0-9]{3} e.g. 020, aWBNumber: any # aWBNumber : The Air Waybill Number , format : [0-9]{8} e.g. 08002050}\n@returns(200)\n\n@endpoint GET /cargo/getRoute/{origin}-{destination}/{fromDate}/{productCode}\n@desc Retrieve all flights\n@required {origin: any # Departure Airport : 3-letter IATA airport code, e.g. FRA., destination: any # Arrival airport : 3-letter IATA airport code, e.g. HKG., fromDate: any # Departure date in the local time of the departure airport. Based on LAT (Latest Acceptance Time). format : yyyy-MM-dd eg : 2017-07-15, productCode: any # Product code for requested service and specials : 3-letter eg: YNZ}\n@returns(200)\n\n@endgroup\n\n@end\n"}}