Instagram API Scraper avatar
Instagram API Scraper

Pricing

Pay per event

Go to Store
Instagram API Scraper

Instagram API Scraper

Developed by

Apify

Apify

Maintained by Apify

Scrape and download Instagram posts, profiles, places, hashtags, photos without login. Supports search keywords and URL lists. Download your data as HTML table, JSON, CSV, Excel, XML, and RSS feed.

4.5 (9)

Pricing

Pay per event

89

Total users

5.1K

Monthly users

676

Runs succeeded

>99%

Issues response

1.3 days

Last modified

4 days ago

NE

Unexpected error (500?)

Closed

neekee opened this issue
2 months ago

When I trigger a run from the API, I see that it starts, but then changes to status "Failed" with message "The Actor process was signalled to stop", and the Log mentions an "unexpected system error"

weuts avatar

Hi 😊

I'm unable to reproduce the issue 😅. Are you still experiencing it?

NE

neekee

2 months ago

Yes I am! To be fair, it seems likely that there's something wrong with my input, but since the error is something that looks like 500, I can't understand what.

Here's what I just ran (using the Python client, I should have mentioned that):

apify_client = ApifyClient(apify_client_id)
actor_name = "apify/instagram-api-scraper"
actor_client = apify_client.actor(actor_name)
call_result = actor_client.call(
run_input={
"directUrls": [link],
"resultsLimit": 1,
"resultsType": "details",
"searchLimit": 1,
}
)

link is a link to a specific Reel, in this case. I first successfully ran the Actor (same reel and everything) from the dashboard, then copied the JSON from the dashboard to my script, and then removed some parameters in the process of troubleshooting and referencing documentation, but triggering it from Python has been unsuccessful every time.

Are you able to reproduce with that approach?

frantisek avatar

Hi

this was caused by a bug in the Apify platform. When you used an API token with a specific combination of limited permissions to start an Actor run, the permission validation failed, and the Actors were unable to start. We've deployed a fix a few minutes ago which should solve this issue, can you try if everything works on your side now?

Thank you, and sorry for the inconvenience!

NE

neekee

2 months ago

Thank you, I am getting a different and more descriptive result now (the Log in the dashboard now has a 403 instead of an unexpected error)! But I think my token should have more than enough permissions here, all I want is to start a Run and read the resulting Dataset, are you able to see what permission check I'm failing?

(Interestingly it's also charging me for the failed job now -- not a lot, but is it supposed to be?)

frantisek avatar

Hi,

I think this Actor needs access to Apify proxy, and for that it needs to access the /users/me endpoint, which is currently not available to be configured in scoped tokens. If you give the Actors started by this token "Full access" (in the bottom of the permissions form), the Actor will get all the permissions it needs, while the token itself will still be restricted. See the [https://docs.apify.com/platform/integrations/api#restricted-access-restrict-what-actors-can-access-using-the-scope-of-this-actor] for more details.

This behavior is a limitation of the platform we're actively working on removing so that everything works seamlessly, we hope to have something to announce in the coming months.

alexey avatar

I will close the issue now, but if there is anything else we can help with, please let us know.

NE

neekee

a month ago

Oh sorry, didn't mean to leave you hanging! We will probably try that change soon, but haven't prioritized it yet since we have a working implementation for the moment. I really appreciate the quickness and thoroughness of your support!