Token导航 LogoToken导航

Agent Skill · 开发

hongkong-payment-qfpay(香港支付 qfpay)

hongkong-payment-qfpay 用于辅助前端页面、组件、样式和交互逻辑开发,适合在 OpenClaw 中需要维护前端项目、生成组件或检查界面实现时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

hongkong-payment-qfpay 是开发类 Agent Skill,可用宿主为 OpenClaw,通过ClawHub获取,权限为接触敏感数据;许可证为 MIT-0,第三方扫描有提醒项,按安装量在开发类的 21,746 个 Skill 里排第 1,084。

总安装 40,835周安装 1,636GitHub Stars 公开资料未说明下载 13,219核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT-0
版本
1.0.0

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:hongkong-payment-qfpay(香港支付 qfpay)
来源仓库:https://github.com/xingstudy/hongkong-payment-qfpay
安装命令:
openclaw skills install hongkong-payment-qfpay
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install hongkong-payment-qfpay

这个 Skill 是做什么的

开发类 Skill 面向写代码、改代码和排查问题,一般会读写仓库文件,部分还会执行构建或测试命令。

QFPay API是一个全面的支付解决方案,提供多种支付方式,满足不同商家的需求。

This skill provides complete API integration guidelines including environment configuration, request formats, signature generation, payment types, supported currencies, and status codes.

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 OpenClaw;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 openclaw skills install hongkong-payment-qfpay;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

hongkong-payment-qfpay 怎么安装?

在终端执行 openclaw skills install hongkong-payment-qfpay。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

hongkong-payment-qfpay 支持哪些 AI 工具?

公开资料标注支持 OpenClaw。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

hongkong-payment-qfpay 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

hongkong-payment-qfpay 是免费的吗?

来源标注的许可证是 MIT-0。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

hongkong-payment-qfpay 用的人多吗?

公开数据是累计安装 40,835 次,近一周安装 1,636 次,下载 13,219 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

hongkong-payment-qfpay 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 专注 OpenClaw 一种宿主,触发方式和使用习惯不用来回切换。
  • 许可证明确为 MIT-0,商用和分发边界好判断。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 OpenClaw,想直接扩展它能力的人。
  • 需要处理开发类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

开发类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
skill-vetter

技能审查员 · OpenClaw

8,779,018986操作浏览器MIT-0通过
ontology

本体论 · OpenClaw

6,636,960576只读MIT-0通过
entra-app-registration

内部应用程序注册 · Codex、Claude

6,631,872764接触敏感数据未明确通过
entra-app-registration

内部应用程序注册 · Codex、Claude

3,757,680201接触敏感数据未明确通过
nano-banana-pro

纳米香蕉专业版 · OpenClaw

3,526,898364接触敏感数据MIT-0有提醒
hongkong-payment-qfpay

香港支付 qfpay · 本页

40,835—接触敏感数据MIT-0有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
HONGKONG-PAYMENT-QFPAY
description
QFPay API is a comprehensive payment solution that offers various payment methods to meet the needs of different businesses. This skill provides complete API integration guidelines including environment configuration, request formats, signature generation, payment types, supported currencies, and status codes.

QFPay Payment API Skill

Overview

QFPay API is a comprehensive payment solution that offers various payment methods to meet the needs of different businesses. This skill provides complete API integration guidelines including environment configuration, request formats, signature generation, payment types, supported currencies, and status codes.

Environment Configuration

QFPay API is accessible via three main environments:

EnvironmentBase URLDescription
Sandboxhttps://openapi-int.qfapi.comFor simulating payments without real fund deduction
Testinghttps://test-openapi-hk.qfapi.comReal payment flow but linked to test accounts (no settlement)
Productionhttps://openapi-hk.qfapi.comReal live payments with actual settlement

Important Notes:

  • Transactions in Testing environment using test accounts will NOT be settled
  • Always ensure refunds are triggered immediately for test transactions
  • Mixing credentials or endpoints across environments will result in signature or authorization errors

Environment Variables Setup

Configure these environment variables before using the API:

