Skip to content

Deal commands: update, delete

The Deal Verbs update, delete as CLI commands, with inputs, result, refusals and an example.

Reference for Deal, one group of Deal commands.

Deal.update

Changes the given properties of a Deal. Verb page.

Text
npx startup-builder do Deal.update --json '<input>' [--try | --send | --do]

Emits Deal.updated.

Inputs

InputTypeRequiredDescription
idstringrequiredThe id of the Deal.
valuemoneyWhat the Deal is worth if won.
ownerWorkerThe Worker who runs it.
closesOndateThe date the buyer expects to decide.
nextSteptextThe next dated step agreed with the buyer.

Returns

OutputTypeRequiredDescription
dealDealrequiredThe Deal.

Refuses when

CheckErrorFixThen call
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.

Example

Terminal
npx startup-builder do Deal.update --json '{"id":"deal_NgACZ6DcII","value":{"amount":29,"currency":"USD"}}'

Deal.delete

Deletes a Deal: a soft delete that keeps its history, undone by Thing.restore. Verb page.

Text
npx startup-builder do Deal.delete --json '<input>' [--try | --send | --do]

Emits Deal.deleted.

Inputs

InputTypeRequiredDescription
idstringrequiredThe id of the Deal.

Returns

OutputTypeRequiredDescription
dealDealrequiredThe Deal.

Refuses when

CheckErrorFixThen call
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.

Example

Terminal
npx startup-builder do Deal.delete --json '{"id":"deal_NgACZ6DcII"}'