(Legacy) Ads Lead Generation

Number of APIs: 13

These are legacy APIs that will reach end of life before July 2024. This collection should not be used. If you already have access to the Ads Lead Generation APIs (radsleadgen_automation) then please migrate to the new Lead Sync APIs before July 2024.

  1. (Legacy) Use Cases-(Legacy) Push workflow - 2. Retrieve the user's Ad Accounts (sponsoredAccount) GET {{baseUrl}}/adAccounts?q=search&search=(type:(values:List(BUSINESS)),status:(values:List(ACTIVE)),test:false)&fields=id,name,test,reference

  2. (Legacy) Use Cases-(Legacy) Push workflow - 4. Look up the ad accounts organization GET {{baseUrl}}/adAccounts/{{sponsoredaccount_id}}?fields=referenceInfo

  3. (Legacy) Use Cases-(Legacy) Push workflow - 5. Validate user's organization role GET {{baseUrl}}/organizationAcls?q=roleAssignee

  4. (Legacy) Use Cases-(Legacy) Push workflow - 6. Retrieve Lead Gen Forms GET {{baseUrl}}/adForms?q=account&account=urn%3Ali%3AsponsoredAccount%3A{{sponsoredaccount_id}}&totals=true&count=10&start=0

  5. (Legacy) Use Cases-(Legacy) Push workflow - 8. Retrieve past leads looking back 90 days GET {{baseUrl}}/adFormResponses?q=account&account=urn%3Ali%3AsponsoredAccount%3A{{sponsoredaccount_id}}&projection=(paging,elements*(id,leadType,account~(id,name,reference~(localizedName)),campaign~(id,name),creative~(id,variables(data((,share~(text))))),form~(form(landingPage,hiddenFields,name)),formResponse(consentResponses*(accepted,consent~),submittedAt,answers*(question~,answerDetails))))&timeRange=(start:1668283699000,end:1668456499000)

  6. (Legacy) Use Cases-(Legacy) Push workflow - 9. Register for lead notifications POST {{baseUrl}}/leadNotificationUrls

  7. (Legacy) Use Cases-(Legacy) Push workflow - 11. Fetch full lead data after a notification is received GET {{baseUrl}}/adFormResponses/<AD FORM RESPONSE ID>?account=urn%3Ali%3AsponsoredAccount%3A{{sponsoredaccount_id}}&projection=(id,leadType,account~(id,name,reference~(localizedName)),campaign~(id,name),creative~(variables(data((,share~(text))))),form~(form(landingPage,hiddenFields,name)),formResponse(consentResponses*(accepted,consent~),submittedAt,answers*(question~,answerDetails)))

  8. (Legacy) Use Cases-(Legacy) Push workflow - Delete a registered webhook DELETE {{baseUrl}}/leadNotificationUrls/(sponsoredEntity:urn%3Ali%3AsponsoredAccount%3A{{sponsoredaccount_id}},developerApplication:urn%3Ali%3AdeveloperApplication%3A{{application_id}})

  9. (Legacy) Use Cases-(Legacy) Pull workflow - 2. Retrieve the user's Ad Accounts (sponsoredAccount) GET {{baseUrl}}/adAccounts?q=search&search=(type:(values:List(BUSINESS)),status:(values:List(ACTIVE)),test:false)&fields=id,name,test,reference

  10. (Legacy) Use Cases-(Legacy) Pull workflow - 4. Look up the ad accounts organization Copy GET {{baseUrl}}/adAccounts/{{sponsoredaccount_id}}?fields=referenceInfo