API Reference
Create a lead form
/rest/leadFormshttps://linkedin-ads.mimicr.dev · provider: https://api.linkedin.comCreates a Lead Gen Form owned by an ad account or an organization. Scope rw_ads. Publishing (state PUBLISHED) starts the form review: AUTO_APPROVED after 10 sandbox minutes, or REJECTED with [reprovar] in the name. Duplicate question names or option ids → 409; no permission → 401 "Member is not authorized to create LeadGenForm".
Authorization
Bearer token in the Authorization: Bearer <token> header. See Authentication.
Headers
API version, YYYYMM (the latest is 202610). Missing → 400 VERSION_MISSING; sunset, unknown or unreleased → 426 NONEXISTENT_VERSION. 202511 stops on 2026-11-16 by the sandbox clock.
"202610"Always 2.0.0. Calls that use the 2.0 syntax (List(…), (key:value), encoded URN keys) without it answer 400 "Invalid query parameters passed to request".
2.0.0Body
application/jsonForm id; the URN is urn:li:leadGenForm:{id}.
One of sponsoredAccount or organization.
Show child attributes
Internal name.
Show child attributes
Country code (BR).
Language code (pt).
Up to 20 hidden fields; {{DYNAMIC_VALUE}} placeholders are kept.
Show child attributes
Form content.
Show child attributes
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Country code (BR).
Language code (pt).
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Country code (BR).
Language code (pt).
At least one question.
Show child attributes
Unique within the form (409 on duplicates).
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Country code (BR).
Language code (pt).
Assigned by the server.
Prefilled member field.
23 values
FIRST_NAMELAST_NAMEPHONE_NUMBEREMAILCITYSTATECOUNTRYZIP_CODEJOB_TITLEJOB_FUNCTIONSENIORITYCOMPANY_NAMECOMPANY_SIZEINDUSTRYDEGREEFIELD_OF_STUDYSCHOOLSTART_DATEGRADUATION_DATEGENDERWORK_EMAILLINKEDIN_PROFILE_LINKWORK_PHONE_NUMBERDefault true.
Default true.
Show child attributes
Show child attributes
1–300.
2–15 options.
Show child attributes
Show child attributes
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Country code (BR).
Language code (pt).
Show child attributes
Localized text.
Show child attributes
Text per locale ({"pt_BR": "…"}).
Show child attributes
Country code (BR).
Language code (pt).
Show child attributes
VISIT_COMPANY_WEBSITELEARN_MOREVIEW_NOWDOWNLOAD_NoWTRY_NOWDRAFT → PUBLISHED → ARCHIVED. Archiving puts the linked creatives on FORM_HOLD.
DRAFTPUBLISHEDARCHIVEDStarts at 1; editing the questions of a published form creates the next version.
urn:li:versionedLeadGenForm:(urn:li:leadGenForm:{id},{versionId}).
Form review, once published.
Show child attributes
PENDINGAPPROVEDREJECTEDPREAPPROVEDAUTO_APPROVEDNEEDS_REVIEWAUTO_REJECTEDResponses
201Created. The id is in the x-restli-id header (empty body): the form id.
400Invalid request: missing LinkedIn-Version (VERSION_MISSING), Rest.li 2.0 syntax without X-Restli-Protocol-Version or with unencoded URNs ("Invalid query parameters passed to request"), or invalid parameters.
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.
401Missing token, or the member can't manage forms of the owner.
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.
403The token lacks the scope (ACCESS_DENIED, "Not enough permissions to access: {resource}.{METHOD}.{version}") or the member's role is too low (NO_PERMISSION_ON_ENTITY).
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.
409"The Lead Form has duplicate {field}."
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.
426LinkedIn-Version sunset, unknown or not released: NONEXISTENT_VERSION "Requested version {version} is not active".
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.
429Daily quota of the application or the member reached: TOO_MANY_REQUESTS, with Retry-After (seconds to 00:00 UTC).
HTTP status.
Service error code (100, 401, 65600…).
Present when LinkedIn gives one (VERSION_MISSING, NONEXISTENT_VERSION, ACCESS_DENIED, USER_NOT_AUTHORIZED, TOO_MANY_REQUESTS).
Error message.