api.setup.pos_categories

/api/setup/pos_categories/

GET /api/setup/pos_categories/

Description:

Provides a list of pos categories.
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<!-- No XML Request. -->

Response:

<categories>
    <category uri="/setup/pos_categories/x/" id="x" full_render="false">
        <name>[string]</name>
        <list_order>[int]</list_order>
        <type>[int]</type>
        <depth>[int]</depth>
        <parent>
            <category> <!-- summarized, full_render=false-->
                ....
            </category>
            [...]
        </parent>
    </category>
    [...]
</categories>

POST /api/setup/pos_categories/

Description:

Create a POS Category
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<category>
    <name>[string: max_len(1023)]</name>
    <parent>
        <category id="[integer]" />
    </parent>
    <list_order>[integer]</list_order>
</category>

Response:

<category uri="/setup/pos_categories/x/" id="x">
    <!-- see GET /setup/pos_categories/x/ response -->
</category>

/api/setup/pos_categories/(d+)/

GET /api/setup/pos_categories/(d+)/

Description:

Provides the details of a pos category.

By default a category will render up to the first 10 assigned products.
To page on the full list see GET /setup/pos_categories/x/products/ .
You can also omit the product details with the hide_products filter.
can_lock requires_lock has_etag requires_etag
True False False False

Filters:

Name Description
count number of categories to display
hide_products do not display any product info.
offset starting point

Request:

<!-- No XML Request. -->

Response:

<category uri="/setup/pos_categories/x/" id="x">
    <name>[string]</name>
    <list_order>[integer]</list_order>
    <type>pos</type>
    <depth>[integer]</depth>
    <parent>
        <category uri="/setup/pos_categories/y/" id="y">
            <name>[string]</name>
            <list_order>[integer]</list_order>
            <type>pos</type>
            <depth>[integer]</depth>
        </category>
    </parent>
    <children>
        <category uri="/setup/pos_categories/z/" id="z"/>
    </children>
    <category_products total_count="[integer]">
        <category_product uri="/setup/pos_categories/x/products/b/" id="b">
            <product uri="/products/b/" id="b" full_render="false">
                <code>[string]</code>
                <flags>
                    <master_model>[boolean]</master_model>
                </flags>
                <description short="">[string]</description>
                <product_photos>
                    <product_photo uri="/products/b/product_photos/e/" id="e" />
                </product_photos>
            </product>
        </category_product>
    </category_products>
</category>

PUT /api/setup/pos_categories/(d+)/

Description:

Modify the details of a pos category.
can_lock requires_lock has_etag requires_etag
True True False False

Request:

<category>
    <parent>
        <category id="[integer]" />
    </parent>
    <name>[string: max_len(1023)]</name>
    <list_order>[integer]</list_order>
</category>

Response:

<category uri="/setup/pos_categories/x/" id="x">
    <!-- see GET /setup/pos_categories/x/ response -->
</category>

DELETE /api/setup/pos_categories/(d+)/

Description:

Delete a POS category and its children categories. Children products become
uncategorized.
can_lock requires_lock has_etag requires_etag
True True False False

Request:

<!-- No XML Request -->

Response:

<!-- No XML Response -->

/api/setup/pos_categories/(d+)/products/

GET /api/setup/pos_categories/(d+)/products/

Description:

Provides the product list of a pos category.
can_lock requires_lock has_etag requires_etag
True False False False

Filters:

Name Description
count number of categories to display
hide_products do not display any product info.
offset starting point

Request:

<!-- No XML Request -->

Response:

<category_products total_count="[integer]">
    <category_product uri="/setup/pos_categories/x/products/b/" id="b">
        <product uri="/products/b/" id="b" full_render="false">
            <code>[string]</code>
            <flags>
                <master_model>[boolean]</master_model>
            </flags>
            <description short="[string]">[string]</description>
            <product_photos>
                <product_photo uri="/products/b/product_photos/r/" id="r" />
            </product_photos>
        </product>
    </category_product>
</category_products>

POST /api/setup/pos_categories/(d+)/products/

Description:

Add a product to a POS category.
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<category_product>
    <product id="[integer]">
</category_product>

Response:

<category_product uri="/setup/pos_categories/x/products/y/" id="y">
    <!-- see GET /setup/pos_categories/x/products/y/ response -->
</category_product>

/api/setup/pos_categories/(d+)/products/(d+)/

GET /api/setup/pos_categories/(d+)/products/(d+)/

Description:

Returns a category product.
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<!-- No XML Request -->

Response:

<category_product uri="/setup/pos_categories/x/products/y/" id="y">
    <product uri="/products/y/" id="y">
        <!-- see GET /products/X/ response for details -->
    </product>
</category_product>

DELETE /api/setup/pos_categories/(d+)/products/(d+)/

Description:

Remove a product from a POS category.
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<!-- No XML Request -->

Response:

<!-- No XML Response -->

/api/setup/pos_categories/root/

GET /api/setup/pos_categories/root/

Description:

Provides the parent-most POS category, which contains uncategorized products
and children categories. Note: Depth is 0 for a primary category, 1 for a
secondary category, and 2 for a tertiary category.

By default this category will render up to the first 10 uncategorized products.
To page on the full list see GET /setup/pos_categories/root/products/ .
You can also omit the product details with the hide_products filter.
can_lock requires_lock has_etag requires_etag
False False False False

Filters:

Name Description
count number of categories to display
hide_products do not display any product info.
offset starting point

Request:

<!-- No XML Request -->

Response:

<!-- see GET /setup/pos_categories/x/ response

NOTE: There is a difference in the way the category and category_products tags are rendered:

<category uri="/setup/pos_categories/root/">
<category_product uri="/setup/pos_categories/root/products/P/">
-->

/api/setup/pos_categories/root/products/

GET /api/setup/pos_categories/root/products/

Description:

Lists uncategorized products.
can_lock requires_lock has_etag requires_etag
False False False False

Filters:

Name Description
count number of categories to display
hide_products do not display any product info.
offset starting point

Request:

<!-- No XML Request -->

Response:

<!-- see GET /setup/pos_categories/x/products/ response

NOTE: There is a difference in the way the category product tag is rendered:

<category_product uri="/setup/pos_categories/root/products/P/">
-->

/api/setup/pos_categories/root/products/(d+)/

GET /api/setup/pos_categories/root/products/(d+)/

Description:

Return an uncategorized product.
can_lock requires_lock has_etag requires_etag
False False False False

Request:

<!-- No XML Request -->

Response:

<!-- see GET /setup/pos_categories/x/products/y/ response

NOTE: There is a difference in the way the category product tag is rendered:

<category_product uri="/setup/pos_categories/root/products/P/">
-->