Consent Limits
Define how much, how often, and for how long payments can be initiated under a consent.
Overview
The control_parameters object defines the boundaries within which payments can be initiated for an Account-on-file consent.
These limits allow you to restrict individual payment amounts, cumulative payment amounts, and the number of payments that can be made - both within a defined period and across the entire lifetime of the consent.
Control parameters are evaluated every time a payment is initiated. If any applicable limit would be exceeded, the payment is rejected.
| Parameter | Description | Requirement |
|---|---|---|
| period_type | The time unit used for periodical limits. Values are Day, Week, Month and Year | Required |
| max_individual_amount | Maximum amount allowed for any single payment. | At least One Of is required |
| max_cumulative_amount_per_period | Maximum total amount that can be processed within each defined period (e.g., per day). | |
| max_cumulative_number_of_payments_per_period | Maximum number of payments that can be initiated within each defined period. | |
| max_cumulative_number_of_payments | Maximum total number of payments allowed over the consent’s lifetime. | Optional |
| max_cumulative_amount | Total amount allowed for all payments over the consent’s lifetime (regardless of period). |
How limits are applied
When a payment is initiated, Lean evaluates it against the following categories of limits:
- Individual payment limits: applied to each payment independently.
- Periodic limits: applied within a defined time period (for example, per day).
- Lifetime limits: applied across the entire duration of the consent.
All applicable limits must be satisfied for the payment to succeed.
Period-based limits and reset behaviour
The period_type parameter defines the time window used for evaluating periodic limits.
It determines when periodic counters reset. Lifetime limits are not affected by period_type.
Supported period types
| Period type | Description | Reset behaviour |
|---|---|---|
Day | A single calendar day | Resets at the start of each day |
Week | Seven consecutive days | Resets every 7 days |
Month | A calendar month | Resets on the first day of each month |
Year | A calendar year | Resets on January 1st |
Only parameters that include
_per_periodare affected by the configuredperiod_type.
Required and optional limits
At least one of the following limits must be provided when creating a consent:
max_individual_amountmax_cumulative_amountmax_cumulative_number_of_payments
All other limit parameters are optional and can be combined to create more restrictive control models.
Choosing the right limits
Use individual limits to prevent large, unexpected payments
- Use periodic limits to control spending velocity
- Use lifetime limits to cap total exposure
- Combine limits to create layered controls
Limit individual payment size
Use this when each payment must stay below a fixed amount, but frequency is flexible.
"control_parameters": {
"period_type": "Day",
"max_individual_amount": 500
}Limit daily spending
Use this when you want to control how much can be paid within each day.
"control_parameters": {
"period_type": "Day",
"max_cumulative_amount": 10000,
"max_cumulative_amount_per_period": 3000
}Limit payment frequency
Use this when the number of payments matters more than their value.
"control_parameters": {
"period_type": "Week",
"max_cumulative_number_of_payments": 100,
"max_cumulative_number_of_payments_per_period": 5
}Enforce lifetime caps
Use this when payments must stop after a total amount or count is reached.
"control_parameters": {
"period_type": "Month",
"max_cumulative_amount": 10000,
"max_cumulative_number_of_payments": 12
}Combine daily limits with a lifetime cap
Use this to control both short-term usage and long-term exposure.
"control_parameters": {
"period_type": "Day",
"max_individual_amount": 500,
"max_cumulative_amount_per_period": 2000,
"max_cumulative_amount": 10000
}Updated 3 days ago
