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

# status

> 获取 VPOS 终端当前的运行状态。

`status` 方法用于获取 VPOS 支付终端当前的运行状态。此端点对于在发起交易之前监控硬件就绪状态,或检查长时间运行的用户交互的进度都至关重要。

使用此方法可以：

* 在发送支付命令之前,验证读卡器是否处于空闲且就绪状态。
* 确定终端当前是在等待卡片交互还是正在处理数据。
* 识别终端是否处于离线或“未就绪”状态,以跟踪硬件健康状况。

Nayax 设备上显示提示的示例:
displaySelect

## 请求

此端点的请求很简单,不需要 `data` 对象。您只需提供标准的 `command` 和唯一的 `requestId`。

```json theme={null}
{
"command": "status",
"requestId": "req-021"
}
```

### 参数定义

下表描述了此请求所需的常见字段:

| 姓名 | 类型 | 必需的 | 描述 |
| :- | :- | :- | :- |
| 命令 | string | 是的 | 设置为`"status"`。 |
| 请求 ID | string | 是的 | 用于跟踪响应的唯一标识符。 |

## 回应

VPOS 终端以整数值的形式返回读卡器的当前状态。

```json theme={null}
{
"requestId": "req-021",
"data": {
"reader": 1
}
}
```

### 读卡器数值

`reader` 整数值表示支付读卡器硬件的当前状态代码。
请使用下表映射其运行含义:

| 价值 | 状态 | 描述 |
| :- | :- | :- |
| 0 | 未就绪(不可用) | 终端处于离线、断开连接或正在初始化状态。 |
| 1 | Idle | 终端处于空闲状态,读卡器未检测到卡片。 |
| 2 | 等待刷卡 | 读卡器处于激活状态,并提示用户提供支付方式。 |
| 3 | 处理中 | 当前正在执行交易或命令。 |


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