{"id":19539758,"url":"https://github.com/extremeexploit/vita3k-api","last_synced_at":"2025-08-20T15:06:31.754Z","repository":{"id":199563153,"uuid":"665215900","full_name":"EXtremeExploit/vita3k-api","owner":"EXtremeExploit","description":null,"archived":false,"fork":false,"pushed_at":"2024-01-01T17:55:32.000Z","size":124,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-08T18:24:49.002Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/EXtremeExploit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-07-11T17:42:38.000Z","updated_at":"2024-07-21T16:28:49.000Z","dependencies_parsed_at":"2023-10-11T00:52:23.123Z","dependency_job_id":"64ae6a4e-6fdc-42cc-8695-14bb99b96495","html_url":"https://github.com/EXtremeExploit/vita3k-api","commit_stats":null,"previous_names":["extremeexploit/vita3k-api"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EXtremeExploit%2Fvita3k-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EXtremeExploit%2Fvita3k-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EXtremeExploit%2Fvita3k-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EXtremeExploit%2Fvita3k-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/EXtremeExploit","download_url":"https://codeload.github.com/EXtremeExploit/vita3k-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240794908,"owners_count":19858719,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-11T02:43:11.206Z","updated_at":"2025-08-02T17:08:58.711Z","avatar_url":"https://github.com/EXtremeExploit.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vita3k-api\nCloudflare worker for the cache service of the compatibility list of Vita3K\n\n## Requirements\n* npm\n* node\n* A GitHub access token, you can get one [here](https://github.com/settings/tokens)\n    * You only need to check the public_repo checkbox for it to work, no other box is needed\n\n## Setup\n* Create a D1 database in cloudflare (dw, its free :D)\n\t* You can name it whatever you want\n\n* Change the configuration (`wrangler.toml`)\n\t* **database_name:** Here goes the name of the database\n\t* **database_id:** Put here the database id you copied from the step above\n* `npm install` to install wrangler CLI dependency\n\n* Once thats done, you can choose to run it either locally or on a cloudflare worker\n\t### Locally\n    * **Even if the worker itself runs on your computer, the database doesnt**\n    * Create a file named `.dev.vars` with the following content\n        * ```ACCESS_TOKEN=YOURTOKENHERE```\n        * **REPLACE `YOURTOKENHERE` WITH THE GITHUB ACCESS TOKEN YOU GOT FROM EARLIER**\n\t* run `npx wrangler dev --test-scheduled`\n\t\t### CRON JOB WONT WORK, YOU WILL HAVE TO TRIGGER IT YOURSELF (`localhost:XXXXX/cdn-cgi/handler/scheduled`)\n\t### Online Cloudflare worker\n\t* run `npx wrangler deploy`\n\t* It will ask you permission to use wranlger on cloudflare, click allow\n\t* Now go to Settings \u003e Variables \u003e Enviroment Variables\n\t\t* Click on **Edit Variables** and add a new secret called `ACCESS_TOKEN`, and have the value be your github access token\n\t* Now once you add the enviroment variable a deploy will happen, you will have an URL to the worker and test things out, list will update every minute\n\n* If you also want to change the passwords of the `setup` and `clear` endpoints, add another key-value pair below `ACCESS_TOKEN` with key `PASSWORD` and the value being the password you want to set, the endpoints have a default password of `\"meow\"`\n## Endpoints\n* All endpoints are asuming the url is `vita3k-api.pedro.moe`\n### `GET /ping`\n* Returns pong\n* Example:\n\t* Command: \n\t```sh\n\tcurl -sL vita3k-api.pedro.moe/ping\n\t```\n\t* Returns:\n\t```js\n\t\"Pong!\"\n\t```\n\n\n### `GET /lists`\n* Returns a list of the available lists\n\n* Example: \n\t* Command:\n\t```sh\n\tcurl -sL vita3k-api.pedro.moe/lists\n\t```\n\t* Returns\n\t```js\n\t[\n\t\t{\n\t\t\t\"name\": \"commercial\", // Name of the list\n\t\t\t\"githubName\": \"Vita3K/compatibility\", // Github owner/repo of the issue list\n\t\t\t\"timestamp\": 1697056024, // UNIX time of the last changes\n\t\t\t\"labels\": [ // The labels that games should be marked with\n\t\t\t\t\"Playable\",\n\t\t\t\t\"Ingame +\",\n\t\t\t\t\"Ingame -\"\n\t\t\t\t...\n\t\t\t]\n\t\t},\n\t\t{\n\t\t\t\"name\": \"homebrew\",\n\t\t\t\"githubName\": \"Vita3K/homebrew-compatibility\",\n\t\t\t\"timestamp\": 1697056024\n\t\t\t...\n\t\t},\n\t\t...\n\t]\n\t```\n\t* **Note:** if `timestamp` is `0`, that means the list was cleared and is scheduled to being repopulated in the next minute\n\n### `GET /list/:type`\n* Arguments\n\t* `:type` = list name, same as the `name` property in [lists](#get-lists)\n* Returns the list itself, and the last update time in UNIX time\n* Example: \n\t* Command\n\t```sh\n\tcurl -sL vita3k-api.pedro.moe/list/commercial\n\t```\n\t* Returns\n\t```js\n\t{\n    \t\"date\": 1697056810, // The date at which this list has been last changed (UNIX Time)\n    \t\"list\": [\n        \t{\n            \t\"name\": \"VVVVVV\",\n            \t\"titleId\": \"PCSB00810\",\n            \t\"status\": \"Playable\",\n            \t\"color\": \"0E8A16\", // hex color for the background\n            \t\"issueId\": 1 // issue ID in the repository\n        \t},\n        \t{\n            \t\"name\": \"Duke Nukem 3D: Megaton Edition\",\n            \t\"titleId\": \"PCSB00437\",\n            \t\"status\": \"Playable\",\n            \t\"color\": \"0E8A16\",\n            \t\"issueId\": 2\n        \t},\n        \t{\n            \t\"name\": \"Downwell\",\n            \t\"titleId\": \"PCSB00952\",\n            \t\"status\": \"Playable\",\n            \t\"color\": \"0E8A16\",\n            \t\"issueId\": 3\n        \t}\n\t\t]\n\t}\n\t```\n\t* **Note**: if `date` is `0`, that means the list was cleared and is scheduled to being repopulated in the next minute\n\n### `POST /clear`\n* Body (JSON)\n    * `password` The password for the endpoint\n* Clears all the lists, for repopulation in the next cron job, also sets the lists timestamp to 0\n* Example:\n    * Command\n    ```sh\n\tcurl -X POST 'http://vita3k-api.pedro.moe/clear' \\\n      --header \"Content-Type: application/json\" \\\n      --data '{\"password\":\"meow\"}'\n\t```\n* Returns the D1 returned object with the stats of the query (changed rows, deleted rows, latency, etc)\n\n\n### `POST /setup`\n* Body (JSON)\n    * `password` The password for the endpoint\n* Deletes all the tables and recreates them for when the schema/inserts changes\n* Example:\n    * Command\n    ```sh\n\tcurl -X POST 'http://vita3k-api.pedro.moe/setup' \\\n      --header \"Content-Type: application/json\" \\\n      --data '{\"password\":\"meow\"}'\n\t```\n* Returns `Ok!` if the DB got recreated correctly\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fextremeexploit%2Fvita3k-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fextremeexploit%2Fvita3k-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fextremeexploit%2Fvita3k-api/lists"}