Read the info
Reads the page count, the PDF version, and whether a PDF is encrypted, tagged, linearized or holds form fields.
POST/forms/pdf/info
Form data
Response
JSON, one entry per PDF under its file name.
The route answers directly: it ignores Gotenberg-Output-Filename, and answers 400 to the webhook headers. An error answers a status and a message: see Errors.
curl \
--request POST http://localhost:3000/forms/pdf/info \
--form files=@report.pdf
Response
{
"report.pdf": {
"pages": 3,
"version": "1.7",
"encrypted": false,
"tagged": false,
"linearized": false,
"formFields": false
}
}
tagged says whether the PDF carries a structure for screen readers, and linearized whether it's built for fast web view. Each PDF answers under its name.
Read an encrypted PDF
Every read route takes a password field to open encrypted PDFs. A wrong one answers 400, and so does a missing one when the PDF has a user password; a PDF with an owner password only opens without it:
curl \
--request POST http://localhost:3000/forms/pdf/info \
--form files=@encrypted.pdf \
--form password=secret
Response
{
"encrypted.pdf": {
"pages": 3,
"version": "1.7",
"encrypted": true,
"tagged": false,
"linearized": false,
"formFields": false
}
}