Overview
The list page that contains the Comments, i.e. the comment lines in Business Central. Comment lines can be registered on many types of records, for example customers, vendors, items and the Wisefish stock centers, lots, pallets and vessels. The field tableName tells what type of record the comment belongs to, and number is the number (code) of the record.
Wisefish adds fields to the comment lines, for example a comment type, a hold status, a reason code and a lock. Wisefish itself uses comment lines for example to log errors and hold status changes on lots and pallets.
|
Endpoint name |
|
|
Source table |
|
|
Fixed view |
No filter. Returns the comment lines of all record types. |
|
Requests allowed |
GET, POST, PATCH, DELETE |
|
Primary key |
“Table Name”, “No.”, “Line No.” |
|
Record ID |
|
|
Procedures |
None |
Reading comments
To read the comments of one record, filter on both tableName and number, since the same number can exist for different record types. Long texts are split over several lines (max 80 characters per line), so read the lines in the order of lineNo.
Creating, changing and deleting comments
The API allows inserting, modifying and deleting comment lines. The same error handling applies as when the same is done within Business Central.
-
The API does not number the lines. Give each line a
lineNothat is unique for the record, for example 10000, 20000, 30000. -
The
dateis not set automatically, so it should be given. -
A comment line with
locked= true cannot be changed or deleted. A line can be changed to locked, but after that, changes fail with the errorRegistered comment cannot be changed or deleted., and deleting fails with the errorLocked comment cannot be changed or deleted.
Notes (record links) are another way to add text to records, see API - Record Notes.
Data
Field List
|
Property |
Type |
Format |
Description |
|
|
|
string |
uuid |
SystemId |
Record ID non-editable |
|
|
string |
max 10 |
Code |
optional |
|
|
string |
max 80 |
Comment, the text of the line. |
recommended |
|
|
string |
date |
Date |
recommended |
|
|
integer |
|
Line No. Unique per record ( |
primary key mandatory |
|
|
string |
max 20 |
Field “No.”, the number (code) of the record the comment belongs to. |
primary key mandatory |
|
|
string |
enum |
Table Name, the type of record. Options: G/L Account, Customer, Vendor, Item, Resource, Job, Resource Group, Bank Account, Campaign, Fixed Asset, Insurance, Nonstock Item, IC Partner, Vendor Agreement, Customer Agreement, WiFi Stock Center, WiFi Lot, WiFi Processing Stage, WiFi Pallet Entry, WiFi GS1 SSCC, WiFi Vessel, WiFi Fishing Trip (and other values added by Business Central or other extensions). |
primary key mandatory |
|
|
string |
enum |
Comment Type (Wisefish field). Options: General, Claim, Processing, Next Step, Transport, Invoicing, Reconciliation, HoldStatus, Error |
optional |
|
|
string |
date |
Entry Date (Wisefish field) |
optional |
|
|
string |
time |
Entry Time (Wisefish field) |
optional |
|
|
string |
enum |
Hold Status (Wisefish field). Options: (blank), Released, Extended (BB4), Hold, QA Hold, QA Lock, Testing (BB4), Customs Hold |
optional |
|
|
boolean |
|
Locked (Wisefish field). A locked comment line cannot be changed or deleted. |
optional |
|
|
string |
max 10 |
Reason Code (Wisefish field) |
optional |
|
|
string |
date |
Modified Entry Date (Wisefish field) |
optional |
|
|
string |
time |
Modified Entry Time (Wisefish field) |
optional |
|
|
string |
max 50 |
Modified User ID (Wisefish field) |
optional |
|
|
string |
max 50 |
User ID (Wisefish field), the user who registered the comment. |
optional |
|
|
integer |
|
System row version. Increments every time the record is modified. |
non-editable |
|
|
string |
date-time |
SystemModifiedAt (date and time of last change) |
non-editable |
Object Example
An example of one object:
{
"systemId": "b7e2c519-4a7c-f011-b02a-8bca792786d1",
"code": "",
"comment": "Pallet put on hold until the temperature log has been checked.",
"date": "2026-11-09",
"lineNo": 10000,
"number": "E2656",
"tableName": "WiFi Lot",
"commentType": "HoldStatus",
"entryDate": "2026-11-09",
"entryTime": "14:21:37.483",
"holdStatus": "QA Hold",
"locked": false,
"reasonCode": "QA",
"modifiedEntryDate": "0001-01-01",
"modifiedEntryTime": "00:00:00",
"modifiedUserID": "",
"userID": "JOHN",
"systemRowVersion": 2583318,
"lastModified": "2026-11-09T14:21:37.497Z"
}
Examples
Read comments
Read the comments of a lot
Reads the comment lines of lot E2656, sorted by line number. The response is a list of comment objects, as shown in Object Example.
GET .../comments?$filter=tableName eq 'WiFi Lot' and number eq 'E2656'&$orderby=lineNo
Read one comment line
Reads one comment line by its Record ID (systemId).
GET .../comments(b7e2c519-4a7c-f011-b02a-8bca792786d1)
Read error comments
Reads the comment lines of type Error, and returns only a few fields with $select.
Request:
GET .../comments?$filter=commentType eq 'Error'&$select=tableName,number,lineNo,comment
Response (shortened):
{
"@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/comments(tableName,number,lineNo,comment)",
"value": [
{
"@odata.etag": "W/\"JzE5Ojg4OTkwMDExMjIzMzQ0NTU2Njc3OzAwOyc=\"",
"tableName": "WiFi Lot",
"number": "E2683",
"lineNo": 10000,
"comment": "Unit Cost Ratio in Base Weight Unit (Redistribution) must have a value in Lot Pr"
},
{
"@odata.etag": "W/\"JzE5Ojk5MDAxMTIyMzM0NDU1NjY3Nzg4OzAwOyc=\"",
"tableName": "WiFi Lot",
"number": "E2683",
"lineNo": 20000,
"comment": "oduct: Lot Code=E2683, Stage Code=, Product No.=01-820137-G. It cannot be zero o"
}
]
}
Create, change and delete comments
Insert a Comment on a Customer
Adds a comment line to customer 01121212.
Request:
POST .../comments
Body:
{
"tableName": "Customer",
"number": "01121212",
"lineNo": 10000,
"date": "2026-11-10",
"comment": "Prefers delivery on Mondays."
}
Response (shortened):
{
"@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/comments/$entity",
"@odata.etag": "W/\"JzE5OjEwMTEyMjMzNDQ1NTY2Nzc4ODk5OzAwOyc=\"",
"systemId": "e1a4f63b-5e8a-f011-b02a-8bca792786d1",
"code": "",
"comment": "Prefers delivery on Mondays.",
"date": "2026-11-10",
"lineNo": 10000,
"number": "01121212",
"tableName": "Customer",
"commentType": "General",
"holdStatus": " ",
"locked": false,
"systemRowVersion": 2583402,
"lastModified": "2026-11-10T12:30:11.604Z"
}
Insert a Claim Comment on a Lot
Adds a claim comment with a reason code to lot E2656.
POST .../comments
Body:
{
"tableName": "WiFi Lot",
"number": "E2656",
"lineNo": 20000,
"date": "2026-11-10",
"comment": "Customer claim: 3 boxes damaged in transport.",
"commentType": "Claim",
"reasonCode": "DAMAGED"
}
Change a comment
Changes the text of the comment line. A PATCH request needs the If-Match header with the @odata.etag of the record (or *).
Request:
PATCH .../comments(e1a4f63b-5e8a-f011-b02a-8bca792786d1)
If-Match: *
Body:
{
"comment": "Prefers delivery on Mondays and Tuesdays."
}
Response (shortened):
{
"@odata.context": "https://containers.wisefish.com/BC/api/wisefish/base/v1.0/$metadata#companies(cf9f7b85-dd11-ef11-9f8b-6045bde9cc61)/comments/$entity",
"@odata.etag": "W/\"JzE5OjEyMTMyMzM0NDU1NjY3Nzg4OTkwOzAwOyc=\"",
"systemId": "e1a4f63b-5e8a-f011-b02a-8bca792786d1",
"comment": "Prefers delivery on Mondays and Tuesdays.",
"lineNo": 10000,
"number": "01121212",
"tableName": "Customer",
"systemRowVersion": 2583415,
"lastModified": "2026-11-10T12:34:52.218Z"
}
Lock a comment
Locks the comment line, so it can no longer be changed or deleted.
PATCH .../comments(e1a4f63b-5e8a-f011-b02a-8bca792786d1)
If-Match: *
Body:
{
"locked": true
}
Delete a comment
Deletes a comment line that is not locked. On success the response is empty (HTTP status 204 No Content).
DELETE .../comments(e1a4f63b-5e8a-f011-b02a-8bca792786d1)