GET
/
api
/
banking
/
rules
[
  {
    "id": 1,
    "name": "Monthly Salary",
    "order": 1,
    "applyIfAccountId": 1,
    "applyIfTransactionType": "deposit",
    "conditionsType": "and",
    "conditions": [
      {
        "id": 1,
        "field": "description",
        "comparator": "contains",
        "value": "Salary"
      }
    ],
    "assignCategory": "InterestIncome",
    "assignAccountId": 1,
    "assignPayee": "Employer Inc.",
    "assignMemo": "Monthly Salary",
    "createdAt": "2024-03-20T10:00:00Z",
    "updatedAt": "2024-03-20T10:00:00Z"
  }
]

Headers

Authorization
string
required

Value must be 'Bearer <token>' where <token> is an API key prefixed with 'bc_' or a JWT token.

Example:

"Bearer bc_1234567890abcdef"

organization-id
string
required

Required if Authorization is a JWT token. The organization ID to operate within.

Response

200 - application/json

The bank rules have been successfully retrieved.

id
number
required

The unique identifier of the bank rule

Example:

1

name
string
required

The name of the bank rule

Example:

"Monthly Salary"

order
number
required

The order in which the rule should be applied

Example:

1

applyIfAccountId
number
required

The account ID to apply the rule if

Example:

1

applyIfTransactionType
enum<string>
required

The transaction type to apply the rule if

Available options:
deposit,
withdrawal
Example:

"deposit"

conditionsType
enum<string>
required

The conditions type to apply the rule if

Available options:
and,
or
Example:

"and"

conditions
object[]
required

The conditions to apply the rule if

Example:
[
{
"id": 1,
"field": "description",
"comparator": "contains",
"value": "Salary"
}
]
assignCategory
enum<string>
required

The category to assign the rule if

Available options:
InterestIncome,
OtherIncome,
Deposit,
Expense,
OwnerDrawings
Example:

"InterestIncome"

assignAccountId
number
required

The account ID to assign the rule if

Example:

1

createdAt
string
required

The creation timestamp of the bank rule

Example:

"2024-03-20T10:00:00Z"

updatedAt
string
required

The last update timestamp of the bank rule

Example:

"2024-03-20T10:00:00Z"

assignPayee
string

The payee to assign the rule if

Example:

"Employer Inc."

assignMemo
string

The memo to assign the rule if

Example:

"Monthly Salary"