Pegpad
pegpad
RewardsChangelogAPI

Getting started

OverviewHow it works

Launch API

EndpointRequest bodyExample requestSign and submit

Reference

Quote tokensMetadata formatErrors

API reference

Launch tokens programmatically

Create a fixed-supply token with a one-sided, stablecoin-quoted market from your own code, signed with your own wallet.

Overview

The Pegpad launch API builds a Solana transaction that creates your token and its market. You sign it with your wallet and submit it to any RPC. Pegpad never holds your keys.

How it works

  1. Host a metadata JSON file (name, symbol, image, socials) at a public URL.
  2. POST the token details and your wallet address to the build endpoint.
  3. Receive a partially signed base64 transaction and the new mint address.
  4. Sign the transaction as fee payer and submit it to Solana.

Endpoint

POSThttps://pegpad.fun/api/launch/build

Request body

All fields are required and sent as JSON.

FieldTypeDescription
namestringToken name. Truncated to 28 characters on-chain.
symbolstringTicker symbol. Truncated to 8 characters on-chain.
uristringPublic URL to a hosted metadata JSON file.
quoteToken"USDC" | "USDT" | "USD1" | "JupUSD"The stablecoin the token trades against.
payerstringBase58 public key that signs and pays rent for the launch.

Example request

curl
curl -X POST https://pegpad.fun/api/launch/build \
  -H "content-type: application/json" \
  -d '{
    "name": "My Pegpad Meme",
    "symbol": "PGM",
    "uri": "https://your-cdn.com/metadata.json",
    "quoteToken": "USDC",
    "payer": "YourWalletPublicKeyBase58"
  }'

A successful response returns:

json
{
  "transaction": "<base64-encoded legacy transaction>",
  "mint": "Cu5...9pk",
  "config": "8Hb...2aa",
  "totalTokenSupply": "2000000",
  "lastValidBlockHeight": 301872455
}

Sign and submit

The returned transaction is a legacy Solana transaction with the config and mint keypairs already partially signed. Add the fee payer signature and send it.

typescript
import { Connection, Keypair, Transaction } from '@solana/web3.js'

const payer = Keypair.fromSecretKey(/* your secret key */)
const connection = new Connection('https://your-rpc-endpoint', 'confirmed')

// 1. Ask Pegpad to build the launch transaction.
const res = await fetch('https://pegpad.fun/api/launch/build', {
  method: 'POST',
  headers: { 'content-type': 'application/json' },
  body: JSON.stringify({
    name: 'My Pegpad Meme',
    symbol: 'PGM',
    uri: 'https://your-cdn.com/metadata.json',
    quoteToken: 'USDC',
    payer: payer.publicKey.toBase58(),
  }),
})

const { transaction, mint } = await res.json()

// 2. Add the fee payer signature and submit.
// The config + mint keypairs are already partially signed server-side.
const tx = Transaction.from(Buffer.from(transaction, 'base64'))
tx.partialSign(payer)

const signature = await connection.sendRawTransaction(tx.serialize())
await connection.confirmTransaction(signature, 'confirmed')

console.log('Launched', mint, 'tx', signature)

Quote tokens

A token trades against exactly one stablecoin, chosen at launch.

KeyNameMint
USDCUSD CoinEPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
USDTTetherEs9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB
USD1World Liberty USDUSD1ttGY1N17NEEHLmELoaybftRBUSErhqYiQzvEmuB
JupUSDJupiter USDJuprjznTrTSp2UFa3ZBUFgwdAmtZCq4MQCwysN55USD
USDGComing soonGlobal Dollar2u1tszSeqZ3qBWF3uNGPFc8TzMk2tdiwknnRMWGWjGWH
PYUSDComing soonPayPal USD2b1kV6DkPAnxd5ixfnxCpjxmKwqjjaYmCZfHsFu24GXo

Metadata format

The uri field must point to a publicly readable JSON file in the standard token metadata shape. Host it anywhere: your own CDN, IPFS, or Arweave.

metadata.json
{
  "name": "My Pegpad Meme",
  "symbol": "PGM",
  "description": "A stable memecoin launched on Pegpad.",
  "image": "https://your-cdn.com/logo.png",
  "extensions": {
    "twitter": "https://x.com/yourhandle",
    "telegram": "https://t.me/yourgroup",
    "website": "https://pegpad.fun/token/<mint>"
  }
}

Errors

Error responses return a JSON object with an error string.

StatusMeaning
400Invalid JSON body, a missing required field, or an unsupported quote token.
400Invalid payer address (not a valid base58 public key).
500Server RPC is not configured, or the transaction failed to build.

On this page

  • Overview
  • How it works
  • Endpoint
  • Request body
  • Example request
  • Sign and submit
  • Quote tokens
  • Metadata format
  • Errors
Pegpad

pegpad.fun - your meme. your dollar.

Twitter / XAPITermsPrivacy