API - GetCategory

The GetCategory POST has now been replaced with the GetContent POST. This POST will eventually be removed from the API. Please use GetContent to get categories.

Overview

Endpoint URL https://www.yournetosite.com.au/do/WS/NetoAPI
Method POST
Headers
NETOAPI_ACTION GetCategory
NETOAPI_KEY Your Neto API Secure Key (generate this in your Neto control panel)
Description Use this call to get product category data. A successful call to GetCategory returns the data requested.
XSD Schema GetCategory XSD   |   GetCategory Response XSD

GetCategory Post

You must specify at least one Filter and one OutputSelector in your GetCategory request. These will determine the results returned.

XML POST

<?xml version="1.0" encoding="utf-8"?>
<GetCategory>
  <Filter>
    <CategoryID>20</CategoryID>
    <ParentCategoryID>2</ParentCategoryID>
    <CategoryName>T-Shirts</CategoryName>
    <Active>True</Active>
    <OnSiteMap>True</OnSiteMap>
    <OnMenu>True</OnMenu>
    <AllowReviews>True</AllowReviews>
    <RequireLogin>True</RequireLogin>
    <DatePostedFrom>(DateTime)</DatePostedFrom>
    <DatePostedTo>(DateTime)</DatePostedTo>
    <DateUpdatedFrom>(DateTime)</DateUpdatedFrom>
    <DateUpdatedTo>(DateTime)</DateUpdatedTo>
    <Page>(Integer)</Page>
    <Limit>(Integer)</Limit>
    <OutputSelector>CategoryID</OutputSelector>
    <OutputSelector>ID</OutputSelector>
    <OutputSelector>CategoryName</OutputSelector>
    <OutputSelector>ParentCategoryID</OutputSelector>
    <OutputSelector>Active</OutputSelector>
    <OutputSelector>SortOrder</OutputSelector>
    <OutputSelector>OnSiteMap</OutputSelector>
    <OutputSelector>OnMenu</OutputSelector>
    <OutputSelector>AllowReviews</OutputSelector>
    <OutputSelector>CategoryReference</OutputSelector>
    <OutputSelector>ShortDescription1</OutputSelector>
    <OutputSelector>ShortDescription2</OutputSelector>
    <OutputSelector>ShortDescription3</OutputSelector>
    <OutputSelector>Description1</OutputSelector>
    <OutputSelector>Description2</OutputSelector>
    <OutputSelector>Description3</OutputSelector>
    <OutputSelector>ExternalSource</OutputSelector>
    <OutputSelector>ExternalReference1</OutputSelector>
    <OutputSelector>ExternalReference2</OutputSelector>
    <OutputSelector>ExternalReference3</OutputSelector>
    <OutputSelector>DatePosted</OutputSelector>
    <OutputSelector>DateUpdated</OutputSelector>
  </Filter>
</GetCategory>

JSON POST

{
  "Filter": {
    "CategoryID":[
      "Integer"
      /*, ...*/
    ],
    "ParentCategoryID":[
      "Integer"
      /*, ...*/
    ],
    "CategoryName":[
      "String"
      /*, ...*/
    ],
    "Active":"Boolean",
    "OnSiteMap":"Boolean",
    "OnMenu":"Boolean",
    "AllowReviews":"Boolean",
    "RequireLogin":"Boolean",
    "DatePostedFrom":"DateTime",
    "DatePostedTo":"DateTime",
    "DateUpdatedFrom":"DateTime",
    "DateUpdatedTo":"DateTime",
    "Page":"Integer",
    "Limit":"Integer",
    "OutputSelector":[
      "Enumeration"
      /*, ...*/
    ]
  } 
}

<Filter>

Element Name Required Field Type / Options
CategoryID Optional
Supports Multiple Elements
Integer
ParentCategoryID Optional
Supports Multiple Elements
Integer
CategoryName Optional
Supports Multiple Elements
String(100)
Active Optional Boolean(True, False)
OnSiteMap Optional Boolean(True, False)
OnMenu Optional Boolean(True, False)
AllowReviews Optional Boolean(True, False)
RequireLogin Optional Boolean(True, False)
DatePostedFrom Optional DateTime
DatePostedTo Optional DateTime
DateUpdatedFrom Optional DateTime
DateUpdatedTo Optional DateTime
Page Optional Integer
Limit Optional Integer

<OutputSelector>

Determines what is returned by the POST. Refer to the example response below this table or the related XSD schema for details and restrictions of each output element.

Note: Each OutputSelector should be a separate element in your post.

OutputSelector Enumeration (CategoryID, ID, CategoryName, ParentCategoryID, Active, SortOrder, OnSiteMap, OnMenu, AllowReviews, CategoryReference, ShortDescription1, ShortDescription2, ShortDescription3, Description1, Description2, Description3, ExternalSource, ExternalReference1, ExternalReference2, ExternalReference3, DatePosted, DateUpdated)

Responses

Sample GetCategory Response (Success)

Includes all outputs

Sample GetCategory Response (Error)

Input call, no data returned.

Sample GetCategory Response (Warning)

Warning message, data returned.