> ## Documentation Index
> Fetch the complete documentation index at: https://docs.swipelux.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 收款方与目的地

> 创建第三方收款方,以及用于接收出金的银行或钱包端点。

当端点属于客户本人时,请使用客户账户。当另一个人或企业接收资金时,请使用收款方和目的地。

收款方记录谁接收资金,目的地记录他们在哪里接收资金。

## 1. 创建收款方

使用 [`POST /v3/customers/{customerId}/recipients`](/api-reference/recipients/post-v3-customers-by-customer-id-recipients) 创建个人或企业。请使用以下请求头:

```http theme={null}
X-API-Key: ${SWIPELUX_API_KEY}
Idempotency-Key: recipient-create-001
Content-Type: application/json
```

```json theme={null}
{
  "type": "individual",
  "relationship": "contractor",
  "firstName": "Jason",
  "lastName": "Swipelux",
  "email": "jason@swipelux.com",
  "phone": "+14155551234",
  "address": {
    "streetLine1": "1 Market Street",
    "city": "San Francisco",
    "state": "CA",
    "postalCode": "94105",
    "country": "US"
  },
  "label": "Jason contractor"
}
```

在创建法币目的地之前,请包含地址。将返回的收款方 `data.id` 保存为 `RECIPIENT_ID` 并保留其当前状态。

## 2. 添加目的地

使用 [`POST /v3/customers/{customerId}/recipients/{recipientId}/destinations`](/api-reference/recipients/post-v3-customers-by-customer-id-recipients-by-recipient-id-destinations) 创建端点。请为该目的地使用一个新的幂等键:

```http theme={null}
X-API-Key: ${SWIPELUX_API_KEY}
Idempotency-Key: recipient-destination-create-001
Content-Type: application/json
```

<Tabs>
  <Tab title="银行目的地">
    ```json theme={null}
    {
      "type": "ach",
      "currency": "USD",
      "details": {
        "routingNumber": "021000021",
        "accountNumber": "123456789",
        "accountType": "checking",
        "bankName": "Example Bank",
        "accountHolderName": "Jason Swipelux",
        "country": "US"
      }
    }
    ```
  </Tab>

  <Tab title="钱包目的地">
    ```json theme={null}
    {
      "type": "wallet",
      "currency": "USDC",
      "ownership": {
        "type": "self_custodied"
      },
      "details": {
        "network": "base",
        "address": "0x1111111111111111111111111111111111111111"
      }
    }
    ```
  </Tab>
</Tabs>

仅当收款方自行掌控该钱包时才使用 `self_custodied`。若钱包由其他托管方持有,请按照当前 API 参考中的对应变体填写。

将返回的目的地 `data.id` 保存为 `DESTINATION_ID` 并保留其当前状态。

## 3. 等待目的地就绪

在创建报价之前,请读取 [`GET /v3/customers/{customerId}/recipients/{recipientId}/destinations/{destinationId}`](/api-reference/recipients/get-v3-customers-by-customer-id-recipients-by-recipient-id-destinations-by-destination-id)。

仅当目的地当前的状态允许出金,并且其币种、方式和网络与预期的资金流转匹配时才继续。收款方和目的地的状态互相独立。

在出金报价中使用 `dst_` 开头的目的地 ID。`rcp_` 开头的收款方 ID 用于标识所属人员/企业记录,并不是报价目的地。

接下来,请携带已就绪的目的地前往[发送资金](/cn/integration/send-funds)。


## Related topics

- [发送资金](/cn/integration/send-funds.md)
- [账户与钱包](/cn/integration/accounts.md)
- [支付方式](/cn/knowledge-base/compliance/payment-methods.md)
- [Travel Rule 合规](/cn/knowledge-base/compliance/travel-rule.md)
- [上线](/cn/integration/go-live.md)
