| id | asyncio-support |
|---|---|
| title | Asyncio support |
import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; import CodeBlock from '@theme/CodeBlock'; import ApiLink from '@theme/ApiLink';
import AsyncSupportExample from '!!raw-loader!./code/01_async_support.py';
The package provides an asynchronous version of the client, ApifyClientAsync, which allows you to interact with the Apify API using Python's standard async/await syntax. This enables you to perform non-blocking operations, see the Python asyncio documentation for more information.
The following example demonstrates how to run an Actor asynchronously and stream its logs while it is running:
{AsyncSupportExample}