openapi: 3.1.0
info:
  title: Lipp Connect API
  description: API for managing Lipp software.
  version: 1.1.0
  contact:
    name: Lipp Connect API Support
    email: develop@linecker.at
servers:
  - url: https://connect.lipp.cloud/api
    description: Production server
security:
  - ApiKeyAuth: []
paths:
  /POSSystem/GetCommodityGroup:
    description: Retrieve your commodity group over id
    get:
      parameters:
        - name: id
          in: query
          required: true
          schema:
            type: string
            format: uuid
      summary: Get Commodity Group
      operationId: commodityGroup
      tags:
        - POS Management
      responses:
        '200':
          description: A commodity group
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/CommodityGroups'
  /POSSystem/GetCommodityGroups:
    description: Retrieve all your commodity groups
    get:
      summary: Get Commodity Groups
      operationId: listCommodityGroups
      tags:
        - POS Management
      responses:
        '200':
          description: A list of all commodity groups
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/CommodityGroups'
  /POSSystem/GetArticle:
    description: Retrieve your article over Id
    get:
      summary: Get article
      operationId: article
      parameters:
        - name: id
          in: query
          required: true
          schema:
            type: string
            format: uuid
      tags:
        - POS Management
      responses:
        '200':
          description: An article
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/Article'
  /POSSystem/GetArticles:
    description: Retrieve all your articles
    get:
      summary: Get articles
      operationId: listarticles
      tags:
        - POS Management
      responses:
        '200':
          description: A list of all articles
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Article'
  /POSSystem/GetDepartment:
    description: Retrieve your department over Id
    get:
      summary: Get department
      operationId: department
      parameters:
        - name: id
          in: query
          required: true
          schema:
            type: string
            format: uuid
      tags:
        - POS Management
      responses:
        '200':
          description: A department
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/Department'
  /POSSystem/GetDepartments:
    description: Retrieve all your departments
    get:
      summary: Get departments
      operationId: listdepartments
      tags:
        - POS Management
      responses:
        '200':
          description: A list of all departments
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/Department'
  /POSSystem/GetTable:
    description: Retrieve your table over Id
    get:
      summary: Get table
      operationId: table
      parameters:
        - name: id
          in: query
          required: true
          schema:
            type: string
            format: uuid
      tags:
        - POS Management
      responses:
        '200':
          description: A table
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/Table'
  /POSSystem/GetTables:
    description: Retrieve all your tables
    get:
      summary: Get tables
      operationId: listtables
      tags:
        - POS Management
      responses:
        '200':
          description: A list of all tables
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Table'
  /POSTransaction/GetInvoice:
    description: Retreive invoice from the provided id
    get:
      parameters:
        - name: id
          in: query
          required: true
          schema:
            type: string
            format: uuid
        - name: includeBookings
          in: query
          required: false
          schema:
            type: boolean
        - name: includePayments
          in: query
          required: false
          schema:
            type: boolean
      summary: Get invoice
      operationId: invoice
      tags:
        - POS Transaction
      responses:
        '200':
          description: The invoice from the provided id
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/Invoice'
  /POSTransaction/GetInvoices:
    description: Retreive all invoices from the provided timespan
    get:
      parameters:
        - name: from
          in: query
          required: true
          example: '2025-06-11'
          description: Start date (inclusive) for filtering invoices.
          schema:
            type: string
            format: date
        - name: to
          in: query
          required: true
          example: '2025-06-11'
          schema:
            type: string
            format: date
          description: End date (inclusive) for filtering invoices.
        - name: includeBookings
          in: query
          required: false
          schema:
            type: boolean
        - name: includePayments
          in: query
          required: false
          schema:
            type: boolean
      summary: Get invoices
      operationId: listinvoices
      tags:
        - POS Transaction
      responses:
        '200':
          description: A list of the invoices from the time period
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Invoice'
  /PMSInterface/SetInhouse:
    description: Retreive all invoices from the provided timespan
    post:
      summary: Set inhouse guests
      operationId: setinhouse
      tags:
        - POS-PMS Interface
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: array
              items:
                $ref: '#/components/schemas/Inhouse'
      responses:
        '200':
          description: Ok
  /PMSInterface/GetTransfers:
    description: Retreive all transfers from the provided day
    get:
      parameters:
        - name: from
          in: query
          required: true
          example: '2025-06-11'
          description: Date for the transfers.
          schema:
            type: string
            format: date
      summary: Get transfers
      operationId: gettransfers
      tags:
        - POS-PMS Interface
      responses:
        '200':
          description: A list of the transfers from the day
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/PMSTransfer'
  /PMSInterface/GetPendingTransfers:
    description: >-
      Retreive all pending transfers. After the request all pending transfers
      count as transfered.
    get:
      summary: Get pending transfers
      operationId: getpendingtransfers
      tags:
        - POS-PMS Interface
      responses:
        '200':
          description: >-
            ⚠️ **Warning:** Calling this endpoint *marks all returned transfers
            as **transferred***.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/PMSTransfer'
  /PMSInterface/GetDailyRevenues:
    description: Get the daily revenue from the provided day
    get:
      parameters:
        - name: from
          in: query
          required: true
          example: '2025-06-11'
          description: Date for the transfers.
          schema:
            type: string
            format: date
      summary: Get daily revenues
      operationId: getdailyrevenues
      tags:
        - POS-PMS Interface
      responses:
        '200':
          description: Revenues from the day
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/PMSDailyRevenueDTO'
  /PMSInterface/GetTransferReport:
    description: Get the PMS Transfer report in base64 as pdf
    get:
      parameters:
        - name: transferId
          in: query
          required: true
          example: 6BB44647-7AAC-452F-820F-FEDFFC8BA229
          description: Id from the transfer.
          schema:
            type: string
            format: uuid
      summary: Get transfer report
      operationId: getpmstransferreport
      tags:
        - POS-PMS Interface
      responses:
        '200':
          description: Get the PMS Transfer report in base64 as pdf
          content:
            application/json:
              schema:
                type: object
                $ref: '#/components/schemas/RenderedReportDTO'
