GitHub API Wrapper
A lightweight, typed Python SDK for interacting with the GitHub REST API.
Features
- Typed Pydantic models
- User API
- Repository API
- Repository search
- Automatic pagination
- Custom exceptions
- Built on httpx
Installation
pip install github-rest-sdk
Quick Start
from github_api import GitHubClient
client = GitHubClient("YOUR_GITHUB_TOKEN")
user = client.get_user("torvalds")
print(user.login)
repo = client.get_repo("openai", "openai-python")
print(repo.stars)
Available Methods
Users
client.get_user(username)
client.list_user_repos(username)
client.list_all_user_repos(username)
Repositories
client.get_repo(owner, repo)
client.search_repositories(query)
Project Structure
github_api/
├── client.py
├── models.py
├── exceptions.py
└── __init__.py
Roadmap
- Async client
- More GitHub endpoints
- Comprehensive test suite
- GitHub Actions CI
License
MIT
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
github_rest_sdk-0.1.1.tar.gz
(4.1 kB
view details)
Built Distribution
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 github_rest_sdk-0.1.1.tar.gz.
File metadata
- Download URL: github_rest_sdk-0.1.1.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
55a80ada49b90ed8bec252ffa8f2c7ec2cd2a0922393e12c820fafaeaeef8678
|
|
| MD5 |
867bd9b72344f3e15e1d1072a7e6dc85
|
|
| BLAKE2b-256 |
3befb70fd2376d618264a87f36a1dd4c676ac9e4160a67871392403a41287ef0
|
File details
Details for the file github_rest_sdk-0.1.1-py3-none-any.whl.
File metadata
- Download URL: github_rest_sdk-0.1.1-py3-none-any.whl
- Upload date:
- Size: 4.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ec5e5fce8fe6bce045cbbefd7bddea3d42b957f8febe53ece7b7ca57739d710
|
|
| MD5 |
22c0bdbb0dc8f52fe757247cc8ea822c
|
|
| BLAKE2b-256 |
c4fb72b5025d77251ac012f38b254d2e5d8f32a5dcd2e100cb23b994455a7f9d
|