Make
Render a PDF or image from an oJo template in a Make scenario, with the HTTP app and your API key. There is no oJo app in Make yet.
Before you start
- An oJo API key .
- A saved template and its ID. See Create Template, or start from the gallery.
1. Add the module
Add the HTTP app’s Make a request module.
2. Add your API key
Set Authentication type to API key and create a keychain in Credentials:
| Field | Value |
|---|---|
| Key | Bearer <your API key> |
| API key placement | Header |
| Parameter name | Authorization |
3. Fill in the request
| Field | Value |
|---|---|
| URL | https://api.ojo.so/v1/pdf/template |
| Method | POST |
| Body content type | application/json |
| Request content | the JSON below |
| Parse response | Yes |
{
"templateId": "<Template ID>",
"modify": {
"invoice": { "number": "INV-2026-0143" },
"customer": { "name": "Acme Inc." }
}
}Replace <Template ID>, shape modify like your template’s variables, and map values from earlier
modules in place of the sample values. Get Template lists every field a
template reads.
For a PNG, use https://api.ojo.so/v1/image/template with the same body. The response then holds
imageUrl.
Values mapped into a JSON string are not escaped. A value with a double quote or a line break
breaks the JSON, so pass it through replace() first, or build the body as a data structure,
which Make escapes for you.
4. Use the file
Run the module once so its output fields can be mapped. The response holds pdfUrl, pages and
credits. pdfUrl has no scheme, so type https:// before the mapped pdfUrl in later modules,
or fetch it with the HTTP app’s Download a file module to attach the PDF itself.
When it fails
| Status | Meaning |
|---|---|
| 400 | The body is not valid JSON. |
| 401 | The keychain’s key is not Bearer followed by a valid key. |
| 402 | Out of credits. |
| 422 | The request was refused before rendering, for example a missing templateId. The message says why. |
| 429 | Too many requests. Add a Sleep module or lower the scenario’s batch size. |
Want an oJo app in Make instead? Tell us.