Delete supplier
delete_supplierDelete one supplier or many to the bin (soft-delete, restorable). Send id for one supplier, which returns {error}. Or send ids (up to 1000) to delete many in one transaction, which returns {error, deleted: [id ...], errors: [{id, message} ...]}. That is partial success: ids this business does not own, already deleted, or still linked to bills/expenses are skipped and listed in errors, and error is true only when nothing was deleted. By default a supplier with linked (non-deleted) bills/expenses is refused so those expenses aren't orphaned. Pass force:true to override, or archive via save_supplier.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | One supplier id to delete. | |
| ids | No | Up to 1000 supplier ids to delete in one transaction. Partial success: ids this business does not own, already deleted, or still linked (unless force) are skipped and listed in errors. | |
| force | No | Delete even when the supplier still has linked (non-deleted) bills/expenses. Default false: the delete is refused when links exist, so linked expenses aren't orphaned (PROD-663). |