Phasio Manufacturer Shipment Controller API

This controller is responsible for managing shipments. It allows you to get rates and fetch existing shipments.

OpenAPI Specification

phasio-manufacturer-shipment-controller-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Phasio Activity Internal Manufacturer Shipment Controller API
  description: This is the API documentation for the Phasio application.
  version: '1.0'
servers:
- url: https://m-api.eu.phas.io
  description: Generated server url
security:
- Phasio API Bearer Token: []
tags:
- name: Manufacturer Shipment Controller
  description: This controller is responsible for managing shipments. It allows you to get rates and fetch existing shipments.
paths:
  /api/manufacturer/v1/shipment/rates:
    post:
      tags:
      - Manufacturer Shipment Controller
      summary: Calculate the shipping rates for a group of parts
      description: This endpoint calculates the shipping rates for a group of parts. The request body should contain the list of parts and their quantities.
      operationId: calculateRatesv2
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CalculateRatesDtov2'
        required: true
      responses:
        '200':
          description: Shipping rates calculated successfully
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/ShippingRatesDto'
        '401':
          description: Unauthorized - operator not found
  /api/manufacturer/v1/shipment/{shipmentId}:
    get:
      tags:
      - Manufacturer Shipment Controller
      summary: Get shipment by ID
      description: Retrieves a specific shipment by its ID
      operationId: getShipment
      parameters:
      - name: shipmentId
        in: path
        description: ID of the shipment to retrieve
        required: true
        schema:
          type: integer
          format: int64
      responses:
        '200':
          description: Shipment retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ShipmentDto'
        '404':
          description: Shipment not found
components:
  schemas:
    ShippingRatesDto:
      type: object
      properties:
        shippingMethodId:
          type: integer
          format: int64
        tooLargeForBoxes:
          type: boolean
        errorWithCarrier:
          type: boolean
        rates:
          type: array
          items:
            $ref: '#/components/schemas/ShippingRateDto'
      required:
      - errorWithCarrier
      - rates
      - tooLargeForBoxes
    PartShippingDetailDto:
      type: object
      properties:
        partRevisionId:
          type: string
          format: uuid
        units:
          type: string
          enum:
          - CENTIMETERS
          - MILLIMETERS
          - METRES
          - INCHES
          - FEET
        quantity:
          type: integer
        processPricesId:
          type: string
          format: uuid
        materialId:
          type: integer
          format: int64
      required:
      - materialId
      - partRevisionId
      - processPricesId
      - quantity
      - units
    CalculateRatesDtov2:
      type: object
      description: Rate calculation parameters
      properties:
        currency:
          type: string
          enum:
          - USD
          - SGD
          - EUR
          - INR
          - JPY
          - AUD
          - GBP
          - NZD
          - MYR
          - CAD
          - CHF
          - DKK
          - SEK
          - MXN
          - ZAR
          - UAH
          - NOK
          - PHP
          - TRY
        organisationId:
          type: integer
          format: int64
        toAddressId:
          type: integer
          format: int64
        parts:
          type: array
          items:
            $ref: '#/components/schemas/PartShippingDetailDto'
      required:
      - currency
      - organisationId
      - parts
      - toAddressId
    ShippingRateDto:
      type: object
      properties:
        id:
          type: string
        rate:
          type: number
        currency:
          type: string
        serviceType:
          type: string
        serviceName:
          type: string
        shippingMethodId:
          type: integer
          format: int64
      required:
      - currency
      - id
      - rate
      - serviceName
      - serviceType
      - shippingMethodId
    ShipmentDto:
      type: object
      discriminator:
        propertyName: shippingMode
      properties:
        id:
          type: integer
          format: int64
        shippingMode:
          type: string
          enum:
          - SELF_COLLECTION
          - FIXED_PRICE
          - CARRIER_ACCOUNT
        shippingMethodId:
          type: integer
          format: int64
        rateId:
          type: string
        toAddressId:
          type: integer
          format: int64
        status:
          type: string
        dispatchDate:
          type: string
          format: date
      required:
      - shippingMode
  securitySchemes:
    Phasio API Bearer Token:
      type: http
      name: Authorization
      in: header
      scheme: bearer
      bearerFormat: JWT