---
title: "Set rules"
method: POST
path: "/rules/set/direction"
tags: ["Rules"]
---

# Set rules

`POST /rules/set/direction`

Sets the transfer rules to be applied to transactions.

## Request body

- TransactionRuleCreateRequestWithDirection
  - `vaspDID` string, required — Decentralized Identifier
  - `ruleSet` object, required — Incoming and Outgoing set of rules
    - `incoming` Ruleset[] — Incoming set of rules
      - `order` number, required — Number that represents the order we should apply a rule per VASP
      - `actionRule` 'APPROVE' | 'REJECT' | 'NOT_READY' | 'SEND_TO_INBOX', required — Action of the rule
      - `ruleCheck` 'ALL' | 'VASP' | 'REVIEWED_VASP_LIST' | 'JURISDICTION' | 'CUSTOMER_JURISDICTION' | 'RISK_SCORE' | 'SANCTION_LIST_CHECK' | 'TRANSACTION_AMOUNT' | 'TRANSACTION_CREATION_TIME' | 'SELF_HOSTED_WALLET', required — Condition to meet to have the action rule set
      - `ruleValue` string, required — Value of the choosen rule - For VASP and JURISDICTION, it is possible to send multiple values, separated by comma
      - `source` string, nullable — In the case of rule value beeing riskScore or sanctionListCheck, this is the field to fill with service provider
    - `outgoing` Ruleset[] — Outgoing set of rules
      - `order` number, required — Number that represents the order we should apply a rule per VASP
      - `actionRule` 'APPROVE' | 'REJECT' | 'NOT_READY' | 'SEND_TO_INBOX', required — Action of the rule
      - `ruleCheck` 'ALL' | 'VASP' | 'REVIEWED_VASP_LIST' | 'JURISDICTION' | 'CUSTOMER_JURISDICTION' | 'RISK_SCORE' | 'SANCTION_LIST_CHECK' | 'TRANSACTION_AMOUNT' | 'TRANSACTION_CREATION_TIME' | 'SELF_HOSTED_WALLET', required — Condition to meet to have the action rule set
      - `ruleValue` string, required — Value of the choosen rule - For VASP and JURISDICTION, it is possible to send multiple values, separated by comma
      - `source` string, nullable — In the case of rule value beeing riskScore or sanctionListCheck, this is the field to fill with service provider

## Response `201`

Transfer Rule created

- object[]
  - `id` string, uuid — Identifier of the transfer Rule
  - `vaspDID` string — Decentralized Identifier
  - `order` number — Number that represents the order we should apply a rule per VASP
  - `actionRule` 'APPROVE' | 'REJECT' | 'NOT_READY' | 'SEND_TO_INBOX' — Action of the rule
  - `ruleCheck` 'ALL' | 'VASP' | 'REVIEWED_VASP_LIST' | 'JURISDICTION' | 'RISK_SCORE' | 'SANCTION_LIST_CHECK' | 'TRANSACTION_AMOUNT' | 'TRANSACTION_CREATION_TIME' — Condition to meet to have the action rule set
  - `ruleValue` string — Value of the choosen rule
  - `source` string — In the case of rule value beeing riskScore or sanctionListCheck, this is the field to fill with service provider
  - `vasps` VaspInfo[] — If ruleCheck is of type VASP, all of the vasps involved in the rule will be returned
    - `did` string, required — Decentralized Identifier
    - `name` string, required — Name of the VASP
  - `jurisdictions` string[] — If ruleCheck is of type JURISDICTION, the list of jurisdictions involved in the rule will be returned

## Other responses

- `400` — Bad Request
- `501` — Not implemented

---

[API](https://skmtc.net/notabene/apis/notabene-api.md) · [All operations](https://skmtc.net/notabene/apis/notabene-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/notabene/notabene-api/revisions/70056745a433/schema)
