{"id":16558456,"url":"https://github.com/leaking/gitknife","last_synced_at":"2026-05-05T16:01:45.001Z","repository":{"id":36551873,"uuid":"40857732","full_name":"Leaking/GitKnife","owner":"Leaking","description":"An Android library for Github API","archived":false,"fork":false,"pushed_at":"2015-08-17T09:02:54.000Z","size":260,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-15T11:00:11.676Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Leaking.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-08-17T02:45:38.000Z","updated_at":"2017-10-31T17:19:04.000Z","dependencies_parsed_at":"2022-09-04T15:50:48.560Z","dependency_job_id":null,"html_url":"https://github.com/Leaking/GitKnife","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Leaking%2FGitKnife","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Leaking%2FGitKnife/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Leaking%2FGitKnife/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Leaking%2FGitKnife/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Leaking","download_url":"https://codeload.github.com/Leaking/GitKnife/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241945473,"owners_count":20046865,"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-10-11T20:10:47.835Z","updated_at":"2025-12-02T18:05:16.904Z","avatar_url":"https://github.com/Leaking.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitKnife\nAn Android library for Github API,I have use it in [WeGit](https://github.com/Leaking/WeGit).\n\n# About The Github API\n\nYou can read the API documents in [https://developer.github.com/v3/](https://developer.github.com/v3/).\n\n\n\n# Rate Limiting\nWithout authorizations,the rate limiting is 60 per minute,With authorizations,the rate limiting is 5000 per minute.So you had better add token in your every request.\n\n\n# Token\nIn the latest API,you can not get existing token,so if you want to get existing token you need to delete it and re-create it.\n\n\n# How to use it\n\n\n\n## Init\n\n```java\nGithub github = new GithubImpl(context);\n```\n\n## Create Token\n\n```java\nString token = github.createToken(username,password);\n```\n\n## Get Login User\n\n```java\nUser user = github.authUser(token);\n```\n\n## Get Certain User\n\n```java\nUser user = github.user(username);\n```\n\n## Repositories\n\n```java\nrepos = github.repo(user, page);                  \n```\n\n## Starred Repositories\n\n```java\nrepos = github.starred(user, page);\n```\n\n## Followings\n\n```java\nusers = github.follwerings(user, page);\n```\n\n## Your Followers\n\n```java\nusers = github.followers(user, page);\n```\n\n## If you has followed someone\n\n```java\ngithub.makeAuthRequest(token);\nboolean ifFollow = github.hasFollow(targetUser);\n```\n\n## Unfollow someone\n\n```java\ngithub.makeAuthRequest(token);\nboolean success = github.unfollow(targetUser);\n```\n\n## Follow someone\n\n```java\ngithub.makeAuthRequest(token);\nboolean success = github.follow(targetUser);\n```\n\n## If you has starred Repo X\n\n```java\nboolean hasStar = github.hasStarRepo(owner, repo);\n```\n\n## Star Repo X\n\n```java\ngithub.makeAuthRequest(token);\nboolean success = github.starRepo(owner, repo);\n```\n\n## Unstar Repo X\n\n```java\ngithub.makeAuthRequest(token);\nboolean success = github.unStarRepo(owner, repo);\n\n\n## Received Event\n\n```java\nevents = github.receivedEvent(user, page);\n```\n\n## Stargzers of Repo X\n\n```java\nusers = github.stargazers(owner,repo,page);\n```\n\n## Forkers of Repo X\n\n```java\nusers = github.forkers(owner,repo,page);\n```\n\n## Load content of Repo X\n\n```java\nTree tree  = github.getTree(owner, repo, sha);\n```\n\n\n## LICENSE\n\n   Copyright 2015 Quinn Chen\n\n   Licensed under the Apache License, Version 2.0 (the \"License\");\n   you may not use this file except in compliance with the License.\n   You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n   Unless required by applicable law or agreed to in writing, software\n   distributed under the License is distributed on an \"AS IS\" BASIS,\n   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n   See the License for the specific language governing permissions and\n   limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleaking%2Fgitknife","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleaking%2Fgitknife","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleaking%2Fgitknife/lists"}