Preview landing page template
Overview
Resolve draft landing-page HTML for an editor preview. It runs the supplied HTML through the same send-time path. This expands the [allReviewSite] grid into the store's enabled sites (using the store's DIRECT landing-page URLs — never click-tracking). It fills location/account tokens. It also swaps recipient-only tokens ([customerName], [senderName], [paragraph_1]) for friendly sample values. The endpoint saves no template and no recipient/campaign is involved.
Prerequisites
- A bearer token in the
Authorizationheader.
Base URL
| Environment | URL |
|---|---|
| Production | https://production-api.shoutaboutus.com |
| Development | https://development-api.shoutaboutus.com |
Endpoint
POST /api/v1/campaign/template/landing-page/preview
Authentication
-
Requires a bearer token in the
Authorization: Bearer <bearer-token>header. -
bearer token, account role — authentication.
store_idmust exist and belong to the caller's hierarchy (an ownership check).
Rate limit
- No rate limit.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
store_id | integer | Required | Must be an existing location inside your own account tree. |
html_content | string | Optional | Draft HTML to resolve. Empty resolves to an empty preview. |
{
"store_id": 12345,
"html_content": "<h1>Hi [customerName]</h1><div>[allReviewSite]</div>"
}How it works
- Synchronous.
200 OKwithdata.data.html= the resolved HTML string.422on validation failure. If the store cannot be loaded post-validation the controller returns a500-coded error envelope (Store not found).
Response
200 OK · 200
200{
"data": {
"status": "success",
"data": {
"html": "<h1>Hi Customer</h1><div><a href=\"https://example.com/lp/site-1\">Google</a></div>"
}
}
}422 Invalid store · 422
422{
"message": "The selected store id does not belong to your company hierarchy.",
"errors": {
"store_id": [
"The selected store id does not belong to your company hierarchy."
]
}
}Errors
| Status | Meaning |
|---|---|
401 | The bearer token is missing, expired or invalid |
422 | Invalid store |
500 | Unexpected server error |
Example request
curl --request POST \
--url "https://production-api.shoutaboutus.com/api/v1/campaign/template/landing-page/preview" \
--header 'Authorization: Bearer <bearer-token>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"store_id": 12345, "html_content": "<h1>Hi [customerName]</h1><div>[allReviewSite]</div>"}'Updated 11 days ago
Did this page help you?
