mollie v0.2.1 Mollie.Orders.Shipments

Link to this section Summary

Functions

Create a shipment to ship order lines. If an empty array is sent for lines, the entire order will be shipped

Retrieve a single shipment and the order lines shipped by a shipment’s ID

Retrieve all shipments for an order

Update the tracking information of a shipment

Link to this section Functions

Link to this function create(client, order_id, body \\ %{})
create(Mollie.Client.t(), binary(), map()) :: Mollie.response()

Create a shipment to ship order lines. If an empty array is sent for lines, the entire order will be shipped.

Shipment example body

%{
  "lines" => []
}

Example

Mollie.Orders.Shipments.create client, "ord_8wmqcHMN4U", shipment_body

More info at: https://docs.mollie.com/reference/v2/shipments-api/create-shipment

Link to this function find(client, order_id, id, params \\ %{})
find(Mollie.Client.t(), binary(), binary(), map() | list()) ::
  Mollie.response()

Retrieve a single shipment and the order lines shipped by a shipment’s ID.

Example

Mollie.Orders.Shipments.find client, "ord_8wmqcHMN4U", "shp_3wmsgCJN4U"

More info at: https://docs.mollie.com/reference/v2/shipments-api/get-shipment

Link to this function list(client, order_id, params \\ %{})
list(Mollie.Client.t(), binary(), map() | list()) :: Mollie.response()

Retrieve all shipments for an order.

Example

Mollie.Orders.Shipments.list client, "ord_8wmqcHMN4U"

More info at: https://docs.mollie.com/reference/v2/shipments-api/list-shipments

Link to this function update(client, order_id, id, body \\ %{})
update(Mollie.Client.t(), binary(), binary(), map()) :: Mollie.response()

Update the tracking information of a shipment.

Update example body

%{
  "tracking" => %{
    "carrier" => "PostNL",
    "code" => "3SKABA000000000"
  }
}

Example

Mollie.Orders.Shipments.update client, "ord_8wmqcHMN4U", "shp_3wmsgCJN4U", update_body

More info at: https://docs.mollie.com/reference/v2/shipments-api/update-shipment