From a5a7ac07b5b3a4f3c7654cf1d02821ab8772af0f Mon Sep 17 00:00:00 2001 From: Josef Prochazka Date: Thu, 19 Feb 2026 11:38:57 +0100 Subject: [PATCH] Update example code which was written for older version of the Actor --- docs/02_concepts/code/06_interacting_call.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/docs/02_concepts/code/06_interacting_call.py b/docs/02_concepts/code/06_interacting_call.py index 664e261f..da798a61 100644 --- a/docs/02_concepts/code/06_interacting_call.py +++ b/docs/02_concepts/code/06_interacting_call.py @@ -8,7 +8,11 @@ async def main() -> None: # Start the apify/screenshot-url Actor. actor_run = await Actor.call( actor_id='apify/screenshot-url', - run_input={'url': 'http://example.com', 'delay': 10000}, + run_input={ + 'urls': [{'url': 'https://www.apify.com/'}], + 'delay': 1000, + 'waitUntil': 'load', + }, ) if actor_run is None: @@ -18,10 +22,10 @@ async def main() -> None: run_client = Actor.apify_client.run(actor_run.id) await run_client.wait_for_finish() - # Get the Actor output from the key-value store. - kvs_client = run_client.key_value_store() - output = await kvs_client.get_record('OUTPUT') - Actor.log.info(f'Actor output: {output}') + # Get the Actor output from the dataset. + dataset_client = run_client.dataset() + item_list = await dataset_client.list_items() + Actor.log.info(f'Actor output: {item_list.items}') if __name__ == '__main__':