Skip to main content
POST
MCP scope: dac.write Use this endpoint to add a spending rule to your sub-account. A new rule starts as UnApproved and takes effect once the owner, or at least 2 admins, approve it in the dashboard. Check its status with List Spending Rules.

Body Parameters

string
required
A name for the rule.
number
required
The maximum amount the rule allows in the time period.
string
required
Who the rule applies to. See initiated_by values.
string
required
What happens to a matching transaction. See sr_action values.
integer
How many approvals a matching transaction needs. Use with sr_action: NeedsApproval.
string
required
Where funds are going. See destination_type values.
string
required
For External destinations, the kind of address. See destination_id values.
string
Depends on destination_id:
  • WhitelistedAddress: the ID of the whitelist the rule applies to. The rule then covers every active address on that whitelist.
  • AdhocAddress: a specific address outside Finrock, not one of your Finrock wallets, for example your cold wallet.
For SubAccount destinations, the ID of the sub-account the rule allows transfers to.
string
required
The period the amount applies to. See rule_type values.
integer
The length of the period, in units of rule_type. For example, Hourly with 24 means any 24-hour window.

Response

integer
1000 when the rule was created.
string | null
null on success.
string | null
Additional information, if any. null on success.