export QFPAY_APPCODE="your_app_code_here"
export QFPAY_KEY="your_client_key_here"
export QFPAY_MCHID="your_merchant_id"  # Optional, depends on account setup
export QFPAY_ENV="sandbox"  # Options: prod, test, sandbox

API Usage Guidelines

Rate Limiting

To ensure fair usage and optimal performance:

  • Limit: Maximum 100 requests per second (RPS) and 400 requests per minute per merchant
  • Exceeding Limit: API responds with HTTP 429 (Too Many Requests)

Best Practices

  1. Batch Requests: Use batch processing to minimize individual requests
  2. Efficient Queries: Utilize filtering and pagination
  3. Caching: Implement response caching to avoid repeated requests
  4. Monitoring: Track API usage and implement logging for request patterns

Error Handling

When receiving HTTP 429:

  1. Pause further requests for a specified duration
  2. Implement exponential backoff for retries
  3. Log errors for monitoring

Traffic Spike Management

For anticipated traffic spikes (e.g., promotional events), contact:

  • Technical Support: technical.support@qfpay.com

Request Format

HTTP Request

POST /trade/v1/payment

Public Payment Request Parameters

AttributeRequiredTypeDescription
txamtYesInt(11)Transaction amount in cents (100 = $1). Suggest > 200 to avoid risk control
txcurrcdYesString(3)Transaction currency. See Currencies section for full list
pay_typeYesString(6)Payment type code. See Payment Types section
out_trade_noYesString(128)External transaction number. Must be unique per merchant account
txdtmYesString(20)Transaction time format: YYYY-MM-DD hh:mm:ss
auth_codeYes (CPM only)String(128)Authorization code for scanning barcode/QR. Expires within one day
expired_timeNo (MPM only)String(3)QR expiration in minutes. Default: 30, Min: 5, Max: 120
goods_nameNoString(64)Item description. Max 20 chars, UTF-8 for Chinese. Required for App payments
mchidNoString(16)Merchant ID. Required if assigned, must NOT be included if not assigned
udidNoString(40)Unique device ID for internal tracking
notify_urlNoString(256)URL for asynchronous payment notifications

HTTP Header Requirements

FieldRequiredDescription
X-QF-APPCODEYesApp code assigned to merchant
X-QF-SIGNYesSignature generated per signature algorithm
X-QF-SIGNTYPENoSignature algorithm. Use SHA256 or defaults to MD5

Content Specifications

  • Character Encoding: UTF-8
  • Method: POST/GET (depends on endpoint)
  • Content-Type: application/x-www-form-urlencoded

Response Format

Success Response Structure

{
  "respcd": "0000",
  "respmsg": "success",
  "data": {
    "txamt": "100",
    "out_trade_no": "20231101000001",
    "txcurrcd": "HKD",
    "txstatus": "SUCCESS",
    "qf_trade_no": "9000020231101000001",
    "pay_type": "800101",
    "txdtm": "2023-11-01 10:00:00"
  }
}

Response Fields

FieldTypeDescription
respcdString(4)Return code. "0000" means success
respmsgString(64)Message description of respcd
dataObjectPayment transaction data

Data Object Fields

FieldTypeDescription
txamtStringTransaction amount in cents
out_trade_noStringMerchant's original order number
txcurrcdStringCurrency code (e.g., HKD)
txstatusStringPayment status: SUCCESS, FAILED, PENDING
qf_trade_noStringQFPay's unique transaction number
pay_typeStringPayment method code
txdtmStringPayment time (YYYY-MM-DD HH:mm:ss)

Signature Verification

Response may include X-QF-SIGN and X-QF-SIGNTYPE headers. Verify by:

  1. Extracting data fields in sorted order
  2. Concatenating as key1=value1&key2=value2&...
  3. Appending client key
  4. Generating MD5 hash and comparing

Signature Generation

All API requests must include a digital signature in the HTTP header:

X-QF-SIGN: <your_signature>

Step-by-Step Guide

Step 1: Sort Parameters

Sort all request parameters by parameter name in ASCII ascending order.

Example:

ParameterValue
mchidZaMVg12345
txamt100
txcurrcdHKD

Sorted result:

