Questions tagged [github-api-v3]
120 questions
3
votes
1 answer
Using GitHub REST APIv3 for global code search
I am new to REST API. I am trying to create a query to search all the java repositories which contains com.jcabi.http.response.JsonResponse in its code.
I created following request by looking at the example given in the API documentation and my…

ShaAk
- 190
- 1
- 12
3
votes
0 answers
Github API extremely slow request with Octokit
trying to query the github api with octokit,
I have the following function which takes 3-4 minutes, does anyone see an obvious problem for why it takes so slow ?
I'm trying to find the top contributors within an organization, by looping through…

sco
- 367
- 3
- 14
2
votes
2 answers
Is it possible to create a user project (V2) with a github app?
I am trying to create a projectV2 with Github's Graphql API, through a Github App, because they have deprecated their classical projects, and if you try to create a project in a repository that doesn't have one previously associated Github doesn't…

Figares
- 63
- 6
2
votes
1 answer
How to add authentication to URL() or JsonSlurper()
I have a groovy script that closes old pull requests. The part where it fetches the open pull requests worked before with an access token:
String json = new URL("${giteaUrl}/api/v1/repos/projectname/reponame/pulls?page=${page}&state=all" +
…

mles
- 4,534
- 10
- 54
- 94
2
votes
0 answers
Setting Accept Headers in PyGithub API for getting commit diff
I want to get the result of the below query using PyGithub. Is there a way to set accept header in pygithub? I want the output in diff format and I don't want to use github compare API.
So is there a way to make below request using pygithub?
curl \
…

Hardik Upadhyay
- 21
- 3
2
votes
0 answers
Get GitHub repository detail info, branches info with default_branch's all sources in one API request?
I can use these three API to get those result.
Repo info API: GET /repos/{owner}/{repo}/
Branch API: GET /repos/{owner}/{repo}/branches
Tree API: GET /repos/{owner}/{repo}/git/trees/{tree_sha}?recursive=true
But it will cost me three API calls.…

minhazmiraz
- 442
- 4
- 12
2
votes
1 answer
Automating GitHub API for creating repos/Gists return 200 OK instead of 201 Created
I use Postman to Create a gist and I added bearer token in the authorization Tab but it suppose to create a gist and return 201 Created instead it returns 200 OK and it doesn't create anything
enter image description here
I have written in the…

Deena M. Zamzam
- 23
- 6
2
votes
1 answer
Github api to get all the commits done to given repository branch
I am trying to get all the commits given to develop branch of repository test using github api but I am always getting first page no matter how i pass the query params. Not sure what's wrong in the request I am sending.
curl -u username:$token -H…

codeaprendiz
- 2,703
- 1
- 25
- 49
2
votes
1 answer
access git blobs via APIs
I am struggling to access my git file using git APIs.
official Documentation : https://developer.github.com/v3/git/blobs/
Tha command I execute :
curl -v -H "Authorization: token 111111111111111111111111111" -H
"Accept: …

UtpMahesh
- 410
- 10
- 25
2
votes
0 answers
"message": "Must have admin rights to Repository." for personal token in standard github account
I am using Github API with the personal access token, from a standard GitHub account.
although the token has the permission to delete the repo.
I am still getting :
'''
{
"message": "Must have admin rights to Repository.",
"documentation_url":…

Akanksha Singh
- 57
- 5
2
votes
1 answer
GitHub commits not verified despite matching GPG Key ID
On the command line I generated a new key pair using the github-api-signature package's generateKeyPair function, providing a name and email of my GitHub account and a random passphrase.
I took the public part of the generated key pair and put it in…

Tom
- 2,734
- 2
- 22
- 39
2
votes
0 answers
Upload zip in github using Github API
Im trying to upload zip file to github repository using github api. Sometimes to upload zip in particular branch. But all fails.
Try 1
curl -XPOST -H "Authorization:token XYZ” -H "Content-Type:application/octet-stream" --data-binary @myfile.ipa…

xemeg
- 21
- 1
2
votes
2 answers
Creating Issue using GitHub API
I am trying to create an Issue in my own repo using Github API, but for some reason it keeps throwing me an error
Route::post('/issue/create/{repo}',function ($_repo){
$client = new Client([
// Base URI is used with relative requests
…

Rehan
- 3,813
- 7
- 37
- 58
2
votes
1 answer
Multibranch job scan fails to discover remote GitHub repo tags
I'm using a Multibranch pipeline job to discover branches/tags/PRs and execute certain jobs. I got repos on GitHub and scan is able to discover all but not tags. I get below error. Also, when the Discover tags option is disabled in multibranch job…

prabhu34
- 67
- 11
2
votes
1 answer
Unable to Create an Issue for an Organization Repo Using GitHub API v3
I want to create an issue for an org repo using enterprise GitHub API, but unable to do that with curl
I am using
curl -u $username -d '{"title":"Big Files List", "label":"big files","body": "'$(find -type f -size +150M)'"}' …
user6934519