查询费用配置规则详情
curl --request GET \
--url https://openplatform.gateapi.io/rate/commission_rule \
--header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
--header 'X-GatePay-MerchantId: <x-gatepay-merchantid>' \
--header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>'import requests
url = "https://openplatform.gateapi.io/rate/commission_rule"
headers = {
"X-GatePay-Certificate-ClientId": "<x-gatepay-certificate-clientid>",
"X-GatePay-Signature": "<x-gatepay-signature>",
"X-GatePay-Timestamp": "<x-gatepay-timestamp>",
"X-GatePay-Nonce": "<x-gatepay-nonce>",
"X-GatePay-MerchantId": "<x-gatepay-merchantid>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-GatePay-Certificate-ClientId': '<x-gatepay-certificate-clientid>',
'X-GatePay-Signature': '<x-gatepay-signature>',
'X-GatePay-Timestamp': '<x-gatepay-timestamp>',
'X-GatePay-Nonce': '<x-gatepay-nonce>',
'X-GatePay-MerchantId': '<x-gatepay-merchantid>'
}
};
fetch('https://openplatform.gateapi.io/rate/commission_rule', 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://openplatform.gateapi.io/rate/commission_rule",
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-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>",
"X-GatePay-MerchantId: <x-gatepay-merchantid>",
"X-GatePay-Nonce: <x-gatepay-nonce>",
"X-GatePay-Signature: <x-gatepay-signature>",
"X-GatePay-Timestamp: <x-gatepay-timestamp>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://openplatform.gateapi.io/rate/commission_rule")
.header("X-GatePay-Certificate-ClientId", "<x-gatepay-certificate-clientid>")
.header("X-GatePay-Signature", "<x-gatepay-signature>")
.header("X-GatePay-Timestamp", "<x-gatepay-timestamp>")
.header("X-GatePay-Nonce", "<x-gatepay-nonce>")
.header("X-GatePay-MerchantId", "<x-gatepay-merchantid>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://openplatform.gateapi.io/rate/commission_rule"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-GatePay-Certificate-ClientId", "<x-gatepay-certificate-clientid>")
req.Header.Add("X-GatePay-Signature", "<x-gatepay-signature>")
req.Header.Add("X-GatePay-Timestamp", "<x-gatepay-timestamp>")
req.Header.Add("X-GatePay-Nonce", "<x-gatepay-nonce>")
req.Header.Add("X-GatePay-MerchantId", "<x-gatepay-merchantid>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://openplatform.gateapi.io/rate/commission_rule")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-GatePay-Certificate-ClientId"] = '<x-gatepay-certificate-clientid>'
request["X-GatePay-Signature"] = '<x-gatepay-signature>'
request["X-GatePay-Timestamp"] = '<x-gatepay-timestamp>'
request["X-GatePay-Nonce"] = '<x-gatepay-nonce>'
request["X-GatePay-MerchantId"] = '<x-gatepay-merchantid>'
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"sub_merchant_id": "123456789",
"has_markup": true,
"config_id": "cfg_202604150001",
"r_markup": 0.001,
"f_markup": 0,
"status": "EFFECTIVE",
"effective_date": "2026-04-15 00:00:00",
"expired_date": null,
"actual_rate": {
"r_total": 0.0035,
"f_total": 1
},
"updated_at": "2026-04-15T08:30:00Z"
}
}费用设置
查询费用配置规则详情
查询子账户在指定时间的生效配置,不传时间则返回当前时间的生效配置。
GET
/
rate
/
commission_rule
查询费用配置规则详情
curl --request GET \
--url https://openplatform.gateapi.io/rate/commission_rule \
--header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
--header 'X-GatePay-MerchantId: <x-gatepay-merchantid>' \
--header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>'import requests
url = "https://openplatform.gateapi.io/rate/commission_rule"
headers = {
"X-GatePay-Certificate-ClientId": "<x-gatepay-certificate-clientid>",
"X-GatePay-Signature": "<x-gatepay-signature>",
"X-GatePay-Timestamp": "<x-gatepay-timestamp>",
"X-GatePay-Nonce": "<x-gatepay-nonce>",
"X-GatePay-MerchantId": "<x-gatepay-merchantid>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-GatePay-Certificate-ClientId': '<x-gatepay-certificate-clientid>',
'X-GatePay-Signature': '<x-gatepay-signature>',
'X-GatePay-Timestamp': '<x-gatepay-timestamp>',
'X-GatePay-Nonce': '<x-gatepay-nonce>',
'X-GatePay-MerchantId': '<x-gatepay-merchantid>'
}
};
fetch('https://openplatform.gateapi.io/rate/commission_rule', 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://openplatform.gateapi.io/rate/commission_rule",
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-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>",
"X-GatePay-MerchantId: <x-gatepay-merchantid>",
"X-GatePay-Nonce: <x-gatepay-nonce>",
"X-GatePay-Signature: <x-gatepay-signature>",
"X-GatePay-Timestamp: <x-gatepay-timestamp>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://openplatform.gateapi.io/rate/commission_rule")
.header("X-GatePay-Certificate-ClientId", "<x-gatepay-certificate-clientid>")
.header("X-GatePay-Signature", "<x-gatepay-signature>")
.header("X-GatePay-Timestamp", "<x-gatepay-timestamp>")
.header("X-GatePay-Nonce", "<x-gatepay-nonce>")
.header("X-GatePay-MerchantId", "<x-gatepay-merchantid>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://openplatform.gateapi.io/rate/commission_rule"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-GatePay-Certificate-ClientId", "<x-gatepay-certificate-clientid>")
req.Header.Add("X-GatePay-Signature", "<x-gatepay-signature>")
req.Header.Add("X-GatePay-Timestamp", "<x-gatepay-timestamp>")
req.Header.Add("X-GatePay-Nonce", "<x-gatepay-nonce>")
req.Header.Add("X-GatePay-MerchantId", "<x-gatepay-merchantid>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://openplatform.gateapi.io/rate/commission_rule")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-GatePay-Certificate-ClientId"] = '<x-gatepay-certificate-clientid>'
request["X-GatePay-Signature"] = '<x-gatepay-signature>'
request["X-GatePay-Timestamp"] = '<x-gatepay-timestamp>'
request["X-GatePay-Nonce"] = '<x-gatepay-nonce>'
request["X-GatePay-MerchantId"] = '<x-gatepay-merchantid>'
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"sub_merchant_id": "123456789",
"has_markup": true,
"config_id": "cfg_202604150001",
"r_markup": 0.001,
"f_markup": 0,
"status": "EFFECTIVE",
"effective_date": "2026-04-15 00:00:00",
"expired_date": null,
"actual_rate": {
"r_total": 0.0035,
"f_total": 1
},
"updated_at": "2026-04-15T08:30:00Z"
}
}概述
本页介绍机构主商户查询子账户在指定时间的生效配置快照。完整字段、请求参数与响应示例由上方 OpenAPI 定义渲染。说明
- 查询子账户在指定时间的生效配置,不传时间则返回当前时间的生效配置。
- 本接口使用
X-GatePay-MerchantId标识主商户上下文,不使用X-GatePay-On-Behalf-Of。 - 通用签名规则请参见 /api-reference/version/100/cn/common/securityAndSignature。
请求头
应用 ClientId。
使用 Payment API Secret 生成的 HMAC-SHA512 签名。
毫秒级时间戳,与服务端时间偏差不得超过30秒
随机字符串,用于防重放。
主商户 ID。该接口组通过此请求头声明当前机构主商户上下文。
⌘I

