Crew Services Overview

Environments

Common Crew Services are available on different environments for development, test and production purposes. Following environments are supported:

  • Sandbox Mock - an environment for development purposes which returns only static mock results
  • Sandbox - an environment for development and integration purposes which accesses the TEST environment of the CMS backend systems
  • Production - the live environment for the production version of the application which accesses the PROD environment of the CMS backend systems

Sandbox Mock

The intention of a "Mock" environment is to provide a realistic API that behaves almost like the real system (in terms of request and response formats) without interfering with data protection needs. The Mock environment only returns fictional, mostly static response data. It is suitable for first implementation drafts, demo sessions or simulations in case the test backend is not available for some reason.

Resource Base

The resource base URL for the Sandbox Mock environment is:

Code snippet: URL
https://api-sandbox.lufthansa.com/v1/flight_operations/crew_services/mock
Login

Authentication and authorization is performed via the OAuth2 TEST Server:

Code snippet: URL
https://oauth-test.lufthansa.com

The required scope is: https://mock.cms.fra.dlh.de/publicCrewApiDev. (Note: Only if you have already access to the LH-internal CMS TEST environment, e.g. for business purposes, you can also register without the "mock" prefix - in this case, your package key for the SANDBOX environment will also be valid for the MOCK environment.) The clientId (and secret) you will get after registering your app to Mashery - see Flight Operations Partner API.

Warning: Currently it is required to authenticate with a valid RSA Token, however for the future it is planned to provide a simpler authentication option to be used for mocked services of the API.

Supported Scenarios

The mocked services generally support all formats and parameters of the real service API. Responses are, in principle static. I.e. the requests lead to static results and do not include "real" crew data. However, some dynamic response support is available: e.g. if a duty plan is requested for a specific date range and specific crew member, the static response is enhanced with the requested date range and the authenticated user ID.

To simulate some specific error or response situations, special parameter values must be used. These parameters have been reserved to simulate special situations:

  • flight numbers: LH0000, LH9999, LH598
  • dates: year in 2016

Following scenarios have been implemented and are supported:

  • Crew Check-In Times:
    • Duty Type OD - all required parameters provided
    • Duty Type DH - all required parameters provided
    • Errors in case of missing mandatory or conditional parameters
    • Error if flight is not in OPS range (condition: use flightDate that is in 2016, e.g. 2016-01-01Z)
  • Crew Lists:
    • All required parameters provided
    • Errors in case of missing mandatory parameters
    • Flight not found error (condition: flightDesignator is LH0000)
    • Crew member not on crew list error (condition: flightDesignator is LH9999)
    • Invalid access code error (condition: accessCode is AAAAAAAA)
  • Duty Events:
    • All required parameters provided
    • Errors in case of missing mandatory parameters
    • Internal access to CDI-server not possible error (condition: use both fromDate and toDate that are in 2016, e.g. 2016-01-01Z)
  • Flight Leg Details:
    • Direct match if all required parameters provided
    • Errors in case of missing mandatory parameter
    • Flight leg choice result on multileg flight (condition: flightDesignator is LH598)
    • Flight not found error (condition: flightDesignator is LH0000)
    • Internal TANGO backend not reachable error (condition: flightDesignator is LH9999)
  • Landing Report:
    • All required parameters provided
    • Errors in case of missing mandatory parameters
    • No matching leg found error (condition: flightDesignator is LH0000)

Sandbox

The sandbox environment provides a realistic API integrated with real (test) backends. The sandbox environment returns real but anonymized crew and flight data, so it can only be used by authorized developers. It is suitable for the development and integration tests, although there is no SLA on the availability and stability of the test systems.

Resource Base

The resource base URL for the Sandbox environment is:

Code snippet: URL
https://api-sandbox.lufthansa.com/v1/flight_operations/crew_services
Login

Authentication and authorization is performed via the OAuth2 TEST Server:

Code snippet: URL
https://oauth-test.lufthansa.com

The required scope is: https://cms.fra.dlh.de/publicCrewApiDev. The clientId (and secret) you will get after registering your app to Mashery (and CrewPortal) - see Flight Operations Partner API.

Warning: For data protection reasons it is required to authenticate with a valid RSA Token and user ID

Production (To Be Published in 2018)

The production environment provides API access to the live crew systems. It can only be used by authorized crew staff so it is not suitable for development and integration.

Resource Base

The resource base URL for the Production environment is:

Code snippet: URL
https://api.lufthansa.com/v1/flight_operations/crew_services
Login

Authentication and authorization is performed via the OAuth2 PRODUCTION Server:

Code snippet: URL
https://oauth.lufthansa.com

The required scope is: https://cms.fra.dlh.de/publicCrewApi. The clientId (and secret) you will get after registering your app to Mashery (and CrewPortal) - see Flight Operations Partner API.

Warning: It is generally required to authenticate with a valid RSA Token and user ID