Playfast - Lightning-Fast Google Play Store Scraper
Project description
Playfast โก
Lightning-Fast Google Play Store Scraper
Playfast is a high-performance Google Play Store scraper built with Rust + PyO3, delivering 5-10x faster performance with true parallel batch processing.
โจ Features
- ๐ Blazingly Fast: Batch API is 5-10x faster than sequential
- โก True Parallel: Rust core completely releases GIL
- ๐ฆ Pure Rust: HTTP + parsing all in Rust for maximum performance
- ๐ Type Safe: Full Pydantic validation and type hints
- ๐พ Memory Efficient: Only 1.5 KB per app, linear scaling
- ๐ Multi-Country: 247 countries, 93 unique Play Stores
- ๐ฆ Batch API: High-level functions for easy parallel processing
๐ Performance
Batch Processing makes bulk operations 5-10x faster through true Rust parallelism!
| Method | Time | Speedup |
|---|---|---|
| Batch API | ~3s | 6-8x ๐ |
| RustClient + ThreadPool | ~3-4s | 6-7x |
| AsyncClient (concurrent) | ~3-5s | 5-7x |
| Sequential | ~20-30s | 1x |
Benchmark: Fetching 3 apps across 3 countries (9 requests total)
๐ Quick Start
Installation
pip install playfast
Option 1: Batch API (Recommended - Easiest & Fastest)
from playfast import fetch_apps
# Fetch multiple apps across countries (parallel!)
apps = fetch_apps(
app_ids=["com.spotify.music", "com.netflix.mediaclient"],
countries=["us", "kr", "jp"],
)
print(f"Fetched {len(apps)} apps in ~3 seconds!")
Option 2: RustClient (Maximum Performance)
from playfast import RustClient
client = RustClient()
# Get app information (GIL-free!)
app = client.get_app("com.spotify.music")
print(f"{app.title}: {app.score}โญ ({app.ratings:,} ratings)")
# Get reviews
reviews, next_token = client.get_reviews("com.spotify.music")
for review in reviews[:5]:
print(f"{review.user_name}: {review.score}โญ")
Option 3: AsyncClient (Easy Async)
import asyncio
from playfast import AsyncClient
async def main():
async with AsyncClient() as client:
app = await client.get_app("com.spotify.music")
print(f"{app.title}: {app.score}โญ")
asyncio.run(main())
๐ Examples
See the examples/ directory for more:
01_async_client.py- AsyncClient basics02_rust_client.py- RustClient for max performance03_batch_api.py- High-level batch API04_countries_and_categories.py- Country optimization
๐ Documentation
- Getting Started - Installation and first steps
- Quick Start - Practical examples
- API Reference - Complete API documentation
- Batch API Guide - Batch processing guide
๐๏ธ Architecture
Playfast uses pure Rust for both HTTP and parsing:
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Python Layer โ
โ - Batch API (high-level) โ
โ - RustClient / AsyncClient โ
โ - Pydantic Models โ
โโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโ
โ PyO3 Bindings
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Rust Core โ
โ - HTTP Client (reqwest) โ
โ - HTML Parser (scraper) โ
โ - Parallel Processing (rayon) โ
โ - Complete GIL Release โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Three Client Options
| Method | Speed | Ease | Best For |
|---|---|---|---|
| Batch API | โกโกโก | โญโญโญ | Multiple items |
| RustClient | โกโกโก | โญโญ | Single items |
| AsyncClient | โกโก | โญโญ | Async code |
๐ Multi-Country Optimization
Playfast optimizes global data collection:
from playfast import get_unique_countries, get_representative_country
# Instead of 247 countries, use 93 unique stores (2.7x faster!)
unique = get_unique_countries() # 93 unique Play Stores
# Get representative for any country
rep = get_representative_country(
"fi"
) # Finland โ Vanuatu store (shared by 138 countries)
๐ง Development
# Clone repository
git clone https://github.com/mixL1nk/playfast.git
cd playfast
# Install dependencies
uv sync
# Build Rust extension
uv run maturin develop --release
# Run tests
uv run pytest
# Run examples
uv run python examples/basic.py
# Run benchmarks
uv run python benchmarks/batch_apps_benchmark.py
See Development Setup for detailed instructions.
๐ค Contributing
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
๐ License
MIT License - see LICENSE for details.
๐ Acknowledgments
- Built with PyO3 (Rust-Python bindings)
- Inspired by google-play-scraper
- HTTP: reqwest
- Parsing: scraper
โ ๏ธ Disclaimer
This tool is for educational and research purposes only. Please respect Google Play Store's Terms of Service. Use responsibly with appropriate rate limiting.
Made with โค๏ธ using Rust + Python
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file playfast-0.3.2.tar.gz.
File metadata
- Download URL: playfast-0.3.2.tar.gz
- Upload date:
- Size: 274.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
57e7c5545b7f5ac9e72d813a80aad295344b44ee200992eec571a1a77bea377b
|
|
| MD5 |
e178da474d5708761656e4df6474cf4d
|
|
| BLAKE2b-256 |
b42e0e2b15b728aae949cb270289b13658488403f0b6dfdae857b53cc11ce24d
|
File details
Details for the file playfast-0.3.2-cp311-abi3-win_amd64.whl.
File metadata
- Download URL: playfast-0.3.2-cp311-abi3-win_amd64.whl
- Upload date:
- Size: 2.3 MB
- Tags: CPython 3.11+, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f09049b33b19b62bd90d62b7370ea12795eb0fd9201bceac6c15b2cae6d0decd
|
|
| MD5 |
6b1cfa91b0283c5e76a1038bd3a2648a
|
|
| BLAKE2b-256 |
da5a36ca6a0ae74520463e37ef07ab7ff4a778b88e122241caa21d5e41922973
|
File details
Details for the file playfast-0.3.2-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: playfast-0.3.2-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 2.9 MB
- Tags: CPython 3.11+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1a8bc18da8d9aa77472a0c6b5e6c5bf5a1d64bef6c63b7e37e0d25b1eaeb19cb
|
|
| MD5 |
4de759a34f49aa6badaf5bf8261511c9
|
|
| BLAKE2b-256 |
e9c0fdaa7c36f561fe7b054485f96dbfe1657231808b70635478fb858e246186
|
File details
Details for the file playfast-0.3.2-cp311-abi3-macosx_10_12_x86_64.whl.
File metadata
- Download URL: playfast-0.3.2-cp311-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 2.7 MB
- Tags: CPython 3.11+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8d1053eb2ed8d9afe36d50ba746520b50599fb896192b893f05ae186c04af967
|
|
| MD5 |
e608d324c75d14eda3016a505295e653
|
|
| BLAKE2b-256 |
c2c295c9cf741447125b5ad72f2e82cdfda4035f857f0a18a9e7321a01b89f1f
|