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

> ## Agent Instructions
> Test in the sandbox first: base URL https://api-sandbox.y.uno (Test Mode in the Dashboard). Production is https://api.y.uno (Live Mode).
> Every API request needs the public-api-key and private-secret-key headers. Get them in the Dashboard at https://dashboard.y.uno/developers (Developers > Credentials); sandbox and production keys are different.
> Send an X-Idempotency-Key (a UUID) when creating payments, refunds and cancels, so retries do not create duplicates.
> Start with the Quickstart (https://docs.y.uno/docs/quickstart.md) and the agent guide (https://docs.y.uno/agents.md). To search these docs from a coding agent, connect the docs MCP server at https://docs.y.uno/mcp.

# 更新 Onboarding

> 更新现有收款方 onboarding 的数据或文件

更新收款方的现有 onboarding。仅更新指定的字段。

此 endpoint 更新收款方的现有 onboarding，让您在初次创建后修改 onboarding 详情。当您需要为 [拆分支付 marketplace](https://docs.y.uno/zh-hans/docs/payment-features/split-payments-marketplace.md#/) 中的现有收款方更新服务提供商信息、文件、银行详情或其他 onboarding 参数时，请使用此 endpoint。

## 前提条件

此 endpoint 需要一个通过 [创建 Onboarding](https://docs.y.uno/zh-hans/reference/recipients-for-marketplace/create-onboarding.md) 创建的现有 onboarding

## 之前已完成 onboarding 的账户

如需重新注册现有的 `PREVIOUSLY_ONBOARDED` onboarding（例如因账户 id 错误而以 `ERROR` 结束之后），请使用 `provider` 对象调用 `PATCH /v1/recipients/{recipient_id}/onboardings/{onboarding_id}`：`provider.id`、`provider.connection_id` 和账户 id。

```json theme={"theme":{"light":"github-dark","dark":"github-dark-dimmed"}}
{
  "provider": {
    "id": "PROVIDER_ID",
    "connection_id": "8fee3cc6-f3cb-455d-b139-973866111a03",
    "recipient_id": "ACCOUNT_ID_AT_PROVIDER",
    "balance_account_id": "BALANCE_ACCOUNT_ID_AT_PROVIDER"
  }
}
```

账户 id 与创建时相同：`provider.recipient_id`、`provider.recipient_additional_id`、`provider.balance_account_id`、`provider.legal_entity` 和 `provider.recipient_type`。服务提供商需要其中哪些 id 由其集成决定。这些 id 按原样转发。

* **集成支持采用现有账户**：Yuno 向服务提供商重新注册，并应用其响应。Onboarding 变为 `SUCCEEDED`（webhook `onboarding.succeeded`），或变为 `ERROR`，服务提供商的消息位于 `response_message` 中（webhook `onboarding.error`）。服务提供商接受更正后的 id 后，处于 `ERROR` 的 onboarding 会变为 `SUCCEEDED`。
* **其他任何服务提供商**：存储这些 id，且不会调用服务提供商。这些 id 不会在服务提供商处验证。

不带服务提供商 id 的更新只会重新发送当前状态的通知，不会再次注册账户。

哪些服务提供商支持采用现有账户由 Yuno 端按环境配置，而不是 API 字段。如需了解您的服务提供商连接是否支持此功能，请联系您的大客户经理。

## 更新银行账户

对于带有服务提供商收款方 ID 的 Zoop 和 Pagar.me onboarding，显式的 `withdrawal_methods.bank` 更新会等待服务提供商的结果。它只更新所选的 onboarding；收款方默认账户和其他 onboarding 保持不变。

Onboarding 只保存已确认的账户。银行更新结果不会改变其生命周期状态。当 onboarding 没有显示银行账户时，请发送完整的账户。有关部分结果、`400` 响应和 `409` 对账指引，请参阅 [银行错误和重试](https://docs.y.uno/zh-hans/reference/recipients-for-marketplace/update-recipient-1.md#bank-errors-and-retries)。

对于这些受支持的服务提供商绑定 onboarding，除 `documentation` 以外的非银行字段会保存在 Yuno 中，不会单独更新服务提供商资料。发送描述或 metadata 不会重新发送已保存的银行账户。在混合请求中，先处理银行账户；只有在其成功后才会保存其他字段。之前已完成 onboarding 的收款方在不含 `documentation` 的非银行更新中，保留现有的状态通知。

例如，仅更改店铺的描述时，其已确认的 payout 账户和 onboarding 状态保持不变。如需更改 payout 账户，请显式包含 `withdrawal_methods.bank`。

## 更新文件

对于带有服务提供商收款方 ID 的 Zoop onboarding，包含 `documentation` 的请求会将该请求中的文件发送给 Zoop 并等待结果。这包括之前已完成 onboarding 的收款方。只发送请求中的文件类别，不会重新发送银行账户。

* 如果 Zoop 接受这些文件，onboarding 会采用 Zoop 报告的状态和要求，并发送常规的 onboarding webhook。
* 如果 Zoop 驳回这些文件，或者无法确认交付或由此产生的状态，响应为 `400`，代码为 `PROVIDER_OPERATION_FAILED`。文件会保存在 Yuno 中，onboarding 保留之前的状态和要求。只需重新发送 `documentation`。
* 在同时更新银行账户的请求中，先处理银行更新。如果之后文件失败，`400` 也会报告银行结果。报告为 `APPLIED` 的银行更改保持已应用状态，因此只需重新发送 `documentation`。

处于 `CANCELLED`、`BLOCKED`、`INACTIVE` 或 `TRANSFERRED` 状态的 onboarding 会以 `400 INVALID_STATE` 拒绝更新，但之前已完成 onboarding 的收款方除外：其更新会将 `documentation` 保存在 Yuno 中，而不会发送给服务提供商。`TERMINATED` onboarding 始终返回 `400 INVALID_STATE`。


## OpenAPI

````yaml openapi/zh-hans/recipients-for-marketplace/update-onboarding.json PATCH /recipients/{recipient_id}/onboardings/{onboarding_id}
openapi: 3.1.0
info:
  title: Recipients API
  version: 1.0.0
  description: >-
    API for managing recipients in split payment scenarios. This feature enables
    merchants to split payments among multiple recipients, which is particularly
    beneficial for marketplace models where transactions need to be divided
    among different sellers or stakeholders.
servers:
  - url: https://api-sandbox.y.uno/v1
    description: Sandbox
  - url: https://api.y.uno/v1
    description: Production (US)
security:
  - sec0: []
    sec1: []
paths:
  /recipients/{recipient_id}/onboardings/{onboarding_id}:
    patch:
      summary: 更新 Onboarding
      description: >-
        对于绑定提供商的 Zoop 和 Pagar.me onboarding，显式的银行更新需等待提供商确认。结果未知时返回
        409；已确认的变更不会回滚。有关目标选择、部分结果和重试建议，请参见 endpoint 指南。
      operationId: update-onboarding
      parameters:
        - in: path
          name: recipient_id
          description: 要更新其 onboarding 的收款方的 ID
          schema:
            type: string
          required: true
          example: 9104911d-5df9-429e-8488-ad41abea1a4b
        - in: path
          name: onboarding_id
          description: 要更新的 onboarding 的 ID
          schema:
            type: string
          required: true
          example: 9104911d-5df9-429e-8488-ad41abea1a4b
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                account_id:
                  type: string
                  description: Yuno 中账户的唯一 id
                  example: 9104911d-5df9-429e-8488-ad41abea1a4b
                type:
                  type: string
                  enum:
                    - PREVIOUSLY_ONBOARDED
                    - ONE_STEP_ONBOARDING
                    - TWO_STEP_ONBOARDING
                  description: >-
                    onboarding 流程的类型。PREVIOUSLY_ONBOARDED
                    用于关联提供商处已存在的账户，ONE_STEP_ONBOARDING 用于一步完成账户创建和
                    KYC，TWO_STEP_ONBOARDING 用于先创建账户，之后再进行 KYC。


                    要重新注册 PREVIOUSLY_ONBOARDED 类型的 onboarding，请发送
                    `provider.id`、`provider.connection_id` 以及提供商账户
                    id。当提供商集成支持采用已有账户时，Yuno 会重复注册并应用返回结果：onboarding 会变为
                    `SUCCEEDED` 或 `ERROR`，提供商的消息会放在 `response_message`
                    中。对于其他任何提供商，这些 id 会被存储，不会调用提供商。不带提供商 id
                    的更新只会重新发送当前状态的通知。哪些提供商采用已有账户属于 Yuno 侧按环境进行的配置；请咨询您的客户经理（Key
                    Account Manager）。
                  example: PREVIOUSLY_ONBOARDED
                workflow:
                  type: string
                  enum:
                    - HOSTED_BY_PROVIDER
                    - HOSTED_BY_YUNO
                    - DIRECT
                  description: onboarding 的工作流程
                  example: HOSTED_BY_PROVIDER
                callback_url:
                  type: string
                  format: uri
                  description: 如有需要，在与提供商完成 onboarding 流程后，用于将您的客户重定向到的 URL。
                  example: https://www.google.com
                provider:
                  type: object
                  description: >-
                    onboarding 的提供商。对于 PREVIOUSLY_ONBOARDED，提供商账户 id
                    会按发送内容原样转发给提供商集成；提供商需要哪些 id 由提供商集成决定。要重新注册账户，请将 `id` 和
                    `connection_id` 与这些 id 一起发送。
                  properties:
                    id:
                      type: string
                      description: 提供商 ID
                      example: PAGARME
                    connection_id:
                      type: string
                      description: Yuno 中连接的 ID
                      example: 104911d-5df9-429e-8488-ad41abea1a4b
                    recipient_id:
                      type: string
                      description: 提供商侧收款方的唯一标识符。
                      example: AAAAA01
                    recipient_additional_id:
                      type: string
                      description: 提供商侧收款方的附加标识符，适用于使用多个 id 标识账户的提供商。是否需要由提供商集成决定。
                      example: AAAAA01-SUB
                    balance_account_id:
                      type: string
                      description: 收款方在提供商处的余额账户标识符。是否需要由提供商集成决定。
                      example: BA00000000000000000000001
                    legal_entity:
                      type: string
                      description: 收款方在提供商处的法人实体标识符。是否需要由提供商集成决定。
                      example: LE00000000000000000000001
                    recipient_type:
                      type: string
                      description: 服务提供商的收款方类型。
                      enum:
                        - MEAL
                        - FOOD
                        - MULTI_BENEFITS
                        - FLEET
                      example: MEAL
                documentation:
                  type: array
                  description: 指定文件对象。
                  items:
                    type: object
                    required:
                      - file_name
                      - content_type
                      - content_category
                      - content
                    properties:
                      file_name:
                        type: string
                        minLength: 3
                        maxLength: 255
                        description: 所发送文档的名称（MAX 255；MIN 3）。
                        example: PDF
                      content_type:
                        type: string
                        enum:
                          - application/pdf
                          - image/jpeg
                          - image/png
                        description: 商户发送的文档类型
                        example: application/pdf
                      content_category:
                        type: string
                        enum:
                          - ACCOUNT_REQUIREMENT
                          - BANK_STATEMENT
                          - BUSINESS_ICON
                          - BUSINESS_LOGO
                          - CANCEL_POLICY
                          - CUSTOMER_INTERACTION
                          - DRIVERS_LICENCE
                          - IDENTIFICATION_DOCUMENT
                          - IDENTIFICATION_DOCUMENT_BACK
                          - IDENTIFICATION_DOCUMENT_FRONT
                          - LEGAL_AGREEMENT
                          - OTHERS
                          - PASSPORT
                          - PAYMENT_DETAIL
                          - PROOF_OF_ADDRESS
                          - PROOF_OF_AUTHENTICITY
                          - PROOF_OF_DELIVERY
                          - PROOF_OF_DIRECTOR
                          - PROOF_OF_INDUSTRY
                          - PROOF_OF_NATIONAL_ID_NUMBER
                          - PROOF_OF_OWNERSHIP
                          - PROOF_OF_REGISTRATION
                          - PROOF_OF_RELATIONSHIP
                          - PROOF_OF_SERVICE
                          - PROOF_OF_SOURCE_OF_FUNDS
                          - PROOF_OF_SOURCE_OF_WEALTH
                          - PROOF_OF_TAX
                          - PROVIDER_IDENTITY_DOCUMENT
                          - RECEIPT
                          - REFUND_POLICY
                          - SELFIE
                          - SERVICE_AGREEMENT
                          - SIGNATURE
                          - TERMS_AND_CONDITIONS
                          - VAT_DOCUMENT
                        description: 商户发送的文档类别
                      content:
                        type: string
                        format: byte
                        description: 商户发送的文件内容，以 base64 编码。最大大小：1MB。
                        example: >-
                          JVBERi0xLjQKJeLjz9MKMSAwIG9iago8PAovVHlwZSAvQ2F0YWxvZwovUGFnZXMgMiAwIFIKPj4KZW5kb2JqCg==
                withdrawal_methods:
                  type: object
                  description: 指定提款方式对象。
                  properties:
                    bank:
                      type: object
                      description: struct
                      properties:
                        code:
                          type: string
                          minLength: 3
                          maxLength: 3
                          description: 银行代码（最多 3，最少 3）
                          example: '246'
                        branch:
                          type: string
                          minLength: 3
                          maxLength: 3
                          description: 银行分行（最多 3，最少 3）
                          example: XXXX
                        branch_digit:
                          type: string
                          minLength: 3
                          maxLength: 3
                          description: 银行分行校验位（最多 3，最少 3）
                        account:
                          type: string
                          minLength: 3
                          maxLength: 250
                          description: 受益人的银行账号（最多 3，最少 250）
                          example: '1093333333'
                        account_digit:
                          type: string
                          minLength: 3
                          maxLength: 250
                          description: 受益人的银行账户校验位（最多 3，最少 250）
                        account_type:
                          type: string
                          enum:
                            - CHECKINGS
                            - SAVINGS
                            - VISTA
                            - PIX_EMAIL
                            - PIX_PHONE
                            - PIX_DOCUMENT_ID
                            - PIX_BANK_ACCOUNT
                          description: >-
                            受益人的银行账户类型（最多 1，最少
                            3）。可以是：CHECKINGS、SAVINGS、VISTA、PIX_EMAIL、PIX_PHONE、PIX_DOCUMENT_ID、PIX_BANK_ACCOUNT
                          example: SAVINGS
                        routing:
                          type: string
                          description: 受益人的银行账户路由号码
                          example: XXXXYYYYC
                        country:
                          type: string
                          minLength: 2
                          maxLength: 2
                          description: 银行账户所在国家（ISO 3166-1，最多 2，最少 2）
                          example: CO
                        currency:
                          type: string
                          minLength: 3
                          maxLength: 3
                          description: 银行账户的币种（ISO 3166-1，最多 3，最少 3）
                          example: COP
                legal_representatives:
                  type: array
                  description: 用于指明组织所有者的对象。Adyen、Stripe 和 dlocal 具有与此相关的字段。
                  items:
                    type: object
                    properties:
                      merchant_reference:
                        type: string
                        minLength: 3
                        maxLength: 255
                        description: 法定代表人的身份标识 id（最多 255，最少 3）。
                      first_name:
                        type: string
                        minLength: 1
                        maxLength: 255
                        description: 法定代表人的名字。（最多 255，最少 1）。
                        example: John
                      last_name:
                        type: string
                        minLength: 1
                        maxLength: 255
                        description: 法定代表人的姓氏。（最多 255，最少 1）。
                        example: Doe
                      email:
                        type: string
                        format: email
                        minLength: 1
                        maxLength: 255
                        description: 法定代表人的电子邮件（最多 255，最少 1）。
                        example: john.doe@email.com
                      date_of_birth:
                        type: string
                        format: date
                        minLength: 10
                        maxLength: 10
                        description: 法定代表人的出生日期，格式为 YYYY-MM-DD（最多 10，最少 10）。
                        example: '1990-02-28'
                      country:
                        type: string
                        minLength: 2
                        maxLength: 2
                        description: 法定代表人所在国家（ISO 3166-1，最多 2，最少 2）
                        example: CO
                      nationality:
                        type: string
                        minLength: 2
                        maxLength: 2
                        description: 法定代表人的国籍（最多 2，最少 2；ISO 3166-1）。
                        example: CO
                      title:
                        type: string
                        minLength: 1
                        maxLength: 255
                        description: 法定代表人的职务（最多 255，最少 1）。
                        example: CTO
                      publicly_exposed_person:
                        type: boolean
                        description: 指明法定代表人是否为政治公众人物
                        example: false
                      ultimate_beneficial_owner:
                        type: boolean
                        description: 指明法定代表人是否为公司的最终受益所有人
                        example: false
                terms_of_service:
                  type: object
                  description: 描述服务条款的对象。
                  required:
                    - acceptance
                    - date
                  properties:
                    acceptance:
                      type: boolean
                      description: 收款方是否已接受服务条款
                      example: true
                    date:
                      type: string
                      format: date-time
                      description: 接受服务条款的日期
                      example: '2022-07-09T20:43:54.786342Z'
                    ip:
                      type: string
                      format: ipv4
                      description: 接受服务条款时的 IP
                      example: 192.168.1.100
            examples:
              Update Onboarding:
                value:
                  account_id: '{{account_id}}'
                  provider:
                    id: YUNO_TEST_PAYMENT_GW
                    connection_id: '{{connection_id}}'
                    recipient_type: MULTI_BENEFITS
      responses:
        '200':
          description: 已更新
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RecipientResponse'
        '400':
          description: >-
            请求无效、所选 onboarding 被银行明确拒绝，或 onboarding
            状态不接受银行更新（INVALID_STATE）。在已确认的银行变更之后，如果后续的非银行步骤失败，也可能返回
            400（REQUEST_CANNOT_BE_PROCESSED）；请阅读结果消息。提供商拒绝的文件，或无法确认送达的文件，会返回
            PROVIDER_OPERATION_FAILED；这些文件会被保存，onboarding 保持其状态。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Invalid Parameters:
                  value:
                    code: INVALID_PARAMETERS
                    messages:
                      - >-
                        Provider rejected or requires attention to field:
                        withdrawal_methods.bank.
                Documents not delivered:
                  value:
                    code: PROVIDER_OPERATION_FAILED
                    messages:
                      - >-
                        Documents saved, but not delivered to the provider.
                        Resend only documentation.
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Unauthorized:
                  value:
                    code: INVALID_CREDENTIALS
                    messages:
                      - Invalid credentials
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Forbidden:
                  value:
                    code: AUTHORIZATION_REQUIRED
                    messages:
                      - The merchant has no authorization to use this API.
        '409':
          description: 银行结果未确认，或有 onboarding 操作阻止了此请求。请检查 code 和 messages；已确认的提供商变更可能已经发生。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Unconfirmed bank update:
                  value:
                    code: PROVIDER_TIMEOUT_AMBIGUOUS
                    messages:
                      - >-
                        Provider ZOOP, onboarding
                        3f6c1a2e-8b4d-4c7e-9a1f-5d2e7b9c0a14: UNKNOWN.
                      - >-
                        The provider did not confirm this bank update. Inspect
                        the provider account before retrying; untrusted provider
                        diagnostics were omitted.
                      - >-
                        Unconfirmed outcomes require provider reconciliation
                        before a different bank is submitted. Resend the same
                        intended account after the approximately three-minute
                        cooldown.
                Operation in progress:
                  value:
                    code: ONBOARDING_OPERATION_IN_PROGRESS
                    messages:
                      - >-
                        A bank or onboarding operation is in progress. After an
                        unconfirmed result, reconcile the provider account
                        before resending the same intended account after about
                        three minutes.
components:
  schemas:
    RecipientResponse:
      type: object
      properties:
        id:
          type: string
          description: 收款方的唯一标识符。
          example: 3aaa4d82-11e8-48ce-8ef5-04eee3a10802
        account_id:
          type: string
          description: 与此收款方关联的账户标识符。
          example: fe14c7c6-c75e-43b7-bdbe-4c87ad52c482
        merchant_recipient_id:
          type: string
          description: 由商户定义的收款方唯一标识符。
          example: MERCHANT_182acf1d-faeb-4ff0-94cd-7fab11b282f6
        national_entity:
          type: string
          description: 受益人的国家实体类型。
          example: INDIVIDUAL
        entity_type:
          type: string
          description: 受益人的组织类型。
          example: PRIVATE
        first_name:
          type: string
          description: 受益人的名字。
          example: Juan
        last_name:
          type: string
          description: 受益人的姓氏。
          example: Perez
        legal_name:
          type:
            - string
            - 'null'
          description: 受益人的法定名称。
          example: null
        email:
          type: string
          description: 受益人的电子邮件。
          example: juan.perez@example.com
        date_of_birth:
          type: string
          description: 受益人的出生日期。
          example: '1990-01-15'
        country:
          type: string
          description: 受益人所在国家。
          example: CO
        website:
          type: string
          description: 卖家的网站 URL。
          example: https://juanperez.com
        industry:
          type: string
          description: 卖家所属行业。
          example: Technology
        merchant_category_code:
          type: string
          description: 商户类别代码（MCC）（最多 235，最少 1）。
          example: '5734'
        document:
          type: object
          properties:
            document_number:
              type: string
              example: '1234567890'
            document_type:
              type: string
              example: CC
        phone:
          type: object
          properties:
            country_code:
              type: string
              example: '57'
            number:
              type: string
              example: '3001234567'
        address:
          type: object
          properties:
            address_line_1:
              type: string
              example: 'Carrera 7 # 32-16'
            address_line_2:
              type:
                - string
                - 'null'
              example: Oficina 201
            city:
              type: string
              example: Bogota
            country:
              type: string
              example: CO
            state:
              type: string
              example: Cundinamarca
            zip_code:
              type: string
              example: '110311'
            neighborhood:
              type: string
              example: Centro
        legal_representatives:
          type: array
          items:
            type: object
            properties:
              merchant_reference:
                type: string
                example: REP_001
              first_name:
                type: string
                example: Maria
              last_name:
                type: string
                example: Gonzalez
              email:
                type: string
                example: maria.gonzalez@example.com
              date_of_birth:
                type: string
                example: '1985-05-20'
              country:
                type: string
                example: CO
              nationality:
                type: string
                example: CO
              title:
                type: string
                example: CEO
              publicly_exposed_person:
                type: boolean
                example: false
              ultimate_beneficial_owner:
                type: boolean
                example: true
              document:
                type: object
                properties:
                  document_type:
                    type: string
                    example: CC
                  document_number:
                    type: string
                    example: '0987654321'
              phone:
                type: object
                properties:
                  country_code:
                    type: string
                    example: '57'
                  number:
                    type: string
                    example: '3109876543'
              address:
                type: object
                properties:
                  address_line_1:
                    type: string
                    example: 'Calle 26 # 13-19'
                  address_line_2:
                    type:
                      - string
                      - 'null'
                    example: null
                  country:
                    type: string
                    example: CO
                  state:
                    type: string
                    example: Cundinamarca
                  city:
                    type: string
                    example: Bogota
                  zip_code:
                    type: string
                    example: '110311'
        withdrawal_methods:
          type: object
          properties:
            bank:
              type: object
              properties:
                code:
                  type: string
                  example: '001'
                branch:
                  type: string
                  example: '004'
                branch_digit:
                  type:
                    - string
                    - 'null'
                  example: '123'
                account:
                  type: string
                  example: '1234567890'
                account_digit:
                  type:
                    - string
                    - 'null'
                  example: '123'
                account_type:
                  type: string
                  example: SAVINGS
                routing:
                  type: string
                  example: '021000021'
                country:
                  type: string
                  example: CO
                currency:
                  type: string
                  example: COP
        documentation:
          type: array
          items:
            type: object
            properties:
              file_name:
                type: string
                example: cc-front.pdf
              content_type:
                type: string
                example: application/pdf
              content_category:
                type: string
                example: IDENTIFICATION
              content:
                type: string
                example: JVBERi0xLjQKJ...
        onboardings:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                example: 84c42684-dbe5-4e0f-bd17-4d094e19762d
              type:
                type: string
                example: ONBOARD_ONTO_THE_PROVIDER
              workflow:
                type: string
                example: DIRECT
              status:
                type: string
                example: PENDING
              callback_url:
                type: string
                example: https://merchant.example.com/webhook/onboarding
              provider:
                type: object
                properties:
                  id:
                    type: string
                    example: ALELO
                  connection_id:
                    type: string
                    example: cc389b51-53a1-4a29-af40-c8cee26c3399
                  recipient_id:
                    type:
                      - string
                      - 'null'
                    example: null
                  redirect_url:
                    type:
                      - string
                      - 'null'
                    example: null
                  onboarding_url:
                    type:
                      - string
                      - 'null'
                    example: null
                  legal_entity:
                    type:
                      - string
                      - 'null'
                    example: null
                  balance_account_id:
                    type:
                      - string
                      - 'null'
                    example: null
                  legal_entity_id:
                    type:
                      - string
                      - 'null'
                    example: null
              documentation:
                type: array
                items:
                  type: object
                  properties:
                    file_name:
                      type: string
                      example: utility-bill.pdf
                    content_type:
                      type: string
                      example: application/pdf
                    content_category:
                      type: string
                      example: ADDRESS_PROOF
                    content:
                      type: string
                      example: JVBERi0xLjQKJ...
              legal_representatives:
                type: array
                items:
                  type: object
                example: []
              requirements:
                type: array
                items:
                  type: object
                  properties:
                    field:
                      type: string
                      example: document.cc
                    message:
                      type: string
                      example: Provide CC document image
                    status:
                      type: string
                      example: PENDING
              withdrawal_methods:
                type: object
                properties:
                  bank:
                    type: object
                    properties:
                      code:
                        type: string
                        example: '002'
                      branch:
                        type: string
                        example: '002'
                      branch_digit:
                        type:
                          - string
                          - 'null'
                        example: null
                      account:
                        type: string
                        example: '9876543210'
                      account_digit:
                        type:
                          - string
                          - 'null'
                        example: null
                      account_type:
                        type: string
                        example: SAVINGS
                      routing:
                        type: string
                        example: '021000022'
                      country:
                        type: string
                        example: CO
                      currency:
                        type: string
                        example: COP
              terms_of_service:
                type: object
                properties:
                  acceptance:
                    type: boolean
                    example: true
                  date:
                    type: string
                    example: '2025-07-21T20:43:54Z'
                  ip:
                    type: string
                    example: 129.21.111.11
              created_at:
                type: string
                format: date-time
                example: '2025-08-27T15:41:19.516982Z'
              updated_at:
                type: string
                format: date-time
                example: '2025-08-27T15:41:19.516989Z'
        split_configuration:
          type: object
          description: 收款方层级的自动拆分计算规则。
          properties:
            calculation_type:
              type: string
              description: 用于计算拆分金额的方法。
              enum:
                - PERCENTAGE
                - FIXED
                - MIXED
              example: PERCENTAGE
            percentage:
              type: number
              description: >-
                要拆分的占支付总额的百分比（0.01-100.00）。当 calculation_type 为 PERCENTAGE 或
                MIXED 时必填。
              minimum: 0.01
              maximum: 100
              example: 10.5
            fixed_amount:
              type: number
              description: 要拆分的固定金额。当 calculation_type 为 FIXED 或 MIXED 时必填。
              minimum: 0.0001
              example: 5
            currency:
              type: string
              description: ISO 4217 货币代码。所有计算类型均必填。
              example: USD
            rounding_mode:
              type: string
              description: 计算金额的舍入策略。PERCENTAGE 和 MIXED 必填。
              enum:
                - STANDARD
                - ROUND_UP
                - ROUND_DOWN
              example: STANDARD
        created_at:
          type: string
          format: date-time
          description: 收款方创建日期（ISO 8601，最多 27，最少 27）。
          example: '2025-08-27T15:41:19.497413Z'
        updated_at:
          type: string
          format: date-time
          description: 收款方最近更新日期（ISO 8601，最多 27，最少 27）。
          example: '2025-08-27T15:41:19.497425Z'
    ErrorResponse:
      type: object
      properties:
        code:
          type: string
          example: INVALID_PARAMETERS
        messages:
          type: array
          items:
            type: string
            example: Invalid request
  securitySchemes:
    sec0:
      type: apiKey
      in: header
      name: public-api-key
      x-default: <Your public-api-key>
    sec1:
      type: apiKey
      in: header
      name: private-secret-key
      x-default: <Your private-secret-key>

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.