Skip to content

Rotate pages

POST
/v1/pdf/rotate
curl -H "X-Api-Key: $KEY" -F files=@a.pdf -F rotation=180 \
http://localhost:9027/v1/pdf/rotate -o turned.pdf

Rotates pages by 90, 180 or 270 degrees.

Media typemultipart/form-data
object
files
required
string format: binary
outputFilename
string | null
pages

Page selection such as 1-3,5; all when empty.

string | null
rotation
required

90, 180 or 270.

string

Example

90

The rotated PDF

Media typeapplication/pdf

The file, as bytes.

string format: binary

The request is wrong

Media typeapplication/json

The JSON body of every error response.

object
error
required

A stable, machine-readable kind.

string
message
required

What went wrong, for a person.

string

Example

{
"error": "invalid_request",
"message": "unknown step 'teleport'"
}