查询静态二维码
curl --request GET \
--url https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no} \
--header 'x-auth-token: <api-key>' \
--header 'x-client-id: <x-client-id>'import requests
url = "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}"
headers = {
"x-client-id": "<x-client-id>",
"x-auth-token": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-client-id': '<x-client-id>', 'x-auth-token': '<api-key>'}
};
fetch('https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-auth-token: <api-key>",
"x-client-id: <x-client-id>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-client-id", "<x-client-id>")
req.Header.Add("x-auth-token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}")
.header("x-client-id", "<x-client-id>")
.header("x-auth-token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-client-id"] = '<x-client-id>'
request["x-auth-token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"code_no": "D5610f5e1",
"status": "SUCCEEDED",
"payment_methods": [
"ALIPAY"
],
"currency": "SGD",
"amount_mode": "DYNAMIC",
"amount": null,
"store_name": "Docs Test",
"city": "Singapore",
"extension": "no payment test",
"create_time": "2026-10-28T10:18:45+08:00",
"updated_time": null
}{
"code": "<string>",
"message": "<string>",
"type": "static_qr_error"
}{
"code": "STATIC_QR_NOT_FOUND",
"message": "The requested static QR resource or endpoint was not found.",
"type": "static_qr_error"
}Static QR Codes
查询静态二维码
查询目标账户内的码。此响应不包含 qr_payload。
GET
/
v2
/
payment
/
static_qrs
/
{code_no}
查询静态二维码
curl --request GET \
--url https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no} \
--header 'x-auth-token: <api-key>' \
--header 'x-client-id: <x-client-id>'import requests
url = "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}"
headers = {
"x-client-id": "<x-client-id>",
"x-auth-token": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-client-id': '<x-client-id>', 'x-auth-token': '<api-key>'}
};
fetch('https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-auth-token: <api-key>",
"x-client-id: <x-client-id>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-client-id", "<x-client-id>")
req.Header.Add("x-auth-token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}")
.header("x-client-id", "<x-client-id>")
.header("x-auth-token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.uqpaytech.com/api/v2/payment/static_qrs/{code_no}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-client-id"] = '<x-client-id>'
request["x-auth-token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"code_no": "D5610f5e1",
"status": "SUCCEEDED",
"payment_methods": [
"ALIPAY"
],
"currency": "SGD",
"amount_mode": "DYNAMIC",
"amount": null,
"store_name": "Docs Test",
"city": "Singapore",
"extension": "no payment test",
"create_time": "2026-10-28T10:18:45+08:00",
"updated_time": null
}{
"code": "<string>",
"message": "<string>",
"type": "static_qr_error"
}{
"code": "STATIC_QR_NOT_FOUND",
"message": "The requested static QR resource or endpoint was not found.",
"type": "static_qr_error"
}授权
UQPAY 提供的登录 API Token。
请求头
UQPAY 生成的 API 客户端 ID
要操作的已授权关联子账户。省略或传空值时使用凭证账户。同一码的所有操作应使用相同目标账户。不要将凭证账户 ID 显式作为子账户传入。
路径参数
区分大小写的码牌号,须保留前导零。历史码牌号可能超过新建码的长度限制。
Required string length:
1 - 64Pattern:
^[A-Za-z0-9][A-Za-z0-9_-]{0,63}$响应
请求已处理,资源状态需单独判断。
码的创建状态,不是付款状态。INITIATED 表示已开始创建,SUCCEEDED 表示码已创建。
此码关联的支付方式。 付款通知的 data.payment_method.type 表示本次交易实际使用的单一支付方式,不回传此数组。
可用选项:
ALIPAY, WECHAT, PAYNOW, UNIONPAY 此码收款使用的币种。 付款通知的 data.currency 表示单笔交易的币种。
FIXED 使用指定金额;DYNAMIC 由付款人输入金额。
可用选项:
FIXED, DYNAMIC 以主货币单位表示的固定付款金额;DYNAMIC 模式下为 null。响应的小数位数可能与创建请求不同。 对账时读取付款通知中的单笔交易金额 data.amount,不要使用 DYNAMIC 静态码的 null 金额。
此码关联的门店名称。
此码关联的城市。
带时区偏移的创建时间。
最近更新时间;无更新时间时为 null。

