JSON file for /content/DAM path | Community
Skip to main content
New Participant
Jul 27, 2021 12:13 AM UTC
Solved

JSON file for /content/DAM path

Folks:

I was wondering if there is a default JSON created that lists all the assets in a path.  

For example: 

I created a folder structure:  https://mydomain/assets.html/content/dam/chec-press-releases/2020  and populated it with several assets.

If I go to > https://mydomain/libs/wcm/core/content/reference.json?path=%2Fcontent%2Fdam%2Fchec-press-releases%2f2020

I get a JSON file that only returns the first asset in the folder.  

Is there an "out of the box" JSON that lists all of the assets in that folder?

 

Thanks,

Glenn

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
arunpatidar
arunpatidarAccepted solution
New Participant
Jul 27, 2021 10:55 AM UTC

Hi,

If you want to filter out the results, you can go with Querybulder API

http://localhost:4502/libs/cq/search/content/querydebug.html

 

type=dam:Asset path=/content/dam/chec-press-releases/2020 p.limit=-1 path.flat=true p.hits=selective p.properties = jcr:path

 

 

JSON QueryBuilder Link will be http://localhost:4502/bin/querybuilder.json?p.hits=selective&p.limit=-1&p.properties=jcr%3apath&path=%2fcontent%2fdam%2fchec-press-releases%2f2020&path.flat=true&type=dam%3aAsset

this link can you can get from the Query Builder Debugger page

 

Note:

remove path.flat=true from the query if want to look for subfolder assets as well.

 

 

 

Arun Patidar

3 replies

arunpatidar
arunpatidarAccepted solution
New Participant
Jul 27, 2021 10:55 AM UTC

Hi,

If you want to filter out the results, you can go with Querybulder API

http://localhost:4502/libs/cq/search/content/querydebug.html

 

type=dam:Asset path=/content/dam/chec-press-releases/2020 p.limit=-1 path.flat=true p.hits=selective p.properties = jcr:path

 

 

JSON QueryBuilder Link will be http://localhost:4502/bin/querybuilder.json?p.hits=selective&p.limit=-1&p.properties=jcr%3apath&path=%2fcontent%2fdam%2fchec-press-releases%2f2020&path.flat=true&type=dam%3aAsset

this link can you can get from the Query Builder Debugger page

 

Note:

remove path.flat=true from the query if want to look for subfolder assets as well.

 

 

 

Translate
Arun Patidar
Dipti_Chauhan
New Participant
Jul 27, 2021 6:44 AM UTC

Hi @geverett 

  If you only want to view  assets on specific path,you can simply use infinity.json if you dont know the exact level, In your case you know exact level you can use .1.json

e.g https://mydomain/assets.html/content/dam/chec-press-releases/2020.1.json

 

Otherwise you can use Assets HTTP API  as @bimmiso  mentioned.

 

Thanks

Dipti Chauhan

 

Translate
Employee
Jul 27, 2021 5:30 AM UTC

Hi @geverett ,

 

You can use the Assets HTTP API as follows:

https://helpx.adobe.com/ca/experience-manager/6-4/assets/using/mac-api-assets.html

 

Hope this helps!!
Thanks

Translate