{"uid":"cap_Ir0f_XeXqes0d-0-Xph2G","slug":"tanod-docs-pdf-page-numbers-4c97b466","name":"Tanod Docs – PDF Page Numbers","description":"Documents: DOCX template fill, Office to PDF, any file to Markdown, PDF to Word, OCR, PDF pipeline.","url":"https://docs.tanod.dev/v1/pdf/page-numbers?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"url":{"anyOf":[{"type":"string","maxLength":2048,"minLength":1},{"type":"null"}],"default":null,"description":"Public http(s) URL of the PDF (at most 20 MB; private, internal and IP-literal hosts are refused); or use pdf_base64."},"font":{"enum":["helvetica","helvetica-bold","times","times-bold","courier","courier-bold"],"type":"string","default":"helvetica","description":"Built-in PDF font: helvetica (default), helvetica-bold, times, times-bold, courier or courier-bold."},"color":{"type":"string","default":"#000000","pattern":"^#[0-9a-fA-F]{6}$","description":"Text colour as #rrggbb (default #000000, black)."},"pages":{"anyOf":[{"type":"string","pattern":"^[0-9a-zA-Z ,\\-]+$","maxLength":200,"minLength":1},{"type":"null"}],"default":null,"description":"Pages to number (default all), e.g. 2- to skip a cover."},"format":{"type":"string","default":"{n} / {N}","maxLength":100,"minLength":1,"description":"{n} = this page's number, {N} = the last number."},"margin":{"type":"number","default":28,"maximum":144,"minimum":0,"description":"Points (1/72 in) from the page edge (0-144, default 28)."},"output":{"enum":["base64","url"],"type":"string","default":"base64","description":"base64 (default): the file comes back inline as base64. url: the file is stored for 24 hours and the reply carries a download link (url, expires_at, bytes, content_type, sha256) instead of the base64, which keeps the file out of your context window."},"opacity":{"type":"number","default":1,"maximum":1,"minimum":0.05,"description":"0.05 (faint) to 1 (opaque, default)."},"position":{"enum":["top-left","top-center","top-right","bottom-left","bottom-center","bottom-right"],"type":"string","default":"bottom-center","description":"top-left, top-center, top-right, bottom-left, bottom-center (default) or bottom-right."},"font_size":{"type":"number","default":10,"maximum":72,"minimum":4,"description":"Points (4-72, default 10)."},"pdf_base64":{"anyOf":[{"type":"string","maxLength":13398872,"minLength":1},{"type":"null"}],"default":null,"description":"The PDF as base64 (at most 10 MB decoded per request); or use url."},"start_number":{"type":"integer","default":1,"maximum":100000,"minimum":0,"description":"Number printed on the first numbered page."}}},"responseSchema":{"type":"json","example":{"file":{"name":"numbered.pdf","bytes":91519,"pages":6,"data_base64":"JVBERi0xLjcKJb/3... (trimmed: 122,028 base64 characters in the reply)","content_type":"application/pdf"},"operation":"page-numbers","input_bytes":140815,"input_pages":6,"last_number":6,"first_number":1,"output_bytes":91519,"numbered_pages":6,"untrusted_content":true,"active_content_removed":{"xfa":1,"javascript":1}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","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.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_PkgCmWivSjj1v1voXwIgg","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Adds customizable page number stamps to a PDF, with control over font, color, position, opacity, format, and page range.","exampleAgentPrompt":"Add page numbers to my PDF at https://example.com/report.pdf — put them at the bottom-center in helvetica-bold size 12, format '1 / 6', in dark gray (#333333), starting from page 2 to skip the cover, and give me back a download URL.","exampleUseCases":[{"title":"Paginate client report before delivery","prompt":"Take this PDF at https://storage.example.com/q3-report.pdf and add page numbers at the bottom-right in times font size 10, formatted as 'Page {n} of {N}', and return a download link I can send to the client."},{"title":"Skip cover page in academic paper","prompt":"Add page numbers to my paper PDF at https://files.example.com/thesis.pdf, but start numbering from page 2 so the cover is skipped — use bottom-center placement, helvetica font size 10, and give me the file back as base64."},{"title":"Faint subtle page stamps for internal draft","prompt":"I need subtle page numbers on this draft PDF at https://docs.example.com/draft.pdf — use bottom-left position, courier font, size 8, opacity 0.3, black color, and return a download URL valid for 24 hours."}],"resultDescription":"Returns a JSON object containing the numbered PDF either as inline base64 or a 24-hour download URL (with expiry, byte size, content type, and SHA-256 hash), plus metadata: operation name, input/output byte sizes, input/output page counts, first and last page numbers stamped, and a flag indicating whether untrusted active content (XFA, JavaScript) was stripped from the PDF.","failureModes":["PDF URL is unreachable, private, or IP-literal — returns error refusing the URL","PDF exceeds 20 MB size limit","Invalid color hex pattern (must be #rrggbb)","Invalid pages range string format","font_size or margin out of allowed range","opacity below 0.05 or above 1","PDF is corrupt or not a valid PDF file","Network timeout fetching remote PDF"],"whenToPreferThis":"Choose this endpoint when you need to add or customize page numbers on an existing PDF — especially when you need fine-grained control over font, color, position, opacity, format string (e.g. '2 / 10'), and page range (e.g. skipping a cover). It also sanitizes active content (JavaScript, XFA) from the PDF as a side benefit. Prefer it over general PDF editors when you want a lightweight, pay-per-call API that returns a clean numbered PDF without a full suite subscription.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-13T12:45:43.263Z","isFirstParty":false,"canonicalSlug":"tanod-docs-pdf-page-numbers-4c97b466"}