Token导航 LogoToken导航TokenDH.com
开发敏感数据clawhub未标认证来源可访问clear审计通过

sohopaysohopay 开发

Agent Skill

sohopay 用于补充开发相关能力,适合在 OpenClaw 中需要让 Agent 承接开发相关任务时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

21,123

周安装

889

GitHub Stars

2

下载量

7,396
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

ClawHubOpenClaw
openclaw skills install sohopay

简介

sohopay 使用 EIP-712 签名在 SOHO Pay 信用层上发起支付。

  • 适用于区块链支付和信用交易开发场景。
  • 支持智能合约交互和支付流程自动化。
  • 安装方式:openclaw skills install sohopay,宿主为 OpenClaw。
  • 使用前请确认权限范围和维护状态,注意可能涉及加密操作或网络请求。

SKILL.md

name
sohopay
description
Initiate payments on the SOHO Pay credit layer using EIP-712 signatures.

SOHO Pay - Credit Layer Payments

This skill allows the agent to initiate payments through the SOHO Pay Creditor smart contract using the spendWithAuthorization EIP-712 flow.

The agent signs the payment authorization off-chain using a pre-configured wallet, and then submits the transaction to the network on the user's behalf.

Core Command

The primary way to use this skill is with a natural language command that maps to:

pay <amount> to <merchant_address>

  • <amount>: The numerical amount to pay (e.g., 10, 0.5).
  • <merchant_address>: The recipient EVM address (0x...). Names are not supported and no random addresses are ever generated by this skill.

Workflow

Payments (credit spend)

When you issue a pay command, the skill performs the following actions:

  1. Parse Inputs: Extracts the amount and merchant address from the user's request.
  2. Validate Merchant Address: Confirms that the merchant is a valid EVM address; otherwise it aborts.
  3. Pre-Flight Checks (BorrowerManager):

- Verifies the borrower is registered and active. - Checks if the credit limit is sufficient for the requested amount. - On demand, can auto-register the agent once via registerAgent.

  1. Generate Authorization: Creates an EIP-712 typed data message for the payment.
  2. Sign Off-Chain: Uses the configured PRIVATE_KEY wallet (from environment variables) to sign the authorization message.
  3. Execute On-Chain: Calls the spendWithAuthorization function on the Creditor contract, providing the signed message.
  4. Report Result: Returns the transaction hash to the user upon confirmation.

Status / Profile checks

The status helper reads the BorrowerManager profile + USDC wallet balance for the bot:

  • Calls the s_borrowerProfiles(address) public mapping getter to fetch:

creditLimit, outstandingDebt, totalSpent, totalRepaid, spendingCount, repaymentCount, lastActivityTime, creditScore, isActive, isAgent, transactionIds.

  • Calls IERC20(USDC).balanceOf(bot) to fetch the USDC wallet balance for the same address.
  • Prints a human-readable summary so you can see, per network:

- Whether the bot is registered / active - Credit limit and whether the profile is flagged as an agent - Outstanding debt and historical spend/repay totals - Last activity timestamp and credit score - USDC balance available in the wallet

This is what powers prompts like:

  • "check my bot status on testnet"
  • "check my bot outstanding debt on mainnet"

Repayments (reduce outstanding debt)

The repay helper uses USDC to pay down outstandingDebt tracked by BorrowerManager and Creditor:

  1. Pre-flight checks:

