Apify Discord Mirror

Updated 5 months ago

Getting the metadata of a run, specifically Usage and Duration, with the js apify client or api?

At a glance

The community member is looking for a way to easily compare different runs of an actor, such as with different memory sizes, or compare different actors that solve the same issues. They have looked through the Apify JS client and API documentation but couldn't find anything. Another community member suggests using the RunClient class and the .get method to retrieve the ActorRun object, which can also be obtained from other endpoints like .waitForFinish.

Useful resources
I want to do this so that I can more easily choose the best way for me to run an actor (compare runs with different memory sizes for example) or even compare different actors that solve the same issues.
I've been looking at the apify js client documentation & at the apify api documentation and didn't find anything, but maybe I just missed it?
A
L
3 comments
just advanced to level 3! Thanks for your contributions! πŸŽ‰
That's strange you couldn't find it, perhaps the docs is confusing? see https://docs.apify.com/api/client/js/reference/class/RunClient and use the .get method
you get back the ActorRun object https://docs.apify.com/api/client/js/reference/interface/ActorRun
which you also get back from other endpoints like .waitForFinish
Add a reply
Sign up and join the conversation on Discord