apify-client
Apify API client for Python
What it is and what it does
apify-client is the official Python wrapper for the Apify platform's REST API. It provides both synchronous and asynchronous clients to orchestrate web scraping Actors, manage cloud storage (datasets, key-value stores, request queues), schedule recurring tasks, and configure webhooks—all from Python code. The library ships with Pydantic-validated typed responses, automatic exponential backoff retries, tiered timeout strategies, pagination and streaming helpers, and a pluggable HTTP layer (defaulting to impit but supporting httpx, requests, aiohttp, or custom implementations).
It's designed for developers who want to consume the Apify platform programmatically rather than build Actors themselves (for that, use the Apify SDK for Python instead). The client handles authentication via API token, compresses requests with gzip by default, offers structured error handling with ApifyApiError subclasses, and includes opt-in debug logging. Runtime dependencies are minimal: colorama, impit, more-itertools, and pydantic.
Use it for:
- Trigger and monitor web scraping Actors from a Python application, then retrieve and process the results.
- Build a data pipeline that orchestrates multiple Apify Actors in sequence, passing data between them via datasets.
- Manage and query key-value stores and request queues programmatically to coordinate distributed scraping jobs.
- Stream live logs from running Actor jobs in real time to monitor progress or debug failures.
- Schedule recurring Apify tasks and manage webhooks to integrate Apify scraping into a larger automation workflow.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A Python client library for the Apify REST API that lets you run Actors, manage storage (datasets, key-value stores, request queues), schedule tasks, and configure webhooks from Python code.
Yes. The package is actively maintained, has no known vulnerabilities, requires only common dependencies, and is the official client for a widely-used platform. Install it if you need to orchestrate Apify Actors or manage Apify storage from Python; skip it if you only build Actors (use the Apify SDK instead) or don't use the Apify platform.
Install
apify-client on PyPI
pip
pip install apify-clientuv
uv add apify-clientpoetry
poetry add apify-clientInstalling apify-client
Before you install
Low friction install with a pure-Python wheel. Actively maintained with a release 4 days old and recent commits. Requires Python 3.11 or higher.
License in practice
Licensed under Apache-2.0 (permissive), allowing use in commercial and private projects with minimal restrictions.
Quickstart
pip install apify-client
from apify_client import ApifyClient
client = ApifyClient('YOUR-APIFY-TOKEN')
run = client.actor('apify/hello-world').call(run_input={'message': 'Hello'})
for item in client.dataset(run.default_dataset_id).iterate_items():
print(item)
Requires Python 3.11 or higher. You must obtain an Apify API token from the Apify Console Integrations section.
Verify before relying
- Whether the optional brotli extra dependency improves performance enough to justify installation for typical workloads.
- Performance characteristics when streaming large datasets or handling high-volume pagination.
- Specific retry and timeout defaults and how they compare to typical API client conventions.
Package facts
| License | Apache-2.0 (permissive) |
| Python support | supports the current Python release (>=3.11) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 4 — colorama, impit, more-itertools, pydantic |
| Maintenance | actively maintained — 4 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 2,726,378/month — #2,918 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: apify_client-3.1.2-py3-none-any.whl
Keywords: apify, api, client, automation, crawling, scraping
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
apifyApify SDK for Python is the official framework…
permissive · top 15,000 on PyPI
apify-sharedApify Shared Python is a deprecated package…
permissive · top 5,000 on PyPI
daprDapr SDK for Python provides client libraries…
permissive · top 15,000 on PyPI
pipedreamProvides a Python client library for accessing…
unclear · top 15,000 on PyPI
python-intercomA Python client library for the Intercom API,…
unclear · top 15,000 on PyPI
apimatic-coreProvides core runtime utilities for REST API…
permissive · top 15,000 on PyPI
SparkSpark is an async-first actor framework for…
permissive · top 15,000 on PyPI
arcadepyProvides a typed Python client library for the…
permissive · top 15,000 on PyPI
letta-clientProvides a Python client library for the Letta…
permissive · top 15,000 on PyPI
cloudflareProvides a Python client library for the…
permissive · top 5,000 on PyPI