- Verifies the borrower is registered and active. - Reads current credit limit and any existing outstandingDebt`.

  1. USDC balance & allowance:

- Ensures the bot wallet has enough USDC balance for the requested repayment. - Checks IERC20(USDC).allowance(bot, Creditor) and, if too low, sends an approve(Creditor, amount) tx first.

  1. On-chain repay:

- Calls Creditor.repay(amount, USDC) from the borrower wallet. - The Creditor contract: - Caps the repayment to min(amount, outstandingDebt). - Applies payments to BNPL plans via applyPaymentToPlans. - Updates the borrower profile via updateOnRepayment (new score + limit). - Transfers USDC from the borrower to the Vault and calls vault.repayVaultDebt. - Emits a repayment event with the new score and limit.

  1. Status after repay:

- After a successful repay, you can run status again to verify: - outstandingDebt has decreased (or is 0), - totalRepaid increased, - creditScore and creditLimit have been updated.

This is what backs prompts like:

  • "repay my bot debt on testnet"
  • "repay 5 USDC of my bot debt on mainnet"

Configuration

  • Environment Variable (runtime): The private key for the signing wallet must be provided via the PRIVATE_KEY environment variable.
  • Why the private key is needed: OpenClaw is designed to run as an autonomous agent. For it to initiate SOHO Pay transactions without human clicks, it must be able to sign EIP-712 authorizations itself.
  • Local-only usage (important): **PRIVATE_KEY is used *only locally* on the machine running OpenClaw. The raw key is never sent to SOHO Pay, ClawHub, or any external service — only signed messages and transactions leave the machine.** Anyone running this bot must understand that the key controls whatever funds are on the selected network.
  • Skill Metadata: The skill declares PRIVATE_KEY as a required, sensitive credential. You can use a single key for both Base mainnet and Base Sepolia, but be aware this may control real funds on mainnet.
  • Networks: The script supports both Base mainnet (default) and Base Sepolia (testnet). It enforces the expected chainId for the selected network and aborts if the RPC does not match.

Defaults

The following values are hardcoded into the script for consistency, and are used on both Base mainnet and Base Sepolia:

  • Creditor Contract: 0xdb34d612dd9aa548f6c94af118f82a461a835e09
  • Borrower Manager: 0xc6ecd37c42ee73714956b6a449b41bc1d46b07b0
  • Asset (USDC): 0x43848d5a4efa0b1c72e1fd8ece1abf42e9d5e221 (6 decimals)
  • Payment Plan ID: 0

Setup, Installation & Dependencies

This skill is a small Node.js project under skills/sohopay.

  1. Set PRIVATE_KEY in the environment where OpenClaw runs:
   export PRIVATE_KEY=0xYOUR_KEY_HERE

This address will be the SOHO Pay "agent" on Base mainnet / Base Sepolia.

  1. Install the skill and dependencies:
   clawhub install sohopay
   cd skills/sohopay
   npm install

This installs the runtime dependencies declared in package.json (currently ethers and dotenv).

  1. Register the agent once on the chosen network (before making payments):
   # Base mainnet (default)
   node scripts/register.js

   # Explicit mainnet
   node scripts/register.js mainnet

   # Base Sepolia testnet
   node scripts/register.js testnet

This calls registerAgent(agent) on the BorrowerManager contract using the PRIVATE_KEY address.

  1. Make payments after registration using scripts/pay.js:
   # Base mainnet (default when no network arg is given)
   node scripts/pay.js 10 0xMerchantOnMainnet

   # Explicit mainnet
   node scripts/pay.js mainnet 10 0xMerchantOnMainnet

   # Base Sepolia testnet
   node scripts/pay.js testnet 10 0xMerchantOnTestnet

This uses the SOHO Pay Creditor contract to spend on credit via spendWithAuthorization.

  1. Check status / profile and balances using scripts/status.js:
   # Base mainnet
   node scripts/status.js mainnet

   # Base Sepolia testnet
   node scripts/status.js testnet

This reads the BorrowerManager profile and USDC wallet balance for the agent and prints a human-readable summary (credit limit, outstanding debt, totals, scores, and USDC balance).

  1. Repay outstanding debt using USDC with scripts/repay.js:
   # Base mainnet
   node scripts/repay.js mainnet 10

   # Base Sepolia testnet
   node scripts/repay.js testnet 10

This uses USDC from the agent wallet to repay outstandingDebt via the Creditor contract, updating the borrower profile and vault debt, and emitting a repayment event.

Security Notes

  • PRIVATE_KEY is highly sensitive. Treat it exactly like the key to a normal wallet: anyone with this value can move all funds it controls.
  • Local signing only: The script signs transactions locally and never transmits the raw private key over the network. Only signatures and transactions are sent to RPC endpoints.
  • This skill never triggers itself; it is only executed when called by a user, cron job, or higher-level workflow. It is safe to wire into autonomous flows (e.g. “if price < 10, then pay …”) as long as you understand what those automations will do with your PRIVATE_KEY.
  • The merchant must be provided as an explicit merchant_address. If the address is wrong, funds on that network may be irrecoverably sent to the wrong account.
  • No random address generation is performed. The skill will refuse non-address merchant inputs.

Example Usage

Natural-language commands

These are the kinds of prompts you can send to your OpenClaw agent once the skill is installed and PRIVATE_KEY is configured.

  • Register bot (testnet)

"register my bot to use sohopay on Base Sepolia testnet"

  • Register bot (mainnet)

"register my bot to use sohopay on Base mainnet"

  • Pay a merchant (EIP‑712 spendWithAuthorization)

"pay 10 USDC to 0x1234567890abcdef1234567890abcdef12345678 on testnet using sohopay"

  • Check bot status (credit limit, outstanding debt, totals, USDC balance)

"check my bot status on testnet" "check my bot outstanding debt on mainnet"

  • Repay debt (calls Creditor.repay(amount, stablecoin))

"repay my bot debt on testnet" "repay 5 USDC of my bot debt on mainnet"

Script entrypoints (for reference)

  • Registration: node scripts/register.js [mainnet|testnet] [check]

- node scripts/register.js testnet – register bot on Base Sepolia - node scripts/register.js mainnet check – status only, no tx

  • Payments (credit spend):

- node scripts/pay.js [mainnet|testnet] <amount> <merchant_address>

  • Status (profile + outstanding debt + USDC balance):

- node scripts/status.js mainnet - node scripts/status.js testnet

  • Repayments (reduce outstanding debt using USDC):

- node scripts/repay.js [mainnet|testnet] <amount>

When mapped through OpenClaw, you should prefer natural-language prompts; the scripts above are provided for debugging and manual CLI use.

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

97.38%
按下载量换算7,202

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

未展示

权限和风险

敏感数据

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

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills