Log a batch
log_batchUse this when the user has made a batch of a formula and wants it recorded: total weight, date, label and notes, optionally at a weaker strength, and optionally deducting what it used from stock. Works from the working copy or a version.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | No | ||
| notes | No | ||
| madeAt | No | ISO date, default today. | |
| formula | Yes | The formula: its id (from list_formulas) or its exact name. | |
| version | No | ||
| totalGrams | Yes | ||
| deductStock | No | ||
| concentrationPct | No |