pump-fee-system

pump-fee-system is a skill for Claude Code, Codex from x402agent/solana-clawd. It costs 39 tokens per session (782 once invoked), scanned A, original, MIT.

A fee-calculation system for the Pump protocol, including market-cap-based fee tiers, protocol fees, creator fees, liquidity-provider fees, and rounding rules. Basis points are a way to express percentages precisely, where 100 basis points equal 1%.

In plain words
What is it for?
Use it to calculate tiered fees, split fees between protocol and creators, support graduated tokens, and handle small amounts without losing rounding dust.
Why use it?
It keeps fee amounts and recipients consistent across buys, sells, bonding curves, and AMM pools.

Skill for Claude CodeCodex

Which agent this was written for is unclear — built for openclaw. Also seen: built for openclaw.

Good fit Use it to calculate tiered fees, split fees between protocol and creators, support graduated tokens, and handle small amounts without losing rounding dust.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/x402agent/solana-clawd/pump-fee-system
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add x402agent/solana-clawd --skill pump-fee-system
Clone the repo
git clone --depth 1 https://github.com/x402agent/solana-clawd

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pump-fee-system

README.md
[![agentmods](https://agentmods.dev/badge/skills/x402agent/solana-clawd/pump-fee-system/github.svg)](https://agentmods.dev/skills/x402agent/solana-clawd/pump-fee-system)
Your own site
<a href="https://agentmods.dev/skills/x402agent/solana-clawd/pump-fee-system"><img src="https://agentmods.dev/badge/skills/x402agent/solana-clawd/pump-fee-system/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for pump-fee-system

Your own site · 80×15
<a href="https://agentmods.dev/skills/x402agent/solana-clawd/pump-fee-system"><img src="https://agentmods.dev/badge/skills/x402agent/solana-clawd/pump-fee-system.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 39 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 782 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00039 $0.00782
Opus 5 $0.00019 $0.00391
Sonnet 5 $0.00008 $0.00156
Haiku 4.5 $0.00004 $0.00078

Measured 7d ago against content hash f4599499a34e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

pump-fee-system scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/skills/pump-fee-system/SKILL.md · 85 lines

How it starts

The opening of the file, as written. The whole thing — 85 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Fee System — Tiered Fees, Creator Fees & Protocol Fees

Implement and extend the Pump protocol's fee system: tiered protocol fees based on market cap, creator fee collection across two programs, and fee computation with ceiling division.

Context

The Pump protocol charges fees on every buy/sell transaction. Fees flow to protocol fee recipients and token creators. The fee system spans three programs and must handle tokens in both bonding curve and graduated (AMM) states.

Fee Types

Fee Recipient When Charged
Protocol fee feeRecipients[] in Global Every buy/sell
Creator fee Token creator's vault PDA Every buy/sell (if creator is set)
LP fee Liquidity providers (AMM only) Post-graduation trades

Tiered Fee Calculation

When a FeeConfig exists, fees are market-cap-dependent:

function calculateFeeTier({ feeTiers, marketCap }): Fees {
  // Iterate tiers in REVERSE order
  for (let i = feeTiers.length - 1; i >= 0; i--) {
    if (marketCap >= feeTiers[i].marketCapLamportsThreshold) {
      return feeTiers[i].fees;
    }
  }
  return feeTiers[0].fees; // fallback to lowest tier
}

Fee Computation

function getFee({ global, feeConfig, mintSupply, bondingCurve, amount }): BN {
  const { protocolFeeBps, creatorFeeBps } = computeFeesBps(...);
  const protocolFee = ceilDiv(amount * protocolFeeBps, 10000);
  const creatorFee = hasCreator ? ceilDiv(amount * creatorFeeBps, 10000) : 0;
  return protocolFee + creatorFee;
}

Creator Vault Balance

Creator fees accumulate in PDAs:

  • creatorVaultPda(creator) — Pump program vault
  • ammCreatorVaultPda(creator) — PumpAMM program vault

Balance = total lamports - rent exemption minimum.

Error Classes

Error Condition
NoShareholdersError Empty shareholders array
TooManyShareholdersError More than 10 shareholders
ZeroShareError Shareholder has shareBps <= 0
InvalidShareTotalError Shares don't sum to 10,000 bps
DuplicateShareholderError Duplicate addresses

Read the full file on GitHub · 85 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 85 lines · 39 tokens per session scan A f4599499a34e

Subscribe to this mod's changes

pump-fee-system is a skill published in the GitHub repository x402agent/solana-clawd (24 stars, last pushed 3mo ago), licensed MIT. It adds 39 tokens to every session and 782 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.