npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@imageapiai/mcp

v1.1.0

Published

Official Model Context Protocol (MCP) Server for ImageAPI AI (imageapiai.com)

Readme

ImageAPI AI MCP Server (@imageapiai/mcp)

Official Model Context Protocol (MCP) server for ImageAPI AI. Connects AI coding assistants and agents (such as Cursor, Claude Desktop, and Windsurf) to generate high-resolution images, refine prompts for 0 credits, and inspect account credits directly within your development workflows and chat sessions.

⚡ Quick Start

1. Claude Desktop Setup

Add the following to your claude_desktop_config.json:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json


{
  "mcpServers": {
    "imageapiai": {
      "command": "npx",
      "args": ["-y", "@imageapiai/mcp"],
      "env": {
        "IMAGEAPIAI_API_KEY": "sk_live_YOUR_API_KEY_HERE"
      }
    }
  }
}

2. Cursor IDE Setup

Add to your project root under .cursor/mcp.json (or globally in ~/.cursor/mcp.json):


{
  "mcpServers": {
    "imageapiai": {
      "command": "npx",
      "args": ["-y", "@imageapiai/mcp"],
      "env": {
        "IMAGEAPIAI_API_KEY": "sk_live_YOUR_API_KEY_HERE"
      }
    }
  }
}

3. Windsurf Setup

Add to ~/.codeium/windsurf/mcp_config.json:


{
  "mcpServers": {
    "imageapiai": {
      "command": "npx",
      "args": ["-y", "@imageapiai/mcp"],
      "env": {
        "IMAGEAPIAI_API_KEY": "sk_live_YOUR_API_KEY_HERE"
      }
    }
  }
}

🛠️ Available MCP Tools

Once installed, your AI agent has native access to the following 4 tools:

1. generate_image

Generates a new AI image from scratch based on a primary text prompt. Deducts standard credits from your account balance.

  • Parameters:

  • prompt (string, required): Primary text prompt describing the image to generate.

  • width (number, optional, default: 512): Width in pixels (min: 256, max: 2048).

  • height (number, optional, default: 512): Height in pixels (min: 256, max: 2048).

  • quality (string, optional, default: "medium"): Inference quality preset ("low", "medium", "high").

  • Example Prompt to AI:"Generate a 1024x1024 high quality cyberpunk city street in the rain."

  • Output: Returns JSON containing image_url, prompt_id, credits_remaining, and credits_deducted.

2. refine_image

Refines an existing image by appending modifications to the original prompt. Allows up to 5 free retries per generation ID for 0 credits.

  • Parameters:

  • parent_prompt_id (string, required): The prompt_id or generation_id of the original base image.

  • prompt_update (string, required): Additions or modifications to append to the base prompt.

  • quality (string, optional, default: "medium"): Optional quality level override ("low", "medium", "high").

  • Example Prompt to AI:"Take image gen_a1b2c3d4e5f6 and refine it: add golden neon reflections on the ground."

  • Output: Returns JSON containing the updated image_url, retries_remaining, and effective_prompt.

3. get_profile

Fetches user account details, current subscription status, and remaining monthly and purchased credit balance.

  • Parameters: None

  • Example Prompt to AI:"Check how many ImageAPI credits I have left."

  • Output: Returns JSON with email, credit_balance, monthly_credits, purchased_credits, and subscription_status.

4. get_history

Retrieves a list of recent historical image generations and their CDN asset URLs associated with the authenticated account.

  • Parameters: None

  • Example Prompt to AI:"List my latest 5 generated images from ImageAPI."

  • Output: Returns an array of historical image objects containing generation_id, original_prompt, prompt_text, r2_image_url, and retry_number.

🔑 Environment Variables

| Variable | Description | | ------------------------------ | ---------------------------------------------------------------------------------------------------------------- | | IMAGEAPIAI_API_KEY | Your secret API key (sk_live_...). Obtainable from imageapiai.com/dashboard. | | IMAGEAPI_API_KEY | Supported alias fallback. | | NEXT_PUBLIC_IMAGEAPIAI_API_KEY | Supported frontend/Next.js environment fallback. | 🔗 Resources

📄 License

MIT © ImageAPI AI