Search code examples
instagraminstagram-graph-api

Instagram Hashtag Search API returns error message "user_id is required" although I have provided it


I am trying to get data about media from my IG Business account with a specific hashtag. I used Graph API Explorer and tried with

/{hashtag_id}?user_id={instagram_business_id}&fields=recent_media

but I got an error "(#100) The parameter user_id is required."

Does anybody know what may be the problem and how to solve it?


Solution

  • The API URL is incorrect, your URL should look like this:

    /{hashtag_id}/recent_media?user_id={instagram_business_id}&fields=id,caption,media_url...