phani
9 years agoAdvisor
API to Search only for posts containing images, videos and/or attachments.
Hi, is there any API available to Search only for posts containing images, videos and/or attachments in the community. Thanks & Regards, Phani
phani - There are V2 API calls available for this. I have formulated on call to check if a message has video, image and attachments.
SELECT * FROM messages WHERE videos.count(*) > 0 AND images.count(*) > 0 AND attachments.count(*) > 0
or, use this to check if either of 3 exists in a message or not:
SELECT * FROM messages WHERE videos.count(*) > 0 OR images.count(*) > 0 OR attachments.count(*) > 0
You can check the calls here http://community.lithium.com/t5/Developer-Documentation/bd-p/dev-doc-portal?section=commv2&collection=messages#constraints-images.count(*)
I hope this helps.