{"uid":"cap_b-2N8Sg1pq4AUwrDndTa9","slug":"agentsvc-io-image-resize-api-869446d9","name":"agentsvc.io Image Resize API","description":"Resize, crop-fit and convert images (PNG, JPEG, WebP, AVIF, GIF, TIFF, SVG input) to webp, png, jpeg or avif. Auto-rotates by EXIF. Use to shrink screenshots before sending them to a vision model, create thumbnails, or convert formats. Params: image_base64 or image_url (one required), width, height (max 4096), fit (inside default | cover | contain | fill), format (webp default), quality (1-100, default 80).","url":"https://agentsvc.io/api/v1/proxy/image-resize?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"fit":{"enum":["inside","cover","contain","fill"],"type":"string","default":"inside"},"width":{"type":"integer","maximum":4096},"format":{"enum":["webp","png","jpeg","avif"],"type":"string","default":"webp"},"height":{"type":"integer","maximum":4096},"quality":{"type":"integer","default":80,"maximum":100,"minimum":1},"image_url":{"type":"string","format":"uri","description":"Public URL of the image (max 15 MB)"},"image_base64":{"type":"string","description":"Base64 image data (data: URI prefix allowed)"}}},"responseSchema":{"type":"json","example":{"data":{"width":320,"format":"webp","height":200,"original":{"width":1280,"format":"png","height":800,"size_bytes":214000},"size_bytes":6120,"image_base64":"UklGRiQAAABXRUJQVlA4..."},"success":true}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0045","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"1.00","reviews":0,"stars":null,"state":"rated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.0045/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0045","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0045","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_0W73bVlG3kH75t4y_Kto4","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0045","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Resizes and converts images to specified dimensions and formats (webp, png, jpeg, avif) with configurable quality and fit modes","exampleAgentPrompt":"Resize the image at https://example.com/photo.png to 800 pixels wide and 600 pixels tall, convert it to webp format at quality 85, fitting it inside those bounds.","exampleUseCases":[{"title":"Thumbnail generation for product catalog","prompt":"Take the product image at https://mystore.com/images/product123.jpg and resize it to 320 wide by 240 tall as a webp at quality 75, fitting it inside those dimensions — I need thumbnails for the catalog grid."},{"title":"Convert and compress large PNG for web","prompt":"I have a large PNG at https://cdn.mysite.com/hero-banner.png — can you convert it to avif format at 1200 by 630 pixels with quality 80? I want to cut down the file size for faster page loads."},{"title":"Normalize user-uploaded avatar to square","prompt":"Resize this base64-encoded user avatar image to exactly 256 by 256 pixels in jpeg format at quality 90, using cover fit so it fills the whole square without leaving empty space."}],"resultDescription":"Returns a JSON object containing the resized image as a base64-encoded string, along with the output width, height, format, and size in bytes, plus the original image's dimensions, format, and size for reference.","failureModes":["Image URL is not publicly accessible or returns a non-image response","Image exceeds the 15 MB size limit","Requested width or height exceeds the 4096-pixel maximum","Invalid or unsupported image format in the source file","Network timeout fetching the source image URL","Malformed base64 image data provided"],"whenToPreferThis":"Choose this endpoint when an AI agent needs to programmatically resize or reformat images on a per-call, pay-as-you-go basis without managing API keys or subscriptions. Particularly suited for agents handling user-uploaded content, generating thumbnails, or preparing images for specific display contexts. Supports both URL-based and base64 inputs, making it flexible for pipelines where the image is already in memory.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":1,"lastUsedAt":"2026-10-26T04:04:28.809Z","lastSuccessfullyRanAt":"2026-10-26T04:04:28.809Z","lastHealthCheckAt":"2026-12-01T06:49:12.635Z","isFirstParty":false,"canonicalSlug":"agentsvc-io-image-resize-api-869446d9"}