{"uid":"cap_b2d0C15Ca7VxTG9YzZR5I","slug":"agent402-tools-image-resize-ae3fecb1","name":"agent402.tools Image Resize","description":"Resize an image to given pixel dimensions. Send a base64 PNG/JPEG/BMP and width and/or height (give one to scale proportionally). Returns the resized image. Deterministic, no network.","url":"https://agent402.tools/api/image-resize","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"image":{"type":"string","description":"base64 image (PNG/JPEG/BMP), optionally a data: URL"},"width":{"type":"number","description":"target width in px (1-4096)"},"format":{"type":"string","description":"output format: png (default), jpeg, bmp"},"height":{"type":"number","description":"target height in px (1-4096)"}}},"responseSchema":{"type":"json","example":{"__note":"returns the resized image as binary (Content-Type set accordingly)"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","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.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_J396Kr9-OiTlCvf8ar2xb","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Resizes a base64-encoded PNG, JPEG, or BMP image to specified pixel dimensions, with optional proportional scaling and output format selection","exampleAgentPrompt":"Resize this image to 800 pixels wide and 600 pixels tall and return it as a JPEG — here's the base64-encoded PNG: [base64data].","exampleUseCases":null,"resultDescription":"Returns the resized image as a base64-encoded string in the requested format (PNG by default, JPEG or BMP if specified), scaled to the exact width and height provided, or proportionally scaled if only one dimension is given.","failureModes":["Invalid or malformed base64 image data returns an error","Width or height outside 1-4096 px range rejected","Unsupported image format (non-PNG/JPEG/BMP) may fail to decode","Missing both width and height with no default behavior may return error","Overly large source images may exceed payload or processing limits"],"whenToPreferThis":"Choose this endpoint when you need deterministic, serverless image resizing without sending images to a third-party cloud service. Ideal for proportional scaling, exact-dimension resizing, or format conversion of PNG/JPEG/BMP images in an automated pipeline. Prefer over cloud image APIs when privacy, determinism, or avoiding network round-trips to external storage matters.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":1,"lastUsedAt":"2026-07-07T21:18:32.246Z","lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:50:09.925Z","isFirstParty":false}