For the complete documentation index, see llms.txt. This page is also available as Markdown.

Update Item Groups

Changes the item groups of one item in Logic ERP – the groups at each of the 30 group levels (what each level means, for example department, category or brand, depends on your company's setup). You name the group at each level; a group that does not exist yet at that level is created automatically. Use it when your system re-classifies an item that already exists in Logic ERP.

Endpoint

Name
Detail

Address

https://your-server/api/UpdateItemGroups

Method

POST

Authorization

Basic Auth

The response and the common messages are explained in How Every API Call Works.

Request fields

Field names are matched without regard to capitals.

Field
Type
Required
Default
Meaning

LogicUserCode

text

Yes

""

The item code as shown in Logic ERP (UserCode in Get Item Master). Matched without regard to capitals; spaces at the end are ignored. The barcode cannot be used here.

GroupName1 … GroupName30

text

No

""

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupShort1 … GroupShort30

text

No

""

Short name for the group at that level. Used only when the group is created by this request; up to 60 characters. It is not used to find a group and does not change the short name of a group that already exists.

Rules Logic ERP applies

  • Finding the group. At each level, Logic ERP looks for a main group (not a sub-group) at that level whose name equals the name you sent – without regard to capitals, ignoring spaces at the end but not at the start. Groups with the same name at other levels do not count.

  • Creating the group. If no such group exists, a new main group is created at that level with the name you sent and your short name (or a blank short name). It is created even when the item is then not changed – see the known issues.

  • The whole item changes. Groups belong to the item (item and shade), so the change applies to every item code of that item – all its sizes and packs – not only the code you sent.

  • Sending (NIL) as a name looks for a group actually named (NIL) at that level and, if there is none, creates one. At level 1 it leaves the item's group unchanged. There is no way to clear a level to "no group" with this endpoint.

  • Everything is saved in one go: if an error occurs (for example a database error), no group is created and the item is not changed. An unknown item code is handled differently – see the known issues.

  • The item's modified date is not changed, so this change does not bring the item into a Get Item Master request for a period. Fetch the item by its code if you need to confirm the change.

  • This endpoint is covered by the same licence as creating items through the API.

Known issue – levels you leave out are overwritten. Every level you leave out or send as "" is not left alone: the item is moved to a group with a blank name at that level, and such a blank group is created at each level that does not have one yet. Until this is fixed, send all 30 levels in every request: the item's current group name (from Get Item Master) for every level you are not changing, and (NIL) for every level where Get Item Master shows an empty group name. At a level that has no group named (NIL) yet, such a group is created and the item is moved to it; it still shows as an empty name in Get Item Master.

Known issue – unknown item code still creates groups. If LogicUserCode is not found, the request fails with Item Head Code : 0 Not Found..., but any groups named in the request that did not exist are created anyway. Check that the item code exists (Get Item Master) before you call this endpoint.

Known issue – apostrophes in group names and item codes. A group name or item code containing an apostrophe (for example MEN'S WEAR) makes the request fail with a database error. Leave apostrophes out of group names.

Example request

Moves item KR1045 to the groups KURTA / ETHNIC / LADIES at levels 1 to 3. Because of the first known issue, a real request should carry all 30 levels; this example shows three to keep it short.

Test it

Send a request to the Logic ERP sandbox (a test company) from this page: open the block below, enter the sandbox user name and password (ask your Logic ERP support team), change the request if you like, and press Test it. This really saves in the sandbox, so use test values like the example. The example sends all 30 levels for the test item APITEST0001, with (NIL) for the levels it does not use (see the known issues on this page).

Update Item Groups

post

Changes the item groups of one item in Logic ERP – the groups at each of the 30 group levels (what each level means, for example department, category or brand, depends on your company's setup). You name the group at each level; a group that does not exist yet at that level is created automatically. Use it when your system re-classifies an item that already exists in Logic ERP.

Authorizations
AuthorizationstringRequired

The user name and password of your API site.

Body
LogicUserCodestringOptional

The item code as shown in Logic ERP (UserCode in Get Item Master). Matched without regard to capitals; spaces at the end are ignored. The barcode cannot be used here.

GroupName1stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName2stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName3stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName4stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName5stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName6stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName7stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName8stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName9stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName10stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName11stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName12stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName13stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName14stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName15stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName16stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName17stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName18stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName19stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName20stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName21stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName22stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName23stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName24stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName25stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName26stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName27stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName28stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName29stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

GroupName30stringOptional

The name of the group at level 1 … 30, as shown in Logic ERP (Group_Name1 … Group_Name30 in Get Item Master). Up to 80 characters. See the rules and the known issue below.

Responses
200

Always HTTP 200. Check Status and Message.

application/json
StatusbooleanOptional

true when the item's groups were saved.

MessagestringOptional

Empty when saved; otherwise the reason.

LastSavedCodeintegerOptional

Always 0.

request_IDstringOptional

The ID of this request. null when the request failed because LogicUserCode was empty.

post/UpdateItemGroups
POST /api/UpdateItemGroups HTTP/1.1
Host: demo.logicerp.com
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 704

{
  "LogicUserCode": "APITEST0001",
  "GroupName1": "SANDAL",
  "GroupName2": "(NIL)",
  "GroupName3": "(NIL)",
  "GroupName4": "(NIL)",
  "GroupName5": "KAMPS FOOTWEAR",
  "GroupName6": "CONTINUED",
  "GroupName7": "INR",
  "GroupName8": "2 NOS",
  "GroupName9": "(NIL)",
  "GroupName10": "(NIL)",
  "GroupName11": "(NIL)",
  "GroupName12": "(NIL)",
  "GroupName13": "(NIL)",
  "GroupName14": "(NIL)",
  "GroupName15": "(NIL)",
  "GroupName16": "(NIL)",
  "GroupName17": "(NIL)",
  "GroupName18": "(NIL)",
  "GroupName19": "(NIL)",
  "GroupName20": "(NIL)",
  "GroupName21": "(NIL)",
  "GroupName22": "(NIL)",
  "GroupName23": "(NIL)",
  "GroupName24": "(NIL)",
  "GroupName25": "64039990",
  "GroupName26": "(NIL)",
  "GroupName27": "(NIL)",
  "GroupName28": "(NIL)",
  "GroupName29": "(NIL)",
  "GroupName30": "GST FOOTWEAR"
}
{
  "Status": true,
  "Message": "text",
  "LastSavedCode": 1,
  "request_ID": "text"
}

Response

Field
What it holds for this endpoint

Status

true when the item's groups were saved.

Message

Empty when saved; otherwise the reason.

LastSavedCode

Always 0.

request_ID

The ID of this request. null when the request failed because LogicUserCode was empty.

Example response

Messages you may see

Message
Meaning
What to do

LogicUserCode Is Missing...

LogicUserCode was empty or left out. Nothing was saved.

Send the item code.

Item Head Code : 0 Not Found...

No item has the code you sent in LogicUserCode. The item was not changed, but new groups named in the request were created (see the known issue).

Check the item code.

A database error (with Status: false)

A group name or the item code contained an apostrophe, or a name was longer than the limits above. Nothing was saved. The reason may be followed by technical detail – read the first line.

Correct the name and send again.