mchid=ZaMVg12345&txamt=100&txcurrcd=HKD
Step 2: Append Client Key

Append your secret client_key to the string.

If client_key = abcd1234:

mchid=ZaMVg12345&txamt=100&txcurrcd=HKDabcd1234
Step 3: Hash the String

Hash using MD5 or SHA256 (SHA256 recommended):

SHA256("mchid=ZaMVg12345&txamt=100&txcurrcd=HKDabcd1234")
Step 4: Add to Header
X-QF-SIGN: <your_hashed_signature>

Important Notes

  • Do NOT insert line breaks, tabs, or extra spaces
  • Parameter names and values are case-sensitive
  • Double-check parameter order and encoding if signature fails

Code Examples

Python
import os
import hashlib

APPCODE = os.getenv('QFPAY_APPCODE')
KEY = os.getenv('QFPAY_KEY')

def generate_signature(params, key):
    """Generate MD5 signature"""
    keys = list(params.keys())
    keys.sort()
    query = []
    for k in keys:
        if k not in ('sign', 'sign_type') and (params[k] or params[k] == 0):
            query.append(f'{k}={params[k]}')
    
    data = '&'.join(query) + key
    md5 = hashlib.md5()
    md5.update(data.encode('utf-8'))
    return md5.hexdigest().upper()

def generate_signature_sha256(params, key):
    """Generate SHA256 signature"""
    keys = list(params.keys())
    keys.sort()
    query = []
    for k in keys:
        if k not in ('sign', 'sign_type') and (params[k] or params[k] == 0):
            query.append(f'{k}={params[k]}')
    
    data = '&'.join(query) + key
    sha256 = hashlib.sha256()
    sha256.update(data.encode('utf-8'))
    return sha256.hexdigest().upper()

Payment Types

The pay_type parameter specifies which payment method to use. This affects transaction routing and UI requirements.

Note: Not all pay_type values are enabled for every merchant. Contact technical.support@qfpay.com for clarification.

Supported Payment Types

CodeDescription
800008CPM for WeChat, Alipay, UnionPay QuickPass, PayMe
800101Alipay MPM (Overseas Merchants)
800108Alipay CPM (Overseas & HK Merchants)
801101Alipay Web Payment (Overseas)
801107Alipay WAP Payment (Overseas)
801110Alipay In-App Payment (Overseas)
800107Alipay Service Window H5 Payment
801501Alipay MPM (HK Merchants)
801510Alipay In-App (HK Merchants)
801512Alipay WAP (HK Merchants)
801514Alipay Web (HK Merchants)
800201WeChat MPM (Overseas & HK)
800208WeChat CPM (Overseas & HK)
800207WeChat JSAPI Payment (Overseas & HK)
800212WeChat H5 Payment
800210WeChat In-App Payment (Overseas & HK)
800213WeChat Mini-Program Payment
801008WeChat Pay HK CPM (Direct Settlement, HK)
801010WeChat Pay HK In-App (Direct Settlement, HK)
805801PayMe MPM (HK Merchants)
805808PayMe CPM (HK Merchants)
805814PayMe Web Payment (HK Merchants)
805812PayMe WAP Payment (HK Merchants)
800701UnionPay QuickPass MPM
800708UnionPay QuickPass CPM
800712UnionPay WAP Payment (HK)
800714UnionPay PC-Web Payment (HK)
802001FPS MPM (HK Merchants)
803701Octopus MPM (HK Merchants)
803712Octopus WAP Payment (HK)
803714Octopus PC-Web Payment (HK)
802801Visa / Mastercard Online
802808Visa / Mastercard Offline
806527ApplePay Online
806708UnionPay Card Offline
806808American Express Card Offline

Special Remarks

  • 801101: Transaction amount must be greater than 1 HKD
  • 802001: This payment method does not support refunds

Supported Currencies

All codes follow ISO 4217 format (3-letter uppercase):

CodeDescription
AEDArab Emirates Dirham
CNYChinese Yuan
EUREuro
HKDHong Kong Dollar
IDRIndonesian Rupiah
JPYJapanese Yen
MMKMyanmar Kyat
MYRMalaysian Ringgit
SGDSingapore Dollar
THBThai Baht
USDUnited States Dollar
CADCanadian Dollar
AUDAustralian Dollar

