Skip to main content
Glama

NFT Pipeline MCP Server

Complete pre-blockchain NFT preparation workflow. Handles the entire asset pipeline from AI image generation through IPFS storage to metadata creation, providing ready-to-mint NFT packages for any blockchain.

Features

šŸŽØ AI Image Generation

  • Pollinations.ai (no API key required)

  • FLUX.1 Schnell via Replicate

  • Stable Diffusion via Hugging Face

  • Playground AI

  • Multiple art styles: realistic, artistic, cartoon, fantasy, cyberpunk, minimalist

šŸ“¦ IPFS Storage

  • Pinata (1GB free tier - V3 API with JWT authentication)

  • NFT.Storage (100% free for NFTs)

  • Web3.Storage (free tier)

  • Automatic metadata creation

  • Public-by-default uploads

šŸš€ One-Stop NFT Preparation

  • Generate image → Upload to IPFS → Create metadata → Upload metadata

  • Returns ready-to-use metadata CID for minting

  • Works with any blockchain

Related MCP server: Uranium MCP Server

Quick Start

Installation

cd servers/testnet/nft-pipeline-mcp-server
npm install
npm run build

Configuration

For Claude Desktop, configure in .mcp.json (see below). The .env.example file shows available environment variables for reference.

Usage with Claude Desktop

Add to .mcp.json in your project root:

{
  "mcpServers": {
    "nft-pipeline": {
      "command": "node",
      "args": [
        "/path/to/servers/testnet/nft-pipeline-mcp-server/dist/index.js"
      ],
      "env": {
        "IPFS_SERVICE": "pinata",
        "PINATA_API_KEY": "your_pinata_jwt_secret_here"
      }
    }
  }
}

Important:

Available Tools

1. nft_pipeline_generate_image

Generate AI images for NFTs

{
  prompt: "Epic dragon in cyberpunk city",
  style: "cyberpunk",
  aspectRatio: "1:1",
  quality: "high"
}

2. nft_pipeline_upload_to_ipfs

Upload images to IPFS

{
  imageUrl: "https://example.com/image.png",
  service: "pinata"
}

3. nft_pipeline_create_metadata

Create and upload NFT metadata

{
  name: "Dragon #1",
  description: "Epic cyberpunk dragon",
  imageHash: "QmXxx...",
  attributes: [
    { trait_type: "Type", value: "Dragon" },
    { trait_type: "Rarity", value: "Legendary" }
  ]
}

4. nft_pipeline_build_complete ⭐ Recommended

Complete NFT preparation pipeline in one call

{
  prompt: "Epic dragon in cyberpunk city",
  style: "cyberpunk",
  name: "Dragon #1",
  description: "Epic cyberpunk dragon",
  attributes: [
    { trait_type: "Type", value: "Dragon" }
  ]
}

Returns:

{
  "success": true,
  "imageCid": "QmXxx...",
  "metadataCid": "QmYyy...",
  "imageUrl": "https://gateway.pinata.cloud/ipfs/QmXxx...",
  "metadataUrl": "https://gateway.pinata.cloud/ipfs/QmYyy...",
  "ipfsMetadataUrl": "ipfs://QmYyy..."
}

Using with Blockchain MCPs

Example: XRP NFT Minting

// Step 1: Create NFT package
const package = await nft_pipeline_build_complete({
  prompt: "Space cat warrior",
  name: "Space Cat #1",
  description: "Epic space adventure"
});

// Step 2: Mint on XRP
await xrp_mint_nft({
  privateKey: "...",
  uri: package.ipfsMetadataUrl  // Use metadata CID
});

Example: Ethereum NFT Minting

// Step 1: Create NFT package
const package = await nft_pipeline_build_complete({
  imageUrl: "https://mysite.com/art.png",
  name: "My Art #1",
  description: "Digital masterpiece"
});

// Step 2: Mint on Ethereum
await eth_mint_nft({
  contractAddress: "0x...",
  tokenURI: package.ipfsMetadataUrl
});

Environment Variables

Required (choose one IPFS service)

Pinata (V3 API with JWT):

# Get JWT Secret from https://app.pinata.cloud/developers/api-keys
# Click "New Key" → Copy the JWT Secret (NOT the 12-digit API Key)
# Required permissions: "Files" Write (or Admin for all features)
PINATA_API_KEY=your_pinata_jwt_secret_here
# Note: PINATA_SECRET_KEY is no longer needed with V3 API

