Check designs with n8n before approval
Before a person approves a design for export, an AI model in n8n looks at it
the way a reviewer would: are the texts spelled right, is the tone yours, is
the mandatory note there? It reports passed or failed with a short reason,
and the reviewer sees the result next to the design.
The check can hold an approval back, never grant it. A person still decides. If the check fails, the reviewer can approve anyway, with a reason that ends up in the audit log.
You need:
- n8n, cloud or self-hosted, and a chat model that reads images (for example Claude through the Anthropic Chat Model node).
- In heycreo, two-factor authentication on your account and the permission to manage service accounts and approvals.
1. Create the service account
Under Settings → Developers → Service accounts, choose New service account. Give it a name and choose External reviewer for approvals under For. It then reads designs and media, nothing else. Choose n8n as the platform. The last step creates the API key and shows it once.
In n8n, create a credential of type Header Auth: name X-API-Key, value
the key. Call it "heycreo check".
2. Make it a reviewer that only checks
Under Settings → Approvals, open Design export approval and switch on Approval required. On the Reviewers tab, add the people who decide. Under External reviewers, set the service account to Only checks.
On the Decision tab, Waiting time for external checks says how long the people wait for the result (30 minutes by default). Without a result by then, they decide without it.
3. Build the workflow
The workflow has six nodes:
Webhook → Verify signature → Load request → Download preview → Check design → Report result
Webhook
Add a Webhook node: HTTP Method POST, Respond Immediately, and
under Options switch on Raw Body. The signature is computed over the
body exactly as heycreo sent it. Copy the node's production URL.
In heycreo, open the service account, go to Webhooks, choose New webhook, paste the URL and tick Approval requested. Copy the signing secret: it is shown once.
Verify signature
A Code node (Run Once for All Items) checks the signature and passes on only approval requests for designs. Put the signing secret into an n8n variable or credential, not into the code.
const crypto = require('crypto');
const secret = $vars.HEYCREO_WEBHOOK_SECRET;
const raw = (await this.helpers.getBinaryDataBuffer(0, 'data')).toString('utf8');
const header = $input.first().json.headers['heycreo-signature'] ?? '';
const parts = Object.fromEntries(header.split(',').map((p) => p.trim().split('=')));
if (Math.abs(Date.now() / 1000 - Number(parts.t)) > 300) throw new Error('Signature too old');
const expected = crypto.createHmac('sha256', secret).update(`${parts.t}.${raw}`).digest('hex');
if (!parts.v1 || !crypto.timingSafeEqual(Buffer.from(parts.v1), Buffer.from(expected))) {
throw new Error('Invalid signature');
}
const event = JSON.parse(raw);
if (event.type !== 'approval.requested' || event.data.approval.entityType !== 'post') return [];
return [{ json: event }];
On self-hosted n8n, allow the module with the environment variable
NODE_FUNCTION_ALLOW_BUILTIN=crypto.
Load request
An HTTP Request node, Authentication Generic Credential Type → Header Auth → "heycreo check":
https://app.heycreo.io/api/organizations/{{ $json.organization.id }}/approvals/{{ $json.data.approval.id }}
The answer names the design in subjectTitle and links its preview in
thumbnailUrl, an image of the saved design at full size.
Download preview
A second HTTP Request node: GET {{ $json.thumbnailUrl }}, Response
Format File, and no authentication. The preview's address works on its
own; sending the key along would hand it to the file storage.
Check design
A Basic LLM Chain with the chat model. Under Chat Messages, add a user
message of type Image (Binary) for the field data, and switch on
Require Specific Output Format with a Structured Output Parser:
{
"type": "object",
"properties": {
"result": { "type": "string", "enum": ["passed", "failed"] },
"summary": { "type": "string" }
},
"required": ["result", "summary"]
}
The prompt holds your rules. Name them concretely; the model checks what you write here and nothing else.
You check a social media design for the brand before a person approves it.
Read every text in the image and check:
- spelling and grammar (German)
- the reader is addressed as "ihr", never as "Sie"
- an ad for alcohol carries the note "Kein Verkauf an Personen unter 16 Jahren. Genieße verantwortungsvoll."
Answer "failed" if a rule is broken, otherwise "passed". In "summary", say in
one or two sentences what is wrong, or that everything is in order.
Report result
A last HTTP Request node with the "heycreo check" credential, POST,
Body Content Type JSON:
https://app.heycreo.io/api/organizations/{{ $('Verify signature').item.json.organization.id }}/approvals/{{ $('Verify signature').item.json.data.approval.id }}/checks
{
"result": "{{ $json.output.result }}",
"summary": {{ JSON.stringify($json.output.summary) }},
"details": "https://your-team.app.n8n.cloud/workflow/{{ $workflow.id }}/executions/{{ $execution.id }}",
"round": {{ $('Verify signature').item.json.data.approval.round }}
}
details is optional. It must be an http or https link, and the reviewer
sees it as Report. Activate the workflow.
What happens next
When someone asks for approval of a design, heycreo sends
approval.requested, the workflow checks the preview and reports. The
reviewer sees n8n design check with the result and the summary:
passed, shown as passed: the people decide as usual.failed, shown as issues found: the people's approval stays on hold until a reviewer chooses Approve anyway and gives a reason. Reject works as always. A check never rejects: the request stays open.
Things to know
- Echo the round. When the request is resubmitted or the design changes,
the checks start a new round and
approval.requestedcomes again. A report for an earlier round is refused with409, so a slow check of the old design can never pass the new one. - Report once per round. The same result again is answered as it stands; a
different one is refused with
409. - No preview, no report. If
thumbnailUrlisnull, end the workflow. The people decide once the waiting time is over. - Only what it may read. The webhook carries no design someone keeps private, and the service account sees only the requests it is listed on.
- An agent on MCP reports the same way with the tool
submit-approval-check.
See also Service accounts and Webhooks.