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

# 公共接口 — 代付订单凭证

> 公共接口 — 代付订单凭证（POST /common/voucher）：获取代付订单的支付凭证图片（base64编码）；关键请求参数含 orderNo。

> [!NOTE]
>
> 本页所有示例请求均基于**沙盒（测试）环境**，请注意区分正式环境。

#### 密钥私钥(生成签名)

## 相关主题

* [公共接口](https://doc.haipay.net/zh/api-reference/overview.md#public-interfaces)
* [HaiPay API 文档简介](https://doc.haipay.net/zh/api-reference/overview.md)
* [HaiPay 配置与签名指南](https://doc.haipay.net/zh/get-started/configuration-and-signatures.md)
* [代付订单凭证](https://doc.haipay.net/zh/operations/voucher.md)
* [查阅接口响应结构与错误码](https://doc.haipay.net/zh/resources/error-responses.md)


## OpenAPI

````yaml docs/zh/api-reference/common/common.openapi.json POST /common/voucher
openapi: 3.1.0
info:
  title: 公共接口 API
  description: HaiPay 公共接口，包括账户查询、对帐文件下载、代付凭证、汇率查询、支付凭证PDF和商户支付配置查询。
  version: 1.0.0
servers:
  - url: https://uat-interface.haipay.asia
    description: 测试-interface
security: []
tags: []
paths:
  /common/voucher:
    post:
      tags: []
      summary: 代付订单凭证
      description: 获取代付订单的支付凭证图片（base64编码）。
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                appId:
                  type: integer
                  description: 业务ID（后台获取）
                  format: int64
                orderNo:
                  type: string
                  description: 平台订单号
                sign:
                  type: string
                  description: 签名
              required:
                - appId
                - orderNo
                - sign
            example:
              appId: 1054
              orderNo: P233323000059
              sign: >-
                af0gAHkUOyYHu9owQp8NJ4mPEeUW4vuJcjdxqLIzrVw8AvpLSjD1DXupReSG/CyuSkFRyiIvCp5u703AuGGmfgD2gKDH3Ywau41bAbG2jnHJ8mtjiSJ5iWUzanyd4Kr7d1+rETbzUl7/BkW3t0X8UUFdqpxwG8DPUjAwUKfplWDHV7koG51Ozexd80DCsmW6eWdouAZ1uNXGLYmV3ftE3BmfNRtuv1C5bfTJWrTEIOxbF6g2uYOFZTlIgrQgd7/2PsAYwQQXNz8Q8CYl4OxqCv4pXJxaLWPbR5tqZu9og5kn32C9aHW/NlU1y39vzz+4ef81yPAqUV9oHlSMSPrMmw==
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    description: 状态码
                  error:
                    type: string
                    description: 错误码
                  msg:
                    type: string
                    description: 消息
                  data:
                    type: string
                    description: 凭证图片的base64编码
              example:
                status: '1'
                error: '00000000'
                msg: success
                data: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJ...
          headers: {}
      deprecated: false
      security: []

````

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