List all scrap log entries
Retrieves all scrap log entries for the specified company, filtered by active status, ordered by log date descending.
path Parameters
companyIdThe unique identifier of the company
query Parameters
activeFilter by active status (true = active items, false = deleted items). Defaults to true.
List all scrap log entries › Responses
List of scrap log entries retrieved successfully
loggedByNameDisplay name of the user who logged this entry
scrapLogIdUnique identifier for the scrap log entry
companyIdIdentifier of the owning company
logDateDate when the scrap was logged
binSkipReferenceBin or skip reference identifier
startingWeightStarting weight in kilograms
closingWeightClosing weight in kilograms
netWeightNet weight (calculated as ClosingWeight - StartingWeight) in kilograms
loggedByUser ID of the person who logged this entry
createdAtTimestamp when the record was created (UTC)
updatedAtTimestamp when the record was last updated (UTC)
activeSoft delete flag (true = active, false = deleted)
Update existing scrap log entries
Updates one or more existing scrap log entries. Each entry must belong to the specified company. All changes are recorded in the edit history for audit purposes.
path Parameters
companyIdThe unique identifier of the company
Update existing scrap log entries › Request Body
scrapLogIdlogDatebinSkipReferencestartingWeightclosingWeightUpdate existing scrap log entries › Responses
Scrap log entries updated successfully
loggedByNameDisplay name of the user who logged this entry
scrapLogIdUnique identifier for the scrap log entry
companyIdIdentifier of the owning company
logDateDate when the scrap was logged
binSkipReferenceBin or skip reference identifier
startingWeightStarting weight in kilograms
closingWeightClosing weight in kilograms
netWeightNet weight (calculated as ClosingWeight - StartingWeight) in kilograms
loggedByUser ID of the person who logged this entry
createdAtTimestamp when the record was created (UTC)
updatedAtTimestamp when the record was last updated (UTC)
activeSoft delete flag (true = active, false = deleted)
Create new scrap log entries
Creates one or more new scrap log entries for the specified company. Each entry will be associated with the companyId provided in the route and the current authenticated user.
path Parameters
companyIdThe unique identifier of the company
Create new scrap log entries › Request Body
logDatebinSkipReferencestartingWeightclosingWeightloggedByCreate new scrap log entries › Responses
Scrap log entries created successfully
scrapLogIdUnique identifier for the scrap log entry
companyIdIdentifier of the owning company
logDateDate when the scrap was logged
binSkipReferenceBin or skip reference identifier
startingWeightStarting weight in kilograms
closingWeightClosing weight in kilograms
netWeightNet weight (calculated as ClosingWeight - StartingWeight) in kilograms
loggedByUser ID of the person who logged this entry
createdAtTimestamp when the record was created (UTC)
updatedAtTimestamp when the record was last updated (UTC)
activeSoft delete flag (true = active, false = deleted)
Delete scrap log entries
Deletes one or more scrap log entries for the specified company using a stored procedure that enforces authorization and ownership.
path Parameters
companyIdThe unique identifier of the company owning the entries
Delete scrap log entries › Responses
Scrap log entries deleted successfully
deletedItemsList of deleted scrap log entry IDs
Download scrap log as CSV
Downloads all scrap log entries for a company as a CSV file
path Parameters
companyIdThe unique identifier of the company
query Parameters
activeFilter by active status (true = active items, false = deleted items). Defaults to true.
Download scrap log as CSV › Responses
CSV file with scrap log data
Get a scrap log entry by ID
Retrieves a single scrap log entry by its unique ID within the specified company.
path Parameters
companyIdThe unique identifier of the company that owns the scrap log entry
scrapLogIdThe unique identifier of the scrap log entry to retrieve
Get a scrap log entry by ID › Responses
Scrap log entry retrieved successfully
loggedByNameDisplay name of the user who logged this entry
scrapLogIdUnique identifier for the scrap log entry
companyIdIdentifier of the owning company
logDateDate when the scrap was logged
binSkipReferenceBin or skip reference identifier
startingWeightStarting weight in kilograms
closingWeightClosing weight in kilograms
netWeightNet weight (calculated as ClosingWeight - StartingWeight) in kilograms
loggedByUser ID of the person who logged this entry
createdAtTimestamp when the record was created (UTC)
updatedAtTimestamp when the record was last updated (UTC)
activeSoft delete flag (true = active, false = deleted)
Get edit history for a scrap log entry
Retrieves the complete audit trail of all changes made to a specific scrap log entry, ordered by edit timestamp descending.
path Parameters
companyIdThe unique identifier of the company
scrapLogIdThe unique identifier of the scrap log entry
Get edit history for a scrap log entry › Responses
Edit history retrieved successfully
scrapLogEditHistoryIdUnique identifier for the edit history entry
scrapLogIdThe scrap log entry that was edited
editorUser ID of the editor
editorNameDisplay name of the editor
fieldChangedName of the field that was changed
oldValuePrevious value before the edit
newValueNew value after the edit
editedAtTimestamp when the edit occurred (UTC)
Restore deleted scrap log entries
Restores one or more soft-deleted scrap log entries for the specified company by setting Active = 1.
path Parameters
companyIdThe unique identifier of the company owning the entries
Restore deleted scrap log entries › Responses
Scrap log entries restored successfully
deletedItemsList of deleted scrap log entry IDs

