GitHubKit


NameGitHubKit JSON
Version 0.12.5 PyPI version JSON
download
home_pageNone
SummaryGitHub SDK for Python
upload_time2025-01-17 03:53:39
maintainerNone
docs_urlNone
authoryanyongyu
requires_python<4.0,>=3.9
licenseMIT
keywords github octokit
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <!-- markdownlint-disable MD041 -->
<div align="center">

[![githubkit](https://socialify.git.ci/yanyongyu/githubkit/image?description=1&descriptionEditable=%E2%9C%A8%20GitHub%20SDK%20for%20Python%20%E2%9C%A8&font=Bitter&language=1&pattern=Circuit%20Board&theme=Light)](https://github.com/yanyongyu/githubkit)

</div>

<p align="center">
  <a href="https://raw.githubusercontent.com/yanyongyu/githubkit/master/LICENSE">
    <img src="https://img.shields.io/github/license/yanyongyu/githubkit" alt="license">
  </a>
  <a href="https://pypi.python.org/pypi/githubkit">
    <img src="https://img.shields.io/pypi/v/githubkit?logo=python&logoColor=edb641" alt="pypi">
  </a>
  <img src="https://img.shields.io/badge/python-3.8+-blue?logo=python&logoColor=edb641" alt="python">
  <a href="https://github.com/psf/black">
    <img src="https://img.shields.io/badge/code%20style-black-000000.svg?logo=python&logoColor=edb641" alt="black">
  </a>
  <a href="https://github.com/Microsoft/pyright">
    <img src="https://img.shields.io/badge/types-pyright-797952.svg?logo=python&logoColor=edb641" alt="pyright">
  </a>
  <a href="https://github.com/astral-sh/ruff">
    <img src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json" alt="ruff">
  </a>
  <a href="https://results.pre-commit.ci/latest/github/yanyongyu/githubkit/master">
    <img src="https://results.pre-commit.ci/badge/github/yanyongyu/githubkit/master.svg" alt="pre-commit" />
  </a>
</p>

<div align="center">

<!-- markdownlint-capture -->
<!-- markdownlint-disable MD036 -->

_✨ The modern, all-batteries-included GitHub SDK for Python ✨_

_✨ Support both **sync** and **async** calls, **fully typed** ✨_

_✨ Always up to date, like octokit ✨_

<!-- markdownlint-restore -->

</div>

<p align="center">
  <a href="https://yanyongyu.github.io/githubkit/"><b>Documentation</b></a> |
  <a href="https://github.com/yanyongyu/githubkit/issues"><b>Report Bug</b></a> |
  <a href="https://docs.github.com/"><b>GitHub Docs</b></a>
</p>

githubkit aims to be an easy-to-use, fully typed, and always up-to-date GitHub SDK for Python. It is inspired by [octokit](https://github.com/octokit).

githubkit provides several features including:

- Support both sync and async calls
- Multiple authentication ways and OAuth flow support
- Calling REST API and GraphQL easily
- REST API versioning, including GHEC
- Built-in pagination support
- Optional data validation with [Pydantic](https://docs.pydantic.dev/latest/), for both webhook events and REST API responses
- Built-in http cache (powered by [Hishel](https://hishel.com/) for HTTPX) and auto retry
- Lazy loading of APIs and models
- Fully typed APIs

## Getting Started

For more, see the [documentation](https://yanyongyu.github.io/githubkit).

### Installation

Install githubkit with the package manager of your choice:

```bash
pip install githubkit
# or, use poetry
poetry add githubkit
# or, use pdm
pdm add githubkit
# or, use uv
uv add githubkit
```

### Usage

Create a [Personal Access Token (PAT)](https://github.com/settings/personal-access-tokens/new) and use it to create a `GitHub` instance:

```python
from githubkit import GitHub

github = GitHub("<your_token_here>")
```

Then, enjoy githubkit now!

```python
from githubkit import Response
from githubkit.versions.latest.models import FullRepository

resp: Response[FullRepository] = github.rest.repos.get("owner", "repo")
repo: FullRepository = resp.parsed_data
print(repo.full_name)
```

## Development

See the [development](https://yanyongyu.github.io/githubkit/contributing/) in the contributing guide.

## Contributors

Thanks to the following people who have contributed to this project:

<a href="https://github.com/yanyongyu/githubkit/graphs/contributors">
  <img src="https://contrib.rocks/image?repo=yanyongyu/githubkit&max=1000" alt="contributors" />
</a>


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "GitHubKit",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.9",
    "maintainer_email": null,
    "keywords": "github, octokit",
    "author": "yanyongyu",
    "author_email": "yyy@yyydl.top",
    "download_url": "https://files.pythonhosted.org/packages/d3/b6/9df221e07fbfe1f5fd66ed1d1d8bbbdd1679cf37953e248c69e1e559425a/githubkit-0.12.5.tar.gz",
    "platform": null,
    "description": "<!-- markdownlint-disable MD041 -->\n<div align=\"center\">\n\n[![githubkit](https://socialify.git.ci/yanyongyu/githubkit/image?description=1&descriptionEditable=%E2%9C%A8%20GitHub%20SDK%20for%20Python%20%E2%9C%A8&font=Bitter&language=1&pattern=Circuit%20Board&theme=Light)](https://github.com/yanyongyu/githubkit)\n\n</div>\n\n<p align=\"center\">\n  <a href=\"https://raw.githubusercontent.com/yanyongyu/githubkit/master/LICENSE\">\n    <img src=\"https://img.shields.io/github/license/yanyongyu/githubkit\" alt=\"license\">\n  </a>\n  <a href=\"https://pypi.python.org/pypi/githubkit\">\n    <img src=\"https://img.shields.io/pypi/v/githubkit?logo=python&logoColor=edb641\" alt=\"pypi\">\n  </a>\n  <img src=\"https://img.shields.io/badge/python-3.8+-blue?logo=python&logoColor=edb641\" alt=\"python\">\n  <a href=\"https://github.com/psf/black\">\n    <img src=\"https://img.shields.io/badge/code%20style-black-000000.svg?logo=python&logoColor=edb641\" alt=\"black\">\n  </a>\n  <a href=\"https://github.com/Microsoft/pyright\">\n    <img src=\"https://img.shields.io/badge/types-pyright-797952.svg?logo=python&logoColor=edb641\" alt=\"pyright\">\n  </a>\n  <a href=\"https://github.com/astral-sh/ruff\">\n    <img src=\"https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json\" alt=\"ruff\">\n  </a>\n  <a href=\"https://results.pre-commit.ci/latest/github/yanyongyu/githubkit/master\">\n    <img src=\"https://results.pre-commit.ci/badge/github/yanyongyu/githubkit/master.svg\" alt=\"pre-commit\" />\n  </a>\n</p>\n\n<div align=\"center\">\n\n<!-- markdownlint-capture -->\n<!-- markdownlint-disable MD036 -->\n\n_\u2728 The modern, all-batteries-included GitHub SDK for Python \u2728_\n\n_\u2728 Support both **sync** and **async** calls, **fully typed** \u2728_\n\n_\u2728 Always up to date, like octokit \u2728_\n\n<!-- markdownlint-restore -->\n\n</div>\n\n<p align=\"center\">\n  <a href=\"https://yanyongyu.github.io/githubkit/\"><b>Documentation</b></a> |\n  <a href=\"https://github.com/yanyongyu/githubkit/issues\"><b>Report Bug</b></a> |\n  <a href=\"https://docs.github.com/\"><b>GitHub Docs</b></a>\n</p>\n\ngithubkit aims to be an easy-to-use, fully typed, and always up-to-date GitHub SDK for Python. It is inspired by [octokit](https://github.com/octokit).\n\ngithubkit provides several features including:\n\n- Support both sync and async calls\n- Multiple authentication ways and OAuth flow support\n- Calling REST API and GraphQL easily\n- REST API versioning, including GHEC\n- Built-in pagination support\n- Optional data validation with [Pydantic](https://docs.pydantic.dev/latest/), for both webhook events and REST API responses\n- Built-in http cache (powered by [Hishel](https://hishel.com/) for HTTPX) and auto retry\n- Lazy loading of APIs and models\n- Fully typed APIs\n\n## Getting Started\n\nFor more, see the [documentation](https://yanyongyu.github.io/githubkit).\n\n### Installation\n\nInstall githubkit with the package manager of your choice:\n\n```bash\npip install githubkit\n# or, use poetry\npoetry add githubkit\n# or, use pdm\npdm add githubkit\n# or, use uv\nuv add githubkit\n```\n\n### Usage\n\nCreate a [Personal Access Token (PAT)](https://github.com/settings/personal-access-tokens/new) and use it to create a `GitHub` instance:\n\n```python\nfrom githubkit import GitHub\n\ngithub = GitHub(\"<your_token_here>\")\n```\n\nThen, enjoy githubkit now!\n\n```python\nfrom githubkit import Response\nfrom githubkit.versions.latest.models import FullRepository\n\nresp: Response[FullRepository] = github.rest.repos.get(\"owner\", \"repo\")\nrepo: FullRepository = resp.parsed_data\nprint(repo.full_name)\n```\n\n## Development\n\nSee the [development](https://yanyongyu.github.io/githubkit/contributing/) in the contributing guide.\n\n## Contributors\n\nThanks to the following people who have contributed to this project:\n\n<a href=\"https://github.com/yanyongyu/githubkit/graphs/contributors\">\n  <img src=\"https://contrib.rocks/image?repo=yanyongyu/githubkit&max=1000\" alt=\"contributors\" />\n</a>\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "GitHub SDK for Python",
    "version": "0.12.5",
    "project_urls": {
        "Documentation": "https://github.com/yanyongyu/githubkit",
        "Homepage": "https://github.com/yanyongyu/githubkit",
        "Repository": "https://github.com/yanyongyu/githubkit"
    },
    "split_keywords": [
        "github",
        " octokit"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "79cea23d4cd771c546379a9e13f2f9db7215a1f8846bc174cf142cb04116a270",
                "md5": "10cc1588d5d31003836e1751e832a630",
                "sha256": "9a5c00591a4218ae311ad5797b215143fbd6a34079f1c8aa6d4db7a80e5b530f"
            },
            "downloads": -1,
            "filename": "githubkit-0.12.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "10cc1588d5d31003836e1751e832a630",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.9",
            "size": 5266887,
            "upload_time": "2025-01-17T03:53:33",
            "upload_time_iso_8601": "2025-01-17T03:53:33.868056Z",
            "url": "https://files.pythonhosted.org/packages/79/ce/a23d4cd771c546379a9e13f2f9db7215a1f8846bc174cf142cb04116a270/githubkit-0.12.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d3b69df221e07fbfe1f5fd66ed1d1d8bbbdd1679cf37953e248c69e1e559425a",
                "md5": "afcef266b24a38e9af52cdca22969ec2",
                "sha256": "d465a8a117c51e53213a6cffca2208f00596c889c3feacd8ad66842ba652ba2d"
            },
            "downloads": -1,
            "filename": "githubkit-0.12.5.tar.gz",
            "has_sig": false,
            "md5_digest": "afcef266b24a38e9af52cdca22969ec2",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.9",
            "size": 1842691,
            "upload_time": "2025-01-17T03:53:39",
            "upload_time_iso_8601": "2025-01-17T03:53:39.117887Z",
            "url": "https://files.pythonhosted.org/packages/d3/b6/9df221e07fbfe1f5fd66ed1d1d8bbbdd1679cf37953e248c69e1e559425a/githubkit-0.12.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-17 03:53:39",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "yanyongyu",
    "github_project": "githubkit",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "githubkit"
}
        
Elapsed time: 0.43146s