Commerce Value Types
These values keep B2B and commerce actions and entities consistent. Import them from @laioutr-core/canonical-types.
@laioutr-core/canonical-typesActivityEntry
A render-oriented entry in a quote or approval timeline. Every field is optional so connectors can emit only the history data their source provides.
| Field | Type | Description |
|---|---|---|
action | WellKnownActivityAction | Open action code such as created, commented, approved, price-changed, or ordered. |
actionLabel | string | Connector-resolved fallback label for an unknown action. |
actorName | string | Display name of the actor. |
actorType | WellKnownActorType | Open actor code such as customer, employee, sales-rep, or system. |
comment | string | Optional note attached to the activity. |
at | Date | When the activity occurred. |
AppliedFee
An already-computed fee shown on a quote or quote item. This differs from the Fee entity, which defines how a fee is calculated.
| Field | Type | Description |
|---|---|---|
code | string | Optional catalog fee code. |
kind | WellKnownFeeKind | Open fee kind such as recycling, deposit, environmental, or handling. |
name | string | Display name. |
amount | Money | Computed charge. |
quantity | number | Units used for a per-unit fee. |
taxRate | number | Tax rate as a decimal, for example 0.19. |
taxIncluded | boolean | Whether tax is included in the amount. |
CartBatchResultItem
The per-item result returned by batch cart operations such as reorder, quick order, and adding a product list to the cart. A result has status: 'added' with the quantity actually added, or status: 'rejected' with an open rejection reason such as not-found, sold-out, quantity-adjusted, or not-orderable. Per-item rejection is output data rather than a whole-action error.
CartSharePermission
An open permission code for shared carts. Well-known values are read-only and full-access; connectors may provide additional codes with a display label in the surrounding action payload.
DocumentType
An open commerce-document code. Well-known values are invoice, delivery-note, credit-note, and order-confirmation.
OrderStatus
An open, backend-independent order status. Well-known values are open, confirmed, shipped, completed, and cancelled. Connectors map vendor statuses to the nearest known code and may return additional codes with a resolved display label.