SolPaw:在 Pump.fun 上部署 Solana 代币 - Openclaw 技能

作者:互联网

2026-03-29

AI教程

什么是 SolPaw?

SolPaw 是专为 Openclaw 技能设计的技术桥梁,使 AI 代理能够与 Solana 区块链交互。它专注于通过 Pump.fun 生态系统部署代币,处理 IPFS 元数据上传、交易构建和安全提交等繁重工作。通过将其集成到您的 Openclaw 技能套件中,您可以让您的代理具备直接从 CLI 或自主工作流创建可验证的社区代币和模因币的能力。

该平台的构建重点在于透明度,确保代理的特定钱包被注册为链上创作者。这使其成为开发人员构建需要参与去中心化金融空间的代理的重要工具,提供简化的 API 和 SDK 来管理 0.1 SOL 平台费用及后续的代币上线流程。

下载入口:https://github.com/openclaw/skills/tree/main/skills/lvcidpsyche/solpaw-skill-final

安装与下载

1. ClawHub CLI

从源直接安装技能的最快方式。

npx clawhub@latest install solpaw-skill-final

2. 手动安装

将技能文件夹复制到以下位置之一

全局模式 ~/.openclaw/skills/ 工作区 /skills/

优先级:工作区 > 本地 > 内置

3. 提示词安装

将此提示词复制到 OpenClaw 即可自动安装。

请帮我使用 Clawhub 安装 solpaw-skill-final。如果尚未安装 Clawhub,请先安装(npm i -g clawhub)。

SolPaw 应用场景

  • 通过代理指令自主发行新的模因币或社区驱动型代币。
  • 部署具有特定元数据的项目代币,包括代号、描述和自定义图像。
  • 为基于研究或社交媒体驱动的加密项目自动化创建 Pump.fun 列表。
  • 管理代币发行,其中代理必须是可验证的链上创作者,以确保信任和透明度。
SolPaw 工作原理
  1. 代理向 SolPaw 进行一次性注册以生成唯一的 API 密钥。
  2. 请求单次使用的 CSRF 令牌以保护特定的启动会话。
  3. 将 0.1 SOL 的平台费用转移到服务钱包以授权部署。
  4. 代币资产和元数据通过 SolPaw 网关上传到 IPFS 以确保数据持久性。
  5. 技能构建一个代表 Pump.fun 代币发行的未签名交易。
  6. 代理使用其私钥在本地签署交易,并将签署后的有效载荷提交至区块链。

SolPaw 配置指南

要将 SolPaw 与您的 Openclaw 技能集成,请先配置环境变量:

export SOLPAW_API_KEY="your_key"
export SOLPAW_CREATOR_WALLET="your_public_key"
export SOLANA_PRIVATE_KEY="your_base58_private_key"

注册您的代理以接收 API 凭据:

curl -s -X POST https://api.solpaw.fun/api/v1/agents/register r
  -H "Content-Type: application/json" r
  -d '{"agent_name":"MyAgent","default_fee_wallet":"YOUR_WALLET_ADDRESS"}'

SolPaw 数据架构与分类体系

SolPaw 使用结构化 API 响应和元数据分类来组织启动数据:

字段 描述
image_id 上传到 IPFS 的代币 Logo 的唯一标识符。
csrf_token 有效期为 30 分钟的一次性安全令牌。
launch_fee_signature 确认支付平台费用的链上交易哈希。
mint 新创建代币的唯一 Solana 地址。
pumpfun_url Pump.fun 平台上代币列表的直接链接。
name: solpaw
description: Launch Solana tokens on Pump.fun via the SolPaw platform. 0.1 SOL one-time fee. Your wallet is the onchain creator.
homepage: https://solpaw.fun
user-invocable: true
disable-model-invocation: false
command-dispatch: tool
command-tool: exec
command-arg-mode: raw
metadata: {"openclaw": {"emoji": "??", "requires": {"bins": ["curl"], "env": ["SOLPAW_API_KEY", "SOLPAW_CREATOR_WALLET", "SOLANA_PRIVATE_KEY"], "config": []}, "primaryEnv": "SOLPAW_API_KEY", "install": []}}

SolPaw — Launch Tokens on Solana via Pump.fun

When to use

Use this skill when the agent needs to:

  • Launch a new memecoin / token on Solana via Pump.fun
  • Deploy a token with a name, symbol, description, and image
  • Create a Pump.fun token listing for a community, project, or meme

Overview

SolPaw is the first Solana token-launch platform for autonomous agents. It handles IPFS metadata uploads, transaction building, and Pump.fun deployment.

  • Cost: 0.1 SOL one-time platform fee + ~0.02 SOL Pump.fun creation fee per launch
  • Creator: Your agent's wallet is the real onchain creator on Pump.fun
  • Limit: 1 launch per agent per 24 hours
  • Platform wallet: GosroTTvsbgc8FdqSdNtrmWxGbZp2ShH5NP5pK1yAR4K
  • Docs: https://solpaw.fun

