Skip to content
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.

A tool for retrieving Open Pull Request information for GitHub users

License

Notifications You must be signed in to change notification settings

brminnick/GitHubPullRequestsTool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHubPullRequestsTool

A tool leveraging GitHub's GraphQL API that retrieves GitHub Repositories to understand the total count of open Pull Requests.

GitHubGraphQLApiService.GetRepositories

Retrieves every GitHub repository for a specific user

IAsyncEnumerable<IEnumerable<Repository>> GetRepositories(string repositoryOwner, GitHubToken authorizationToken, [EnumeratorCancellation] CancellationToken cancellationToken, int numberOfRepositoriesPerRequest = 100)

Example

await foreach (var repositories in gitHubGraphQLApiService.GetRepositories("brminnick", new GitHubToken("Insert Your GitHubToken Here", "bearer"), CancellationToken.None).ConfigureAwait(false))
{
    foreach (var repository in repositories)
    {
        System.Console.WriteLine(repository);
    }
}

GitHubGraphQLApiService.GetRepository

Retrieves a specific GitHub Repository

Task<Repository> GetRepository(string repositoryOwner, string repositoryName, GitHubToken authorizationToken, CancellationToken cancellationToken)

Example

var gitTrendsRepository = await gitHubGraphQLApiService.GetRepository("brminnick", "GitTrends", new GitHubToken("Insert Your GitHubToken Here", "bearer"), CancellationToken.None).ConfigureAwait(false);
System.Console.WriteLine(gitTrendsRepository);

Repository

class Repository
{
  public DateTimeOffset DataDownloadedAt { get; }
  public string OwnerLogin { get; }
  public string OwnerAvatarUrl { get; }
  public long PullRequestCount { get; }
  public string Name { get; }
  public string Description { get; }
  public bool IsFork { get; }
  public string Url { get; }
}

Releases

No releases published

Packages

No packages published

Languages