Create a transaction rule
Creates a transaction rule. When your user makes a transaction with their Adyen-issued card, the transaction is allowed or declined based on the conditions and outcome defined in the transaction rule. You can apply the transaction rule to several cards, such as all the cards in your platform, or to a specific card. For use cases, see examples.
The maximum amount that a payment instrument can be used for in the period specified in the interval.type
.
The unique identifier of the balance platform to which the rule applies.
List of countries to which the rule applies. For example: ["NL","US"].
Your description for the transaction rule, maximum 300 characters.
The date when the rule will stop being evaluated, in ISO 8601 extended offset date-time format. For example, 2020-12-18T10:15:30+01:00.
If not provided, the rule will be evaluated until the rule status is set to inactive.
List of point-of-sale entry modes to which the rule applies.
Possible values: manual, chip, magstripe, contactless, cof, token, server, barcode, ocr.
The maximum number of transactions that a payment instrument can be used for in the period specified in the interval.type
.
List of Merchant Category Codes (MCCs) to which the rule applies.
The unique identifier of the payment instrument group to which the rule applies.
The unique identifier of the payment instrument to which the rule applies.
List of processing types to which the rule applies.
Possible values: atmWithdraw, pos, ecommerce, moto, recurring, balanceInquiry.
Your reference for the transaction rule, maximum 150 characters.
The date when the rule will start to be evaluated, in ISO 8601 extended offset date-time format. For example, 2020-12-18T10:15:30+01:00.
If not provided when creating a transaction rule, the startDate
is set to the date when the rule status is set to active.
The status of the transaction rule. If you provide a startDate
in the request, the rule is automatically created
with an active status.
Possible values: active, inactive.
Type of conditions provided in the rule.
Possible values:
- allowList: The rule provides categories (such as country and MCC) where payments must be allowed.
- blockList: The rule provides categories (such as country and MCC) where payments must be blocked.
- maxUsage: The rule sets limits for the maximum amount or maximum number of transactions for the lifetime of the payment instrument.
- velocity: The rule sets limits for the maximum amount or maximum number of transactions for a given time interval.
After submitting a call, you receive a response message to inform you that your request was received and processed.
Depending on the HTTP status code of the response message, it is helpful to build some logic to handle any errors that a request or the system may return.
HTTP Responses
200 - OK
The request has succeeded.
400 - Bad Request
A problem reading or understanding the request.
401 - Unauthorized
Authentication required.
403 - Forbidden
Insufficient permissions to process the request.
422 - Unprocessable Entity
A request validation error.
500 - Internal Server Error
The server could not process the request.