API - Item Categories


Overview

The list page that contains the Item Categories.

Endpoint name

itemCategories

Source table

Item Category

Fixed view


Requests allowed

GET, POST, PATCH, DELETE

Primary key

Code

Record ID

code

Procedures

None


Data

Field List

Property

Type

Format

Description


systemId

string (UUID)

uuid

System ID. This is really not needed because the code is the record ID.

non-editable

code

string

max 20

The unique id of this entry.

Record ID

primary key

description

string

max 100

The description of this item category.

mandatory

parentCategory

string

max 20

If this is a child category, this is the parent category code.

optional

wisefishUsage

string

enum

Options:

  • Pallet

  • Lot

optional

hasChildren

boolean


Tells if this category has children or not.

non-editable

indentation

integer


Indentation

non-editable

presentationOrder

integer


An integer that controls the presentation within BC.

non-editable

systemRowVersion

integer


System row version. Increments every time the record is modified.

non-editable

lastModified

string

date-time

SystemModifiedAt (date and time of last change)

non-editable


Object Example

An example of one object:

JSON
{
    "code": "FISH-PROD",
    "systemId": "33434031-7a14-f011-b01f-bdbc04fc3978",
    "description": "Finished fish products",
    "parentCategory": "FISH",
    "wisefishUsage": " ",
    "hasChildren": false,
    "indentation": 1,
    "presentationOrder": 7500,
    "systemRowVersion": 2576402,
    "lastModified": "2025-04-08T13:05:52.293Z"
}


Examples

Read item categories

Read all item categories

Reads all item categories. The response is a list of item category objects, as shown in Object Example.

JSON
GET .../itemCategories

Read one item category

The record ID is the code of the item category, so one entry is read with the code in the URL:

JSON
GET .../itemCategories('FISH-PROD')

Read the child categories of a category

Reads the code and description of all item categories that have FISH as parent category (the response is shortened).

Request:

JSON
GET .../itemCategories?$filter=parentCategory eq 'FISH'&$select=code,description,parentCategory

Response:

JSON
{
    "@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/itemCategories(code,description,parentCategory)",
    "value": [
        {
            "@odata.etag": "W/\"JzE5OzQ4MjE5MzcwNTUxODI3NDYzOTEyOzAwOyc=\"",
            "code": "FISH-PROD",
            "description": "Finished fish products",
            "parentCategory": "FISH"
        }
    ]
}


Create, change and delete item categories

Create a new item category

Creates the item category FISH-FROZEN as a child of FISH. description is mandatory; hasChildren, indentation and presentationOrder are set by Business Central.

Request:

JSON
POST .../itemCategories

Body:
{
    "code": "FISH-FROZEN",
    "description": "Frozen fish products",
    "parentCategory": "FISH"
}

Response:

JSON
{
    "@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/itemCategories/$entity",
    "@odata.etag": "W/\"JzE5OzcyNjE4MzkyMDQ1NTE3MzgyOTQxOzAwOyc=\"",
    "code": "FISH-FROZEN",
    "systemId": "5b2e8c41-9a1f-f111-b02a-8bca792786d1",
    "description": "Frozen fish products",
    "parentCategory": "FISH",
    "wisefishUsage": " ",
    "hasChildren": false,
    "indentation": 1,
    "presentationOrder": 7600,
    "systemRowVersion": 2581952,
    "lastModified": "2025-12-19T11:02:17.640Z"
}

Change an item category

Sets the Wisefish usage of item category FISH-FROZEN to Pallet. A PATCH request needs the If-Match header with the @odata.etag of the record (or *).

Request:

JSON
PATCH .../itemCategories('FISH-FROZEN')
If-Match: *

Body:
{
    "wisefishUsage": "Pallet"
}

Response:

JSON
{
    "@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/itemCategories/$entity",
    "@odata.etag": "W/\"JzE5OzI5MzA0ODE3MzY1MDkyODQ3MTYzOzAwOyc=\"",
    "code": "FISH-FROZEN",
    "systemId": "5b2e8c41-9a1f-f111-b02a-8bca792786d1",
    "description": "Frozen fish products",
    "parentCategory": "FISH",
    "wisefishUsage": "Pallet",
    "hasChildren": false,
    "indentation": 1,
    "presentationOrder": 7600,
    "systemRowVersion": 2581977,
    "lastModified": "2025-12-19T11:09:41.205Z"
}

Delete an item category

Deletes item category FISH-FROZEN. On success the response is empty (HTTP status 204 No Content).

JSON
DELETE .../itemCategories('FISH-FROZEN')