Actions31
Campaign → Set Content
AI-generatedSummary
Set the content for a Laposta campaign by providing direct HTML or specifying a URL to import content from.
Inputs
- campaignId (required) — The unique identifier of the target campaign.
- contentSource (required) — Select whether to supply HTML content directly ('html') or import it from a remote web address ('url').
- html (required) — The raw HTML body for the campaign. Required when Content Source is set to HTML.
- import_url (required) — The web URL from which to fetch the campaign HTML content. Required when Content Source is set to Import URL.
- contentOptions — Collection of optional settings, including 'inline_css' to automatically inline CSS styles within the HTML.
Output shape
a single record
Returns the API response object containing the updated campaign content details.
Examples
Example 1: Set campaign content using raw HTML
Campaign ID: 'cmp_123456', Content Source: 'HTML', HTML: '
Monthly Update
Welcome to our newsletter.
'Example 2: Import campaign content from a URL with CSS inlining enabled
Campaign ID: 'cmp_123456', Content Source: 'Import URL', Import URL: 'https://example.com/emails/july-newsletter.html', Additional Options: { Inline CSS: true }