When I call the api:
graph.facebook.com/userid?fields=business_discovery.username(name){followers_count,media_count}
in Graph API explore, I got an invalid parameter error:
(#100) Tried accessing nonexisting field (business_discovery) on node type (User)
Could anyone please explain to me what I miss in the API url?
Thanks
2
Answers
This only works for Instagram Business Accounts, but you seem to be using it with a normal user id.
As https://developers.facebook.com/docs/instagram-api/reference/user/business_discovery says,
You can not use this for other types of Instagram accounts, only for business accounts.
In my case the problem was that the instagram account was not connected to the page when the access-token was issue i.e. I added the instagram account after connecting the app.
So what worked for me was to remove the app, make sure that the instagram account is connected to the page the connect the app. Now the access token works.