{"uid":"cap_cn7PSz8g73jpEveqml29x","slug":"gif-header-parser-375e948a","name":"GIF Header Parser","description":"Read a GIF's version, width, height and global colour table size from its first 13 bytes.","url":"https://file-formats.x402tookit.com/gif-header?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["hex"],"properties":{"hex":{"type":"string","description":"First 13 or more bytes of the GIF as hex (up to 512 bytes)"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"asOf":{"type":["null","string"]},"width":{"type":["null","number"]},"height":{"type":["null","number"]},"sorted":{"type":["boolean","null"]},"source":{"type":["null","string"]},"reasons":{"type":["array","null"]},"summary":{"type":["null","string"]},"verdict":{"type":["null","string"]},"version":{"type":["null","string"]},"degraded":{"type":["boolean","null"]},"disclaimer":{"type":["null","string"]},"notChecked":{"type":["array","null"],"items":{"type":"string"}},"globalColors":{"type":["null","number"]},"bytesExamined":{"type":["null","number"]},"backgroundIndex":{"type":["null","number"]},"pixelAspectByte":{"type":["null","number"]},"globalColorTable":{"type":["boolean","null"]},"pixelAspectRatio":{},"colorResolutionBits":{"type":["null","number"]}}}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","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.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_zqCb4lj1m47hITfc08H0_","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Parses the first 13 bytes of a GIF file to extract version, dimensions, and global colour table metadata.","exampleAgentPrompt":"Can you read the header of this GIF and tell me its version, width, height, and global colour table info? Here are the first 13 bytes in hex: 47494638396180007000f70000.","exampleUseCases":[{"title":"Verify GIF dimensions before upload","prompt":"I have a GIF file and want to confirm its width and height before uploading it. Here are its first 13 bytes as hex: 47494638396180007000f70000 — can you parse the header and tell me the dimensions?"},{"title":"Identify GIF version in media pipeline","prompt":"I need to know if this GIF is GIF87a or GIF89a before processing it. The first 13 bytes in hex are 474946383961c800c800f70000 — can you extract the version from the header?"},{"title":"Audit GIF colour table in forensic review","prompt":"I'm reviewing a suspect GIF file and need to know its global colour table size and colour resolution bits. Here are the first 16 bytes in hex: 474946383961200020008700ff — can you break down the header fields?"}],"resultDescription":"Returns a structured object including GIF version (e.g. GIF87a or GIF89a), image width and height in pixels, whether a global colour table is present, number of global colours, colour resolution bits, background colour index, pixel aspect ratio byte, and the number of bytes examined. May also include a summary, verdict, reasons, and degraded/disclaimer flags if the input is incomplete or malformed.","failureModes":["Fewer than 13 hex bytes provided — returns null or partial fields","Invalid hex string causes parsing failure","Non-GIF magic bytes result in version/fields returning null","Truncated or corrupted header may set degraded flag and return partial data"],"whenToPreferThis":"Use this endpoint when you specifically need to extract structured metadata from the GIF file format header — version, dimensions, and colour table details — without fully decoding the image. Prefer this over generic file-type detection endpoints when you already know the file is a GIF and need its specific header fields. It is faster and cheaper than full image decoding libraries for header-only inspection tasks.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-30T00:30:45.883Z","isFirstParty":false,"canonicalSlug":"gif-header-parser-375e948a"}