Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Attribute

Description

Endpoint

https://postpurchase.fenixcommerce.com/fenix/oms/crs/v1/rateshopping/get-shipping-info

Method

POST

Headers

tenant_id

auth_token

Request Sample

Code Block
{
  "request_id": "4ba0d463-6476-47f8-b67a-5c8c4bbcf3da",
  "shipment_id": "b7866a89-8dc1-4bac-8c4b-be1fabb56cb7",
  "to": {
    "fname": "",
    "lname": "",
    "address1": "4320 Stevens Creek Blvd",
    "address2": "",
    "city": "San Jose",
    "country": "US",
    "state": "CA",
    "zipcode": "95129",
    "residential": true,
    "po_box": false
  },
  "from": {
    "fname": "",
    "lname": "",
    "address1": "2325 Enborg Ln",
    "address2": "",
    "city": "San Jose",
    "country": "US",
    "state": "CA",
    "zipcode": "95128",
    "residential": false,
    "po_box": false
  },
  "warehouse_id": "3bcde514-c7d7-40d5-9e41-2d0c1303810f",
  "product_infos": [
    {
      "sku": "abc",
      "quantity": 1,
      "variant_id": 123,
      "product_id": 123,
      "dimensions": {
        "length": 6,
        "width": 8,
        "height": 6,
        "units": "IN"
      },
      "weight": {
        "value": 1,
        "units": "LB"
      }
    }
  ],
  "shipment_info": {
    "package_name": null,
    "dimensions": {
      "length": 6,
      "width": 8,
      "height": 6,
      "units": "IN"
    },
    "weight": {
      "value": 1,
      "units": "LB"
    },
    "product_infos": [
      {
        "sku": "abc",
        "quantity": 1,
        "variant_id": 123,
        "product_id": 123,
        "dimensions": {
          "length": 6,
          "width": 8,
          "height": 6,
          "units": "IN"
        },
        "weight": {
          "value": 1,
          "units": "LB"
        }
      }
    ]
  },
  "expected_delivery_date": "2023-10-31T01:30+01:00",
  "expected_shipping_date": "2023-10-31T01:30+01:00",
  "deliver_within_days": 10
}

Response

