A modern, type-safe Python library for interacting with the Geometry Dash private API.
- Sync & Async - Both synchronous (
Client) and asynchronous (AsyncClient) interfaces - Modern HTTP - Built with
httpxfor both sync and async operations - Type-safe - Full type hints with runtime validation via Pydantic
- Custom servers - Connect to private GD servers via
base_urlparameter - Built-in crypto - XOR cipher, GJP2 encoding, base64 utilities, and checksums
- Comprehensive errors - Full exception hierarchy for different error scenarios
pip install gdpyOr using uv:
uv pip install gdpyfromgdpyimportClientwithClient() asclient:
# Get user infouser=client.get_user(account_id=71) # RobTopprint(f"Username: {user.username}")
print(f"Stars: {user.stars}")
# Search levelslevels=client.search_levels(query="ReTraY", limit=5)
forlevelinlevels:
print(f"{level.name} - {level.downloads} downloads")importasynciofromgdpyimportAsyncClientasyncdefmain():
asyncwithAsyncClient() asclient:
# Get user infouser=awaitclient.get_user(account_id=71) # RobTopprint(f"Username: {user.username}")
print(f"Stars: {user.stars}")
# Search levelslevels=awaitclient.search_levels(query="ReTraY", limit=5)
forlevelinlevels:
print(f"{level.name} - {level.downloads} downloads")
asyncio.run(main())fromgdpyimportClient# Connect to a private GD serverwithClient(base_url="https://your-server.com/database") asclient:
user=client.get_user(account_id=1)Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'feat: add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
MIT