NFT.Storage:

NFT_STORAGE_API_KEY=xxx

Web3.Storage:

WEB3_STORAGE_API_KEY=xxx

Optional (Image Generation)

# Pollinations.ai works by default (no key needed)

# Optional enhanced services:
FLUX_API_KEY=xxx              # Replicate.com API key
FLUX_MODEL_VERSION=xxx        # Optional: specific FLUX model version
HUGGINGFACE_API_KEY=xxx       # Hugging Face API key
PLAYGROUND_API_KEY=xxx        # Playground AI API key

Development

# Development mode
npm run dev

# Build
npm run build

# Run tests
npm test

# MCP Inspector
npm run inspect

Architecture

nft-pipeline-mcp-server/
ā”œā”€ā”€ src/
│   ā”œā”€ā”€ tools/
│   │   ā”œā”€ā”€ image/          # Image generation tools
│   │   ā”œā”€ā”€ ipfs/           # IPFS upload tools
│   │   └── combined/       # Complete pipeline tools
│   ā”œā”€ā”€ utils/
│   │   ā”œā”€ā”€ ai-image-generation.ts
│   │   └── ipfs-nft-tool.ts
│   └── index.ts
└── tests/

API Changes & Migration

Pinata V3 Migration (Important)

The server now uses Pinata's V3 API which requires JWT authentication:

  1. Old format (deprecated):

    • Used PINATA_API_KEY + PINATA_SECRET_KEY pair

    • Endpoint: https://api.pinata.cloud/pinning/pinFileToIPFS

  2. New format (current):

    • Uses JWT token only in PINATA_API_KEY

    • Endpoint: https://uploads.pinata.cloud/v3/files

    • Response structure: CID is at response.data.data.cid

Getting a Pinata JWT Secret

  1. Go to https://app.pinata.cloud/developers/api-keys

  2. Click "New Key"

  3. Enable "Files" with Write permission (or Admin for all features)

  4. Copy the JWT Secret (the long token, NOT the 12-digit API Key)

  5. Use this JWT Secret as your PINATA_API_KEY

Note: The confusing naming is due to backward compatibility. Pinata shows:

  • API Key: 12-digit identifier (we don't use this)

  • JWT Secret: Long JWT token (this is what we need)

Why Separate Server?

Benefits:

  • āœ… Write image/IPFS logic once, use everywhere

  • āœ… All blockchain MCPs can use same service

  • āœ… Easy to add new generators/storage providers

  • āœ… Users configure API keys once

  • āœ… Follows MCP composability principles

License

MIT

Contributing

This is part of the Blockchain MCP Ecosystem. Contributions welcome!

Available Tools

4 tools
nft_pipeline_build_completeB

Complete NFT preparation pipeline: generate/upload image, create metadata, upload to IPFS. Full workflow solution.

Inputs: name (required), description (required), style, prompt, +9 more.

nft_pipeline_create_metadataC

Create NFT metadata JSON and upload to IPFS

Inputs: name (required), imageHash (required), description (required), apiKey, +4 more.

nft_pipeline_generate_imageB

Generate AI image for NFT using free APIs (Pollinations.ai, FLUX.1, Stable Diffusion)

Inputs: prompt (required), seed, model, style, +2 more.

nft_pipeline_upload_to_ipfsC

Upload image to IPFS using Pinata, NFT.Storage, or Web3.Storage

Inputs: apiKey, service, fileName, imageUrl, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 4 tools

    Disambiguation4/5

    The three step tools are clearly distinct: image generation, IPFS upload, and metadata creation. The only ambiguity is nft_pipeline_build_complete, which overlaps with all three by orchestrating the full workflow, so an agent must decide between using the aggregate tool or individual steps.

    Naming Consistency5/5

    All tool names use the same nft_pipeline_ prefix and consistent snake_case verb/object phrasing. The convention is predictable and easy to scan.

    Tool Count5/5

    Four tools is well-scoped for a focused NFT preparation pipeline: three granular operations plus one end-to-end workflow tool. Each tool has a clear role.

    Completeness4/5

    The surface covers the core pipeline: generate an image, upload to IPFS, create metadata, and run the full workflow. Minor gaps include no explicit validation or retrieval/inspection of uploaded assets, but the stated preparation lifecycle is mostly covered.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers