Skip to main content
POST
/
templates
/
render
Render a PDF from a template with optional files and JSON data
curl --request POST \
  --url https://pdfs.platform.arb.inc/templates/render \
  --header 'Content-Type: multipart/form-data' \
  --form documentID=mailParkingNotice \
  --form 'placeholders={
  "url": "https://portal.arb.inc",
  "inviteCode": "ABC-123-XYZ",
  "qrCodeBase64": "iVBORw0KGgoAAAANSUhEUgAA..."
}' \
  --form 'data={
  "content": {
    "ticketNumber": "ABC123",
    "licensePlate": "XYZ9999",
    "state": "XX",
    "lotName": "Test Parking Lot",
    "lotStreet": "123 Example Street",
    "lotCity": "Sample City",
    "lotState": "XX",
    "lotZip": "12345",
    "entryPlateImageUrl": "https://example.com/images/plate1.jpg",
    "entryVehicleImageUrl": "https://example.com/images/vehicle1.jpg",
    "exitPlateImageUrl": "https://example.com/images/plate2.jpg",
    "exitVehicleImageUrl": "https://example.com/images/vehicle2.jpg",
    "totalAmount": "99.99"
  }
}' \
  --form 'files={}' \
  --form files.additionalProperties='@example-file'
"<string>"

Body

multipart/form-data
documentID
string
required

Identifier of the template to render.

Example:

"mailParkingNotice"

placeholders
object
required

JSON object mapping placeholder names to string values. May be empty ({}).

Example:
{
  "url": "https://portal.arb.inc",
  "inviteCode": "ABC-123-XYZ",
  "qrCodeBase64": "iVBORw0KGgoAAAANSUhEUgAA..."
}
data
object

Dynamic JSON data parts (HTML templates only): zero or more parts named data.<fieldName> (e.g. data.content, data.ticket). Each part contains JSON-encoded data (objects, arrays, primitives). PDF templates will reject data.* parts.

Example:
{
  "content": {
    "ticketNumber": "ABC123",
    "licensePlate": "XYZ9999",
    "state": "XX",
    "lotName": "Test Parking Lot",
    "lotStreet": "123 Example Street",
    "lotCity": "Sample City",
    "lotState": "XX",
    "lotZip": "12345",
    "entryPlateImageUrl": "https://example.com/images/plate1.jpg",
    "entryVehicleImageUrl": "https://example.com/images/vehicle1.jpg",
    "exitPlateImageUrl": "https://example.com/images/plate2.jpg",
    "exitVehicleImageUrl": "https://example.com/images/vehicle2.jpg",
    "totalAmount": "99.99"
  }
}
files
object

Dynamic file parts: zero or more parts named file.<fieldName> (e.g. file.qrCode, file.attachment). For PDF templates: must match template field names. For HTML templates: available as {fieldName}Base64 in template.

Response

PDF successfully rendered.

The response is of type file.