Webhook Payload Variables
When iContentForge publishes an article via Generic Webhook, it makes all article fields available as template variables. You can use these in the Template Mode JSON editor using the {{variableName}} syntax to build any payload structure your receiver expects.
Variable Reference
| Variable | Type | Default Payload Key | Description |
|---|---|---|---|
{{title}} | string | title | Full article title. |
{{slug}} | string | slug | URL-friendly slug (kebab-case). |
{{html}} | string | html | Article content as clean HTML (converted from Markdown). |
{{markdown}} | string | markdown | Article content as raw Markdown. |
{{excerpt}} | string | excerpt | Short summary / first paragraph. Also used as meta description fallback. |
{{metaTitle}} | string | metaTitle | SEO meta title. |
{{metaDescription}} | string | metaDescription | SEO meta description. |
{{keyword}} | string | keyword | Primary target keyword for the article. |
{{wordCount}} | integer | wordCount | Approximate total word count. |
{{readingTime}} | integer | readingTime | Estimated reading time in minutes. |
{{categories}} | string[] | categories | Array of category names. |
{{tags}} | string[] | tags | Array of tag names. |
{{publishedAt}} | string | publishedAt | ISO 8601 publication timestamp (e.g. 2026-03-30T15:00:00.000Z). |
{{projectName}} | string | projectName | Name of the iContentForge project. |
{{projectDomain}} | string | projectDomain | Domain URL associated with the project. |
{{authorName}} | string | authorName | Author display name. |
{{pageId}} | string | pageId | Unique internal ID of the article in iContentForge. |
In the default payload (no template configured), all variables are sent using the keys listed in "Default Payload Key" column above. When using Template Mode, the left-hand key names are whatever you define — the right-hand {{variable}} is where the value comes from.
Template Mode Syntax
String Variables
Wrap in double quotes. iContentForge automatically JSON-escapes string content (including newlines, quotes, and special characters inside html and markdown fields):
{
"title": "{{title}}",
"content": "{{html}}",
"summary": "{{excerpt}}"
}
Number Variables
Do not wrap in quotes:
{
"word_count": {{wordCount}},
"reading_time": {{readingTime}}
}
Array Variables
Do not wrap in quotes. They are serialized as a JSON array automatically:
{
"tags": {{tags}},
"categories": {{categories}}
}
Full Template Example
This example shows a complete template for a custom blog receiver, using renamed field keys:
{
"title": "{{title}}",
"slug": "{{slug}}",
"content": "{{html}}",
"summary": "{{excerpt}}",
"seo_title": "{{metaTitle}}",
"seo_desc": "{{metaDescription}}",
"focus_kw": "{{keyword}}",
"tags": {{tags}},
"published_at": "{{publishedAt}}",
"author": "{{authorName}}",
"word_count": {{wordCount}}
}
When your receiver gets this payload, it reads the left-hand key names you defined:
// Your receiver reads the keys YOU defined in the template
const title = payload.title; // "How to Optimize..."
const content = payload.content; // "<h2>Introduction...</h2>" ← NOT payload.html
const seoTitle = payload.seo_title; // "Image SEO Guide..." ← NOT payload.metaTitle
const tags = payload.tags; // ["seo", "images", ...]
Common mistake — field name mismatch. If your template maps "content": "{{html}}", your receiver must read payload.content — not payload.html. The variable name (html) only determines which value is injected. The key name (content) is what your code must reference.
Field Mapping Mode vs Template Mode
The Generic Webhook connector supports two configuration modes:
Field Mapping Mode (Recommended for simple APIs)
A form-based approach where you select iContentForge variables from dropdowns and assign them to the field names your API uses. Best for flat JSON structures.
Advantages:
- No JSON syntax to write
- Less risk of template errors
- Variables listed in a UI — no memorization needed
Template Mode (For custom structures)
Write the entire JSON payload yourself, embedding variables with {{variableName}}. Best for:
- APIs requiring nested JSON
- APIs with specific required field names
- Combining variables with static values
- Serverless functions with custom schemas
{
"post": {
"metadata": {
"source": "iContentForge",
"project": "{{projectName}}"
},
"body": {
"title": "{{title}}",
"html": "{{html}}",
"excerpt": "{{excerpt}}"
}
}
}
Start with Field Mapping Mode if your API accepts flat key-value JSON. Only switch to Template Mode when you need nested structures or the mapping UI can't accommodate your API's schema.
Next Steps
- Set up your webhook endpoint: Generic Webhook Integration
- Manage published content: Publish Hub
- Schedule automatic publishing: Drip Feed