Note: Some payment methods may only support HKD. Verify with your integration manager before non-HKD transactions.

Status Codes

Standard respcd values returned by QFPay API:

CodeDescription
0000Transaction successful
1100System under maintenance
1101Reversal error
1102Duplicate request
1103Request format error
1104Request parameter error
1105Device not activated
1106Invalid device
1107Device not allowed
1108Signature error
1125Transaction already refunded
1136Transaction does not exist or not operational
1142Order already closed
1143Order not paid, password being entered
1145Processing, please wait
1147WeChat Pay transaction error
1150T0 billing method does not support cancellation
1155Refund request denied
1181Order expired
1201Insufficient balance
1202Incorrect or expired payment code
1203Merchant account error
1204Bank error
1205Transaction failed, try again later
1212Please use UnionPay overseas payment code
1241Store does not exist or status incorrect
1242Store not configured correctly
1243Store has been disabled
1250Transaction forbidden
1251Store configuration error
1252System error making order request
1254Problem occurred, resolving issue
1260Order already paid
1261Order not paid
1262Order already refunded
1263Order already cancelled
1264Order already closed
1265Transaction cannot be refunded (11:30pm-0:30am)
1266Transaction amount wrong
1267Order information mismatch
1268Order does not exist
1269Insufficient unsettled balance for refund
1270Currency does not support partial refund
1271Transaction does not support partial refund
1272Refund amount exceeds maximum refundable
1294Transaction non-compliant, prohibited by bank
1295Connection slow, waiting for network response
1296Connection slow, try again later
1297Banking system busy
1298Connection slow, do not repeat payment if already paid
2005Customer payment code incorrect or expired
2011Transaction serial number repeats

Usage Examples

Complete Payment Flow (Python)

import os
import requests
import hashlib
import datetime
import time

# Load configuration from environment variables
APPCODE = os.getenv('QFPAY_APPCODE')
KEY = os.getenv('QFPAY_KEY')
MCHID = os.getenv('QFPAY_MCHID')
ENV = os.getenv('QFPAY_ENV', 'test')

# Environment URLs
ENV_URLS = {
    'prod': 'https://openapi-hk.qfapi.com',
    'test': 'https://test-openapi-hk.qfapi.com',
    'sandbox': 'https://openapi-int.qfapi.com'
}

BASE_URL = ENV_URLS.get(ENV, ENV_URLS['test'])

def generate_signature(params, key, sign_type='SHA256'):
    """Generate signature for QFPay API request"""
    keys = list(params.keys())
    keys.sort()
    query = []
    for k in keys:
        if k not in ('sign', 'sign_type') and (params[k] or params[k] == 0):
            query.append(f'{k}={params[k]}')
    
    data = '&'.join(query) + key
    
    if sign_type == 'SHA256':
        sha256 = hashlib.sha256()
        sha256.update(data.encode('utf-8'))
        return sha256.hexdigest().upper()
    else:
        md5 = hashlib.md5()
        md5.update(data.encode('utf-8'))
        return md5.hexdigest().upper()

def create_payment(amount, currency, pay_type, goods_name, notify_url=None):
    """Create a payment request"""
    params = {
        'txamt': str(amount),
        'txcurrcd': currency,
        'pay_type': pay_type,
        'out_trade_no': f"ORDER{int(time.time() * 10000)}",
        'txdtm': datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S'),
        'goods_name': goods_name
    }
    
    if MCHID:
        params['mchid'] = MCHID
    
    if notify_url:
        params['notify_url'] = notify_url
    
    signature = generate_signature(params, KEY)
    
    headers = {
        'X-QF-APPCODE': APPCODE,
        'X-QF-SIGN': signature,
        'Content-Type': 'application/x-www-form-urlencoded'
    }
    
    response = requests.post(
        f'{BASE_URL}/trade/v1/payment',
        data=params,
        headers=headers
    )
    
    return response.json()

