Re: Fetch all Programs inside a Folder

Anonymous
Not applicable

Fetch all Programs inside a Folder

How do we fetch the list of Programs which are associated with a Folder?

Tags (2)
10 REPLIES 10
SanfordWhiteman
Level 10 - Community Moderator

Re: Fetch all Programs inside a Folder

This is an explicit filter type for the Programs API. Are you reading the docs?

Anonymous
Not applicable

Re: Fetch all Programs inside a Folder

Hi Stanford, as per API description for Programs, we can query based on Name,ID,tag and browsing based on filter. I am not able to fetch the list of programs based on Folder Name of Id. Please let me know if i am missing anything here.

SanfordWhiteman
Level 10 - Community Moderator

Re: Fetch all Programs inside a Folder

... and what are those filter types again?

Anonymous
Not applicable

Re: Fetch all Programs inside a Folder

Regarding Program Browsing, filter only applies to Engagement and Email programs.  The possible values are “on” and “off” for Engagement programs, and “unlocked” for Email programs. So, where do we mention the Folder Name or Id?

SanfordWhiteman
Level 10 - Community Moderator

Re: Fetch all Programs inside a Folder

filterType=folderId

Anonymous
Not applicable

Re: Fetch all Programs inside a Folder

I tried fetching programs with below url :

https://113-EDC-810.mktorest.com/rest/asset/v1/programs.json?maxReturn=200&folderId=262

But in response, i am seeing the programs associated with different folderId as well like below :

{

      "id": 1444,

      "name": "0 - Empowered Retail Nurture",

      "description": "",

      "createdAt": "2015-11-16T22:41:44Z+0000",

      "updatedAt": "2015-11-16T22:50:11Z+0000",

      "url": "https://app-ab11.marketo.com/#NP1444A1",

      "type": "Engagement",

      "channel": "Nurture",

      "folder": {

        "type": "Folder",

        "value": 1129,

        "folderName": "Empowered by Digital - Retail"

      },

      "status": "on",

      "workspace": "2nd Workspace"

    },

Please let me know what param i am missing here?

Thanks in Advance

SanfordWhiteman
Level 10 - Community Moderator

Re: Fetch all Programs inside a Folder

I gave you the param and you didn't include it.

Anonymous
Not applicable

Re: Fetch all Programs inside a Folder

Javier_Sanchez1
Level 2

Re: Fetch all Programs inside a Folder

May I hijack the thread and dive deeper?

what if

?maxReturn=200&filterType=folderId&filterValues=141&earliestUpdatedAt=2018-01-01T00:00:00-05:00

returns more than 200 records?

how do i fetch all the records?

campaigns.json have "nextpagetoken" in the result and it is possible to iterate over that.

I have a feeling that for programs "offset" parameter might do the trick, but can't really figure out how to properly use it.

Please somebody post an example.