Skip to main content

Shipping Provider Webhooks (v0)

Download OpenAPI specification:Download

Manage deliveries or shipments in the NewStore platform using these webhooks.

To learn how NewStore integrates with a shipping provider, see the guide.

Shipments

Represents the shipment(s) created once an order with delivery is being placed. Depending on the provider, a shipment is generally pre-booked (also called a delivery promise), then booked, and finally tracked.

As an integrator, implement the methods of this resource to integrate a shipping provider such as UPS with NewStore Cloud.

The integration of a shipment provider also uses theĀ Shipping offersĀ resource. For more information about the integration, seeĀ Integrating a shipping provider.

Note:Ā The validity of a shipping offer token can vary based on the shipping provider and shipping offer. ForĀ in-store pickupĀ orders, a shipping offer token does not expire.

Book shipment

Books a shipment based on an offer received by the provider.

Request Body schema: application/json
offer
string non-empty

Identifier of the offer.

rate
required
string <= 256 characters

Identifier of the rate, examples are 'FEDEX_GROUND' or 'DHL_WUNSCHZEIT'.

carrier_code
required
string <= 256 characters

Identifier of the shipping carrier, examples are 'FEDEX' or 'DELIV'.

external_order_id
required
string non-empty

External identifier of the order to be shipped.

booking_method
required
string
Enum: "only_shipping" "only_return" "shipping_and_return"

Type of shipments to book.

required
object

Address of the sender.

required
object

Address of the consumer.

object

Specifications of the package.

required
Array of objects

List of the identifiers of the products contained in the package.

demand_location_id
string <= 256 characters

Represents the location where the order was placed, examples are 'DC01' or 'US01'.

fulfillment_node_id
string <= 256 characters

Represents the location from where the order will be shipped, examples are 'DC02' or 'US02'.

object

Responses

Request samples

Content type
application/json
{
  • "rate": "FEDEX_GROUND",
  • "demand_location_id": "US01",
  • "fulfillment_node_id": "US02",
  • "carrier_code": "FEDEX",
  • "external_order_id": "981475723",
  • "booking_method": "shipping_and_return",
  • "sender_address": {
    },
  • "shipping_address": {
    },
  • "items": [
    ]
}

Response samples

Content type
application/json
{
  • "tracking_code": "string",
  • "label_url": "string",
  • "tracking_url": "string",
  • "commercial_invoice_url": "string",
  • "offer": "string",
  • "return_tracking_code": "string",
  • "return_label_url": "string",
  • "return_tracking_url": "string",
  • "return_commercial_invoice_url": "string",
  • "cost": {
    }
}

Cancel shipment

Cancels a shipment. Canceling a shipment is only possible before it reaches the in_transit status.

To retrieve the status of the shipment, use the List shipments method.

path Parameters
tracking_code
required
string

The tracking code for the delivery/shipment that needs to be cancelled. The tracking code is provided by the shipping provider to NewStore Omnichannel Cloud when a shipment is booked.

Responses

Response samples

Content type
application/json
{ }

Shipping offers

Represents the shipping offers presented to the customer during the checkout step, for exampleĀ  Standard deliveryĀ orĀ Next-day delivery.

As an integrator, implement the methods of this resource to integrate a shipping provider with NewStore Omnichannel Cloud.

The integration of a shipment provider also uses theĀ ShipmentsĀ resource. For more information about the integration, seeĀ Integrating a shipping provider.

Note:Ā The validity of a shipping offer token can vary based on the shipping provider and shipping offer. ForĀ in-store pickupĀ orders, a shipping offer token does not expire.

Request shipping offers

Requests shipping offers, including quotes and delivery windows.

Request Body schema: application/json
object

used only for international shipments (ex: different sender/shipping country code, military address...)

required
object

Address of the sender.

required
object

Address of the consumer.

required
Array of objects non-empty

List containing information about the products to be shipped.

fulfillment_node_id
string

Unique ID representing the pickup location of the shipment.

ready_by
required
string <date-time>

Estimate of the time when the package becomes ready for delivery. Use this property's value to filter shipping offers from the provider to select manageable delivery time slots.

provider_rate
required
string <= 256 characters

Identifier of the rate, examples are 'FEDEX_GROUND' or 'DHL_WUNSCHZEIT'.

service_level
required
string <= 256 characters

Identifier of the service level, examples are 'SAME DAY' or 'EXPRESS'.

Responses

Request samples

Content type
application/json
{
  • "sender_address": {
    },
  • "shipping_address": {
    },
  • "deliverables": [
    ],
  • "ready_by": "2018-03-04T10:29:05Z",
  • "service_level": "sameday",
  • "provider_rate": "deliv"
}

Response samples

Content type
application/json
[
  • {
    }
]