mark_sold
Mark an inventory item as sold (status=sold).
Convenience wrapper over `update_inventory_item` for the natural
"I sold the drill" request.
Authenticated. Required OAuth scope: `inventory:write`. Caller must
own the item.
Args:
item_id: ID of the inventory row.
api_key: Optional API key (`pk_*`, generate at /account).
Used when there is no OAuth token, and also when the OAuth
token lacks the required scope — an explicitly passed key
overrides an ambient token that is scoped too narrowly.
An invalid or revoked token still fails regardless.
Returns:
The updated inventory row, or ``{"error": ...}``.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| api_key | No | ||
| item_id | Yes |