---
openapi: 3.0.1
info:
  title: CustomerOrder
  description: API specifications for API Customer Order interface issued by SOGET
  contact:
    name: SOGET S.A.
    url: https://www.soget.fr/
    email: hello@soget.fr
  license:
    name: Copyright © SOGET
    url: https://www.soget.fr/
  version: v1
paths:
  "/customer-orders":
    post:
      tags:
      - CustomerOrders
      summary: Create a new customer order.
      description: "Sample request:\n            \n    POST /customer-orders\n            \nYou
        have to call this service with following conditions:\n1. Content-Type: multipart/form-data\n2.
        1st part: customer order data. The part name is \"order\"\n3. 2nd part: List
        of attached documents. The part name is \"files\""
      operationId: Create
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                Order:
                  "$ref": "#/components/schemas/CustomerOrderPost"
                Files:
                  type: array
                  items:
                    type: string
                    format: binary
                  description: IFormFile form multipart/form-data
      responses:
        '200':
          description: Identifiers of created customer order and all the associated
            segments.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/CustomerOrderCreationResponse"
            application/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrderCreationResponse"
            text/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrderCreationResponse"
        '400':
          description: Failed to create a new customer order.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
    get:
      tags:
      - CustomerOrders
      summary: Filter customer orders by given parameters.
      description: "Sample request:\n            \n    GET /customer-orders?transportOrderNumber=TOC-02-03-2022&offset=0&limit=10&isProjection=true"
      operationId: Filter
      parameters:
      - name: transportOrderNumber
        in: query
        description: Transport order number.
        schema:
          type: string
      - name: containerNumber
        in: query
        description: Container reference number.
        schema:
          type: string
      - name: carrierCode
        in: query
        description: Carrier code.
        schema:
          type: string
      - name: processingIndicator
        in: query
        description: Processing indicator.
        schema:
          "$ref": "#/components/schemas/CustomsFlag"
      - name: startDate
        in: query
        description: Start of search range for creation date (included)
        schema:
          type: string
          format: date-time
      - name: endDate
        in: query
        description: End of search range for creation date (included)
        schema:
          type: string
          format: date-time
      - name: status
        in: query
        description: Order status.
        schema:
          "$ref": "#/components/schemas/CustomerOrderStatus"
      - name: offset
        in: query
        description: Index of the first returned result.
        schema:
          type: integer
          format: int32
          default: 0
      - name: limit
        in: query
        description: Number of results to be returned. Max value is 50.
        schema:
          type: integer
          format: int32
          default: 10
      - name: desc
        in: query
        description: Indicate the sorting order based on transport order id field.
          The default value is FALSE, which means the API will sort the returned list
          by ascending order.
        schema:
          type: boolean
          default: false
      - name: isProjection
        in: query
        description: |-
          Determine that response model should be a complete model or a light model.
                       If this parameter is set to true, server returns the light version of segment.
                       Otherwise, it will returns all order information.
        schema:
          type: boolean
          default: false
      responses:
        '200':
          description: Successful operation.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/CustomerOrderProjectionPagedList"
            application/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrderProjectionPagedList"
            text/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrderProjectionPagedList"
        '400':
          description: Bad request.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
  "/customer-orders/{id}":
    get:
      tags:
      - CustomerOrders
      summary: Get customer order information by its identifiers.
      description: "Sample request:\n            \n    GET /customer-orders/CDE0000000001"
      operationId: GetById
      parameters:
      - name: id
        in: path
        description: Customer order identifier
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Successful operation.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/CustomerOrder"
            application/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrder"
            text/json:
              schema:
                "$ref": "#/components/schemas/CustomerOrder"
        '400':
          description: Bad request.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
        '404':
          description: Customer order not found.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
  "/customer-orders/{orderId}/incident-pictures/{pictureId}":
    get:
      tags:
      - CustomerOrders
      summary: Get an incident picture by its identifier.
      description: "Sample request:\n            \n    GET /customer-orders/CDE0000000001/incident-pictures/12"
      operationId: GetPictureById
      parameters:
      - name: orderId
        in: path
        description: Customer order identifier.
        required: true
        schema:
          type: string
      - name: pictureId
        in: path
        description: Picture identifier.
        required: true
        schema:
          type: integer
          format: int32
      responses:
        '200':
          description: Successful operation.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/IncidentPicture"
            application/json:
              schema:
                "$ref": "#/components/schemas/IncidentPicture"
            text/json:
              schema:
                "$ref": "#/components/schemas/IncidentPicture"
        '400':
          description: Bad request.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
  "/customer-orders/{orderId}":
    put:
      tags:
      - CustomerOrders
      summary: Update an existing customer order.
      description: "Sample request:\n            \n    PUT /customer-orders/CDE0000000001"
      operationId: Update
      parameters:
      - name: orderId
        in: path
        description: Customer order identifier
        required: true
        schema:
          type: string
      - name: If-Match
        in: header
        description: ETag value to determine resource version.
        required: true
        schema:
          type: string
      requestBody:
        description: Information of customer order
        content:
          application/json-patch+json:
            schema:
              "$ref": "#/components/schemas/CustomerOrderPut"
          application/json:
            schema:
              "$ref": "#/components/schemas/CustomerOrderPut"
          text/json:
            schema:
              "$ref": "#/components/schemas/CustomerOrderPut"
          application/*+json:
            schema:
              "$ref": "#/components/schemas/CustomerOrderPut"
      responses:
        '200':
          description: Successful operation.
        '400':
          description: Bad request.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
        '412':
          description: PreconditionFailed.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
    delete:
      tags:
      - CustomerOrders
      summary: Cancel a customer order.
      description: "Sample request:\n            \n    DELETE /customer-orders/CDE0000000001"
      operationId: Cancel
      parameters:
      - name: orderId
        in: path
        description: Customer order identifier.
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Successful operation.
        '400':
          description: Bad request.
          content:
            text/plain:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            application/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
            text/json:
              schema:
                "$ref": "#/components/schemas/HttpBusinessError"
components:
  schemas:
    Actor:
      type: object
      properties:
        code:
          maxLength: 32
          type: string
          description: |2-

            Actor code.

            Detailed information is available in the API Referential.
          nullable: true
          example: SOGETS.
        name:
          maxLength: 256
          type: string
          description: Actor name.
          nullable: true
          example: SOGET SA
        company:
          "$ref": "#/components/schemas/Company"
        contact:
          "$ref": "#/components/schemas/Contact"
      additionalProperties: false
      description: Actor information.
    AdditionalData:
      required:
      - key
      type: object
      properties:
        key:
          maxLength: 256
          minLength: 1
          type: string
          description: Key of the additional data (unique per order).
          example: VOYAGEEXPORT
        value:
          type: string
          description: Value of the additional data.
          nullable: true
          example: EX1234
      additionalProperties: false
      description: Additional data for customer order.
    BusinessErrorCode:
      enum:
      - ACTOR_NOT_FOUND
      - ALREADY_JOINED_GROUP
      - CANNOT_CANCEL_NOT_MASTER_ORDER
      - CANNOT_CANCEL_ORDER_WITH_ASSOCIATED_CONTAINER
      - CANNOT_CHANGE_NUMBER_OF_CONTAINERS
      - CANNOT_UPDATE_VALID_ORDER_TO_DRAFT
      - CARRIER_EMAIL_REQUIRED
      - CONFLICT
      - CONTRACTOR_UNAUTHORIZED_BY_GEDMOUV
      - CUSTOMER_ORDER_NOT_FOUND
      - CUSTOMS_FLAG_NOT_BE_MODIFIED
      - EVENT_LOCATION_FIELDS_REQUIRED
      - EVENT_START_DATE_REQUIRED
      - EXISTS_ORDER_WITH_HANDLING_UNIT_SPI
      - HANDLING_UNIT_REFERENCE_INVALID
      - LIMIT_NONPOSITIVE
      - NOT_SUPPORTED_ORDER_TYPE
      - OFFSET_NEGATIVE
      - ORDER_ALREADY_CANCELED
      - ORDER_DUPLICATED
      - ORGANIZATION_ACTOR_CODE_INVALID
      - ORGANIZATION_NOT_FOUND
      - R0005
      - R0006
      - R0007
      - R0008
      - R0009
      - SEARCH_DATE_ERROR
      - UNKNOWN_LOCATION
      - USER_ID_INVALID
      - WRONG_EVENT_DATE_ORDER
      - WRONG_FORMAT
      type: string
      description: "Error that could be returned by the system.<ul><li><i>ACTOR_NOT_FOUND</i>:
        Actor indicated in order doesn't exist in MouvONE.</li><li><i>ALREADY_JOINED_GROUP</i>:
        User has already joined a group</li><li><i>CANNOT_CANCEL_NOT_MASTER_ORDER</i>:
        You can only cancel an order if type of the order is Master. \n            It's
        not allowed to cancel an Elementary or Segment order.</li><li><i>CANNOT_CANCEL_ORDER_WITH_ASSOCIATED_CONTAINER</i>:
        Order cannot be cancelled because the container has been associated with a
        booking.</li><li><i>CANNOT_CHANGE_NUMBER_OF_CONTAINERS</i>: You can't change
        the number of containers when updating an order.</li><li><i>CANNOT_UPDATE_VALID_ORDER_TO_DRAFT</i>:
        Cannot update order status from VALID to DRAFT.</li><li><i>CARRIER_EMAIL_REQUIRED</i>:
        If carrier in the given order is unknown by GEDMOUV, then the carrier email
        is required.</li><li><i>CONFLICT</i>: This error can happens if you try to
        update an order but it has been updated by another user so your version has
        been out-dated. \n            You have to update your local version with the
        latest one before you can make any changes.</li><li><i>CONTRACTOR_UNAUTHORIZED_BY_GEDMOUV</i>:
        A contractor unknown by GEDMOUV is not allowed to create new transport order.</li><li><i>CUSTOMER_ORDER_NOT_FOUND</i>:
        Order doesn't exist in MouvONE.</li><li><i>CUSTOMS_FLAG_NOT_BE_MODIFIED</i>:
        You can't modify customs flag of an order.</li><li><i>EVENT_LOCATION_FIELDS_REQUIRED</i>:
        The fields of event location is required.</li><li><i>EVENT_START_DATE_REQUIRED</i>:
        Start date of event is required.</li><li><i>EXISTS_ORDER_WITH_HANDLING_UNIT_SPI</i>:
        Exists order with the given handling unit spi.</li><li><i>HANDLING_UNIT_REFERENCE_INVALID</i>:
        Container number must contain letters and/ or numbers and has max length of
        11</li><li><i>LIMIT_NONPOSITIVE</i>: The LIMIT parameter must be greater than
        0 when searching order.</li><li><i>NOT_SUPPORTED_ORDER_TYPE</i>: The type
        of order is not supported for requested action.</li><li><i>OFFSET_NEGATIVE</i>:
        The OFFSET parameter cannot be negative when searching order.</li><li><i>ORDER_ALREADY_CANCELED</i>:
        The order has already been cancelled.</li><li><i>ORDER_DUPLICATED</i>: You
        cannot create order if an order with the same characteristics already exists.</li><li><i>ORGANIZATION_ACTOR_CODE_INVALID</i>:
        An organization must be verified by a SOGET administrator before its members
        can create and manage orders. Let's contact SOGET if you encounter this error.</li><li><i>ORGANIZATION_NOT_FOUND</i>:
        A user must belong to an organization to be able to create and manage orders.</li><li><i>R0005</i>:
        Cannot update information of containers and events.</li><li><i>R0006</i>:
        Cannot update order if it is in certain status.</li><li><i>R0007</i>: Cannot
        update container references.</li><li><i>R0008</i>: Cannot cancel the order
        due to the status is Submitted or InProgress.</li><li><i>R0009</i>: Cannot
        cancel the order that at least one of its segment is delivered.</li><li><i>SEARCH_DATE_ERROR</i>:
        Date parameters is invalid when searching order.</li><li><i>UNKNOWN_LOCATION</i>:
        Location is unknown by MouvONE.</li><li><i>USER_ID_INVALID</i>: User ID is
        invalid.</li><li><i>WRONG_EVENT_DATE_ORDER</i>: Dates of events must be in
        chronological order.\n            For Import order: LadingImport -&gt; DeliveryImport
        -&gt; EmptyReleaseImport -&gt; EmptyReturnImport.\n            For Export
        order: EmptyReleaseExport -&gt; PositioningExport -&gt; LadingExport -&gt;
        DeliveryExport.</li><li><i>WRONG_FORMAT</i>: Order identifier is in wrong
        format.</li></ul>"
    Company:
      type: object
      properties:
        name:
          maxLength: 64
          type: string
          description: Name of the agency.
          nullable: true
          example: ABC Logistics
        location:
          "$ref": "#/components/schemas/Location"
      additionalProperties: false
      description: Company information.
    Contact:
      type: object
      properties:
        name:
          maxLength: 255
          type: string
          description: Name of the contact (person, department,...).
          nullable: true
          example: SA Soget
        email:
          maxLength: 255
          type: string
          description: Email address.
          nullable: true
          example: hello@soget.fr
        phone:
          maxLength: 255
          type: string
          description: Phone number.
          nullable: true
          example: '0235123456'
      additionalProperties: false
      description: Contact information.
    Container:
      required:
      - events
      type: object
      properties:
        containerId:
          type: integer
          description: Entity identifier.
          format: int32
          nullable: true
          example: 1
        spi:
          maxLength: 13
          minLength: 13
          type: string
          description: |-
            S ONE ID of the container.

            This unique identifier is composed of a prefix(3 characters) and a number(10 digits).
          nullable: true
          example: CNI0000063978
        rank:
          type: integer
          description: Rank of container.
          format: int32
          nullable: true
        rangeMin:
          type: number
          description: Min temperature value received from the Gedmouv system (unit
            in DEG), indicated by the carrier.
          format: double
          nullable: true
        rangeMax:
          type: number
          description: Max temperature value received from the Gedmouv system (unit
            in DEG), indicated by the carrier.
          format: double
          nullable: true
        reefer:
          "$ref": "#/components/schemas/Reefer"
        oog:
          "$ref": "#/components/schemas/OutOfGauge"
        events:
          type: array
          items:
            "$ref": "#/components/schemas/EventGet"
          description: List of events
          nullable: true
        goods:
          type: array
          items:
            "$ref": "#/components/schemas/Goods"
          description: Goods
          nullable: true
        reference:
          type: string
          description: Container number. It's mandatory for import and transfer flow.
          nullable: true
          example: CGMU1234567
        type:
          maxLength: 4
          minLength: 4
          type: string
          description: |2-

            Size type. It's mandatory for export flow.

            Detailed information is available in the API Referential.
          nullable: true
          example: 22G1
        grossWeight:
          type: number
          description: Gross weight of container (unit in KGM).
          format: double
          nullable: true
          example: 2000
        tare:
          type: number
          description: Weight of empty container (unit in KGM).
          format: double
          nullable: true
          example: 200.5
        sealNumbers:
          type: array
          items:
            type: string
          description: List of seal numbers of container.
          nullable: true
        indicator:
          "$ref": "#/components/schemas/ContainerIndicator"
        customsInformation:
          maxLength: 64
          type: string
          description: Customs information.
          nullable: true
          example: Customs passed at MTDF
        comment:
          maxLength: 1024
          type: string
          description: Comment about the container.
          nullable: true
          example: This is a new container
        billOfLading:
          maxLength: 256
          type: string
          description: Bill of lading. It's available for import and transfer flow.
          nullable: true
          example: BOL-12-345-6789
        bookingNumber:
          maxLength: 256
          type: string
          description: Booking reference. It's mandatory for export flow. Available
            for export and transfer flow.
          nullable: true
          example: BCK-03-03-2022
      additionalProperties: false
      description: Information about the entity to be transported, usually a container.
    ContainerBase:
      required:
      - events
      type: object
      properties:
        goods:
          type: array
          items:
            "$ref": "#/components/schemas/Goods"
          description: Goods
          nullable: true
        reference:
          type: string
          description: Container number. It's mandatory for import and transfer flow.
          nullable: true
          example: CGMU1234567
        type:
          maxLength: 4
          minLength: 4
          type: string
          description: |2-

            Size type. It's mandatory for export flow.

            Detailed information is available in the API Referential.
          nullable: true
          example: 22G1
        grossWeight:
          type: number
          description: Gross weight of container (unit in KGM).
          format: double
          nullable: true
          example: 2000
        tare:
          type: number
          description: Weight of empty container (unit in KGM).
          format: double
          nullable: true
          example: 200.5
        sealNumbers:
          type: array
          items:
            type: string
          description: List of seal numbers of container.
          nullable: true
        indicator:
          "$ref": "#/components/schemas/ContainerIndicator"
        customsInformation:
          maxLength: 64
          type: string
          description: Customs information.
          nullable: true
          example: Customs passed at MTDF
        comment:
          maxLength: 1024
          type: string
          description: Comment about the container.
          nullable: true
          example: This is a new container
        reefer:
          "$ref": "#/components/schemas/Reefer"
        oog:
          "$ref": "#/components/schemas/OutOfGauge"
        billOfLading:
          maxLength: 256
          type: string
          description: Bill of lading. It's available for import and transfer flow.
          nullable: true
          example: BOL-12-345-6789
        bookingNumber:
          maxLength: 256
          type: string
          description: Booking reference. It's mandatory for export flow. Available
            for export and transfer flow.
          nullable: true
          example: BCK-03-03-2022
        events:
          type: array
          items:
            "$ref": "#/components/schemas/EventBase"
          description: "List of events (must contains exactly 4 events with import/
            export order and 2 events with transfer order)\n\n\n\nList of mandatory
            events when creating an export order:\n\n\n- EmptyReleaseExport: Empty
            container made available.\n- PositioningExport: Empty container positioned.\n-
            LadingExport: Full container export handled.\n- DeliveryExport: Full export
            container delivered.\n     \nList of mandatory events when creating an
            import order:\n\n\n- LadingImport: Full container import handled.\n- DeliveryImport:
            Full container import delivered.\n- EmptyReleaseImport: Empty container
            recovered.\n- EmptyReturnImport: Empty container returned.\n\nList of
            mandatory events when creating a transfer order:\n\n\n- LadingTransfer:
            Full container handled.\n- DeliveryTransfer: Full container delivered.\n"
          nullable: true
      additionalProperties: false
      description: Container base payload.
    ContainerIndicator:
      type: object
      properties:
        isReefer:
          type: boolean
          description: "Reefer indicator. \n\n Default value: false."
          nullable: true
          example: false
        isHazardous:
          type: boolean
          description: "Hazardous indicator. \n\nDefault value: false."
          nullable: true
          example: false
        isOog:
          type: boolean
          description: "Out of gauge indicator. \n\nDefault value: false."
          nullable: true
          example: false
      additionalProperties: false
      description: Indicators information.
    ContainerPost:
      required:
      - events
      type: object
      properties:
        reference:
          type: string
          description: Container number. It's mandatory for import and transfer flow.
          nullable: true
          example: CGMU1234567
        type:
          maxLength: 4
          minLength: 4
          type: string
          description: |2-

            Size type. It's mandatory for export flow.

            Detailed information is available in the API Referential.
          nullable: true
          example: 22G1
        grossWeight:
          type: number
          description: Gross weight of container (unit in KGM).
          format: double
          nullable: true
          example: 2000
        tare:
          type: number
          description: Weight of empty container (unit in KGM).
          format: double
          nullable: true
          example: 200.5
        sealNumbers:
          type: array
          items:
            type: string
          description: List of seal numbers of container.
          nullable: true
        indicator:
          "$ref": "#/components/schemas/ContainerIndicator"
        customsInformation:
          maxLength: 64
          type: string
          description: Customs information.
          nullable: true
          example: Customs passed at MTDF
        comment:
          maxLength: 1024
          type: string
          description: Comment about the container.
          nullable: true
          example: This is a new container
        reefer:
          "$ref": "#/components/schemas/Reefer"
        oog:
          "$ref": "#/components/schemas/OutOfGauge"
        goods:
          type: array
          items:
            "$ref": "#/components/schemas/GoodsPost"
          description: List of goods inside container.
          nullable: true
        billOfLading:
          maxLength: 256
          type: string
          description: Bill of lading. It's available for import and transfer flow.
          nullable: true
          example: BOL-12-345-6789
        bookingNumber:
          maxLength: 256
          type: string
          description: Booking reference. It's mandatory for export flow. Available
            for export and transfer flow.
          nullable: true
          example: BCK-03-03-2022
        events:
          type: array
          items:
            "$ref": "#/components/schemas/EventBase"
          description: "List of events (must contains exactly 4 events with import/
            export order and 2 events with transfer order)\n\n\n\nList of mandatory
            events when creating an export order:\n\n\n- EmptyReleaseExport: Empty
            container made available.\n- PositioningExport: Empty container positioned.\n-
            LadingExport: Full container export handled.\n- DeliveryExport: Full export
            container delivered.\n     \nList of mandatory events when creating an
            import order:\n\n\n- LadingImport: Full container import handled.\n- DeliveryImport:
            Full container import delivered.\n- EmptyReleaseImport: Empty container
            recovered.\n- EmptyReturnImport: Empty container returned.\n\nList of
            mandatory events when creating a transfer order:\n\n\n- LadingTransfer:
            Full container handled.\n- DeliveryTransfer: Full container delivered.\n"
          nullable: true
      additionalProperties: false
      description: Entity model to be sent in customer order when creating a new order.
    CustomerOrder:
      required:
      - carrier
      - containers
      - customerOrderId
      - customsFlag
      - histories
      - status
      - transportOrderNumber
      - type
      type: object
      properties:
        customerOrderId:
          minLength: 1
          type: string
          description: Customer order identifier.
          example: CDE0000000002
        type:
          "$ref": "#/components/schemas/CustomerOrderType"
        status:
          "$ref": "#/components/schemas/CustomerOrderStatus"
        histories:
          minItems: 1
          type: array
          items:
            "$ref": "#/components/schemas/CustomerOrderHistory"
          description: Histories of the order.
        container:
          "$ref": "#/components/schemas/Container"
        contractor:
          "$ref": "#/components/schemas/Actor"
        carrier:
          "$ref": "#/components/schemas/Actor"
        transportOrderNumber:
          maxLength: 256
          minLength: 1
          type: string
          description: Number of transport order.
          example: TOC-02-03-2022
        additionalData:
          type: array
          items:
            "$ref": "#/components/schemas/AdditionalData"
          description: List of additional data.
          nullable: true
        date:
          type: string
          description: |-
            Date of the customer order.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        sender:
          maxLength: 256
          type: string
          description: Name of the person who created the order.
          nullable: true
          example: Dupont Jean
        clientReference:
          maxLength: 256
          type: string
          description: Importer/Exporter reference.
          nullable: true
          example: AUCHAN_12_678
        customsFlag:
          "$ref": "#/components/schemas/CustomsFlag"
        priceInformation:
          maxLength: 1024
          type: string
          description: Comment about pricing.
          nullable: true
          example: Let's apply a discount for this order
        instructionsInformation:
          maxLength: 1024
          type: string
          description: Instructions for the driver.
          nullable: true
          example: This order has to be handled fast!
        contractTermsInformation:
          maxLength: 1024
          type: string
          description: Information about the contract terms.
          nullable: true
          example: International terms and conditions
        comment:
          maxLength: 1024
          type: string
          description: General comments about the transport order.
          nullable: true
          example: This is an urgent transport.
        voyage:
          "$ref": "#/components/schemas/Voyage"
      additionalProperties: false
      description: Customer order payload model.
    CustomerOrderAction:
      enum:
      - CREATE
      - UPDATE
      - DELETE
      type: string
      description: 'List of actions that actor can perform on an order.<ul><li><i>CREATE</i>:
        Create new order.</li><li><i>UPDATE</i>: Update order information.</li><li><i>DELETE</i>:
        Cancel an order.</li></ul>'
    CustomerOrderCreationResponse:
      type: object
      properties:
        elementaryOrders:
          type: array
          items:
            "$ref": "#/components/schemas/ElementaryOrder"
          description: List of elementary orders (used for multi-container case).
          nullable: true
        segments:
          type: array
          items:
            "$ref": "#/components/schemas/Segment"
          description: List of segments (transport segment managed by the carrier).
          nullable: true
        id:
          type: string
          description: |-
            Order identifier that is composed of a prefix of 3 characters and 10 digits.

            The following prefix means :
            - CDE : global customer order
            - ELM : elementary order (used for the multi-container case)
            - SEG : transport segment (managed by the carrier)
          nullable: true
          example: SEG0000000672
        transportOrderNumber:
          type: string
          description: Reference
          nullable: true
          example: OT-0510-1204-1
        type:
          "$ref": "#/components/schemas/CustomerOrderType"
      additionalProperties: false
      description: |-
        Response model when created a new customer order composed of :

        - id : global customer order ID (ex: CDE0000000001).
        - transportOrderNumber : global customer order ref (ex: OT3 MI 560156).
        - type : 'Master' which identifies the global customer order.
        - segments : global customer order is divided into segments managed by the carrier. Each segment is composed of an ID, a ref and a type.
        - elementaryOrders : this field is used in case of a multi-container order : the global customer order is split into an elementary order linked to a container which is split into different segments managed by the carrier.
    CustomerOrderHistory:
      required:
      - action
      - actor
      - date
      - status
      type: object
      properties:
        actor:
          "$ref": "#/components/schemas/Actor"
        date:
          minLength: 1
          type: string
          description: |-
            Date time information.

            ISO 8601 Extended Format
          format: date-time
          example: '2020-05-20T23:00:00+00:00'
        status:
          "$ref": "#/components/schemas/CustomerOrderStatus"
        action:
          "$ref": "#/components/schemas/CustomerOrderAction"
        comment:
          type: string
          description: |-
            Comment about history.
            If order is rejected, a list of reasons will be saved here, separated by commas.
          nullable: true
          example: Dangerous class is incorrect; Reference cannot be null
        details:
          type: array
          items:
            "$ref": "#/components/schemas/CustomerOrderHistoryDetail"
          description: Customer order history details.
          nullable: true
        editor:
          type: string
          description: User name who edits this change.
          nullable: true
      additionalProperties: false
      description: History information of a customer order.
    CustomerOrderHistoryDetail:
      type: object
      properties:
        fieldName:
          type: string
          description: Field name which is edited
          nullable: true
          example: HandlingUnit.Goods[0].Description
        oldValue:
          type: string
          description: Old value
          nullable: true
          example: ABC
        newValue:
          type: string
          description: New value
          nullable: true
          example: DEF
        type:
          "$ref": "#/components/schemas/CustomerOrderPropertyAction"
        fieldType:
          "$ref": "#/components/schemas/PrimitiveFieldType"
      additionalProperties: false
      description: Customer order history detail
    CustomerOrderPost:
      required:
      - carrier
      - containers
      - customsFlag
      - transportOrderNumber
      type: object
      properties:
        contractor:
          "$ref": "#/components/schemas/Actor"
        carrier:
          "$ref": "#/components/schemas/Actor"
        transportOrderNumber:
          maxLength: 256
          minLength: 1
          type: string
          description: Number of transport order.
          example: TOC-02-03-2022
        containers:
          minItems: 1
          type: array
          items:
            "$ref": "#/components/schemas/ContainerPost"
          description: Container.
        additionalData:
          type: array
          items:
            "$ref": "#/components/schemas/AdditionalData"
          description: List of additional data.
          nullable: true
        date:
          type: string
          description: |-
            Date of the customer order.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        sender:
          maxLength: 256
          type: string
          description: Name of the person who created the order.
          nullable: true
          example: Dupont Jean
        clientReference:
          maxLength: 256
          type: string
          description: Importer/Exporter reference.
          nullable: true
          example: AUCHAN_12_678
        customsFlag:
          "$ref": "#/components/schemas/CustomsFlag"
        priceInformation:
          maxLength: 1024
          type: string
          description: Comment about pricing.
          nullable: true
          example: Let's apply a discount for this order
        instructionsInformation:
          maxLength: 1024
          type: string
          description: Instructions for the driver.
          nullable: true
          example: This order has to be handled fast!
        contractTermsInformation:
          maxLength: 1024
          type: string
          description: Information about the contract terms.
          nullable: true
          example: International terms and conditions
        comment:
          maxLength: 1024
          type: string
          description: General comments about the transport order.
          nullable: true
          example: This is an urgent transport.
        voyage:
          "$ref": "#/components/schemas/Voyage"
      additionalProperties: false
      description: Model to be sent to server when you want to create a new customer
        order.
    CustomerOrderProjection:
      required:
      - carrier
      - contractor
      - customerOrderId
      - customsFlag
      - date
      - status
      - transportOrderNumber
      - type
      type: object
      properties:
        customerOrderId:
          minLength: 1
          type: string
          description: Customer order identifier.
          example: CDE0000000002
        date:
          type: string
          description: |-
            Date of the customer order.

            ISO 8601 Extended Format
          format: date-time
          example: '2022-03-02T18:00:00+00:00'
        type:
          "$ref": "#/components/schemas/CustomerOrderType"
        clientReference:
          maxLength: 255
          minLength: 0
          type: string
          description: Reference of customer order.
          nullable: true
          example: FLASD421312
        transportOrderNumber:
          maxLength: 256
          minLength: 0
          type: string
          description: Number of transport order.
        status:
          "$ref": "#/components/schemas/CustomerOrderStatus"
        contractor:
          "$ref": "#/components/schemas/Actor"
        carrier:
          "$ref": "#/components/schemas/Actor"
        customsFlag:
          "$ref": "#/components/schemas/CustomsFlag"
      additionalProperties: false
      description: Simple projection of CustomerOrder model.
    CustomerOrderProjectionPagedList:
      type: object
      properties:
        total:
          type: integer
          description: Number of total items
          format: int32
          example: 10
        returned:
          type: integer
          description: Number of items returned
          format: int32
          example: 1
        first:
          type: integer
          description: Position of the first element of the list among all the founded
          format: int32
          example: 0
        items:
          type: array
          items:
            "$ref": "#/components/schemas/CustomerOrderProjection"
          description: List of items
          nullable: true
      additionalProperties: false
      description: A Paginated list
    CustomerOrderPropertyAction:
      enum:
      - Added
      - Edited
      - Removed
      type: string
      description: 'List of actions that user can perform on an order property.<ul><li><i>Added</i>:
        Added property</li><li><i>Edited</i>: Edited property</li><li><i>Removed</i>:
        Removed property</li></ul>'
    CustomerOrderPut:
      required:
      - containers
      - customsFlag
      type: object
      properties:
        containers:
          minItems: 1
          type: array
          items:
            "$ref": "#/components/schemas/ContainerBase"
          description: Container
        date:
          type: string
          description: |-
            Date of the customer order.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        sender:
          maxLength: 256
          type: string
          description: Name of the person who created the order.
          nullable: true
          example: Dupont Jean
        clientReference:
          maxLength: 256
          type: string
          description: Importer/Exporter reference.
          nullable: true
          example: AUCHAN_12_678
        customsFlag:
          "$ref": "#/components/schemas/CustomsFlag"
        priceInformation:
          maxLength: 1024
          type: string
          description: Comment about pricing.
          nullable: true
          example: Let's apply a discount for this order
        instructionsInformation:
          maxLength: 1024
          type: string
          description: Instructions for the driver.
          nullable: true
          example: This order has to be handled fast!
        contractTermsInformation:
          maxLength: 1024
          type: string
          description: Information about the contract terms.
          nullable: true
          example: International terms and conditions
        comment:
          maxLength: 1024
          type: string
          description: General comments about the transport order.
          nullable: true
          example: This is an urgent transport.
        voyage:
          "$ref": "#/components/schemas/Voyage"
      additionalProperties: false
      description: Model to be sent to server when you want to update a customer order.
    CustomerOrderStatus:
      enum:
      - Draft
      - Valid
      - Cancelled
      - Submitted
      - Rejected
      - InProcess
      - Accepted
      - Refused
      type: string
      description: |2-

        Updating information related to a stage of the logistics flow (example: delivery to the importer) is no longer possible once the associated event has been completed.



        Updating the order is no longer possible once all the events have been completed.



        The order cannot be canceled if it has the "Submitted" status or if all the events have been completed.



        List of order states:<ul><li><i>Draft</i>: The order has been integrated in draft mode in MouvONE and is awaiting validation.</li><li><i>Valid</i>: Order has been validated.</li><li><i>Cancelled</i>: After order was validated, it is cancelled.</li><li><i>Submitted</i>: The order has been integrated into GedMouv and is awaiting processing by the carrier.</li><li><i>Rejected</i>: The order could not be integrated into GedMouv.</li><li><i>InProcess</i>: The order has been submitted to Gedmouv successfully and is in progress.</li><li><i>Accepted</i>: The order has been accepted by the carrier.</li><li><i>Refused</i>: The order was refused by the carrier.</li></ul>
    CustomerOrderType:
      enum:
      - Master
      - Elementary
      - SegmentTerminalEntrepot
      - SegmentEntrepotDepot
      - SegmentDepotEntrepot
      - SegmentEntrepotTerminal
      - SegmentTransfer
      type: string
      description: |-
        Order types (note that the value handled by this service is only Master):<ul><li><i>Master</i>: Global order.</li><li><i>Elementary</i>: Order linked to one container.</li><li><i>SegmentTerminalEntrepot</i>: The segment of Import order from the handling place to the warehouse.</li><li><i>SegmentEntrepotDepot</i>: The segment of Import order from the warehouse to the empty return location.</li><li><i>SegmentDepotEntrepot</i>: The segment of Export order from the empty release location to the warehouse.</li><li><i>SegmentEntrepotTerminal</i>: The segment of Export order from the warehouse to the handling place.</li><li><i>SegmentTransfer</i>: The segment of Transfer order. There are 3 cases:<br />
                    - Transfer of a full export container from a warehouse to a loading terminal;<br />
                    - Transfer of a full import container from an unloading terminal to a stripping or inspection location;<br />
                    - Transfer of a container from an unloading terminal to a loading terminal.<br /></li></ul>
    CustomsFlag:
      enum:
      - Import
      - Export
      - Transfer
      type: string
      description: 'Type of flows:<ul><li><i>Import</i>: Import flow.</li><li><i>Export</i>:
        Export flow.</li><li><i>Transfer</i>: Transfer flow.</li></ul>'
    ElementaryOrder:
      type: object
      properties:
        segments:
          type: array
          items:
            "$ref": "#/components/schemas/Segment"
          description: List of segments (transport segment managed by the carrier).
          nullable: true
        id:
          type: string
          description: |-
            Order identifier that is composed of a prefix of 3 characters and 10 digits.

            The following prefix means :
            - CDE : global customer order
            - ELM : elementary order (used for the multi-container case)
            - SEG : transport segment (managed by the carrier)
          nullable: true
          example: SEG0000000672
        transportOrderNumber:
          type: string
          description: Reference
          nullable: true
          example: OT-0510-1204-1
        type:
          "$ref": "#/components/schemas/CustomerOrderType"
      additionalProperties: false
      description: Elementary order information.
    EventBase:
      required:
      - location
      - type
      type: object
      properties:
        type:
          "$ref": "#/components/schemas/EventType"
        startDate:
          type: string
          description: |-
            Date where the event starts.

            It's mandatory for the delivery in import, positioning of the empty container in export, and delivery in transfer.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        endDate:
          type: string
          description: |-
            Date where the event ends.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T23:21:00+00:00'
        creationDate:
          type: string
          description: |-
            Date of event creation / Completion date for OK event.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
        location:
          "$ref": "#/components/schemas/EventLocation"
      additionalProperties: false
      description: Event payload when post or put a customer order.
    EventGet:
      required:
      - location
      - type
      type: object
      properties:
        state:
          "$ref": "#/components/schemas/EventState"
        location:
          "$ref": "#/components/schemas/EventLocationGet"
        incidents:
          type: array
          items:
            "$ref": "#/components/schemas/EventIncidentGet"
          description: List of incidents in an event.
          nullable: true
        type:
          "$ref": "#/components/schemas/EventType"
        startDate:
          type: string
          description: |-
            Date where the event starts.

            It's mandatory for the delivery in import, positioning of the empty container in export, and delivery in transfer.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        endDate:
          type: string
          description: |-
            Date where the event ends.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T23:21:00+00:00'
        creationDate:
          type: string
          description: |-
            Date of event creation / Completion date for OK event.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
      additionalProperties: false
      description: Event info when retrieving customer order.
    EventIncidentGet:
      type: object
      properties:
        type:
          "$ref": "#/components/schemas/ReservationIncidentType"
        comment:
          type: string
          description: Transporter's comment about the incident.
          nullable: true
          example: This package has a hole on it
        pictures:
          type: array
          items:
            "$ref": "#/components/schemas/IncidentPictureGet"
          description: Pictures describe the incident.
          nullable: true
      additionalProperties: false
      description: Class contains information about incident happened at an event.
    EventLocation:
      type: object
      properties:
        code:
          maxLength: 20
          type: string
          description: |2-

            Location code.

            Detailed information is available in the API Referential.
          nullable: true
          example: MTDF
        name:
          maxLength: 64
          type: string
          description: Location name.
          nullable: true
          example: Terminal de France
        location:
          "$ref": "#/components/schemas/Location"
        contact:
          "$ref": "#/components/schemas/Contact"
        reference:
          maxLength: 64
          type: string
          description: Given reference during the event.
          nullable: true
          example: LOC-13-286-182
      additionalProperties: false
      description: Class contains information about location where an event occurs.
    EventLocationGet:
      type: object
      properties:
        reserves:
          maxLength: 64
          type: string
          description: Reservations and related information.
          nullable: true
        code:
          maxLength: 20
          type: string
          description: |2-

            Location code.

            Detailed information is available in the API Referential.
          nullable: true
          example: MTDF
        name:
          maxLength: 64
          type: string
          description: Location name.
          nullable: true
          example: Terminal de France
        location:
          "$ref": "#/components/schemas/Location"
        contact:
          "$ref": "#/components/schemas/Contact"
        reference:
          maxLength: 64
          type: string
          description: Given reference during the event.
          nullable: true
          example: LOC-13-286-182
      additionalProperties: false
      description: Event of a customer order.
    EventState:
      enum:
      - InProgress
      - OK
      - KO
      type: string
      description: 'List of possible state of a event. Must be one of the following
        values:<ul><li><i>InProgress</i>: The event is in progress.</li><li><i>OK</i>:
        The event went well.</li><li><i>KO</i>: The event has been cancelled.</li></ul>'
    EventType:
      enum:
      - Announced
      - CarrierIdentification
      - LadingImport
      - DeliveryImport
      - EmptyReleaseImport
      - EmptyReturnImport
      - EmptyReleaseExport
      - PositioningExport
      - LadingExport
      - DeliveryExport
      - Association
      - TokenCodeTrucker
      - CancelCarrierIdentification
      - UpdateAssociation
      - AnnouncementCancelled
      - LadingTransfer
      - DeliveryTransfer
      type: string
      description: "List of mandatory events when exporting an order:\n\n\n- EmptyReleaseExport:
        Empty container made available.\n- PositioningExport: Empty container positioned.\n-
        LadingExport: Full container export handled.\n- DeliveryExport: Full export
        container delivered.\n\n            \nList of mandatory events when importing
        an order:\n\n\n- LadingImport: Full container import handled.\n- DeliveryImport:
        Full container import delivered.\n- EmptyReleaseImport: Empty container recovered.\n-
        EmptyReturnImport: Empty container returned.\n\n\nList of mandatory events
        for the Transfer order:\n\n\n- LadingTransfer: Full container handled.\n-
        DeliveryTransfer: Full container delivered.\n\nThe other events are related
        to the interconnection between MouvONE and the PCS S ONE (Announced, CarrierIdentification,
        ...)."
    Goods:
      type: object
      properties:
        goodsId:
          type: integer
          description: Identify of good.
          format: int32
        description:
          maxLength: 264
          type: string
          description: Goods description.
          nullable: true
          example: Colorful balloon
        type:
          maxLength: 4
          type: string
          description: |2-

            Packaging code (UNCL code standard).

            Detailed information is available in the API Referential.
          nullable: true
          example: BF
        quantity:
          type: integer
          description: Number of packages.
          format: int32
          nullable: true
          example: 3000000
        weight:
          type: number
          description: Weight of goods (unit in KGM).
          format: double
          nullable: true
          example: 100.5
        volume:
          type: number
          description: Volume of goods.
          format: double
          nullable: true
          example: 20.5
        hazardousClasses:
          type: array
          items:
            "$ref": "#/components/schemas/HazardousClass"
          description: List of hazardous classes.
          nullable: true
      additionalProperties: false
      description: Class contains information about goods.
    GoodsPost:
      type: object
      properties:
        description:
          maxLength: 264
          type: string
          description: Goods description.
          nullable: true
          example: Colorful balloon
        type:
          maxLength: 4
          type: string
          description: |2-

            Packaging code (UNCL code standard).

            Detailed information is available in the API Referential.
          nullable: true
          example: BF
        quantity:
          type: integer
          description: Number of packages.
          format: int32
          nullable: true
          example: 3000000
        weight:
          type: number
          description: Weight of goods (unit in KGM).
          format: double
          nullable: true
          example: 100.5
        volume:
          type: number
          description: Volume of goods.
          format: double
          nullable: true
          example: 20.5
        hazardousClasses:
          type: array
          items:
            "$ref": "#/components/schemas/HazardousClass"
          description: List of hazardous classes.
          nullable: true
      additionalProperties: false
      description: Goods post model.
    HazardousClass:
      type: object
      properties:
        imdgCode:
          maxLength: 11
          type: string
          description: IMDG code.
          nullable: true
          example: '3.1'
        undgCode:
          maxLength: 11
          type: string
          description: UNDG code.
          nullable: true
          example: '1001'
        packagingGroup:
          maxLength: 11
          type: string
          description: Packaging group.
          nullable: true
          example: III
      additionalProperties: false
      description: Hazardous class information.
    HttpBusinessError:
      type: object
      properties:
        timestamp:
          type: string
          description: |-
            Time information.

            ISO 8601 Extended Format
          format: date-time
          example: '2022-11-08T14:17:19Z'
        code:
          "$ref": "#/components/schemas/BusinessErrorCode"
        message:
          type: string
          description: Error message.
          nullable: true
          example: Commande de transport est introuvable!
      additionalProperties: false
      description: Returned error schema.
    IncidentPicture:
      required:
      - content
      - fileName
      type: object
      properties:
        pictureId:
          type: integer
          description: Picture identifier, it can be used to retrieve a picture when
            needed.
          format: int32
        fileName:
          maxLength: 255
          type: string
          description: Picture name.
        content:
          type: string
          description: Base64 encoded content of the JPEG picture.
      additionalProperties: false
      description: Class contains information about picture describes an incident.
    IncidentPictureGet:
      type: object
      properties:
        pictureId:
          type: integer
          description: Picture identifier, it can be used to retrieve a picture when
            needed.
          format: int32
          example: 1
        fileName:
          type: string
          description: Picture name.
          nullable: true
          example: 79873945793257.jpg
      additionalProperties: false
      description: Class contains information about picture describes an incident.
    Location:
      type: object
      properties:
        address:
          maxLength: 256
          type: string
          description: Address of the location.
          nullable: true
          example: Terre-Plein de la Barre B.P. 1413 Le Havre
        zipCode:
          maxLength: 256
          type: string
          description: Post code of the location.
          nullable: true
          example: '76600'
        city:
          maxLength: 64
          type: string
          description: City name.
          nullable: true
          example: Le Havre
        country:
          maxLength: 2
          minLength: 2
          type: string
          description: ISO 3166-1 alpha-2 code of country .
          nullable: true
          example: FR
      additionalProperties: false
      description: Location information.
    OutOfGauge:
      type: object
      properties:
        length:
          type: number
          description: Excess length (unit in M).
          format: double
          nullable: true
          example: 5
        width:
          type: number
          description: Excess width (unit in M).
          format: double
          nullable: true
          example: 5
        height:
          type: number
          description: Excess height (unit in M).
          format: double
          nullable: true
          example: 5
      additionalProperties: false
      description: Class contains out of gauge information.
    PrimitiveFieldType:
      enum:
      - Boolean
      - Number
      - String
      type: string
      description: 'Primitive field type enum.<ul><li><i>Boolean</i>: Boolean</li><li><i>Number</i>:
        Number</li><li><i>String</i>: String</li></ul>'
    Reefer:
      type: object
      properties:
        setPoint:
          type: number
          description: Setpoint temperature, indicated by the contractor.
          format: double
          nullable: true
          example: 14.5
      additionalProperties: false
      description: Class contains refrigeration information.
    ReservationIncidentType:
      enum:
      - Late
      - NonCompliantQuantity
      - Damage
      - Other
      type: string
      description: 'List of incident types existing in an event''s reservation of
        Gedmouv<ul><li><i>Late</i>: Goods arrived late at the location</li><li><i>NonCompliantQuantity</i>:
        Goods quantity is not confirmed</li><li><i>Damage</i>: Goods are damaged</li><li><i>Other</i>:
        Other reason</li></ul>'
    Segment:
      type: object
      properties:
        id:
          type: string
          description: |-
            Order identifier that is composed of a prefix of 3 characters and 10 digits.

            The following prefix means :
            - CDE : global customer order
            - ELM : elementary order (used for the multi-container case)
            - SEG : transport segment (managed by the carrier)
          nullable: true
          example: SEG0000000672
        transportOrderNumber:
          type: string
          description: Reference
          nullable: true
          example: OT-0510-1204-1
        type:
          "$ref": "#/components/schemas/CustomerOrderType"
      additionalProperties: false
      description: Segment information.
    Voyage:
      type: object
      properties:
        meansName:
          maxLength: 384
          type: string
          description: Transport means name.
          nullable: true
          example: MSC GORILLA
        freightAgent:
          maxLength: 256
          type: string
          description: Freight agent.
          nullable: true
          example: CCGM
        shippingCompany:
          maxLength: 256
          type: string
          description: Shipping company name.
          nullable: true
          example: ZIM
        eta:
          type: string
          description: |-
            Estimated time of arrival: available for import and transfer flow.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        etd:
          type: string
          description: |-
            Estimated date of departure: available for the export flow.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        closingCustoms:
          type: string
          description: |-
            Customs closing date: available for the export flow.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        closingDangerous:
          type: string
          description: |-
            Dangerous closing date: available for the export flow

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
        closingDelivery:
          type: string
          description: |-
            Delivery closing date: available for the export flow.

            ISO 8601 Extended Format
          format: date-time
          nullable: true
          example: '2022-03-02T18:00:00+00:00'
      additionalProperties: false
      description: Voyage information.
  securitySchemes:
    bearer_token:
      type: http
      scheme: bearer
      bearerFormat: JWT
    api_key:
      type: apiKey
      name: Ocp-Apim-Subscription-Key
      in: header
x-topics:
- title: Get Started
  content: "# Format\n\nSoget API platform exposes RESTful APIs. \n\nOur API uses
    the HTTP methods to connect to our data sources. It returns responses in JSON
    format in UTF-8 encoding. It uses:\n\n- ISO-8601 format for date and time,\n-
    JSON object or JSON array in the body of POST and PUT methods,\n- *Application/json;
    charset=UTF-8* in the parameter *Content-Type* of the header\n\n# Parameters\n\nParameters
    must be passed:\n\n- in the URL’s query string for GET and DELETE requests;\n-
    in the request’s body for PUT and POST requests.\n\nIf the call requires other
    parameters, add them as well with the appropriate values.\n\nParameters passed
    in the **URL** must be properly URL-encoded, using UTF-8 encoding for non-ASCII
    characters. Also, the plus character (*+*) is interpreted as a space (so it’s
    an alternative to *%20*).  Unless otherwise stated, arrays passed in the URL can
    be specified either:\n\n-\tas a comma-separated string; example: *attributesToRetrieve=title,description*;
    or\n-\tas a JSON array (which must be properly URL-encoded, of course);\n  \n>
    __example__: *attributesToRetrieve=%5B%22title%22,%22description%22%5D*.\n\nArrays
    passed in the **body** should always be regular JSON arrays.\n\n# What You Need
    \n\nIn order to make requests, you must have an account and update your password.\n**THEN**,\n\n1.
    Create an organization\n2. Create a client application\n3. Retrieve your authentication
    tokens : [Authentication](#topic-authentication)\n4. Subscribe to an offer\n5.
    Retrieve your API Key : [Authentication](#topic-authentication) \n\n# Make your
    first request\n\nFor the first examples, you can use your terminal, with curl,
    sending the request.\n\nIt returns a JSON response like this:\n```json\n{\n    \"code\":
    \"CCGM\",\n    \"name\": \"CMA CGM\",\n    \"type\": \"FB\",\n    \"location\":
    \"FR\",\n    \"organization\": \"CMA CGM\"\n}\n```"
- title: Authentication
  content: "Soget API use double authentication to identify the application and the
    customer.\nThe first authentication is performed by the OAuth2 token to identify
    application and the second authentication is performed by the API key to identify
    the customer.\n\n# OAuth2 token\n\nTo authenticate your application, you need
    register for the API Portal and create an application.  \n\n- Get and use client_id
    and client_secret to get the $ACCESS_TOKEN\n- Use the $ACCESS_TOKEN to call our
    API services\n\nNote that the access token url is : https://soget-api-integration.azure-api.net/soget-connect/v1/openid-connect/token.\n\n#
    API Key\n\nTo authenticate the customer, you need register for the API Portal
    and subscribe to an offer.\n\n- Get and use the $API_KEY to call our API services\n\nNote,
    that you should use the $API_KEY in the `Ocp-Apim-Subscription-Key` header of
    your request."
  example: |-
    ## Request an access token

    ```
    curl -X POST https://soget-api-integration.azure-api.net/soget-connect/v1/openid-connect/token --data-urlencode "client_id=$YOUR_CLIENT_ID" --data-urlencode "client_secret=$YOUR_CLIENT_SECRET"
    ```

    ## Request an API
    ````
    curl \
      -X GET https://soget-api-integration.azure-api.net \
      -H "Authorization: Bearer $ACCESS_TOKEN"
      -H "Ocp-Apim-Subscription-Key: $API_KEY"
    ```
security:
- bearer_token: []
  api_key: []
servers:
- url: https://soget-api-integration.azure-api.net/customer-orders/v1
