{"uid":"cap_8hNFkavmXw1aTdDwg4V5T","slug":"fastapi-online-image-compress-95c82c41","name":"fastapi.online — Image Compress","description":"Chat, embeddings, OCR, speech-to-text, image editing, image understanding (captioning/Q&amp;A), text-to-speech, translation, writing tools, classification tools, developer tools, local utilities, format/checksum validators, encoding &amp; crypto utilities, date/time calculators, geo/coordinate math, math &amp; finance calculators, novelty tools, and business/social writing generators — 179 endpoints in all, across multiple specialized self-hosted models. Pay per call with crypto — no signup — or get an API key.","url":"https://api.fastapi.online/image-compress","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"file":{"type":"string","format":"binary","description":"Image file (PNG/JPEG/WebP)"},"format":{"type":"string"},"quality":{"type":"string"}}},"responseSchema":null,"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_UT5IyHdPflnFDjRjcUkOE","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":"Compresses an image file (PNG, JPEG, or WebP) with configurable output format and quality, returning a smaller image file.","exampleAgentPrompt":"Can you compress this JPEG image to reduce its file size? Use JPEG format with quality set to 75 so it loads faster on the web.","exampleUseCases":[{"title":"Web asset optimization before deployment","prompt":"Take this PNG screenshot I uploaded and compress it down using WebP format at quality 80 — I need it to load quickly on the site."},{"title":"Email attachment size reduction","prompt":"This photo is too large to email — can you compress it as a JPEG at quality 60 so it fits within the attachment limit?"},{"title":"Mobile app image pipeline compression","prompt":"I need to compress this JPEG image with quality set to 85 and keep it as JPEG — it's going into my mobile app and needs to be lightweight."}],"resultDescription":"A compressed image file returned as binary data, in the requested output format (PNG, JPEG, or WebP) and at the specified quality level, with a reduced file size compared to the original.","failureModes":["Unsupported file format (non-PNG/JPEG/WebP input) returns an error","Invalid quality value outside accepted range returns a validation error","Missing or malformed file binary returns a 400 bad request","Payment not included or insufficient triggers a 402 Payment Required response","Server-side model or processing failure returns a 500 error"],"whenToPreferThis":"Choose this endpoint when you need a simple, per-call, no-signup image compression API that accepts PNG, JPEG, or WebP and supports configurable output format and quality. It is ideal for agents that want to pay per use with crypto (USDC via x402) rather than maintain a subscription. Prefer it for lightweight, one-off compression tasks in automated pipelines where cost transparency per call matters.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:51:30.694Z","isFirstParty":false}