n8n
Connect Spectra.fm to n8n for self-hosted, privacy-focused visual automation.
1. Add HTTP Request Node
Section titled “1. Add HTTP Request Node”In your n8n workflow, add an HTTP Request node.
2. Configure the Node
Section titled “2. Configure the Node”| Setting | Value |
|---|---|
| Method | POST |
| URL | https://api.spectra.fm/v1/projects/YOUR_PROJECT_ID/exports |
3. Authentication
Section titled “3. Authentication”- Select Header Auth under Authentication
- Create new credentials:
- Name:
X-API-Key - Value: Your Spectra.fm API key
- Name:
4. Request Body
Section titled “4. Request Body”Enable Send Body and configure:
| Setting | Value |
|---|---|
| Body Content Type | JSON |
| Specify Body | Using JSON |
{ "combinations": [ {"locale": "en", "theme": "light"}, {"locale": "en", "theme": "dark"} ]}Example Workflows
Section titled “Example Workflows”Product launch → social kit
Section titled “Product launch → social kit”Webhook → HTTP Request (Spectra) → Slack- Webhook - Trigger on release or launch event
- HTTP Request - Export OG, LinkedIn, and Instagram assets
- Slack - Share export links with the team
Blog publish → header + OG
Section titled “Blog publish → header + OG”Schedule Trigger → HTTP Request (Spectra) → S3- Schedule Trigger - Poll CMS or run on publish
- HTTP Request - Export blog hero + OG image
- S3 - Store assets by slug
Certificates → personalized batch
Section titled “Certificates → personalized batch”Webhook Trigger → HTTP Request (Spectra) → S3- Webhook - Receive completion data (name, date, course)
- HTTP Request - Export certificates using content variations
- S3 - Save and notify
Using Expressions
Section titled “Using Expressions”Reference data from previous nodes:
{ "combinations": [ {"locale": "{{ $json.locale }}", "theme": "{{ $json.theme }}"} ]}Or use the expression editor for the URL:
https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exportsAsync Export Flow (Recommended)
Section titled “Async Export Flow (Recommended)”-
HTTP Request (GET) — export options
URL:https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exports/options -
HTTP Request (POST) — create export
URL:https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exports
Response includesexportId. -
Wait — 2–5 seconds
-
HTTP Request (GET) — poll status
URL:https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exports/{{ $json.exportId }}
Loop untilstatusiscompleted. -
HTTP Request (GET) — list artifacts
URL:https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exports/{{ $json.exportId }}/artifacts
Use downloadUrl from the artifacts response, or call:
https://api.spectra.fm/v1/projects/{{ $json.projectId }}/exports/download?objectKey={{ $json.objectKey }}&filename={{ $json.filename }}Next Steps
Section titled “Next Steps”- View the full API documentation
- Get your API key at app.spectra.fm/settings/api-keys