curl --request POST \
--url https://api.kyrenpay.com/epay/submit.php \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data pid=merch_001 \
--data type=alipay \
--data out_trade_no=order_20260409001 \
--data notify_url=https://merchant.example.com/pay/notify \
--data return_url=https://merchant.example.com/pay/return \
--data 'name=AI Credits Package' \
--data money=99.00 \
--data money_type=CNY \
--data 'display_merchant_name=Campaign Store' \
--data param=user_42 \
--data sign=fb7f5f742f89eb1f137fbc293f2bf42a \
--data sign_type=MD5import requests
url = "https://api.kyrenpay.com/epay/submit.php"
payload = {
"pid": "merch_001",
"type": "alipay",
"out_trade_no": "order_20260409001",
"notify_url": "https://merchant.example.com/pay/notify",
"return_url": "https://merchant.example.com/pay/return",
"name": "AI Credits Package",
"money": "99.00",
"money_type": "CNY",
"display_merchant_name": "Campaign Store",
"param": "user_42",
"sign": "fb7f5f742f89eb1f137fbc293f2bf42a",
"sign_type": "MD5"
}
headers = {"Content-Type": "application/x-www-form-urlencoded"}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/x-www-form-urlencoded'},
body: new URLSearchParams({
pid: 'merch_001',
type: 'alipay',
out_trade_no: 'order_20260409001',
notify_url: 'https://merchant.example.com/pay/notify',
return_url: 'https://merchant.example.com/pay/return',
name: 'AI Credits Package',
money: '99.00',
money_type: 'CNY',
display_merchant_name: 'Campaign Store',
param: 'user_42',
sign: 'fb7f5f742f89eb1f137fbc293f2bf42a',
sign_type: 'MD5'
})
};
fetch('https://api.kyrenpay.com/epay/submit.php', 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.kyrenpay.com/epay/submit.php",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5",
CURLOPT_HTTPHEADER => [
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.kyrenpay.com/epay/submit.php"
payload := strings.NewReader("pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/x-www-form-urlencoded")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.kyrenpay.com/epay/submit.php")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kyrenpay.com/epay/submit.php")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/x-www-form-urlencoded'
request.body = "pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5"
response = http.request(request)
puts response.read_body{
"code": 0,
"msg": "签名验证失败"
}{
"code": 42901,
"message": "Too many requests"
}submit.php (redirect checkout compatibility endpoint)
Creates (or reuses) an Epay-compatible payment and returns HTTP 302 redirect to the hosted payment page. This endpoint also accepts GET with the same parameters.
Paydify:商户一次性加密货币通道绑定 Paydify 时使用 type=crypto(不是 paydify)。
返回 302 到 KyrenPay 本地 /epay/redirect/{orderId},入口受理时不创建上游支付。
买家在本地页选择 App / 网络并确认 USDT 报价后,才创建上游支付和展示二维码。
无需商户提交 App、网络或 Paydify 专用 channel_param。目标环境须已部署且渠道已开通。
Signature algorithm:
- Remove
signandsign_type, and drop empty values. - Sort parameters by key in ascending order.
- Join as
k=vwith&, append merchant API key. - MD5 the final string and compare in lowercase.
curl --request POST \
--url https://api.kyrenpay.com/epay/submit.php \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data pid=merch_001 \
--data type=alipay \
--data out_trade_no=order_20260409001 \
--data notify_url=https://merchant.example.com/pay/notify \
--data return_url=https://merchant.example.com/pay/return \
--data 'name=AI Credits Package' \
--data money=99.00 \
--data money_type=CNY \
--data 'display_merchant_name=Campaign Store' \
--data param=user_42 \
--data sign=fb7f5f742f89eb1f137fbc293f2bf42a \
--data sign_type=MD5import requests
url = "https://api.kyrenpay.com/epay/submit.php"
payload = {
"pid": "merch_001",
"type": "alipay",
"out_trade_no": "order_20260409001",
"notify_url": "https://merchant.example.com/pay/notify",
"return_url": "https://merchant.example.com/pay/return",
"name": "AI Credits Package",
"money": "99.00",
"money_type": "CNY",
"display_merchant_name": "Campaign Store",
"param": "user_42",
"sign": "fb7f5f742f89eb1f137fbc293f2bf42a",
"sign_type": "MD5"
}
headers = {"Content-Type": "application/x-www-form-urlencoded"}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/x-www-form-urlencoded'},
body: new URLSearchParams({
pid: 'merch_001',
type: 'alipay',
out_trade_no: 'order_20260409001',
notify_url: 'https://merchant.example.com/pay/notify',
return_url: 'https://merchant.example.com/pay/return',
name: 'AI Credits Package',
money: '99.00',
money_type: 'CNY',
display_merchant_name: 'Campaign Store',
param: 'user_42',
sign: 'fb7f5f742f89eb1f137fbc293f2bf42a',
sign_type: 'MD5'
})
};
fetch('https://api.kyrenpay.com/epay/submit.php', 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.kyrenpay.com/epay/submit.php",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5",
CURLOPT_HTTPHEADER => [
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.kyrenpay.com/epay/submit.php"
payload := strings.NewReader("pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/x-www-form-urlencoded")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.kyrenpay.com/epay/submit.php")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kyrenpay.com/epay/submit.php")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/x-www-form-urlencoded'
request.body = "pid=merch_001&type=alipay&out_trade_no=order_20260409001¬ify_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Fnotify&return_url=https%3A%2F%2Fmerchant.example.com%2Fpay%2Freturn&name=AI%20Credits%20Package&money=99.00&money_type=CNY&display_merchant_name=Campaign%20Store¶m=user_42&sign=fb7f5f742f89eb1f137fbc293f2bf42a&sign_type=MD5"
response = http.request(request)
puts response.read_body{
"code": 0,
"msg": "签名验证失败"
}{
"code": 42901,
"message": "Too many requests"
}Body
Types for the 21 live payment methods available through submit.php and mapi.php. Use the recommended lowercase types below. Type matching is case-insensitive; sign the original value sent. Queries and notifications return the recommended type. Availability depends on enabled merchant channels, bindings, supported currencies and amount limits.
| Payment method | Recommended type | Accepted aliases |
|---|---|---|
| Alipay | alipay | — |
| AlipayHK | alipay_hk | alipayhk, alihk |
| Boost | boost | — |
| Credit card | creditcard | credit_card |
| Cryptocurrency | crypto | — |
| DANA | dana | — |
| JKOPay | jkopay | — |
| Mir | mir | — |
| OVO SNAP | ovo | — |
| PAYCO | payco | — |
| PayNow | paynow | — |
| Samsung Pay | samsungpay | samsung_pay |
| Sber Pay | sberpay | sber_pay |
| SBP | sbp | — |
| ShopeePay | shopeepay | — |
| Toss Pay | tosspay | toss_pay |
| Touch ’n Go eWallet | touch_n_go_ewallet | touchngo, tng |
| T-Pay | t_pay | tpay |
| USDT Direct | usdt_direct | — |
| WeChat Pay | wxpay | — |
| YooMoney | yoomoney | yoo_money |
crypto uses the existing merchant binding to Paydify or legacy Satogate.
usdt_direct is the separate USDT Direct method and only routes to Satogate.
Provider names such as paydify, satogate, and evonet are not valid types.
alipay, alipay_hk, boost, creditcard, crypto, dana, jkopay, mir, ovo, payco, paynow, samsungpay, sberpay, sbp, shopeepay, tosspay, touch_n_go_ewallet, t_pay, usdt_direct, wxpay, yoomoney, alipayhk, alihk, credit_card, samsung_pay, sber_pay, toss_pay, touchngo, tng, tpay, yoo_money Optional JSON string for non-card channel-specific fields. For type=creditcard, the raw value participates in signature verification but is ignored after verification. Do not send card details or billing/contact data in this field; the buyer enters card information on a hosted payment page.
