From ideogram-pack
Installs and configures Ideogram API authentication for AI image generation in Node.js and Python. Covers key retrieval, .env setup, HTTP client install, and verification scripts.
npx claudepluginhub jeremylongshore/claude-code-plugins-plus-skills --plugin ideogram-packThis skill is limited to using the following tools:
Set up Ideogram API authentication for AI image generation. Ideogram provides a REST API at `api.ideogram.ai` for text-to-image generation, editing, remixing, upscaling, and describing images. Authentication uses an `Api-Key` header on every request.
Provides TypeScript and Python patterns for Ideogram API: type-safe clients, retry logic, validation, multi-tenant support, image generation/description/download.
Expert guidance for Next.js Cache Components and Partial Prerendering (PPR). **PROACTIVE ACTIVATION**: Use this skill automatically when working in Next.js projects that have `cacheComponents: true` in their next.config.ts/next.config.js. When this config is detected, proactively apply Cache Components patterns and best practices to all React Server Component implementations. **DETECTION**: At the start of a session in a Next.js project, check for `cacheComponents: true` in next.config. If enabled, this skill's patterns should guide all component authoring, data fetching, and caching decisions. **USE CASES**: Implementing 'use cache' directive, configuring cache lifetimes with cacheLife(), tagging cached data with cacheTag(), invalidating caches with updateTag()/revalidateTag(), optimizing static vs dynamic content boundaries, debugging cache issues, and reviewing Cache Component implementations.
Guides building MCP servers enabling LLMs to interact with external services via tools. Covers best practices, TypeScript/Node (MCP SDK), Python (FastMCP).
Share bugs, ideas, or general feedback.
Set up Ideogram API authentication for AI image generation. Ideogram provides a REST API at api.ideogram.ai for text-to-image generation, editing, remixing, upscaling, and describing images. Authentication uses an Api-Key header on every request.
set -euo pipefail
# Node.js (no SDK required -- Ideogram uses a plain REST API)
npm install dotenv
# Python
pip install requests python-dotenv
# Create .env file (NEVER commit to git)
echo 'IDEOGRAM_API_KEY=your-api-key-here' >> .env
# Add to .gitignore
echo '.env' >> .gitignore
echo '.env.local' >> .gitignore
// verify-ideogram.ts
import "dotenv/config";
async function verifyIdeogramAuth() {
const response = await fetch("https://api.ideogram.ai/generate", {
method: "POST",
headers: {
"Api-Key": process.env.IDEOGRAM_API_KEY!,
"Content-Type": "application/json",
},
body: JSON.stringify({
image_request: {
prompt: "A simple blue circle on white background",
model: "V_2_TURBO",
aspect_ratio: "ASPECT_1_1",
magic_prompt_option: "OFF",
},
}),
});
if (response.ok) {
const result = await response.json();
console.log("Auth verified. Image URL:", result.data[0].url);
console.log("Seed:", result.data[0].seed);
} else {
const err = await response.text();
console.error(`Auth failed (${response.status}):`, err);
}
}
verifyIdeogramAuth();
# verify_ideogram.py
import os, requests
from dotenv import load_dotenv
load_dotenv()
response = requests.post(
"https://api.ideogram.ai/generate",
headers={
"Api-Key": os.environ["IDEOGRAM_API_KEY"],
"Content-Type": "application/json",
},
json={
"image_request": {
"prompt": "A simple blue circle on white background",
"model": "V_2_TURBO",
"aspect_ratio": "ASPECT_1_1",
"magic_prompt_option": "OFF",
}
},
)
if response.ok:
data = response.json()
print("Auth verified. Image URL:", data["data"][0]["url"])
else:
print(f"Auth failed ({response.status_code}):", response.text)
| API Version | Base URL | Notes |
|---|---|---|
| Legacy (V_2) | https://api.ideogram.ai/generate | JSON body with image_request wrapper |
| V3 Generate | https://api.ideogram.ai/v1/ideogram-v3/generate | Multipart form data |
| V3 Edit | https://api.ideogram.ai/v1/ideogram-v3/edit | Multipart form data |
| V3 Remix | https://api.ideogram.ai/v1/ideogram-v3/remix | Multipart form data |
| V3 Reframe | https://api.ideogram.ai/v1/ideogram-v3/reframe | Multipart form data |
| Upscale | https://api.ideogram.ai/upscale | Multipart form data |
| Describe | https://api.ideogram.ai/describe | Multipart form data |
partnership@ideogram.ai for higher limits| Error | HTTP Status | Cause | Solution |
|---|---|---|---|
| Invalid API Key | 401 | Key missing or revoked | Verify key in dashboard, regenerate if needed |
| Rate Limited | 429 | Exceeded 10 in-flight requests | Queue requests, add backoff |
| Insufficient Credits | 402 | Balance depleted | Top up via dashboard billing |
| Safety Rejected | 422 | Prompt or image failed safety check | Rephrase prompt, remove flagged content |
IDEOGRAM_API_KEY configured.env file with key (git-ignored)After successful auth, proceed to ideogram-hello-world for your first real generation.