Transactions are the core operational record in the GSM Operations service. Each transaction is identified by aDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/ti-infinite/GSMApplication/llms.txt
Use this file to discover all available pages before exploring further.
TrxPrefix that encodes the business context — for example, PRDLBR indicates a productivity-labor transaction. A transaction progresses through a defined lifecycle: it is initially CREATED, transitions to INPROGRESS when work begins, and is ultimately resolved as either COMPLETED or CANCELLED. State changes are recorded as entries in the TrxStates collection, providing a complete audit trail.
Each transaction can carry arbitrary key/value attributes (TrxAttributes), associated product lines (TrxProducts), and typed detail lines (TrxDetails), making the structure flexible enough to represent diverse operational workflows without schema changes.
Create Transaction
Create a new transaction header with its initial state, attributes, products, and detail lines.Endpoint
Authentication
Bearer token. Format:
Bearer <token>Request Body
Business-type prefix that classifies the transaction. This value determines processing rules and reporting groupings. Example values:
PRDLBR (productivity-labor), RCVHB (herb receipt), DSPHB (herb dispatch).Optional free-text description for the transaction.
Username of the operator creating the transaction. Used for audit trail purposes.
Optional physical location or site identifier where the transaction originates.
Arbitrary key/value metadata attached to the transaction. Can be used to store custom attributes without modifying the schema.
Product lines included in the transaction.
The initial state record for the transaction.
Typed detail lines that carry the transaction’s operational data.
HTTP Status Codes
| Code | Meaning |
|---|---|
200 OK | Transaction created. data contains confirmation (typically the new TrxDocument identifier). |
400 Bad Request | Required fields missing or validation failed. |
401 Unauthorized | Token missing or invalid. |
Example
Update Transaction
Apply a partial update to an existing transaction. Only the collections provided in the body are updated; omitted collections remain unchanged.Endpoint
Path Parameters
The numeric ID of the transaction header to update.
Request Body
Updated or additional key/value attribute lines.
Updated product lines.
New state entry to append to the transaction’s state history. Use this to advance the lifecycle (e.g. from
INPROGRESS to COMPLETED).Updated or appended detail lines.
HTTP Status Codes
| Code | Meaning |
|---|---|
200 OK | Transaction updated successfully. |
400 Bad Request | Validation failed (e.g. invalid state transition). |
401 Unauthorized | Token missing or invalid. |
404 Not Found | No transaction found with the given idTrxHeader. |
Example
Search Transactions
Search and retrieve transactions matching the specified filter criteria.Endpoint
Authentication
Bearer token. Format:
Bearer <token>Request Body
Filter by transaction type prefix (e.g.
"PRDLBR"). Returns only transactions of this type.Filter by current transaction status. Standard values:
CREATED, INPROGRESS, COMPLETED, CANCELLED.Filter by originating location.
Response
List of matching transaction records.
HTTP Status Codes
| Code | Meaning |
|---|---|
200 OK | Transactions returned (may be empty list). |
400 Bad Request | Invalid search criteria. |
401 Unauthorized | Token missing or invalid. |
Example
Transaction Lifecycle
Transactions follow a linear state machine. State transitions are appended to thetrxStates collection — the current status of the transaction is always the most recently recorded state.
| State | Description |
|---|---|
CREATED | Transaction has been recorded but work has not started. |
INPROGRESS | Work is actively under way. |
COMPLETED | Work finished successfully and the transaction is closed. |
CANCELLED | Transaction was abandoned before completion. |
TrxPrefix Convention
ThetrxPrefix value encodes the business type of the transaction. Prefixes are configured per tenant and drive processing rules, reporting, and integrations. Common examples:
| Prefix | Description |
|---|---|
PRDLBR | Productivity — labor-based harvest recording |
RCVHB | Receipt of herb inventory |
DSPHB | Dispatch of herb inventory |