{"uid":"cap_Tna-6iVGLZOkxqLm5can_","slug":"402utils-mime-type-detector-f7a4dded","name":"402utils MIME Type Detector","description":"Detect a file's true MIME type from its magic-number byte signature — not from a declared extension or Content-Type. Send the raw bytes (≤10 MB) as the body, or JSON { bytes: base64 }. Returns {mime, extension, confidence, description, category, executable}. Covers images, documents (incl. OOXML/OpenDocument), archives, audio/video, fonts and executables (which are flagged). Security check for file pipelines. Not a barcode/QR reader.","url":"https://402utils.com/v1/mime-detect","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"bytes":{"type":"string","description":"The file's raw bytes as base64 (alternative to sending them raw)."}}},"responseSchema":null,"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_3_QzgG6yGyYhRNl2lesYg","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":"Detects a file's true MIME type from its magic-number byte signature, returning type, extension, confidence, category, and executable flag","exampleAgentPrompt":"I just received an uploaded file with a .jpg extension but I'm not sure it's really an image — can you check its actual MIME type from the raw bytes and tell me if it's an executable or something dangerous?","exampleUseCases":null,"resultDescription":"Returns a JSON object with fields: mime (the detected MIME type string), extension (canonical file extension), confidence (detection confidence score), description (human-readable file type description), category (broad category such as image/document/archive), and executable (boolean flag indicating if the file is an executable, useful for security screening)","failureModes":["File exceeds 10 MB limit — request rejected","Unrecognized byte signature — low confidence or unknown MIME returned","Malformed base64 input — parse error","Empty body sent — no bytes to analyze","Network timeout for large files near the size limit"],"whenToPreferThis":"Use this endpoint when you need to determine a file's true type based on its actual binary content rather than trusting its declared extension or Content-Type header. Ideal for security-sensitive file upload pipelines, content validation, and detecting disguised executables. Covers a wide range of formats including images, OOXML/OpenDocument, archives, audio/video, fonts, and executables.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T19:02:09.902Z","isFirstParty":false}