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

# AFT 参数

> 创建 Payment Intent 进行账户充值交易（AFT）时需要传入的额外参数。

当业务场景涉及资金划转时，创建 Payment Intent 需要额外传入 AFT（Account Funding Transaction）相关参数。以下是这些参数的说明。

<h2 id="parameter-reference">参数说明</h2>

下列所有字段都属于 `recipient_sender_details` 对象。

| 对象            | 字段               | 类型     | 约束                                                                       | 说明                                                                                                                     |
| :------------ | :--------------- | :----- | :----------------------------------------------------------------------- | :--------------------------------------------------------------------------------------------------------------------- |
| **(root)**    | `fund_source`    | String | **必填。** 取值：`01`、`02`、`03`、`04`、`05`、`06`、`25`                            | **资金来源代码：**<br />`01`：信用卡<br />`02`：借记卡<br />`03`：预付卡<br />`04`：现金<br />`05`：借记 / 存款账户<br />`06`：信用账户<br />`25`：移动支付账户 |
| **recipient** | `first_name`     | String | **必填。** `^[a-zA-Z0-9 \-]{1,30}$`                                         | 收款人（主账户持有人）的名。                                                                                                         |
|               | `last_name`      | String | **必填。** `^[a-zA-Z0-9 \-]{1,30}$`                                         | 收款人的姓。                                                                                                                 |
|               | `birth`          | String | **必填。** 必须为 YYYYMMDD 格式的 8 位数字                                           | 收款人出生日期。                                                                                                               |
|               | `account_number` | String | **必填。** `^[a-zA-Z0-9*]{8}$`                                              | 收款人的 PAN 或账号。                                                                                                          |
|               | `postcode`       | String | **必填。** `^[a-zA-Z0-9 /\-]{1,10}$`                                        | 收款人邮编。                                                                                                                 |
|               | `street`         | String | **必填。** `^['"0-9A-Za-z]{1,30}$`                                          | 收款人详细地址。                                                                                                               |
|               | `city`           | String | **必填。** `^['"0-9A-Za-z]{1,25}$`                                          | 收款人所在城市。                                                                                                               |
|               | `state`          | String | **当 `country_code` 为 `CAN`/`USA`/`COL`/`NIC` 时必填。** `^[0-9A-Za-z]{2,3}$` | 收款人所在州 / 省代码。                                                                                                          |
|               | `country_code`   | String | **必填。** `^[A-Z]{3}$`。必须是有效的 ISO 国家代码                                     | 收款人国家代码（ISO 3166-1 alpha-2/3）。                                                                                         |
| **sender**    | `first_name`     | String | **必填。** 最大长度：30 个字符                                                      | 发送人（付款人）的名。                                                                                                            |
|               | `last_name`      | String | **必填。** 最大长度：6 个字符                                                       | 发送人的姓。                                                                                                                 |
|               | `birth`          | String | **必填。** 必须为 YYYYMMDD 格式的 8 位数字                                           | 发送人出生日期。                                                                                                               |
|               | `street`         | String | **必填。** 最大长度：30 个字符                                                      | 发送人详细地址。                                                                                                               |
|               | `city`           | String | **必填。** 最大长度：25 个字符                                                      | 发送人所在城市。                                                                                                               |
|               | `state`          | String | **当 `country_code` 为 `CAN`/`USA`/`COL`/`NIC` 时必填。** 长度：2\~3 个字符          | 发送人所在州 / 省代码。                                                                                                          |
|               | `country_code`   | String | **必填。** 最大长度：3 个字符。必须是有效的 ISO 国家代码                                       | 发送人国家代码（ISO 3166-1 alpha-2/3）。                                                                                         |

<h3 id="trimming-guidelines">截取规则</h3>

如果字段值超过设定的长度上限，可以进行截取。此规则主要适用于地址相关字段，如 street、state 和 city。

姓名字段通常不会超过上限，但在极少数情况下也可以截取。若对姓名字段进行了截取，请确保同一个人在所有记录中的截取结果保持一致。

<h2 id="json-example">JSON 示例</h2>

```json theme={null}
{
  "recipient_sender_details": {
    "fund_source": "01",
    "recipient": {
      "first_name": "John",
      "last_name": "Doe",
      "birth": "19900101",
      "account_number": "12345678",
      "postcode": "123456",
      "street": "123 Main Street",
      "city": "Singapore",
      "state": "01",
      "country_code": "SG"
    },
    "sender": {
      "first_name": "Jane",
      "last_name": "Smith",
      "birth": "19950505",
      "street": "456 Orchard Road",
      "city": "Singapore",
      "state": "03",
      "country_code": "SG"
    }
  }
}
```
