{"uid":"cap_vpb9PWq9o-h7l93JcEd9H","slug":"fretchen-ai-image-generation-nft-minting-service-ad15a515","name":"Fretchen AI Image Generation & NFT Minting Service","description":"AI-powered image generation with NFT minting on Optimism/Base, paid via x402 USDC.","url":"https://imagegen-agent.fretchen.eu/","method":"POST","headers":{},"bodySchema":{"type":"object","required":["prompt","tokenId"],"properties":{"mode":{"enum":["generate","edit"],"type":"string","description":"generate: create new image, edit: modify existing image"},"size":{"enum":["1024x1024","1792x1024"],"type":"string","description":"Output image dimensions"},"prompt":{"type":"string","description":"The text prompt for AI image generation"},"tokenId":{"type":"integer","description":"The NFT token ID to update"},"referenceImage":{"type":"string","description":"Base64-encoded reference image (required for edit mode)"}}},"responseSchema":{"type":"object","properties":{"image_url":{"type":"string","format":"uri","description":"URL to the generated image"},"metadata_url":{"type":"string","format":"uri","description":"URL to the NFT metadata JSON"},"transaction_hash":{"type":"string","description":"Mint transaction hash on-chain"}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.07","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"registry","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.07/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.07","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.07","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_6Xx20F15NelAo6JtdjI1A","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.07","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Generates AI images from text prompts (or edits existing images) and mints them as NFTs on Optimism/Base, paid via x402 USDC.","exampleAgentPrompt":"Generate a new AI image of 'a cyberpunk fox under neon lights at night' in 1024x1024 size and mint it as NFT token ID 42 on Fretchen.","exampleUseCases":[{"title":"Mint original AI artwork as NFT","prompt":"Generate an AI image of 'a serene Japanese garden at sunset with cherry blossoms reflecting in a koi pond' at 512x512 and mint it as NFT token ID 7."},{"title":"Edit existing NFT with new AI image","prompt":"I have NFT token ID 15 — can you update it with an edited version that adds dramatic storm clouds to the background? Here's the reference image in base64."},{"title":"Automated AI art NFT collection drop","prompt":"Create a new AI-generated image of 'a glowing geometric dragon on a dark void background' in 1024x1024 and publish it as NFT token ID 101 on-chain."}],"resultDescription":"Returns a JSON object containing a URL to the generated image, a URL to the NFT metadata JSON, and the on-chain transaction hash confirming the mint on Optimism/Base.","failureModes":["Invalid or missing prompt — returns error indicating prompt is required","Missing tokenId — returns validation error as tokenId is required","Insufficient USDC payment via x402 — payment not accepted, request rejected","Edit mode requested without referenceImage — returns error that base64 reference image is required","Invalid base64 referenceImage — image decoding failure","Unsupported size parameter — may return error or default to a supported dimension","On-chain transaction failure — mint may fail due to network congestion or contract error, no transaction_hash returned","Rate limiting or service unavailability — HTTP 429 or 503"],"whenToPreferThis":"Choose this endpoint when you need to both generate an AI image AND mint it as an NFT on Optimism or Base in a single call, especially in Web3 or blockchain-native agent workflows where payment via x402 USDC is already supported. It is uniquely suited for scenarios requiring on-chain provenance of AI-generated art, NFT collection management, or automated minting pipelines. If you only need image generation without NFT minting, a standard image generation API would be simpler and cheaper.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T18:36:51.908Z","isFirstParty":false}