{"id":46760281,"url":"https://github.com/lunakv/academyruins-api","last_synced_at":"2026-03-09T22:04:53.324Z","repository":{"id":59609450,"uuid":"495853868","full_name":"lunakv/academyruins-api","owner":"lunakv","description":"Rules API for Magic: The Gathering","archived":false,"fork":false,"pushed_at":"2025-11-08T11:10:05.000Z","size":602,"stargazers_count":7,"open_issues_count":20,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-11-08T13:08:50.451Z","etag":null,"topics":["judge","magic-the-gathering","mtg","postgresql","python"],"latest_commit_sha":null,"homepage":"https://api.academyruins.com/docs","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lunakv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"ko_fi":"vaasa"}},"created_at":"2022-05-24T14:14:40.000Z","updated_at":"2025-11-08T11:10:08.000Z","dependencies_parsed_at":"2023-01-29T19:02:55.658Z","dependency_job_id":"913911d8-c020-438f-8b6f-d8045e7681cf","html_url":"https://github.com/lunakv/academyruins-api","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/lunakv/academyruins-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunakv%2Facademyruins-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunakv%2Facademyruins-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunakv%2Facademyruins-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunakv%2Facademyruins-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lunakv","download_url":"https://codeload.github.com/lunakv/academyruins-api/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunakv%2Facademyruins-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30314458,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-09T20:05:46.299Z","status":"ssl_error","status_checked_at":"2026-03-09T19:57:04.425Z","response_time":61,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["judge","magic-the-gathering","mtg","postgresql","python"],"created_at":"2026-03-09T22:04:52.784Z","updated_at":"2026-03-09T22:04:53.317Z","avatar_url":"https://github.com/lunakv.png","language":"Python","funding_links":["https://ko-fi.com/vaasa"],"categories":[],"sub_categories":[],"readme":"# Academy Ruins API\nProgrammatic resources for Magic: the Gathering rules documents.\n\n## About\nThis API provides access to various versions of MTG rules documents (CR, MTR, IPG), both in their raw form and (for the CR) as a structured JSON. It also contains diffs of those documents, and links to the most up-to-date version of them.\n\nIt is used to power the [Academy Ruins](https://github.com/lunakv/academyruins) project and utilized by several other MTG-related sites and services.\n\n## Setup\n### Prerequisites\n- Python 3.10 or later\n- PostgreSQL 14\n- (optional) [Pushover](https://pushover.net/) account\n- (recommended) Working Java installation\n\n### Installation\n1. Install the [Poetry](https://python-poetry.org/docs/#installation) package manager\n2. `poetry install`\n3. Start Postgres and create a user and database for your API.\n4. `cp .env_EXAMPLE .env`\n5. Adjust the values in your `.env` file according to your local configuration\n6. `poetry run ./update_schema.sh` to load the current schema into the database.\n\n### Run\n`poetry run python devstart.py`\n\nThe API server will start on port 8000 by default.\n\n### Containers\nFor production deployments, there's a prepared `Dockerfile` and `docker-compose.yml` file you can inspect and use to run the API fully contained in a Docker container. Note that if you're running Postgres in a container and want to use `psql` from the host machine, you have to map port 5432 to the host and specify the `--host localhost` flag in any `psql` command in order to connect successfully.\n\n## Documentation\nThe full API docs are available at https://api.academyruins.com/docs\n\n## Data\nAll data used by the site, both raw and processed, is periodically backed up to public a [Backblaze B2](https://www.backblaze.com/b2/) (S3 compatible) bucket. You can view the contents of this bucket at \u003chttps://backup.academyruins.com\u003e If you need bulk/programatic access to that data for some reason, send me a message through one of the channels specified [on the site](https://academyruins.com/about). \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flunakv%2Facademyruins-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flunakv%2Facademyruins-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flunakv%2Facademyruins-api/lists"}