{"uid":"cap_C78BcgISLqLS1Hu5ACJHg","slug":"stability-ai-inpainting-via-locus-x402-beacfd1f","name":"Stability AI Inpainting via Locus x402","description":"Generative AI platform for images, 3D models, and audio — text-to-image, editing, upscaling, and more.","url":"https://stability-ai.x402.paywithlocus.com/stability-ai/inpaint","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"mask":{"type":"string"},"seed":{"type":"number"},"image":{"type":"string"},"prompt":{"type":"string"},"grow_mask":{"type":"number"},"output_format":{"type":"string"},"negative_prompt":{"type":"string"}}},"responseSchema":{"type":"json","example":{"data":{},"payment":{"scheme":"exact","settledUsdc":"0.001000","authorizedMaxUsdc":"0.001000"},"request":{"id":"00000000-0000-4000-8000-000000000000","statusUrl":"/requests/00000000-0000-4000-8000-000000000000"},"success":true}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.057","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","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.057/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.057","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.057","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_KoMTQVU6qAgnwEziaqbHO","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.057","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Fill or replace masked regions of an existing image using a text prompt with Stability AI's inpainting model.","exampleAgentPrompt":"Take this photo of a living room and use the mask I've drawn over the window to fill that area with a snowy mountain view outside — output as a PNG and exclude any curtains or blinds.","exampleUseCases":[{"title":"Remove unwanted object from photo","prompt":"I have a product photo but there's a power outlet visible on the wall behind it — here's the image and a mask over the outlet area. Fill it in with a plain white wall to match the surroundings, output as JPEG."},{"title":"Swap background behind portrait subject","prompt":"Take this portrait photo and replace the blurred office background using this mask — fill it with a lush green garden scene. Keep the output as PNG and exclude any indoor or artificial elements."},{"title":"Restore damaged section of artwork","prompt":"I have a scan of an old painting with a torn section — here's the image and the mask over the damaged area. Fill it in to match the artistic style of the rest of the painting, Baroque oil painting style, output as PNG."}],"resultDescription":"Returns a JSON object containing a 'data' field with the generated image result, a 'payment' object confirming the settled USDC amount, a 'request' object with a unique request ID and a status URL for polling, and a 'success' boolean.","failureModes":["Missing required 'image' or 'mask' field returns validation error","Mask and image dimensions mismatch causes generation failure","Invalid output_format value (not jpeg, png, or webp) returns bad request","Payment failure or insufficient USDC balance blocks the request","Overly complex or ambiguous prompt may produce poor fill quality","Seed value out of acceptable range causes parameter error"],"whenToPreferThis":"Choose this endpoint when you need to selectively edit, replace, or fill a specific region of an existing image guided by a text prompt. It is ideal for object removal, background swapping, region-specific style changes, or restoring damaged areas, as opposed to generating a brand-new image from scratch or upscaling an existing one. Use this over generic image generation when spatial control via a mask is required.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:30:15.601Z","isFirstParty":false}