There is no concrete way to indicate that I only need photos or videos, but you can filter the results based on filter:links or filter:images or filter:videos in your request along with include_entities=true .
Example. To get tweets containing links from 2012-01-31 , you must have the include_entities parameter, as well as filter:links , as shown below:
https://search.twitter.com/search.json?q=from%3Agoogle%20since%3A2012-01-31%20filter%3Alinks&include_entities=true"
As you need to filter tweets based on images / photos, I think you should use filter:images .
An example of your case will look like this:
https://search.twitter.com/search.json?q=from%3Agoogle%20since%3A2012-01-31%20filter%3Aimages&include_entities=true"
Hope this helps.
Abhishek sivasubramanian
source share