-
-
Notifications
You must be signed in to change notification settings - Fork 599
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get workflow runs for a specific branch. #963
Comments
@nextgenthemes actually already implemented this case on $workflowRuns = $client->api('repo')->workflowRuns()->all('KnpLabs', 'php-github-api', [
'branch' => 'foo',
]); |
@lexor Not documented, AFAIK. Searched long and hard for the docs on this found them not linked, the last I even guessed there was maybe a one general way for each command to take parameters, searched for general docs on this and did not find anything. So again, without the claim "Extensively Documented" I would not be mad about this .... Should probably just look at the source in the first place. Ended up doing this, and that also works. $response = $client->getHttpClient()->get("/repos/$user/$repo/actions/runs?branch=$tag");
$data = Github\HttpClient\Message\ResponseMediator::getContent($response); |
Hi @nextgenthemes, this is an opensource project so we are open for contributions to improve our code, docs, tests, etc. So I you find some parts of the documentation not clear, please open a PR to improve the docs for future users. I've created #964 to keep track of this. That being said, the |
The original issue/question is resolved. The documentation changes are moved to separate issues. |
https://docs.github.com/en/rest/reference/actions#list-workflow-runs-for-a-repository
Not sure if I read this right, but it sounds like I should be able to get workflow runs for a
branch
but I can't found out how I would be able to do this with this. Seems parameters are missing completely.I am wondering why I am messing with this at all not try some PHP CURL directly. Why is this so complicated? Why does this need additional abstractions to build on top of it? Why does GitHub itself does not have an official PHP lib for this?
I guess I could use https://github.com/KnpLabs/php-github-api/blob/master/doc/request_any_route.md. I would not call this "Extensively Documented".
The text was updated successfully, but these errors were encountered: