> ## 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.

# 交易

> 说明 Yuno 支付中的主要交易类型和次要交易类型及其状态。

## 什么是交易？

每笔支付都关联一笔或多笔交易。Yuno 上的一笔支付可以通过回退、重试或拆分路由经过多个处理方。每条路径都可能为该支付添加多笔交易。您可以在 Yuno Dashboard 的[支付时间线](https://docs.y.uno/zh-hans/docs/using-yuno/dashboard-overview/payments.md)中查看与某笔支付相关的所有交易。

在 Yuno 上，交易分为**主要**交易和**次要**交易。此外，每笔交易可能因所处的处理阶段不同而具有不同的状态。

## 交易类型和状态

### 主要交易

主要交易用于发起支付，可以是以下三种类型之一：

* **Purchase**：标准的销售交易。
* **Authorize**：用于授权一笔支付金额，以便稍后捕获的交易。
* **Verify**：用于验证客户使用的支付方式是否有效的交易。

### 次要交易

次要交易是指影响支付和主要交易最终结果的附加交易。次要交易可以是：

* **Refund**：针对初始交易的退款，可以是全额退款或部分退款。
* **Cancel**：取消初始授权。
* **Capture**：从初始授权交易中捕获资金，可以是全额捕获或部分捕获。
* **Chargeback**：客户针对初始交易发起的争议。
* **3DS**：对初始交易进行的 3D Secure（3DS）验证。
* **Fraud screening**：对初始交易进行的欺诈筛查验证。这类交易在您的支付响应中表示为 `FRAUD_SCREENING`。
* **Marketplace transfers**：Marketplace 内的独立转账，正向转账表示为 `SPLIT_TRANSFER`，独立冲正表示为 `SPLIT_TRANSFER_REVERSE`。与支付交易关联的转账也可以冲正，表示为 `SPLIT_TRANSFER_REVERSAL`。

下面列出了每种交易类型的所有可能状态。

![每种交易类型所有可能状态的示意图](https://mintcdn.com/yuno-3979e326/OXm4Cjavq6YgX3ks/images/reference/transactions/image1.png?fit=max\&auto=format\&n=OXm4Cjavq6YgX3ks\&q=85\&s=d6871f086461dfd5c420dc58a25d7894)

有关交易状态码和消息的更多详细信息，请参阅 [Transactions API 参考](https://docs.y.uno/reference/payments/status-and-response-codes/transaction.md)。

您可以在 Yuno Dashboard 的 [Payments](https://docs.y.uno/zh-hans/docs/using-yuno/dashboard-overview/payments.md) 部分查看您的支付和交易，还可以从中导出这些信息。


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