{"uid":"cap_Tr667vmYKK2PR_VzFstTv","slug":"tanod-docs-pdf-rotate-cc19784f","name":"Tanod Docs PDF Rotate","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/rotate?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."},"angle":{"enum":[90,180,270,-90],"type":"integer","description":"Clockwise degrees, added to the current rotation."},"pages":{"anyOf":[{"type":"string","pattern":"^[0-9a-zA-Z ,\\-]+$","maxLength":200,"minLength":1},{"type":"null"}],"default":null,"description":"Pages to rotate (default all)."},"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."},"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."}}},"responseSchema":{"type":"json","example":{"file":{"name":"rotated.pdf","bytes":13202,"pages":1,"data_base64":"JVBERi0xLjQKJb/3... (trimmed: 17,604 base64 characters in the reply)","content_type":"application/pdf"},"angle":90,"operation":"rotate","input_bytes":13264,"input_pages":1,"output_bytes":13202,"rotated_pages":1,"untrusted_content":true,"active_content_removed":{}}},"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_v41FgfKFDM1DRskbEj0WU","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":"Rotates specified pages (or all pages) of a PDF by a given angle (90, 180, 270, or -90 degrees clockwise) and returns the result as base64 or a download URL.","exampleAgentPrompt":"Can you rotate all the pages of this PDF 90 degrees clockwise? Here's the file URL: https://example.com/myfile.pdf — please give me back the rotated version as a download link.","exampleUseCases":[{"title":"Fix sideways scanned document","prompt":"I scanned a contract and all the pages came out rotated 90 degrees sideways — can you rotate them back so they read correctly? Here's the PDF URL: https://storage.example.com/contract.pdf"},{"title":"Rotate specific pages for presentation","prompt":"I have a PDF report and pages 3, 5, and 7 are landscape but the rest are portrait. Can you rotate just those pages 270 degrees clockwise so everything is consistently portrait? The file is at https://files.example.com/report.pdf"},{"title":"Flip upside-down PDF inline","prompt":"This PDF came back upside down — rotate all its pages 180 degrees and send me back the base64 so I can embed it directly. Here's the base64 of the file."}],"resultDescription":"Returns a JSON object containing the rotated PDF either as inline base64 data (with filename, byte size, page count, and content type) or as a temporary 24-hour download URL (with expiry timestamp, byte size, content type, and SHA256 hash). Also includes metadata: the angle applied, operation name, input/output byte counts, number of rotated pages, and a flag indicating whether untrusted content was removed.","failureModes":["PDF URL exceeds 20 MB size limit — request rejected","base64-encoded PDF exceeds 10 MB decoded limit — request rejected","Private, internal, or IP-literal host URLs are refused","Invalid angle value (not 90, 180, 270, or -90) — validation error","Malformed page range string — validation error","PDF is password-protected or corrupted — processing error","Network timeout fetching remote PDF URL"],"whenToPreferThis":"Choose this endpoint when you need a simple, reliable PDF page rotation operation as part of a document processing pipeline, especially when you want inline base64 output (for immediate embedding) or a short-lived download URL (to avoid bloating your context window). It is ideal for correcting scanned document orientation, fixing improperly exported PDFs, or automating PDF preparation workflows. Prefer it over general-purpose office conversion endpoints when the only transformation needed is page rotation.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-13T12:45:16.626Z","isFirstParty":false,"canonicalSlug":"tanod-docs-pdf-rotate-cc19784f"}