Prerequisites

  1. A Solana wallet with at least 0.15 SOL (0.1 platform fee + ~0.02 Pump.fun fee + gas)
  2. A SolPaw API key (register at the API)
  3. Environment variables set:
    • SOLPAW_API_KEY — your SolPaw API key
    • SOLPAW_CREATOR_WALLET — your Solana wallet public key
    • SOLANA_PRIVATE_KEY — your wallet private key (base58 encoded, for signing)

Steps

Step 1: Register (one-time)

curl -s -X POST https://api.solpaw.fun/api/v1/agents/register r
  -H "Content-Type: application/json" r
  -d '{"agent_name":"MyAgent","default_fee_wallet":"YOUR_WALLET_ADDRESS"}' | jq .

Save the api_key from the response. It will NOT be shown again.

Step 2: Get a CSRF token

CSRF=$(curl -s -H "Authorization: Bearer $SOLPAW_API_KEY" r
  https://api.solpaw.fun/api/v1/agents/csrf | jq -r '.data.csrf_token')

Step 3: Send 0.1 SOL launch fee

Send 0.1 SOL (100,000,000 lamports) to the platform wallet: GosroTTvsbgc8FdqSdNtrmWxGbZp2ShH5NP5pK1yAR4K

Save the transaction signature.

IMAGE_ID=$(curl -s -X POST https://api.solpaw.fun/api/v1/tokens/upload-image r
  -H "Authorization: Bearer $SOLPAW_API_KEY" r
  -F "file=@token-logo.png" | jq -r '.data.image_id')

Step 5: Launch token (Local Mode — your wallet is the creator)

# Build unsigned transaction
TX_DATA=$(curl -s -X POST https://api.solpaw.fun/api/v1/tokens/launch-local r
  -H "Content-Type: application/json" r
  -H "Authorization: Bearer $SOLPAW_API_KEY" r
  -d '{
    "name": "MyCoolToken",
    "symbol": "MCT",
    "description": "An awesome token launched by an AI agent on SolPaw",
    "creator_wallet": "'$SOLPAW_CREATOR_WALLET'",
    "signer_public_key": "'$SOLPAW_CREATOR_WALLET'",
    "launch_fee_signature": "YOUR_FEE_TX_SIGNATURE",
    "image_id": "'$IMAGE_ID'",
    "initial_buy_sol": 0,
    "slippage": 10,
    "priority_fee": 0.0005,
    "csrf_token": "'$CSRF'"
  }')

# Sign the transaction with your private key, then submit
SIGNED_TX="..." # sign the base64 transaction from TX_DATA
curl -s -X POST https://api.solpaw.fun/api/v1/tokens/submit r
  -H "Content-Type: application/json" r
  -H "Authorization: Bearer $SOLPAW_API_KEY" r
  -d '{"signed_transaction": "'$SIGNED_TX'", "mint": "MINT_FROM_TX_DATA"}'

Using the TypeScript SDK (Easier)

import SolPawSkill from './solpaw-skill';
import { Keypair } from '@solana/web3.js';

const solpaw = new SolPawSkill({
  apiEndpoint: 'https://api.solpaw.fun/api/v1',
  apiKey: process.env.SOLPAW_API_KEY,
  defaultCreatorWallet: process.env.SOLPAW_CREATOR_WALLET,
});

const keypair = Keypair.fromSecretKey(bs58.decode(process.env.SOLANA_PRIVATE_KEY));

// One-call launch: pays fee + uploads + signs + submits
const result = await solpaw.payAndLaunch({
  name: 'MyCoolToken',
  symbol: 'MCT',
  description: 'Launched by an AI agent on SolPaw',
  image_url: 'https://example.com/logo.png',
  initial_buy_sol: 0.5,
}, keypair);

console.log(result.pumpfun_url); // https://pump.fun/coin/...

Constraints

  • DO NOT launch tokens without user approval — always confirm name, symbol, and description first
  • DO NOT launch more than 1 token per 24 hours (enforced server-side)
  • DO NOT include offensive or misleading token names/descriptions
  • ALWAYS include a token image — tokens without images perform poorly on Pump.fun
  • ALWAYS use Local Mode (pass signer_keypair) so the agent's wallet is the onchain creator
  • The 0.1 SOL platform fee is non-refundable once the launch succeeds
  • CSRF tokens expire after 30 minutes and are single-use
  • Image uploads expire after 30 minutes

Examples

Successful launch

Agent: I'll launch the DOGE2 token on Pump.fun for you.
> Uploading token image...
> Paying 0.1 SOL launch fee...
> Building transaction...
> Signing and submitting...
> Token launched successfully!
> Pump.fun: https://pump.fun/coin/So1...
> Mint: So1...
> Your wallet is the onchain creator.

Error: insufficient balance

Agent: Your wallet only has 0.05 SOL. You need at least 0.15 SOL to launch:
- 0.1 SOL platform fee
- ~0.02 SOL Pump.fun creation fee
- ~0.01 SOL for gas