openapi: 3.0.0
info:
  title: SAP API
  version: 1.0.0
servers:
- url: http://localhost:8080
paths:
  /rfc/BAPI_FLTRIP_CREATE:
    post:
      tags:
      - SAPBC_BAPI_SFLTRIP
      summary: Create flight
      operationId: /rfc/BAPI_FLTRIP_CREATE
      requestBody:
        content:
          application/json:
            schema:
              properties:
                FLIGHT_TRIP_DATA:
                  type: object
                  properties:
                    AGENCYNUM:
                      type: integer
                      format: int64
                      description: Travel Agency Number
                    CUSTOMERID:
                      type: integer
                      format: int64
                      description: Customer Number
                    FLCONN1:
                      type: integer
                      format: int64
                      description: Flight Connection Number of the Flight to Destination
                    FLDATE1:
                      type: string
                      format: date
                      description: Date of Flight to Destination
                    FLCONN2:
                      type: integer
                      format: int64
                      description: Return Flight Connection
                    FLDATE2:
                      type: string
                      format: date
                      description: Return Flight Date
                    CLASS:
                      type: string
                      maxLength: 1
                      description: 'Flight Class  enumValues: Y=Economy Class,F=First Class,C=Business Class'
                      enum:
                      - Y
                      - F
                      - C
                EXTENSION_IN:
                  type: array
                  items:
                    type: object
                    properties:
                      STRUCTURE:
                        type: string
                        maxLength: 30
                        description: Structure name of  BAPI table extension
                      VALUEPART1:
                        type: string
                        maxLength: 240
                        description: Data part of BAPI extension parameter
                      VALUEPART2:
                        type: string
                        maxLength: 240
                        description: Data part of BAPI extension parameter
                      VALUEPART3:
                        type: string
                        maxLength: 240
                        description: Data part of BAPI extension parameter
                      VALUEPART4:
                        type: string
                        maxLength: 240
                        description: Data part of BAPI extension parameter
                PASSENGER_LIST:
                  type: array
                  items:
                    type: object
                    properties:
                      PASSNAME:
                        type: string
                        maxLength: 25
                        description: Name of the Passenger
                      PASSFORM:
                        type: string
                        maxLength: 15
                        description: Form of address
                      PASSBIRTH:
                        type: string
                        format: date
                        description: Date of Birth of a Passenger
              required:
              - FLIGHT_TRIP_DATA
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                properties:
                  TICKET_PRICE:
                    type: object
                    properties:
                      TRIPPRICE:
                        type: integer
                        format: int64
                        description: Total trip price
                      TRIPTAX:
                        type: integer
                        format: int64
                        description: Flight taxes
                      CURR:
                        type: string
                        maxLength: 5
                        description: Travel agency local currency
                      CURR_ISO:
                        type: string
                        maxLength: 3
                        description: ISO currency code
                  TRAVELAGENCYNUMBER:
                    type: integer
                    format: int64
                    description: Travel Agency Number
                  TRIPNUMBER:
                    type: integer
                    format: int64
                    description: Flight trip number
                  EXTENSION_IN:
                    type: array
                    items:
                      type: object
                      properties:
                        STRUCTURE:
                          type: string
                          maxLength: 30
                          description: Structure name of  BAPI table extension
                        VALUEPART1:
                          type: string
                          maxLength: 240
                          description: Data part of BAPI extension parameter
                        VALUEPART2:
                          type: string
                          maxLength: 240
                          description: Data part of BAPI extension parameter
                        VALUEPART3:
                          type: string
                          maxLength: 240
                          description: Data part of BAPI extension parameter
                        VALUEPART4:
                          type: string
                          maxLength: 240
                          description: Data part of BAPI extension parameter
                  PASSENGER_LIST:
                    type: array
                    items:
                      type: object
                      properties:
                        PASSNAME:
                          type: string
                          maxLength: 25
                          description: Name of the Passenger
                        PASSFORM:
                          type: string
                          maxLength: 15
                          description: Form of address
                        PASSBIRTH:
                          type: string
                          format: date
                          description: Date of Birth of a Passenger
                  RETURN:
                    type: array
                    items:
                      type: object
                      properties:
                        TYPE:
                          type: string
                          maxLength: 1
                          description: 'Message type: S Success, E Error, W Warning, I Info, A Abort'
                        ID:
                          type: string
                          maxLength: 20
                          description: Message Class
                        NUMBER:
                          type: integer
                          format: int64
                          description: Message Number
                        MESSAGE:
                          type: string
                          maxLength: 220
                          description: Message Text
                        LOG_NO:
                          type: string
                          maxLength: 20
                          description: 'Application log: log number'
                        LOG_MSG_NO:
                          type: integer
                          format: int64
                          description: 'Application log: Internal message serial number'
                        MESSAGE_V1:
                          type: string
                          maxLength: 50
                          description: Message Variable
                        MESSAGE_V2:
                          type: string
                          maxLength: 50
                          description: Message Variable
                        MESSAGE_V3:
                          type: string
                          maxLength: 50
                          description: Message Variable
                        MESSAGE_V4:
                          type: string
                          maxLength: 50
                          description: Message Variable
                        PARAMETER:
                          type: string
                          maxLength: 32
                          description: Parameter Name
                        ROW:
                          type: integer
                          format: int32
                          description: Lines in parameter
                        FIELD:
                          type: string
                          maxLength: 30
                          description: Field in parameter
                        SYSTEM:
                          type: string
                          maxLength: 10
                          description: Logical system from which message originates
        '400':
          description: Bad request.
        5XX:
          description: Unexpected error.
