Create lead form
POST/ad-publishing/linkedin/:accountId/form
Create a new LinkedIn lead gen form for an ad account
Request
Version stringrequired
API Version
Available options
v3locationId stringrequired
Location identifier
- application/json
- Body
- Example (auto)
Bodyrequired
ownerobjectrequired
Form owner
creationLocaleobjectrequired
Creation locale
namestringrequired
Form name
statestringrequired
Form state
Available options
PUBLISHEDcontentobjectrequired
Form content
hiddenFieldsobject[]
Hidden fields
{
"owner": {
"sponsoredAccount": "urn:li:sponsoredAccount:123456"
},
"creationLocale": {
"country": "US",
"language": "en"
},
"name": "Contact Us",
"state": "PUBLISHED",
"content": {
"questions": [],
"headline": {
"localized": {
"en_US": "Get in touch"
}
},
"postSubmissionInfo": {},
"legalInfo": {}
},
"hiddenFields": [
{
"name": "utm_source",
"value": "linkedin"
}
]
}
The created lead form. Same shape as a list entry, minus reviewInfo until LinkedIn reviews it.
- application/json
- Schema
- Example (auto)
Schema
idnumber
Form id. Returned as a number.
namestring
Form name
statestring
Form lifecycle state
versionIdnumber
Version of the form definition
creatednumber
When the form was created, epoch milliseconds
lastModifiednumber
When the form was last modified, epoch milliseconds
creationLocaleobject
Locale the form was authored in
ownerobject
Account that owns the form
reviewInfoobject
LinkedIn review outcome. Absent on a form that has just been created and not yet reviewed; present on reads.
hiddenFieldsobject[]
Hidden fields submitted alongside the lead. Empty array when none.
contentobject
Form definition
{
"id": 1025914010,
"name": "Q3 demand generation form",
"state": "PUBLISHED",
"versionId": 1,
"created": 1787056838757,
"lastModified": 1787057842322,
"creationLocale": {
"country": "US",
"language": "en"
},
"owner": {
"sponsoredAccount": "urn:li:sponsoredAccount:556129919"
},
"reviewInfo": {
"reviewStatus": "REJECTED",
"rejectionReasons": [
"MISSING_PRIVACY_POLICY",
"NONFUNCTIONAL_SITE"
],
"lastUpdated": 1787057842315
},
"hiddenFields": [
{
"name": "utm_source",
"value": "linkedin"
}
],
"content": {
"headline": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
},
"description": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
},
"questions": [
{
"questionId": 20711780444,
"question": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
},
"name": "lastName",
"label": "Last name",
"responseRequired": true,
"responseEditable": true,
"predefinedField": "LAST_NAME",
"questionDetails": {
"textQuestionDetails": {
"maxResponseLength": 300
},
"multipleChoiceQuestionDetails": {
"options": [
{
"id": 0,
"label": "Option 1",
"text": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
}
}
]
}
}
}
],
"postSubmissionInfo": {
"message": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
},
"callToAction": {
"callToActionLabel": "VISIT_COMPANY_WEBSITE",
"callToActionTarget": {
"landingPageUrl": "https://example.com"
}
}
},
"legalInfo": {
"legalInfoId": 2873998916,
"privacyPolicyUrl": "https://example.com/privacy",
"consents": [
{
"id": 1,
"label": "I agree to be contacted",
"checkRequired": true,
"consent": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
}
}
],
"legalDisclaimer": {
"localized": {
"en_US": "Hi there, good to see you here!"
}
}
}
}
}