shipment

Collection: shipments

A shipment resource contains the address for where items in a transaction grouped by a common shipto were sent.

If you create custom attributes for a shipment, they will automatically be included in the response as embedded resources without having to zoom in on them.

Required Scopes

Full store_full_access
Read transactions_read
Write transactions_write

Actions

GET View a shipment
HEAD Get just the header response
OPTIONS Get a response explaining which HTTP methods are supported

Properties (19)

address_name String · Read-only

Either the shipto value or "Default Shipping Address" for non-multiship transactions.

first_name String · Read-only

The given name associated with this address.

last_name String · Read-only

The surname associated with this address.

company String · Read-only

The company associated with this address.

address1 String · Read-only

The first line of the street address.

address2 String · Read-only

The second line of the street address.

city String · Read-only

The city of this address.

region String · Read-only

The two character code for states in the United States. Other countries may call this a province. When a two character code isn't available, the full region name will be used.

postal_code String · Read-only

The postal code of this address.

country String · Read-only

The country code of this address.

phone String · Read-only

The phone of this address.

shipping_service_id Number · Read-only

The shipping service id selected during checkout. This will normally correspond with a shipping_service from one of the shipping_methods available.

shipping_service_description String · Read-only

The description of the shipping service selected for this shipment.

total_item_price Number · Read-only

The total price of the items in this shipment.

total_tax Number · Read-only

The total tax on the items in this shipment.

total_shipping Number · Read-only

The total shipping cost of the items in this shipment.

total_price Number · Read-only

The total price of this shipment.

date_created String (nullable) · Read-only

The date this resource was created.

date_modified String (nullable) · Read-only

The date this resource was last modified.

Link Relations (9)

self This Shipment
fx:store GET PATCH PUT DELETE This Store
fx:items GET POST Items in this shipment
fx:transaction GET PATCH PUT POST This Transaction
fx:shipments GET Shipments for this Transaction
fx:customer GET PATCH PUT DELETE This Customer
fx:customer_address GET PATCH PUT DELETE This Customer Address
fx:attributes GET POST PATCH PUT Attributes for this shipment
fx:custom_fields GET POST Custom Fields for this shipment

Zoomable Resources

Embed related resources using ?zoom=<resource>. Filter with ?resource:property=value.

https://api.foxycart.com/shipments/{id}
Available via fx:shipment on item

Example Representation

Zoom
{
  "_links": {
    "curies": [
      {
        "name": "fx",
        "href": "https://api.foxycart.com/rels/{rel}",
        "templated": true
      }
    ],
    "self": {
      "href": "https://api.foxycart.com/shipments/123",
      "title": "This Shipment"
    },
    "fx:store": {
      "href": "https://api.foxycart.com/stores/456",
      "title": "This Store"
    },
    "fx:items": {
      "href": "https://api.foxycart.com/transactions/999/items?shipto={address_name}",
      "title": "Items in this shipment"
    },
    "fx:transaction": {
      "href": "https://api.foxycart.com/transactions/999",
      "title": "This Transaction"
    },
    "fx:shipments": {
      "href": "https://api.foxycart.com/transactions/999/shipments",
      "title": "Shipments for this Transaction"
    },
    "fx:customer": {
      "href": "https://api.foxycart.com/customers/789",
      "title": "This Customer"
    },
    "fx:customer_address": {
      "href": "https://api.foxycart.com/customer_addresses/999",
      "title": "This Customer Address"
    },
    "fx:attributes": {
      "href": "https://api.foxycart.com/shipments/123/attributes",
      "title": "Attributes for this shipment"
    },
    "fx:custom_fields": {
      "href": "https://api.foxycart.com/shipments/123/shipment_custom_fields",
      "title": "Custom Fields for this shipment"
    }
  },
  "address_name": "Default Shipping Address",
  "first_name": "John",
  "last_name": "Doe",
  "company": "",
  "address1": "1234 Anystreet",
  "address2": "",
  "city": "NASHVILLE",
  "region": "TN",
  "postal_code": "37211",
  "country": "US",
  "phone": "555-555-55555",
  "shipping_service_id": 55,
  "shipping_service_description": "FedEx Home Delivery",
  "total_item_price": 10,
  "total_tax": 1.99,
  "total_shipping": 11.29,
  "total_price": 23.28,
  "date_created": "2015-04-15T08:46:39-0700",
  "date_modified": "2015-04-15T08:46:39-0700"
}