RunClient
Index
Methods
abort
Abort the Actor run which is starting or currently running and return its details.
https://docs.apify.com/api/v2#/reference/actor-runs/abort-run/abort-run
Parameters
keyword-onlygracefully: bool | None = None
Returns dict
charge
Charge for an event of a Pay-Per-Event Actor run.
https://docs.apify.com/api/v2#/reference/actor-runs/charge-events-in-run
Parameters
event_name: str
count: int | None = None
idempotency_key: str | None = None
Returns None
dataset
Get the client for the default dataset of the Actor run.
https://docs.apify.com/api/v2#/reference/actors/last-run-object-and-its-storages
Returns DatasetClient
delete
Returns None
get
Return information about the Actor run.
https://docs.apify.com/api/v2#/reference/actor-runs/run-object/get-run
Returns dict | None
get_status_message_watcher
Get
StatusMessageWatcherinstance that can be used to redirect status and status messages to logs.StatusMessageWatchercan be explicitly started and stopped or used as a context manager.Parameters
to_logger: logging.Logger | None = None
check_period: timedelta = timedelta(seconds=1)
Returns StatusMessageWatcherSync
get_streamed_log
Get
StreamedLoginstance that can be used to redirect logs.StreamedLogcan be explicitly started and stopped or used as a context manager.Parameters
to_logger: logging.Logger | None = None
keyword-onlyfrom_start: bool = True
Returns StreamedLogSync
key_value_store
Get the client for the default key-value store of the Actor run.
https://docs.apify.com/api/v2#/reference/actors/last-run-object-and-its-storages
Returns KeyValueStoreClient
log
Get the client for the log of the Actor run.
https://docs.apify.com/api/v2#/reference/actors/last-run-object-and-its-storages
Returns LogClient
metamorph
Transform an Actor run into a run of another Actor with a new input.
https://docs.apify.com/api/v2#/reference/actor-runs/metamorph-run/metamorph-run
Parameters
keyword-onlytarget_actor_id: str
keyword-onlytarget_actor_build: str | None = None
keyword-onlyrun_input: Any = None
keyword-onlycontent_type: str | None = None
Returns dict
reboot
Reboot an Actor run. Only runs that are running, i.e. runs with status RUNNING can be rebooted.
https://docs.apify.com/api/v2#/reference/actor-runs/reboot-run/reboot-run
Returns dict
request_queue
Get the client for the default request queue of the Actor run.
https://docs.apify.com/api/v2#/reference/actors/last-run-object-and-its-storages
Returns RequestQueueClient
resurrect
Resurrect a finished Actor run.
Only finished runs, i.e. runs with status FINISHED, FAILED, ABORTED and TIMED-OUT can be resurrected. Run status will be updated to RUNNING and its container will be restarted with the same default storages.
https://docs.apify.com/api/v2#/reference/actor-runs/resurrect-run/resurrect-run
Parameters
keyword-onlybuild: str | None = None
keyword-onlymemory_mbytes: int | None = None
keyword-onlytimeout_secs: int | None = None
keyword-onlymax_items: int | None = None
keyword-onlymax_total_charge_usd: Decimal | None = None
keyword-onlyrestart_on_error: bool | None = None
Returns dict
update
Update the run with the specified fields.
https://docs.apify.com/api/v2#/reference/actor-runs/run-object/update-run
Parameters
keyword-onlystatus_message: str | None = None
keyword-onlyis_status_message_terminal: bool | None = None
keyword-onlygeneral_access: RunGeneralAccess | None = None
Returns dict
wait_for_finish
Wait synchronously until the run finishes or the server times out.
Parameters
keyword-onlywait_secs: int | None = None
Returns dict | None
Sub-client for manipulating a single Actor run.