def query_transaction(out_trade_no):
    """Query transaction status"""
    params = {
        'out_trade_no': out_trade_no,
        'txdtm': datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')
    }
    
    if MCHID:
        params['mchid'] = MCHID
    
    signature = generate_signature(params, KEY)
    
    headers = {
        'X-QF-APPCODE': APPCODE,
        'X-QF-SIGN': signature,
        'Content-Type': 'application/x-www-form-urlencoded'
    }
    
    response = requests.post(
        f'{BASE_URL}/trade/v1/query',
        data=params,
        headers=headers
    )
    
    return response.json()

def refund_transaction(out_trade_no, txamt, qf_trade_no=None):
    """Process a refund"""
    params = {
        'out_trade_no': out_trade_no,
        'txamt': str(txamt),
        'txdtm': datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')
    }
    
    if qf_trade_no:
        params['qf_trade_no'] = qf_trade_no
    
    if MCHID:
        params['mchid'] = MCHID
    
    signature = generate_signature(params, KEY)
    
    headers = {
        'X-QF-APPCODE': APPCODE,
        'X-QF-SIGN': signature,
        'Content-Type': 'application/x-www-form-urlencoded'
    }
    
    response = requests.post(
        f'{BASE_URL}/trade/v1/refund',
        data=params,
        headers=headers
    )
    
    return response.json()

# Example usage
if __name__ == '__main__':
    # Create a payment
    result = create_payment(
        amount=100,  # $1.00 HKD
        currency='HKD',
        pay_type='800101',
        goods_name='Test Product'
    )
    print(f"Payment created: {result}")
    
    if result.get('respcd') == '0000':
        out_trade_no = result['data']['out_trade_no']
        
        # Query transaction
        query_result = query_transaction(out_trade_no)
        print(f"Transaction status: {query_result}")

Environment Configuration with Multiple Merchants

import os

# Configuration loader from environment
class QFPayConfig:
    def __init__(self, env='sandbox'):
        self.env = env
        self.appcode = os.getenv(f'QFPAY_{env.upper()}_APPCODE') or os.getenv('QFPAY_APPCODE')
        self.key = os.getenv(f'QFPAY_{env.upper()}_KEY') or os.getenv('QFPAY_KEY')
        self.mchid = os.getenv(f'QFPAY_{env.upper()}_MCHID') or os.getenv('QFPAY_MCHID')
        
    @property
    def base_url(self):
        urls = {
            'prod': 'https://openapi-hk.qfapi.com',
            'test': 'https://test-openapi-hk.qfapi.com',
            'sandbox': 'https://openapi-int.qfapi.com'
        }
        return urls.get(self.env, urls['sandbox'])

# Usage
config = QFPayConfig(env=os.getenv('QFPAY_ENV', 'sandbox'))
print(f"Using base URL: {config.base_url}")

Important Notes

  1. Signature Security: Never expose your client_key in frontend code or client-side applications. Always compute signatures on the server side.
  1. Order Number Uniqueness: out_trade_no must be unique across all payment and refund requests under the same merchant account.
  1. Character Encoding: All requests and responses use UTF-8 encoding.
  1. Timeout Handling: For payment requests that don't return promptly, implement a polling mechanism to query transaction status.
  1. Async Notifications: Configure notify_url to receive asynchronous payment completion notifications and verify notification signatures.
  1. Refund Limitations: FPS (802001) payment type does not support refunds. Confirm business requirements before integration.
  1. Amount Format: Amount is in cents. For example, 100 represents 1 HKD.
  1. Timezone: The txdtm parameter uses the merchant's local timezone.
  1. Environment Variables: Always load sensitive credentials from environment variables, never hardcode them in source files.

Technical Support

For any integration issues, contact:

  • Email: technical.support@qfpay.com
  • Documentation: https://sdk.qfapi.com
  • Postman Collection: https://sdk.qfapi.com/assets/files/qfpay_openapi_payment_request.postman_collection-c8de8c8fe69f3fcd5a7653d41c289a29.json

See Also

平台分布

OpenClaw

91.67%
按下载量换算12,118

安全审计

VirusTotal

通过

ClawScan

可疑

Static analysis

未展示

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills