XOMNI: Experience Omni-Channel

Last Updated: May 05, 2016

This API allows a client application to fetch all the shopping cart items based on the shopping cart unique key. Shopping cart items may be used by client applications to display shopping cart of a particular user. This is especially useful when an application needs to fetch close-by shopping carts and fetch the shopping cart of a PII whose token is not available client side.

Request

HTTP Method Resource URI
GET https://{tenantName}.api.xomni.com/pii/shoppingcart?shoppingCartUniqueKey={shoppingCartUniqueKey}&longitude={longitude}&latitude={latitude}&includeItemStaticProperties={includeItemStaticProperties}&includeItemDynamicProperties={includeItemDynamicProperties}&includeCategoryMetadata={includeCategoryMetadata}&imageAssetDetail={imageAssetDetail}&videoAssetDetail={videoAssetDetail}&documentAssetDetail={documentAssetDetail}&metadataKey={metadataKey}&metadataValue={metadataValue}

URI Parameters

Parameter Name Description Type Conditions
shoppingCartUniqueKey The unique key of the shopping cart. String
longitude Longitude value of the fetch operation location Number
latitude Latitude value of the fetch operation location Number
IncludeItemStaticProperties Indicates whether the response contains items static properties (like SKU, RFID, CategoryId etc. except for Dynamic Attributes) Boolean
IncludeItemDynamicProperties Indicates if the response contains items dynamic properties (like DynamicAttributes) Boolean
IncludeCategoryMetadata Indicates if the response contains shopping cart items category metadata. Boolean
ImageAssetDetail Indicates whether the response contains item image assets (see Possible values for ImageAssetDetail below). Number
VideoAssetDetail Indicates if the response contains item image assets (see Possible values for VideoAssetDetail below). Number
DocumentAssetDetail Indicates whether the response contains item image assets (see Possible values for DocumentAssetDetail below). Number
MetadataKey For querying assets with their metadata. You can send metadata key filter using this field. String
MetadataValue For querying assets with their metadata. You can send metadata value filter using this field. String

Possible Values For ImageAssetDetail

Value Description
0 Default Value – Image assets are not included in response.
1 Includes only default image asset.
2 Includes only default image asset with metadata.
4 Includes all image assets.
8 Includes all image assets with metadata.

Possible Values For VideoAssetDetail

Value Description
0 Default Value – Video assets are not included in response.
1 Includes only default image asset.
2 Includes only default video asset with metadata.
4 Includes all video assets.
8 Includes all video assets with metadata.

Possible Values For DocumentAssetDetail

Value Description
0 Default Value – Document assets are not included in response.
1 Includes only default document asset.
2 Includes only default document asset with metadata.
4 Includes all document assets.
8 Includes all document assets with metadata.

Request Headers

