octokit / octokit.net

A GitHub API client library for .NET
https://octokitnet.readthedocs.io/en/latest/
MIT License
2.68k stars 1.07k forks source link

[FEAT]: Allow specifying per_page property for Actions.Workflows.Runs.ListByWorkflow() #2974

Closed jruales closed 4 hours ago

jruales commented 4 hours ago

Describe the need

The GitHub API documentation says that the API for "List workflow runs for a repository" takes parameters per_page (default: 30. max: 100) and page (Default: 1). However, the WorkflowRunsRequest class taken by Actions.Workflows.Runs.ListByWorkflow() doesn't have properties PerPage or Page.

SDK Version

No response

API Version

No response

Relevant log output

No response

Code of Conduct

jruales commented 4 hours ago

Oh, never mind, I just realized that Actions.Workflows.Runs.ListByWorkflow() does have a signature that allows passing in ApiOptions, which allows specifying PageSize https://github.com/octokit/octokit.net/blob/28ae4ef85339e3cd8ef65a4e293790fb811d224a/Octokit/Clients/IActionsWorkflowRunsClient.cs#L265