Repository
A repository contains the content for a project.
Implements
Connections
UserConnection!)
A list of users that can be assigned to issues in this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
query |
String
|
Filters users with query on user name and login |
BranchProtectionRuleConnection!)
A list of branch protection rules for this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
RepositoryCollaboratorConnection)
A list of collaborators associated with the repository.
| Argument | Type | Description |
|---|---|---|
affiliation |
CollaboratorAffiliation
|
Collaborators affiliation level with a repository. |
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
query |
String
|
Filters users with query on user name and login |
CommitCommentConnection!)
A list of commit comments associated with the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
DependencyGraphManifestConnection)
This part of the schema is currently available for developers to preview. During this preview period, the API may change without any advance notice. Please see the Access to a Repositories Dependency Graph preview for more details.
Note: The GraphQL resources under preview cannot be accessed via the Explorer at this time.
A list of dependency manifests contained in the repository
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
dependenciesAfter |
String
|
Cursor to paginate dependencies |
dependenciesFirst |
Int
|
Number of dependencies to fetch |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
withDependencies |
Boolean
|
Flag to scope to only manifests with dependencies |
DeployKeyConnection!)
A list of deploy keys that are on this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
DeploymentConnection!)
Deployments associated with the repository
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
environments |
[String!]
|
Environments to list deployments for |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
DeploymentOrder
|
Ordering options for deployments returned from the connection. The default value is |
RepositoryConnection!)
A list of direct forked repositories.
| Argument | Type | Description |
|---|---|---|
affiliations |
[RepositoryAffiliation]
|
Array of viewer's affiliation options for repositories returned from the connection. For example, OWNER will include only repositories that the current viewer owns. |
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
isLocked |
Boolean
|
If non-null, filters repositories according to whether they have been locked |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
RepositoryOrder
|
Ordering options for repositories returned from the connection |
ownerAffiliations |
[RepositoryAffiliation]
|
Array of owner's affiliation options for repositories returned from the connection. For example, OWNER will include only repositories that the organization or user being viewed owns. The default value is |
privacy |
RepositoryPrivacy
|
If non-null, filters repositories according to privacy |
IssueConnection!)
A list of issues that have been opened in the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
filterBy |
IssueFilters
|
Filtering options for issues returned from the connection. |
first |
Int
|
Returns the first n elements from the list. |
labels |
[String!]
|
A list of label names to filter the pull requests by. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
IssueOrder
|
Ordering options for issues returned from the connection. |
states |
[IssueState!]
|
A list of states to filter the issues by. |
LabelConnection)
A list of labels associated with the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
LabelOrder
|
Ordering options for labels returned from the connection. The default value is |
query |
String
|
If provided, searches labels by name and description. |
LanguageConnection)
A list containing a breakdown of the language composition of the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
LanguageOrder
|
Order for connection |
UserConnection!)
A list of Users that can be mentioned in the context of the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
query |
String
|
Filters users with query on user name and login |
MilestoneConnection)
A list of milestones associated with the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
MilestoneOrder
|
Ordering options for milestones. |
states |
[MilestoneState!]
|
Filter by the state of the milestones. |
PackageConnection!)
A list of packages under the owner.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
names |
[String]
|
Find packages by their names. |
orderBy |
PackageOrder
|
Ordering of the returned packages. The default value is |
packageType |
PackageType
|
Filter registry package by type. |
repositoryId |
ID
|
Find packages in a repository by ID. |
PinnedIssueConnection)
This part of the schema is currently available for developers to preview. During this preview period, the API may change without any advance notice. Please see the Pinned Issues Preview preview for more details.
Note: The GraphQL resources under preview cannot be accessed via the Explorer at this time.
A list of pinned issues for this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
ProjectConnection!)
A list of projects under the owner.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
ProjectOrder
|
Ordering options for projects returned from the connection |
search |
String
|
Query to search projects by, currently only searching by name. |
states |
[ProjectState!]
|
A list of states to filter the projects by. |
PullRequestConnection!)
A list of pull requests that have been opened in the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
baseRefName |
String
|
The base ref name to filter the pull requests by. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
headRefName |
String
|
The head ref name to filter the pull requests by. |
labels |
[String!]
|
A list of label names to filter the pull requests by. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
IssueOrder
|
Ordering options for pull requests returned from the connection. |
states |
[PullRequestState!]
|
A list of states to filter the pull requests by. |
RefConnection)
Fetch a list of refs from the repository
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
direction |
OrderDirection
|
DEPRECATED: use orderBy. The ordering direction. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
RefOrder
|
Ordering options for refs returned from the connection. |
query |
String
|
Filters refs with query on name |
refPrefix |
String!
|
A ref name prefix like |
ReleaseConnection!)
List of releases which are dependent on this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
ReleaseOrder
|
Order for connection |
RepositoryTopicConnection!)
A list of applied repository-topic associations for this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
StargazerConnection!)
A list of users who have starred this starrable.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
orderBy |
StarOrder
|
Order for connection |
SubmoduleConnection!)
Returns a list of all submodules in this repository parsed from the .gitmodules file as of the default branch's HEAD commit.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
RepositoryVulnerabilityAlertConnection)
A list of vulnerability alerts that are on this repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
UserConnection!)
A list of users watching the repository.
| Argument | Type | Description |
|---|---|---|
after |
String
|
Returns the elements in the list that come after the specified cursor. |
before |
String
|
Returns the elements in the list that come before the specified cursor. |
first |
Int
|
Returns the first n elements from the list. |
last |
Int
|
Returns the last n elements from the list. |
Fields
CodeOfConduct)
Returns the code of conduct for this repository
DateTime!)
Identifies the date and time when the object was created.
Int)
Identifies the primary key from the database.
Ref)
The Ref associated with the repository's default branch.
Boolean!)
Whether or not branches are automatically deleted when merged in this repository.
String)
The description of the repository.
HTML!)
The description of the repository rendered to HTML.
Int)
The number of kilobytes this repository occupies on disk.
Int!)
Returns how many forks there are of this repository in the whole network.
[FundingLink!]!)
The funding links for this repository
Boolean!)
Indicates if the repository has issues feature enabled.
Boolean!)
Indicates if the repository has the Projects feature enabled.
Boolean!)
Indicates if the repository has wiki feature enabled.
URI)
The repository's URL.
ID!)
Boolean!)
Indicates if the repository is unmaintained.
Boolean!)
Returns whether or not this repository disabled.
Boolean!)
Identifies if the repository is a fork.
Boolean!)
Indicates if the repository has been locked or not.
Boolean!)
Identifies if the repository is a mirror.
Boolean!)
Identifies if the repository is private.
Boolean!)
Identifies if the repository is a template that can be used to generate new repositories.
Issue)
Returns a single issue from the current repository by number.
| Argument | Type | Description |
|---|---|---|
number |
Int!
|
The number for the issue to be returned. |
IssueOrPullRequest)
Returns a single issue-like object from the current repository by number.
| Argument | Type | Description |
|---|---|---|
number |
Int!
|
The number for the issue to be returned. |
License)
The license associated with the repository
RepositoryLockReason)
The reason the repository has been locked.
Boolean!)
Whether or not PRs are merged with a merge commit on this repository.
Milestone)
Returns a single milestone from the current repository by number.
| Argument | Type | Description |
|---|---|---|
number |
Int!
|
The number for the milestone to be returned. |
URI)
The repository's original mirror URL.
String!)
The name of the repository.
String!)
The repository's name with owner.
GitObject)
A Git object in the repository
| Argument | Type | Description |
|---|---|---|
expression |
String
|
A Git revision expression suitable for rev-parse |
oid |
GitObjectID
|
The Git object ID |
URI!)
The image used to represent this repository in Open Graph data.
RepositoryOwner!)
The User owner of the repository.
Repository)
The repository parent, if this is a fork.
Language)
The primary language of the repository's code.
Project)
Find project by number.
| Argument | Type | Description |
|---|---|---|
number |
Int!
|
The project number to find. |
URI!)
The HTTP path listing the repository's projects
URI!)
The HTTP URL listing the repository's projects
PullRequest)
Returns a single pull request from the current repository by number.
| Argument | Type | Description |
|---|---|---|
number |
Int!
|
The number for the pull request to be returned. |
DateTime)
Identifies when the repository was last pushed to.
Boolean!)
Whether or not rebase-merging is enabled on this repository.
Ref)
Fetch a given ref from the repository
| Argument | Type | Description |
|---|---|---|
qualifiedName |
String!
|
The ref to retrieve. Fully qualified matches are checked in order
( |
Release)
Lookup a single release given various criteria.
| Argument | Type | Description |
|---|---|---|
tagName |
String!
|
The name of the Tag the Release was created from |
URI!)
The HTTP path for this repository
HTML!)
A description of the repository, rendered to HTML without any links in it.
| Argument | Type | Description |
|---|---|---|
limit |
Int
|
How many characters to return. The default value is |
Boolean!)
Whether or not squash-merging is enabled on this repository.
GitSSHRemote!)
The SSH URL to clone this repository
String)
Temporary authentication token for cloning this repository.
Repository)
The repository from which this repository was generated, if any.
DateTime!)
Identifies the date and time when the object was last updated.
URI!)
The HTTP URL for this repository
Boolean!)
Whether this repository has a custom image to use with Open Graph as opposed to being represented by the owner's avatar.
Boolean!)
Indicates whether the viewer has admin permissions on this repository.
Boolean!)
Can the current viewer create new projects on this owner.
Boolean!)
Check if the viewer is able to change their subscription status for the repository.
Boolean!)
Indicates whether the viewer can update the topics of this repository.
Boolean!)
Returns a boolean indicating whether the viewing user has starred this starrable.
RepositoryPermission)
The users permission level on the repository. Will return null if authenticated as an GitHub App.
SubscriptionState)
Identifies if the viewer is watching, not watching, or ignoring the subscribable entity.