StockItems

Read-only endpoint for StockItem information. StockItems represent individual products or variations on products available for purchase. StockItems may have associated videos or images, may be related to other StockItems, and may be grouped into one or more MXCategories. StockItems may have a set of user-defined attributes.

Fields

id

  • Type: Number

ID of the StockItem in the ItemExtend system

url

  • Type: String

URL to this StockItem.

stock_number

  • Type: String

The Southware stock number for this Stock Item. This with the location_number will be unique

location_number

  • Type: String

The Southware Location number. This with the stock_number will be unique.

  • Type: String

This is a string that can be defined as a lookup for this item. to be used with front end CMS systems for better SEO naming.

catalog_description

  • Type: String

A longer form description that can be added on to a StockItem for display to customers.

product_name

  • Type: String

The name of the StockItem.

quantity_available

  • Type: String

The number in stock as of the last sync with Southware. This value is stored as a string as to preserve the formatting from Southware.

page_title

  • Type: String

This can be used to display a page title different from the product name on your front end website.

meta_keywords

meta_description

  • Type: String

This can be used to specify keywords and description to be put in a meta tag that will show up in search results. This might be different from your normal description.

brand

  • Type: Object

This is the Brand information about the product. This value is Synchronized from Southware. It has the following fields:

  • name - Name of the brand
  • catalog_description - A description of the brand.

product_type

  • Type: String

This is the product type of the StockItem. This value is synchronized from Southware.

show_inventory_messaging

  • Type: Boolean

Whether or not to show inventory messaging.

inventory_handling_normal

  • Type: Choice: [normal(default) , not_replenishable, coming_soon, retailer, dropship]

This field is used to specify how the inventory is handled. Use this is you want to put out StockItems that you don't have yet, or you are going to no longer have for sale.

attributes

  • Type: URL

This url will have a list of the ItemExtend Attributes of the StockItem. You can define extra data about StockItems and retrieve it here. Each attribute has the following fields:

  • name - identifying name
  • title - Display name
  • value - The value of the attribute. this can be a String, Boolean, or Number
  • Type: URL

A link to related Items of this StockItem. Related Items are defined in Southware and synchronized to ItemExtend.

mxcategories

  • Type: URL

A link to a list of MXCategories that contain this StockItem. Each item in this list will contain the ancestor list of the MXCategories, from root to direct parent of the item, suitable for populating breadcrumbs. List elements will contain the following fields:

  • id - Identifier for the MXCategory
  • seo_link - The SEO URL friendly name for the MXCategory
  • name - The user display friendly name for the MXCategory

linked_images

  • Type: Array of Objects

This contains all the Images associated with the StockItem. Each image has the following fields:

  • order - order that this image should be displayed in
  • image - Object containing:
    • name - image name
    • alt_text - Alt text for your image tag
    • zoom - A URL for the 600x600 version of the image
    • large - A URL for the 400x400 version of the image
    • medium - A URL for the 200x200 version of the image
    • thumbnail - A URL for the 120x120 version of the image
    • mini - A URL for the 60x60 version of the image
    • attributes - An Array of attributes of the image.

linked_videos

  • Type: Array of Objects

This contains all the Videos associated with the StockItem. Each video has the following fields:

  • order - order that this video should be displayed in
  • video - Object containing:
    • name - Video name
    • url - The url to the Video file
    • thumb - A link to the thumbnail for this video
    • video_url - The link to the video
    • embed_url - URL for embedding the video on a page in an iframe.
    • attributes - An Array of attributes of the document.

linked_documents

  • Type: Array of Objects

This contains all the Documents associated with the StockItem. Each document has the following fields:

  • order - order that this video should be displayed in
  • document - Object containing:
    • name - Document name
    • file - The url to the document file
    • type - The file format
    • attributes - An Array of attributes of the document.

pricing

The pricing of the StockItem based on Southware Rules. See Prices for more information

stock_description_1, stock_description_2, stock_description_3

  • Type: String

These are the Southware Description fields.

Endpoints

List

GET /api/stockitems/

Return a list of StockItems. Can be filtered by stock_number or item_seo_link.

Retrieve

GET /api/stockitems/:key/

Return an individual StockItem by primary key or stock_number

Attributes

GET /api/stockitems/:key/attributes/

return a list of attributes of this stock item

GET /api/stockitems/:key/related/

return a list of stockitems related to the current item

MXCategories

GET /api/stockitems/:key/mxcategories/

return a list of mxcatgories and ancestors related to the current item