{"uid":"cap_E6F4wb5CpS0yK4Cvwveao","slug":"tanod-imagepeek-image-crop-0df12632","name":"Tanod imagepeek Image Crop","description":"Crop an image to a box or aspect ratio. Use when an image must be cut to a box or to a given aspect ratio. Add output=url for a 24 h link.","url":"https://tanod.dev/v1/image/crop?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"top":{"type":["integer","null"],"default":null,"maximum":32768,"minimum":0},"url":{"type":["string","null"],"default":null,"maxLength":2048},"left":{"type":["integer","null"],"default":null,"maximum":32768,"minimum":0},"width":{"type":["integer","null"],"default":null,"maximum":32768,"minimum":1},"aspect":{"type":["string","null"],"default":null,"pattern":"^\\d{1,4}(\\.\\d{1,3})?:\\d{1,4}(\\.\\d{1,3})?$"},"format":{"anyOf":[{"enum":["png","jpeg","webp","gif","tiff","bmp","ico","avif"],"type":"string"},{"type":"null"}],"default":null},"height":{"type":["integer","null"],"default":null,"maximum":32768,"minimum":1},"output":{"enum":["base64","url"],"type":"string","default":"base64"},"gravity":{"enum":["center","north","south","east","west","northwest","northeast","southwest","southeast"],"type":"string","default":"center"},"quality":{"type":["integer","null"],"default":null,"maximum":100,"minimum":1},"auto_orient":{"type":"boolean","default":true},"image_base64":{"type":["string","null"],"default":null,"maxLength":13333464}}},"responseSchema":{"type":"json","example":{"box":{"top":60,"left":0,"width":640,"height":360},"bytes":104465,"input":{"bytes":161713,"width":640,"format":"jpeg","frames":1,"height":480,"animated":false,"has_alpha":false},"notes":[],"width":640,"format":"jpeg","height":360,"source":{"url":"https://python-pillow.org","library":"Pillow","license":"MIT-CMU (HPND)"},"final_url":"https://raw.githubusercontent.com/ianare/exif-samples/master/jpg/gps/DSCN0010.jpg","operation":"crop","source_url":"https://raw.githubusercontent.com/ianare/exif-samples/master/jpg/gps/DSCN0010.jpg","data_base64":"/9j/4AAQSkZJRgAB... (trimmed: 139,288 base64 characters in the reply)","content_type":"image/jpeg"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_rZmc0QEYkdOLNgbWFRMDC","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Crops an image to a specified pixel box or aspect ratio, with configurable gravity, format, and quality.","exampleAgentPrompt":"Crop this image (https://example.com/photo.jpg) to a 16:9 aspect ratio, keeping the center in frame, and return it as a JPEG at quality 85.","exampleUseCases":[{"title":"Square thumbnail for social media","prompt":"Take this product photo at https://example.com/product.png and crop it to a 1:1 square centered on the middle, output as JPEG at quality 90."},{"title":"Extract specific region from screenshot","prompt":"Crop the region starting at pixel 120 from the top and 80 from the left, 640 pixels wide and 360 pixels tall, from this screenshot: https://example.com/screenshot.png — give me back a PNG."},{"title":"Widescreen banner from portrait image","prompt":"I have this portrait image as base64 and I need it cropped to a 16:9 aspect ratio, pulling from the north edge, saved as webp at quality 80."}],"resultDescription":"Returns the cropped image as binary data in the requested output format (defaulting to the input format). The image is cropped either to the specified pixel box (top/left/width/height) or to the given aspect ratio using the selected gravity direction. EXIF orientation is applied first if auto_orient is enabled.","failureModes":["Image URL is not publicly accessible or exceeds 10 MB — returns an error","Both url and image_base64 are omitted — returns validation error","Crop box coordinates fall outside image bounds — may return error or clamp","Unsupported or corrupted image format — returns processing error","Invalid aspect ratio string format — returns schema validation error","Network timeout fetching remote image URL"],"whenToPreferThis":"Choose this endpoint when you need a simple, pay-per-call image crop operation without standing up your own image processing infrastructure. It supports both URL-based and base64 image input, aspect-ratio cropping with gravity control, and multiple output formats — making it more flexible than basic crop utilities for agent workflows that need to process images on the fly.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-28T06:44:53.290Z","isFirstParty":false,"canonicalSlug":"tanod-imagepeek-image-crop-0df12632"}