Code Block
{
  "request_id": "4ba0d463-6476-47f8-b67a-5c8c4bbcf3da",
  "shipment_id": "b7866a89-8dc1-4bac-8c4b-be1fabb56cb7",
  "to": {
    "fname": "",
    "lname": "",
    "address1": "4320 Stevens Creek Blvd",
    "address2": "",
    "city": "San Jose",
    "country": "US",
    "state": "CA",
    "zipcode": "95129",
    "residential": true,
    "po_box": false
  },
  "expected_delivery_date": "2023-10-31T01:30+01:00",
  "expected_shipping_date": "2023-10-31T01:30+01:00",
  "deliver_within_days": 10,
  "error_info": {
    "error_code": "123",
    "error_message": "error message",
    "description": "message description"
  },
  "shipment_infos": [
    {
      "fulfillment_info": {
        "loc_id": "54862250135",
        "address": {
          "fname": "",
          "lname": "",
          "address1": "4320 Stevens Creek Blvd",
          "address2": "",
          "city": "San Jose",
          "country": "US",
          "state": "CA",
          "zipcode": "95129",
          "residential": true,
          "po_box": false
        }
      },
      "shipment_info": [
        {
          "shipment_id": "abc",
          "sourcing_info": [
            {
              "sku_id": "black-leather-bag-12",
              "product_id": "7106172944535",
              "variant_id": "42499122102423",
              "line_item_id": null,
              "requested_quantity": 1,
              "allocated_quantity": 1
            }
          ],
          "cartonization_info": {
            "length": {
              "value": 10,
              "units": "IN"
            },
            "width": {
              "value": 10,
              "units": "IN"
            },
            "height": {
              "value": 10,
              "units": "IN"
            },
            "weight": {
              "value": 1,
              "units": "LB"
            }
          },
          "rate_shopping_info": [
            {
              "recommended_service": {
                "carrier": "UPS",
                "service": {
                  "code": "04",
                  "name": null
                },
                "ship_cost": {
                  "amount": 6.74,
                  "currency": "USD"
                },
                "transit_info": {
                  "delivery_date": "2023-10-31T01:30+01:00",
                  "transit_time": 2
                },
                "ship_by_date": "2023-10-31T01:30+01:00",
                "delivery_accuracy_percent": 0.0,
                "metainfo": {
                  "included": true,
                  "exclusion_code": null,
                  "exclude_message": null
                }
              },
              "services_excluded": [
                {
                  "carrier": "UPS",
                  "service": {
                    "code": "04",
                    "name": null
                  },
                  "ship_cost": {
                    "amount": 6.74,
                    "currency": "USD"
                  },
                  "transit_info": {
                    "delivery_date": "2023-10-31T01:30+01:00",
                    "transit_time": 2
                  },
                  "ship_by_date": "2023-10-31T01:30+01:00",
                  "delivery_accuracy_percent": 0.0,
                  "metainfo": {
                    "included": true,
                    "exclusion_code": null,
                    "exclude_message": null
                  }
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}

Request Attribute Definitions

Attribute

Required

Description

request_id

true

A unique identifier of the request

shipment_id

true

Shipment id of the shipment

request.from

true

Address of the shipper

from.fname

false

First name of the shipper

from.lname

false

Last name of the shipper

from.address_line1

true

The line 1 of the shipper address

from.address_line2

false

The line 2 of the shipper address

from.city

false

The city of the shipper

from.state

false

The state of the shipper

from.zipcode

true

The zip code of the shipper

from.country

true

The country of the shipper (Use ISO code. Ex, US, CA, IN, etc)

from.residential

false

Flag to denote if the shipper address is a residential

from.po_box

false

Flag to denote if the shipper address is a po box

to

true

Address of the buyer

to.fname

false

First name of the buyer

to.lname

false

Last name of the buyer

to.address_line1

true

The line 1 of the buyer address

to.address_line2

false

The line 2 of the buyer address

to.city

false

The city of the buyer

to.state

false

The state of the buyer

to.zipcode

true

The zip code of the buyer

to.country

true

The country of the buyer (Use ISO code. Ex, US, CA, IN, etc)

to.residential

false

Flag to denote if the buyer address is a residential

to.po_box

false

Flag to denote if the buyer address is a po box

warehouse_id

false

The warehouse id if the details are configured it in Fenix

shipment_info

true

Details of the shipment

shipment_info.package_name

false

Note: Must be specified when the dimensions are not specified

Specify the kind of package. You can specify CUSTOM for your own packaging dims or else specify the carrier’s own packaging info.

Examples of carrier packaging info

  • FEDEX_ENVELOPE

  • FEDEX_SMALL_BOX

  • FEDEX_MEDIUM_BOX

  • etc.,

 

shipment_info.dimensions

false

Note: Must be specified when the package name is not specified

The dimension details of the shipment

shipment_info.dimensions.length

true

The length of the shipping package

shipment_info.dimensions.width

true

The width of the shipping package

shipment_info.dimensions.height

true

The height of the shipping package

shipment_info.dimensions.units

false

The units of the above dimensions.

Valid Values: IN, CM

Default: IN

shipment_info.weight

false

The weight details of the shipment

shipment_info.weight.value

true

The weight of the shipping package

shipment_info.weight.units

false

The units of the above weight.

Valid Values: LB, KG, OZ

Default: LB

shipment_info.product_infos

false

The SKUs and their quantities shipping as part of the shipment

shipment_info.product_infos.sku

false

The SKU Id

shipment_info.product_infos.quantity

false

The number of units of the above SKU

shipment_info.product_infos.variant_id

false

The variant id of the above SKU (applies only to shopify platform)

shipment_info.product_infos.product_id

false

The product id of the above SKU

shipment_info.product_infos.weight

false

The weight details of the above SKU

shipment_info.product_infos.weight.value

true

The weight of the above SKU

shipment_info.product_infos.weight.units

false

The units of the above weight.

Valid Values: LB, KG, OZ

Default: LB

shipment_info.product_infos.dimensions

false

Note: Must be specified when the package name is not specified

The dimension details of the SKU

shipment_info.product_infos.dimensions.length

true

The length of the SKU

shipment_info.product_infos.dimensions.width

true

The width of the SKU

shipment_info.product_infos.dimensions.height

true

The height of the SKU

shipment_info.product_infos.dimensions.units

false

The units of the above dimensions.

Valid Values: IN, CM

Default: IN

expected_delivery_date

false

Expected delivery date of the shipment

Info

ISO Date Time Format: yyyy-MM-dd'T'HH:mmXXX

Example: 2000-10-31T01:30:00.000-05:00

request.expected_shipping_date

false

Expected shipping date of the shipment

Info

ISO Date Time Format: yyyy-MM-dd'T'HH:mmXXX

Example: 2000-10-31T01:30:00.000-05:00

If the date is not specified, the current date and time will be taken as the shipping date

request.deliver_within_days

false

Expected days to deliver the shipment