Skip to guide

Generate images in n8n with HTTP Request.

Turn a title from your workflow into a new image using your own design. This connection uses n8n’s built-in HTTP Request and Webhook nodes, with a Pikstrapi API key.

Begin with one title and one template.

You need a saved Pikstrapi template, its UUID, an API key from the same account and access to an n8n workflow. Name the text layer title. This guide does not require a native Pikstrapi connector.

For the first test, connect Manual Trigger to Edit Fields (Set). Add a string field called title with a sample headline. The input reaching HTTP Request should look like this:

{
  "title": "A new article. Ready to share."
}

Later, replace this sample with a row from your spreadsheet or an event from your CMS. First confirm that the title field is present and contains text.

Review the Pikstrapi image API request and response

Configure HTTP Request for Pikstrapi.

Add HTTP Request after your input node. Set Method to POST and URL to the endpoint from your account’s API playground. If the placeholder below appears, replace YOUR_API_BASE_URL with the base URL including /api/v1.

POST https://api.pikstrapi.com/api/v1/templates/generate-image
  1. Authentication: choose Generic Credential Type → Header Auth. Create a credential whose Name is x-api-key and Value is your Pikstrapi API key.
  2. Send Body: enable it, set Body Content Type to JSON and Specify Body to Using JSON.
  3. Switch the JSON body field to Expression. Paste this expression, replace YOUR_TEMPLATE_ID and inspect the preview before executing.
{{ JSON.stringify({
  templateId: "YOUR_TEMPLATE_ID",
  exportFormat: "png",
  mode: "immediate",
  layers: { title: { text: $json.title } }
}) }}

JSON.stringify serializes the whole body, including quotation marks and line breaks in the title. Do not build JSON by inserting a title between quotation marks. The named layer title must match your saved template.

Receive a file, then pass it on.

Under Options → Response, set Response Format to File and Put Output in Field to data. Execute one item. An immediate PNG response is binary, so JSON is the wrong response format.

Check the binary output and preview the image. The next upload, storage or messaging node must read the binary property data. Whether that destination accepts an upload or a URL depends on its own API.

Try a second headline with quotation marks or accented characters. Once both images are correct, replace the manual input with your real trigger and map its title field.

Use a webhook when generation should run separately.

For deferred generation, change mode to deferred and the HTTP Request response format to JSON. The immediate response contains jobId, status, progress and fileId; it is an acknowledgement, not the finished image.

Create a receiving workflow with a POST Webhook node and copy its production URL. Publish or activate the workflow according to your n8n version so that URL can receive requests. A test webhook only listens while you are testing; use the production URL for ongoing delivery.

{
  "templateId": "YOUR_TEMPLATE_ID",
  "exportFormat": "png",
  "mode": "deferred",
  "layers": {
    "title": {
      "text": "My next article"
    }
  },
  "webhookUrl": "YOUR_N8N_PRODUCTION_WEBHOOK_URL",
  "metadata": {
    "sourceId": "YOUR_SOURCE_RECORD_ID"
  }
}

Replace every placeholder. The receiving URL must be reachable from Pikstrapi over HTTP(S); localhost and private network addresses are unsuitable. Metadata can carry your source record ID so the receiver can match the result.

  • render.completed: the payload data contains jobId and, when available, fileUrl and fileId. In an n8n Webhook node, inspect body.event and body.data in the received item.
  • render.failed: handle the error separately and keep the source record for review. Do not treat an acknowledgement as success.

Delivery can be retried. Deduplicate downstream actions by jobId and event, and acknowledge receipt promptly. For private files, use the access requirements shown in your account rather than assuming fileUrl is public.

Pikstrapi node: check publication status.

A Pikstrapi community node is prepared as a local development candidate. Its operations cover immediate rendering, deferred jobs, status checks, canceling queued jobs and combining completed PDFs. As checked on 9 October 2026, n8n-nodes-pikstrapi is not published in the public npm registry and a verified n8n integration listing has not been confirmed.

The HTTP Request steps above use built-in n8n nodes and the public API contract. They remain the documented way to reproduce this guide without a community package. Before installing a future Pikstrapi node, confirm the published package, installation instructions and compatibility with your n8n environment.

For immediate PDF output with HTTP Request, choose exportFormat: pdf and Response Format: File. To combine pages, follow the PDF guide: render individual pages as deferred PDF jobs, wait for completion and send their job IDs to the merge endpoint.

PDF generation and merging API guide

If the workflow stops, check the boundary.

  • Authentication error. Check Header Auth, x-api-key and the account owning the template. Keep the key out of shared workflows.
  • No text change. Inspect incoming title and the exact saved layer name. Test one item before adding more data sources.
  • JSON parsing error. Use the whole-body expression and check its evaluated preview. Immediate output must be File; deferred output must be JSON.
  • No callback. Check the production URL, receiving workflow state and public reachability. Inspect the job status before submitting another render.

Connect your actual publishing workflow.

Use a new article for a blog cover, a completed course for a certificate or a spreadsheet row for a product banner. The template defines the design; your workflow supplies the data and decides where the result goes.

Create your Pikstrapi account

Configuration guide by Pikstrapi, checked against its API contract and n8n documentation on 9 October 2026. Use your own credentials and verify the steps in your n8n version.