https://github.com/ponylang/github_rest_api
Pony library for working with GitHub's REST API
https://github.com/ponylang/github_rest_api
github-api pony-core-team-library ponylang ponylang-langauge
Last synced: about 1 month ago
JSON representation
Pony library for working with GitHub's REST API
- Host: GitHub
- URL: https://github.com/ponylang/github_rest_api
- Owner: ponylang
- License: bsd-2-clause
- Created: 2021-08-03T21:32:14.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2026-04-12T01:00:54.000Z (about 1 month ago)
- Last Synced: 2026-04-12T03:00:16.306Z (about 1 month ago)
- Topics: github-api, pony-core-team-library, ponylang, ponylang-langauge
- Language: Pony
- Homepage:
- Size: 410 KB
- Stars: 7
- Watchers: 8
- Forks: 2
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# GitHub REST API
Library for interacting with the GitHub REST API.
## Status
GitHub REST API is an alpha-level package.
The library currently does not implement the GitHub REST API. It contains at minimum, the functionality required for various ponylang organization needs.
Additional API surface and functionality will be added as needed. If you need functionality that is currently missing, please join us on the [Pony Zulip](https://ponylang.zulipchat.com/) and we can figure out if you opening a PR or using doing the work would be the best approach.
## Installation
* Requires ponyc 0.63.1 or later
* Install [corral](https://github.com/ponylang/corral)
* `corral add github.com/ponylang/github_rest_api.git --version 0.4.0`
* `corral fetch` to fetch your dependencies
* `use "github_rest_api"` to include this package
* `corral run -- ponyc` to compile your application
## Usage
```pony
use "github_rest_api"
use "github_rest_api/request"
use "net"
actor Main
new create(env: Env) =>
let auth = TCPConnectAuth(env.root)
let creds = Credentials(auth, "your-github-token")
GitHub(creds).get_repo("ponylang", "ponyc")
.next[None](PrintRepository~apply(env.out))
primitive PrintRepository
fun apply(out: OutStream, result: RepositoryOrError) =>
match result
| let repo: Repository =>
out.print(repo.full_name)
| let err: RequestError =>
out.print(err.message)
end
```
See the [examples](examples/) directory for more.
## API Documentation
[https://ponylang.github.io/github_rest_api](https://ponylang.github.io/github_rest_api)