lads_create_carousel_creative
LinkedIn Ads write high risk
Part of the Sponsored Content Agent.
What it does
Creates the carousel POST only: a Posts-API ugcPost with content.carousel.cards (2-10 cards, each an image URN + landing page + title), author (organization URN), commentary, contentLandingPage and adContext for direct sponsored content (feedDistribution NONE). It does NOT create the creative that wraps the post — call lads_create_image_creative with the returned post URN as content.reference (the chained creative step is scheduled for November). Two-phase (parity with Google, ADR-028/029): the first call (no preview_id) builds the request locally and returns a preview_id — nothing is sent to LinkedIn; re-call with that preview_id and identical arguments to COMMIT (single-use, 30-min; a changed/forged/replayed token fails closed).
When to use it
Use when the user wants a multi-card swipeable ad (product features, step-by-step, multi-offer). Build all cards in DRAFT, show every card's image + headline + landing page plus the intro and the editorial check, require explicit approval, and only then activate. Re-preview if any card changes. First call lads_plan_sponsored_content_campaign for the campaign blueprint, operation ordering, and policy pre-checks.
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
ad_account_id | string | yes | Numeric sponsored account ID; strip urn prefix and dashes. Server-derived from bearer scope; reject out-of-scope accounts. |
cards | array | yes | 2-10 carousel cards. Each: {media:{id: urn:li:image:{id}, title (<=400 chars, required), altText (<=4086 chars)}, landingPage: absolute http/https URL (required)}. <2 or >10 cards is invalid (CARD_COUNT_INVALID). |
commentary | string | yes | Intro/commentary text shown above the carousel. Carousel intro hard limit 255 chars; per-card headline 45 chars (30 if the card carries its own landingPage URL). |
content_landing_page | string | no | Optional content-level landing page (contentLandingPage) applied when a card has no own landing page; absolute http/https. |
author | string | yes | Sponsoring organization URN urn:li:organization:{id}; must be an org the bearer can post direct sponsored content for (DIRECT_SPONSORED_CONTENT_MISMATCH otherwise). LinkedIn checks the author and the card images at commit: Scalix cannot read organizations or images with the ads scopes (403, probe 1 Oct 2026), so the preview does not check them. |
preview_id | string | no | Omit it to preview: nothing is applied, and the call returns a preview_id bound to this exact request. Pass it only after the user approves that preview in a later message, with the same arguments (leave out validate_only, and add any confirmation flag the preview names). Single-use, expires in 30 minutes; changed arguments need a fresh preview. |
Safeguards
A change in two steps. The first call previews and changes nothing; Claude shows you the preview and applies it only after you approve, within 30 minutes and with the same arguments. Every applied change goes to the audit log. How changes are approved.
Policy
Carousel creatives must use URN relation type ACTIVITY (rejection CAROUSEL_NON_ACTIVITY_REFERENCE) and a dark-post feed distribution NONE (UGC_INVALID_FEED_DISTRIBUTION). Each card and the intro must meet LinkedIn editorial standards (no ALL CAPS / EXCESSIVE_CAPITALIZATION, standard punctuation / NON_STANDARD_TEXT, one link + one email/phone / EXCESSIVE_CONTACT_INFORMATION, professional imagery / INAPPROPRIATE_LANGUAGE_OR_IMAGE), and every card's destination must support its claim (MISLEADING_CLAIMS, INCONSISTENT_DISPLAY_AND_LANDING_PAGE_URLS). Card count must be 2-10.
Reminder
Create paused, confirm each card's preview, then activate; report card-level metrics not a blended CTR; never sponsor content outside the bearer's authorized account or retain member data from referenced posts.
Errors
| Error class | Means | What to do | Retry |
|---|---|---|---|
TOKEN_REVOKED | Access token expired/revoked; member must re-authorize (refresh TTL caps ~365 days). | Refresh once and retry; else trigger needs_reauth. Never log the token. | yes |
PERMISSION_DENIED | 403 - missing rw_ads, missing write ad-account role, missing org posting role, or out-of-scope account. | Confirm scope and roles; do not retry until corrected. | no |
INVALID_ARGUMENT | 400 - surface platform message (CAROUSEL_NON_ACTIVITY_REFERENCE, UGC_INVALID_FEED_DISTRIBUTION, FIELD_VALUE_TOO_LONG for title/altText, INVALID_HREF for a card landingPage, INVALID_VALUE_NOT_EXIST for a bad image URN). | Relay LinkedIn's exact error; fix the named card/field; do not guess. | no |
CARD_COUNT_INVALID | 400 - fewer than 2 or more than 10 cards supplied. | Adjust to 2-10 cards and retry. | no |
CAMPAIGN_FORMAT_MISMATCH | 400 CAMPAIGN_EXCEEDING_CREATIVE_TYPE_LIMIT / REFERENCE_MEDIA_CATEGORY_AND_CAMPAIGN_FORMAT_MISMATCH - the campaign format is not CAROUSEL. | Target a CAROUSEL campaign (or a fresh campaign with no format set); do not retry the same campaign. | no |
RESOURCE_EXHAUSTED | 429 daily app/member limit (alert at 75%). | Honor X-RateLimit-Reset; backoff 5/10/20s cap 60s; retry once. | yes |
PLATFORM_ERROR | 500/503 transient (e.g. FAIL_TO_RETRIEVE_UPDATE). | Retry with backoff; report clearly if persistent; do not silently drop. | yes |
Edge cases
- A single bad card image URN fails the whole post create - validate every urn:li:image URN before submitting.
- Card headline limit drops to 30 chars when that card carries its own landingPage URL (otherwise 45).
- Carousel post must be a dark post (feedDistribution NONE); MAIN_FEED distribution is rejected (UGC_INVALID_FEED_DISTRIBUTION).
- Campaign/account creative caps (100/campaign, 15,000/account) apply -> 400 when exceeded.
- Two-step (Posts then creative) leaves an orphan ugcPost if the creative step fails - surface the orphan post URN so it can be cleaned up; prefer createInline to avoid orphans.
- Expired token -> refresh and retry once.
- Card images still PROCESSING surface servingHoldReasons (e.g. UNDER_REVIEW/processing) on the resulting creative until ready - do not treat as serving.