components:
  schemas:
    BaseEntityWithChangeInfo:
      type: object
      description: Base entity with audit information
      properties:
        _id:
          type: string
          format: uuid
          description: Unique identifier
          example: 6c0df0b4-4a8a-4278-8b47-5e68f32b6658
        createdOnUTC:
          type: string
          format: date-time
          description: Timestamp when the entity was created (UTC)
          example: '2025-01-23T12:34:56Z'
        createdByUserName:
          type: string
          description: Username of the creator
          example: Peter
        modifiedOnUTC:
          oneOf:
            - type: string
              format: date-time
            - type: 'null'
          description: Timestamp when the entity was last modified (UTC)
        modifiedByUserName:
          oneOf:
            - type: string
            - type: 'null'
          description: Username of the last modifying user
    CommodityGroups:
      type: object
      properties:
        _id:
          type: string
          format: uuid
          description: Unique identifier for the commodity group
          example: 6c0df0b4-4a8a-4278-8b47-5e68f32b6658
        _sc:
          type: string
          format: uuid
          description: The stationcode
          example: 6c0df0b4-4a8a-4278-8b47-5e68f32b6658
        createdOnUTC:
          type: string
          format: date-time
          example: '1889-03-10T23:50:00Z'
        createdByUserName:
          type: string
          description: The user who created it
        modifiedOnUTC:
          type: string
          format: date-time
          example: '1889-03-10T23:50:00Z'
        modifiedByUserName:
          type: string
          description: The user who modified it
        parentCommodityGroupId:
          type: string
          format: uuid
        name:
          type: string
          description: The name of the commodity group
        description:
          type: string
          description: The description of the commodity group
        isActive:
          type: boolean
          description: Determents if it is active or not
        taxId:
          type: string
          format: uuid
        sort:
          type: number
    Invoice:
      type: object
      description: Represents an invoice in the POS system.
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier of the invoice.
        number:
          type: string
          description: Invoice number.
        timestamp:
          type: string
          format: date-time
          description: Date and time when the invoice was created.
        tableId:
          type: string
          format: uuid
          description: Identifier of the table related to this invoice.
        tableInvoiceCarrierId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Optional ID of the invoice carrier for the table.
        priceGrossTotal:
          type: number
          format: decimal
          description: Total gross price of the invoice.
        customerSalutationId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Optional salutation of the customer.
        customerName01:
          oneOf:
            - type: string
            - type: 'null'
          description: First line of the customer name.
        customerName02:
          oneOf:
            - type: string
            - type: 'null'
          description: Second line of the customer name.
        customerStreet:
          oneOf:
            - type: string
            - type: 'null'
          description: Customer street.
        customerZip:
          oneOf:
            - type: string
            - type: 'null'
          description: Customer ZIP code.
        customerCity:
          oneOf:
            - type: string
            - type: 'null'
          description: Customer city.
        customerCountryId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Country ID of the customer.
        customerVatId:
          oneOf:
            - type: string
            - type: 'null'
          description: Customer VAT ID.
        customerId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Reference to the customer.
        headerText:
          oneOf:
            - type: string
            - type: 'null'
          description: Optional header text printed on the invoice.
        footerText:
          oneOf:
            - type: string
            - type: 'null'
          description: Optional footer text printed on the invoice.
        isCancelled:
          type: boolean
          description: Indicates if the invoice is cancelled.
        isRetrieved:
          type: boolean
          description: Indicates if the invoice was retrieved.
        isCorrected:
          type: boolean
          description: Indicates if the invoice was corrected.
        correctedOn:
          oneOf:
            - type: string
              format: date-time
            - type: 'null'
          description: Date and time when the invoice was corrected.
        cancelledOn:
          oneOf:
            - type: string
              format: date-time
            - type: 'null'
          description: Date and time when the invoice was cancelled.
        cancelledByUserId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: User who cancelled the invoice.
        cancelledInvoiceId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Reference to the invoice that was cancelled.
        createdByUserId:
          type: string
          format: uuid
          description: User who created the invoice.
        paymentMethodInfo:
          type: string
          description: Information about the payment method used.
        dailyClosingId:
          oneOf:
            - type: string
              format: uuid
            - type: 'null'
          description: Reference to the related daily closing.
        statisticsValueDate:
          type: string
          format: date
          description: Date used for statistical purposes.
        invoiceType:
          type: integer
          description: >-
            Type of the invoice (enum EnInvoiceType, e.g. 0 = Default, 10 =
            Effort, 20 = PMS Transfer).
        customerName:
          oneOf:
            - type: string
            - type: 'null'
          description: Full customer name (combined).
        priceGrossTotalString:
          type: string
          description: Formatted string of total gross price.
        wsNumber:
          type: integer
          description: Workstation number where the invoice was generated.
        bookings:
          oneOf:
            - type: array
              description: List of bookings that belong to this invoice.
              items:
                $ref: '#/components/schemas/Booking'
            - type: 'null'
        invoicePayments:
          oneOf:
            - type: array
              description: List of payments related to this invoice.
              items:
                $ref: '#/components/schemas/InvoicePayment'
            - type: 'null'
    Article:
      allOf:
        - $ref: '#/components/schemas/BaseEntityWithChangeInfo'
        - type: object
          description: Represents a POS article.
          properties:
            number:
              type: string
              description: Unique article number.
            name:
              type: string
              description: Article name.
            description:
              oneOf:
                - type: string
                - type: 'null'
              description: Optional article description.
            isActive:
              type: boolean
              description: Indicates whether the article is active.
              default: true
            type:
              type: integer
              description: Numeric article type (based on EnArticleType).
              example: 0
            commodityGroupId:
              type: string
              format: uuid
              description: ID of the commodity group.
            commodityGroup:
              oneOf:
                - $ref: '#/components/schemas/CommodityGroups'
                - type: 'null'
              description: Related commodity group entity.
            courseId:
              oneOf:
                - type: string
                  format: uuid
                - type: 'null'
              description: Optional course ID.
            costs:
              type: number
              format: double
              description: Cost price of the article.
            textEntryForBooking:
              type: boolean
              description: Requires a text entry during booking.
              default: false
            priceEntryForBooking:
              type: boolean
              description: Requires a manual price input during booking.
              default: false
            externalDocumentNumberEntryForBooking:
              type: boolean
              description: Requires an external document number during booking.
              default: false
            isNegative:
              type: boolean
              description: Indicates that the article is a negative item (e.g., discount).
              default: false
            priceGross:
              type: number
              format: double
              description: Gross price of the article.
            priceListPrices:
              oneOf:
                - type: array
                - type: 'null'
              x-not-supported: true
              description: Field reserved for future features.
            printerIds:
              oneOf:
                - type: array
                  items:
                    type: string
                    format: uuid
                - type: 'null'
              description: List of printer IDs.
            barcodes:
              oneOf:
                - type: array
                  items:
                    type: string
                - type: 'null'
              description: List of barcodes associated with the article.
            articlePackageDetails:
              oneOf:
                - type: array
                - type: 'null'
              x-not-supported: true
              description: Field reserved for future features.
            articlePackageGroups:
              oneOf:
                - type: array
                - type: 'null'
              x-not-supported: true
              description: Field reserved for future features.
            articleAddons:
              oneOf:
                - type: array
                - type: 'null'
              x-not-supported: true
              description: Field reserved for future features.
    Department:
      allOf:
        - $ref: '#/components/schemas/BaseEntityWithChangeInfo'
        - type: object
          description: Represents a POS department.
          properties:
            name:
              type: string
              description: Department name.
            discountRate:
              type: number
              format: double
              description: Default discount rate for this department.
              example: 0
            isActive:
              type: boolean
              description: Indicates whether the department is active.
              default: true
            sort:
              type: integer
              format: int32
              description: Sort order for displaying the department.
              example: 99999999
            tables:
              oneOf:
                - type: array
                  items:
                    $ref: '#/components/schemas/Table'
                - type: 'null'
              description: List of tables belonging to this department.
    Table:
      allOf:
        - $ref: '#/components/schemas/BaseEntityWithChangeInfo'
        - type: object
          description: Represents a table in a POS department.
          properties:
            departmentId:
              type: string
              format: uuid
              description: ID of the department this table belongs to.
            department:
              oneOf:
                - $ref: '#/components/schemas/Department'
                - type: 'null'
              description: Related department entity.
            number:
              type: integer
              format: int32
              description: Table number.
            name:
              type: string
              description: Table name or label.
            isActive:
              type: boolean
              description: Indicates whether the table is active.
              default: true
            recalledCourseId:
              oneOf:
                - type: string
                  format: uuid
                - type: 'null'
              description: Optional ID of the recalled course.
            tableType:
              type: integer
              format: int32
              description: Table type identifier.
              example: 0
    Booking:
      type: object
      description: Represents a single booking entry in the POS system.
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier of the booking.
        tableId:
          type: string
          format: uuid
          description: Identifier of the table where the booking was made.
        tableInvoiceCarrierId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Optional ID of the invoice carrier for the table.
        articleId:
          type: string
          format: uuid
          description: Identifier of the related article.
        createdByUserId:
          type: string
          format: uuid
          description: Identifier of the user who created the booking.
        parentBookingId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Identifier of the parent booking, if this is a sub-booking.
        courseId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Optional ID of the course.
        bookingTimestamp:
          type: string
          format: date-time
          description: Timestamp when the booking was created.
        statisticsValueDate:
          type: string
          format: date
          description: Date used for statistical evaluations.
        bookingText:
          type: string
          maxLength: 400
          description: Descriptive text of the booking.
        quantity:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Quantity booked.
        taxRate:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Tax rate applied to the booking.
        priceNet:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Net price of a single item.
        priceTax:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Tax amount for a single item.
        priceGross:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Gross price of a single item.
        priceNetTotal:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Total net amount (quantity * price).
        priceTaxTotal:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Total tax amount (quantity * tax).
        priceGrossTotal:
          type: number
          format: decimal
          multipleOf: 1.e-8
          description: Total gross amount (quantity * gross).
        discount:
          oneOf:
            - type: number
            - type: 'null'
          format: decimal
          multipleOf: 1.e-8
          description: Optional discount amount applied.
        discountType:
          type: integer
          description: Type of discount (enum EnDiscountType).
        discountPercent:
          oneOf:
            - type: number
            - type: 'null'
          format: decimal
          multipleOf: 1.e-8
          description: Optional discount percentage.
        isPriceChanged:
          type: boolean
          description: Indicates if the price was manually changed.
        isCancelled:
          type: boolean
          description: Indicates if the booking was cancelled.
        bookingCancellationReasonId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Reason ID for the cancellation, if applicable.
        cancelledOn:
          oneOf:
            - type: string
            - type: 'null'
          format: date-time
          description: Date and time when the booking was cancelled.
        cancelledByUserId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: User who cancelled the booking.
        bookingOrderReceiptId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Reference to the related order receipt.
        invoiceId:
          oneOf:
            - type: string
            - type: 'null'
          format: uuid
          description: Reference to the associated invoice.
        printers:
          oneOf:
            - type: string
            - type: 'null'
          description: Printer configuration for this booking.
        commodityGroupId:
          type: string
          format: uuid
          description: Reference to the related commodity group.
        test:
          type: integer
          description: Article type (enum EnArticleType).
        sequence:
          type: number
          format: decimal
          multipleOf: 0.0001
          description: Sequence number used for ordering bookings.
        externalDocumentNumber:
          oneOf:
            - type: string
            - type: 'null'
          description: External document number (if available).
    InvoicePayment:
      type: object
      description: Represents a single payment entry associated with an invoice.
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier of the invoice payment.
        invoiceId:
          type: string
          format: uuid
          description: Identifier of the related invoice.
        paymentMethodId:
          type: string
          format: uuid
          description: Identifier of the payment method used.
        amount:
          type: number
          format: decimal
          description: Amount paid with this payment method.
        name:
          type: string
          description: Name of the payment method (e.g. Cash, Card, Voucher).
        timestamp:
          type: string
          format: date-time
          description: Date and time when the payment was recorded.
    Inhouse:
      type: object
      description: Represents a single inhouse entry.
      properties:
        reservationId:
          type: string
          description: Unique reservation id from the PMS System.
        roomNr:
          type: string
          description: Room number from the PMS System.
        bed:
          type: string
          description: Bed from the PMS System.
        resText:
          type: string
          description: Reservation text from the PMS System.
        guestNr:
          type: string
          description: Guest number from the PMS System.
        tableCode:
          oneOf:
            - type: integer
            - type: 'null'
          description: Table code for mapping with the POS Table.
        arrivalDate:
          type: string
          format: date-time
          description: Date and time when the guest arrive.
        departureDate:
          type: string
          format: date-time
          description: Date and time when the guest depart.
    PMSTransfer:
      allOf:
        - $ref: '#/components/schemas/BaseEntityWithChangeInfo'
        - type: object
          description: Represents a PMSTransfer.
          properties:
            number:
              type: string
              description: Pms transfer number.
            roomNr:
              type: string
              description: The room number.
            bed:
              type: string
              description: The bed.
            resNr:
              type: string
              description: The reservation number.
            resText:
              type: string
              description: The reservation text.
            guestNr:
              type: integer
              description: The guest number
            isTransfered:
              type: boolean
              description: Determense if the PMS Transfer is already transfered
            invoiceId:
              type: string
              format: uuid
              description: The associated invoice id
            invoice:
              $ref: '#/components/schemas/Invoice'
    PMSDailyRevenueDTO:
      type: object
      properties:
        date:
          type: string
          format: date-time
        revenues:
          type: array
          items:
            $ref: '#/components/schemas/PMSRevenueDTO'
        payments:
          type: array
          items:
            $ref: '#/components/schemas/PMSPaymentDTO'
    PMSRevenueDTO:
      type: object
      properties:
        itemGroupId:
          type: string
          format: uuid
        itemGroup:
          type: string
        taxRate:
          type: number
          format: decimal
        amount:
          type: number
          format: decimal
    PMSPaymentDTO:
      type: object
      properties:
        paymentMethodId:
          type: string
          format: uuid
        paymentMethod:
          type: string
        amount:
          type: number
          format: decimal
    RenderedReportDTO:
      type: object
      properties:
        name:
          type: string
        exportFormat:
          type: integer
          default: 0
          description: 0 = PDF
        contentBase64:
          type: string
          format: base64
        mdcInBase64:
          type: string
          format: base64
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: API Key
