---
title: "Master Wallet Create Rule"
method: POST
path: "/v1/wallets/{walletId}/auto-settlements/rules"
tags: ["Auto Settlements"]
---

# Master Wallet Create Rule

`POST /v1/wallets/{walletId}/auto-settlements/rules`

This endpoint allows you to create a new auto-settlement rule for a specific wallet. By providing the necessary parameters in the request body, you can define the conditions and actions for the auto-settlement process.

## Request Body Parameters

| Parameter           | Type                | Required | Description |
|---------------------|---------------------|----------|-----------------------------------------------------------------------------|
| type                | string              | No       | The settlement rule type: `withdraw`, `swap`, `gateway`, or `earn`. Recommended on every create; rules saved without it keep the legacy inferred behavior. `withdraw` settles each deposited source asset as-is to `destination.address` on the source blockchain (address required). |
| name                | string              | Yes      | The name of the auto-settlement rule. A descriptive title reflecting its purpose. |
| order               | string              | Yes      | The order in which this rule should be processed. Possible values: `FASTEST`, `CHEAPEST`, `RECOMMENDED`, `NO_SLIPPAGE`. |
| slippageTolerance   | string              | Yes      | The acceptable slippage tolerance (as a percentage). Example: `"5"` = 5% tolerance. |
| isGateway           | boolean             | Yes      | Indicates whether the rule involves a gateway. `true` if processed through a gateway. |
| source              | object              | Yes      | Details about the source of the settlement.                                 |
| ├─ assets           | array of strings    | Yes      | List of asset types involved (e.g., `["USDC"]`).                            |
| ├─ minAmount        | string              | Yes      | The minimum amount required for settlement (e.g., `"1"`).                   |
| ├─ maxAmount        | string              | Yes      | The maximum amount that can be settled (e.g., `"1000"`).                    |
| destination         | object              | Yes      | Details about the destination of the settlement.                            |
| ├─ blockchain       | string              | No       | The blockchain network for the destination.                                 |
| ├─ asset            | string              | No       | The asset type to which the settlement is directed.                         |
| ├─ address          | string              | No       | The address where the settlement will be sent.                              |

## Request body

- object
  - `type` 'withdraw' | 'swap' | 'gateway' | 'earn' — Settlement rule type. Recommended on every create; rules saved without it keep the legacy inferred behavior.
  - `destination` object
  - `isActive` boolean
  - `isGateway` boolean
  - `name` string
  - `order` string
  - `slippageTolerance` string
  - `source` object
    - `assets` string[]
    - `maxAmount` string
    - `minAmount` string

## Response `200`

Regular 200 / Gateway 200

- object
  - `data` object
    - `destination` object
      - `address` string
      - `asset` string
      - `blockchain` string
    - `id` string
    - `isActive` boolean
    - `isGateway` boolean
    - `name` string
    - `order` string
    - `slippageTolerance` string
    - `source` object
      - `assets` string[]
      - `blockchain` string
      - `maxAmount` string
      - `minAmount` string
  - `message` string
  - `statusCode` number

---

[API](https://skmtc.net/blockradar/apis/blockradar-documentation.md) · [All operations](https://skmtc.net/blockradar/apis/blockradar-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/blockradar/blockradar-documentation/versions/97f95b4cfc0d/schema)
