Hello,
I have encountered a strange problem while testing my application that uses Marketo REST API.
When I try to get a landing page by ID, everything works fine and the response contains all data: GET /rest/asset/v1/landingPage/{id}.json
However, when I call this request: GET /rest/asset/v1/landingPage/{id}/content.json, I always get this response:
{"success":true,"errors":[],"requestId":"2407#1614cdc6a5c","warnings":["No assets found for the given search criteria."]}
Any idea why is this happening or what it could mean? I am pretty sure the landing page has a content because I can see it when I click Edit Draft.
Filip
It's not about content as a whole, but named content sections. Does your page have content that is present at the LP level?
Thanks for your quick response Sanford.
I am not sure because the landing page is not mine, it was created by a customer. How can I check if it has a named content? Sorry, I am quite new to Marketo and maybe I am just missing something obvious.
Filip
I think I understand now. The page that does not return any content has only Template Elements in the draft view, but the other one that works has both Template Elements and Page Elements. So, the /rest/asset/v1/landingPage/{id}/content.json request works only with Page Elements, right?
Filip
That's right.
OK, thanks again.
Filip
No prob, could you mark my first answer as Correct? Thanks.