Header Field Name Description
Authorization
Access or identity token taken from oauth APIs.
Sample: Bearer dc8f1dcdbe454da8a25621839a93569337522968019e4bd7becd6e01285444da
Accept
Includes minor version header.
Sample: application/vnd.xomni.api-v4-1, */*

Response

{
   "Data":{
      "Name":"ShoppingCart Sample Name",
      "ShoppingCartItems":[
         {
            "CategoryMetadata":null,
            "Quantity":5,
            "Item":{
               "DynamicAttributes":[
                  {
                     "TypeId":1,
                     "TypeValueId":1,
                     "Value":"Red",
                     "TypeName":"Color"
                  },
                  {
                     "TypeId":3,
                     "TypeValueId":7,
                     "Value":"A",
                     "TypeName":"Style"
                  },
                  {
                     "TypeId":2,
                     "TypeValueId":9,
                     "Value":"S",
                     "TypeName":"Size"
                  }
               ],
               "Id":1,
               "RFID":null,
               "UUID":null,
               "SKU":null,
               "Name":"D1 Red-S-A Style",
               "Model":"Model 1",
               "Title":"D1 Title",
               "ShortDescription":"Master Item 1 Short Description",
               "LongDescription":null,
               "Rating":null,
               "LikeCount":80,
               "CategoryId":66,
               "InStock":true,
               "PublicWebLink":null,
               "DefaultItemId":1,
               "BrandId":1,
               "UnitTypeId":3,
               "UnitTypeName":"Quantity",
               "UnitTypeCode":"Quantity",
               "Prices":[
                  {
                     "NormalPrice":100.55,
                     "DiscountPrice":null,
                     "CurrencySymbol":"€",
                     "CurrencyId":2
                  },
                  {
                     "NormalPrice":140.55,
                     "DiscountPrice":null,
                     "CurrencySymbol":"$",
                     "CurrencyId":1
                  }
               ],
               "Tags":[

               ],
               "Weights":[

               ],
               "Dimensions":[
                  {
                     "DimensionTypeId":1,
                     "DimensionDescription":"Meter",
                     "Width":1,
                     "Height":1,
                     "Depth":1
                  },
                  {
                     "DimensionTypeId":2,
                     "DimensionDescription":"Inch",
                     "Width":3,
                     "Height":3,
                     "Depth":3
                  }
               ],
               "Metadata":[

               ],
               "ImageAssets":[

               ],
               "VideoAssets":[

               ],
               "DocumentAssets":[

               ],
               "HasVariants":true
            },
            "BluetoothId":"BluetoothId",
            "DateAdded":"2013-07-12T12:53:39.777",
            "UniqueKey":"90a1de56-20ea-4460-b6f1-6ab533387f6b"
         },
         {
            "CategoryMetadata":null,
            "Quantity":5,
            "Item":{
               "DynamicAttributes":[
                  {
                     "TypeId":1,
                     "TypeValueId":1,
                     "Value":"Red",
                     "TypeName":"Color"
                  },
                  {
                     "TypeId":3,
                     "TypeValueId":7,
                     "Value":"A",
                     "TypeName":"Style"
                  },
                  {
                     "TypeId":2,
                     "TypeValueId":9,
                     "Value":"S",
                     "TypeName":"Size"
                  }
               ],
               "Id":2,
               "RFID":null,
               "UUID":null,
               "SKU":null,
               "Name":"D2 Red-S-A Style",
               "Model":"Model 2",
               "Title":"D2 Title",
               "ShortDescription":"D2 Short Description",
               "LongDescription":"D2 Long Description",
               "Rating":null,
               "LikeCount":null,
               "CategoryId":67,
               "InStock":true,
               "PublicWebLink":null,
               "DefaultItemId":2,
               "BrandId":2,
               "UnitTypeId":2,
               "UnitTypeName":"250 Kilogram",
               "UnitTypeCode":"Kg",
               "Prices":[
                  {
                     "NormalPrice":10.55,
                     "DiscountPrice":null,
                     "CurrencySymbol":"$",
                     "CurrencyId":1
                  },
                  {
                     "NormalPrice":20.55,
                     "DiscountPrice":15,
                     "CurrencySymbol":"€",
                     "CurrencyId":2
                  }
               ],
               "Tags":[
                  {
                     "Id":2,
                     "Name":"c4da4bd6-2783-4a45-8fa8-2c4777113f19",
                     "Description":"c4da4bd6-2783-4a45-8fa8-2c4777113f19",
                     "TagMetadata":[

                     ]
                  }
               ],
               "Weights":[

               ],
               "Dimensions":[
                  {
                     "DimensionTypeId":1,
                     "DimensionDescription":"Meter",
                     "Width":11,
                     "Height":11,
                     "Depth":11
                  },
                  {
                     "DimensionTypeId":2,
                     "DimensionDescription":"Inch",
                     "Width":5,
                     "Height":5,
                     "Depth":5
                  }
               ],
               "Metadata":[

               ],
               "ImageAssets":[

               ],
               "VideoAssets":[

               ],
               "DocumentAssets":[

               ],
               "HasVariants":true
            },
            "BluetoothId":"BluetoothId",
            "DateAdded":"2013-07-12T12:53:40.753",
            "UniqueKey":"5df0c833-326f-4ac1-8ea2-a118b17b6e95"
         }
      ],
      "LastSeenLocation":null,
      "IsPublic":true,
      "UniqueKey":"3d6a2c36-d85e-458f-b13f-438c03bc22be"
   }
}

Response Body Description

Parameter Name Description Type
Data.UniqueKey The unique key of the shopping cart. String
Data.Name The name of the shopping cart. String
Data.IsPublic A Boolean value indicating whether the shopping cart is publicly visible. Bool
Data.LastSeenLocation.Longitude Longitude value of the location. Number
Data.LastSeenLocation.Latitude Latitude value of the location. Number
Data.ShoppingCartItems[0..N].Quantity Quantity of the shopping cart item. Number
Data.ShoppingCartItems[0..N].BluetoothId Bluetooth sensor id. String
Data.ShoppingCartItems[0..N].DateAdded Shopping cart item creation time. Date
Data.ShoppingCartItems[0..N].UniqueKey The unique key of shopping cart item. String
Data.ShoppingCartItems[0..N].LastSeenLocation.Longitude Longitude value of the location. Number
Data.ShoppingCartItems[0..N].LastSeenLocation.Latitude Latitude value of the location. Number
Data.ShoppingCartItems[0..N].Item.Id The unique ID of the item Number
Data.ShoppingCartItems[0..N].Item.RFID The radio frequency ID of the item. String
Data.ShoppingCartItems[0..N].Item.UUID The universally unique ID of the item. String
Data.ShoppingCartItems[0..N].Item.SKU Stock keeping unit of the item. String
Data.ShoppingCartItems[0..N].Item.Name Name of the item. String
Data.ShoppingCartItems[0..N].Item.Model Model of the item. String
Data.ShoppingCartItems[0..N].Item.Title Title of the item. String
Data.ShoppingCartItems[0..N].Item.ShortDescription Short description of the item. String
Data.ShoppingCartItems[0..N].Item.LongDescription Long description of the item. String
Data.ShoppingCartItems[0..N].Item.Rating Rating of the item. Number
Data.ShoppingCartItems[0..N].Item.LikeCount Like count of the item. Number
Data.ShoppingCartItems[0..N].Item.CategoryId The unique ID of a category assigned to the item. Number
Data.ShoppingCartItems[0..N].Item.InStock The Boolean field indicating if the item is in stock or not. Boolean
Data.ShoppingCartItems[0..N].Item.PublicWebLink Public web link of the item. String
Data.ShoppingCartItems[0..N].Item.DefaultItemId The ID of the default item in the associated variant list. If the DefaultItemID equals to the ID, the current item is a default item in its variant list. Number
Data.ShoppingCartItems[0..N].Item.BrandId The unique ID of a brand assigned to the item. Number
Data.ShoppingCartItems[0..N].Item.UnitTypeId ID of item’s unit type. Number
Data.ShoppingCartItems[0..N].Item.UnitTypeName The name of the type used to define a unit of the item (e.g.: kilogram). String
Data.ShoppingCartItems[0..N].Item.UnitTypeCode The code of the type used to define a unit of item (e.g. kg). String
Data.ShoppingCartItems[0..N].Item.HasVariants The Boolean field indicating if the item has variants or doesn’t. Boolean
Data.ShoppingCartItems[0..N].Item.DocumentAssets[0..N].AssetMetadata A list of key/value metadata pairs Array
Data.ShoppingCartItems[0..N].Item.DocumentAssets[0..N].AssetId The unique ID of the asset. Number
Data.ShoppingCartItems[0..N].Item.DocumentAssets[0..N].AssetUrl The unique URL of the asset. String
Data.ShoppingCartItems[0..N].Item.DocumentAssets[0..N].IsDefault A boolean field indicating whether the asset is default or not. Boolean
Data.ShoppingCartItems[0..N].Item.VideoAssets[0..N].AssetMetadata A list of key/value metadata pairs Array
Data.ShoppingCartItems[0..N].Item.VideoAssets[0..N].AssetId The unique ID of the asset. Number
Data.ShoppingCartItems[0..N].Item.VideoAssets[0..N].AssetUrl The unique URL of the asset. String
Data.ShoppingCartItems[0..N].Item.VideoAssets[0..N].IsDefault A boolean field indicating whether the asset is default or not. Boolean
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].IsDefault Boolean field indicating whether this asset is the default image of the related object or not. Boolean
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].AssetId The unique ID of the asset. Number
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].AssetUrl The unique URL of the asset. String
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].AssetMetadata[0..N].Key The key for the metadata. String
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].AssetMetadata[0..N].Value The value of the metadata. String
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].ResizedAssets[0..N].AssetUrl The unique URL of the asset. String
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].ResizedAssets[0..N].ImageSizeProfile.Id The unique ID of the resized asset size profile. Number
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].ResizedAssets[0..N].ImageSizeProfile.Height Height of the resized asset. Number
Data.ShoppingCartItems[0..N].Item.ImageAssets[0..N].ResizedAssets[0..N].ImageSizeProfile.Width Width of the resized asset. Number
Data.ShoppingCartItems[0..N].Item.Dimensions[0..N].DimensionTypeId The unique ID of the dimension type to define the dimension. Number
Data.ShoppingCartItems[0..N].Item.Dimensions[0..N].DimensionDescription The description of the dimension type to define the dimension. String
Data.ShoppingCartItems[0..N].Item.Dimensions[0..N].Width The width value of the item. Number
Data.ShoppingCartItems[0..N].Item.Dimensions[0..N].Height The hight value of the item. Number
Data.ShoppingCartItems[0..N].Item.Dimensions[0..N].Depth The depth value of the item. Number
Data.ShoppingCartItems[0..N].Item.Weights[0..N].WeightTypeId The unique ID of the weight type to define the weight. Number
Data.ShoppingCartItems[0..N].Item.Weights[0..N].WeightTypeDescription The description of the weight type to define the weight. String
Data.ShoppingCartItems[0..N].Item.Weights[0..N].Value The weight value of the item. Number
Data.ShoppingCartItems[0..N].Item.Tags[0..N].Id The unique ID of the tag. Number
Data.ShoppingCartItems[0..N].Item.Tags[0..N].Name The name of the tag. String
Data.ShoppingCartItems[0..N].Item.Tags[0..N].Description The description of the tag. String
Data.ShoppingCartItems[0..N].Item.Tags[0..N].TagMetadata[0..N].Key The key for the metadata. String
Data.ShoppingCartItems[0..N].Item.Tags[0..N].TagMetadata[0..N].Value The value of the metadata. String
Data.ShoppingCartItems[0..N].Item.Prices[0..N].NormalPrice Reqular price. Number
Data.ShoppingCartItems[0..N].Item.Prices[0..N].DiscountPrice Discount price. Number
Data.ShoppingCartItems[0..N].Item.Prices[0..N].PriceTypeSymbol Unique symbol of the price type. String
Data.ShoppingCartItems[0..N].Item.Prices[0..N].PriceTypeId Unique ID of the price type. Number
Data.ShoppingCartItems[0..N].Item.DynamicAttributes[0..N].TypeId Unique ID of a dynamic field. Number
Data.ShoppingCartItems[0..N].Item.DynamicAttributes[0..N].TypeValueId Unique ID of a dynamic field value. Number
Data.ShoppingCartItems[0..N].Item.DynamicAttributes[0..N].Value Value of a dynamic field. String
Data.ShoppingCartItems[0..N].Item.DynamicAttributes[0..N].TypeName Unique name of a dynamic field. String
Data.ShoppingCartItems[0..N].CategoryMetadata[0..N].Key The key for the metadata. String
Data.ShoppingCartItems[0..N].CategoryMetadata[0..N].Value The value of the metadata. String

Response Headers

Header Field Name Description
Content-Type
Content type of the response entity. The value of this header is always application/json.

Status Codes

A successful operation returns status code 200 (OK) for GET operations. Possible response status codes are as listed below:

Status Code Description
403 (Forbidden) This shopping cart is private or not accessible to specified PII User.
404 (Not Found) The shopping cart not found.