Object GitHub::Repository

A repository contains the content for a project.

Fields

assignableUsers(query: String, after: String, before: String, first: Int, last: Int): UserConnection!

A list of users that can be assigned to issues in this repository.

Args

query: String

Filters users with query on user name and login

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.

branchProtectionRules(after: String, before: String, first: Int, last: Int): BranchProtectionRuleConnection!

A list of branch protection rules for this repository.

Args

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.

codeOfConduct: CodeOfConduct

Returns the code of conduct for this repository

collaborators(affiliation: CollaboratorAffiliation, query: String, after: String, before: String, first: Int, last: Int): RepositoryCollaboratorConnection

A list of collaborators associated with the repository.

Args

affiliation: CollaboratorAffiliation

Collaborators affiliation level with a repository.

query: String

Filters users with query on user name and login

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.

commitComments(after: String, before: String, first: Int, last: Int): CommitCommentConnection!

A list of commit comments associated with the repository.

Args

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.

createdAt: DateTime!

Identifies the date and time when the object was created.

databaseId: Int

Identifies the primary key from the database.

defaultBranchRef: Ref

The Ref associated with the repository's default branch.

deleteBranchOnMerge: Boolean!

Whether or not branches are automatically deleted when merged in this repository.

deployKeys(after: String, before: String, first: Int, last: Int): DeployKeyConnection!

A list of deploy keys that are on this repository.

Args

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.

deployments(environments: [String!], orderBy: DeploymentOrder = {field: CREATED_AT, direction: ASC}, after: String, before: String, first: Int, last: Int): DeploymentConnection!

Deployments associated with the repository

Args

environments: [String!]

Environments to list deployments for

orderBy: DeploymentOrder = {field: CREATED_AT, direction: ASC}

Ordering options for deployments returned from the connection.

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.

description: String

The description of the repository.

descriptionHTML: HTML!

The description of the repository rendered to HTML.

diskUsage: Int

The number of kilobytes this repository occupies on disk.

forkCount: Int!

Returns how many forks there are of this repository in the whole network.

forks(privacy: RepositoryPrivacy, orderBy: RepositoryOrder, affiliations: [RepositoryAffiliation], ownerAffiliations: [RepositoryAffiliation] = [OWNER, COLLABORATOR], isLocked: Boolean, after: String, before: String, first: Int, last: Int): RepositoryConnection!

A list of direct forked repositories.

Args

privacy: RepositoryPrivacy

If non-null, filters repositories according to privacy

orderBy: RepositoryOrder

Ordering options for repositories returned from the connection

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.

ownerAffiliations: [RepositoryAffiliation] = [OWNER, COLLABORATOR]

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.

isLocked: Boolean

If non-null, filters repositories according to whether they have been locked

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.

hasIssuesEnabled: Boolean!

Indicates if the repository has issues feature enabled.

hasProjectsEnabled: Boolean!

Indicates if the repository has the Projects feature enabled.

hasWikiEnabled: Boolean!

Indicates if the repository has wiki feature enabled.

homepageUrl: URI

The repository's URL.

id: ID!

isArchived: Boolean!

Indicates if the repository is unmaintained.

isDisabled: Boolean!

Returns whether or not this repository disabled.

isEmpty: Boolean!

Returns whether or not this repository is empty.

isFork: Boolean!

Identifies if the repository is a fork.

isLocked: Boolean!

Indicates if the repository has been locked or not.

isMirror: Boolean!

Identifies if the repository is a mirror.

isPrivate: Boolean!

Identifies if the repository is private.

isTemplate: Boolean!

Identifies if the repository is a template that can be used to generate new repositories.

issue(number: Int!): Issue

Returns a single issue from the current repository by number.

Args

number: Int!

The number for the issue to be returned.

issueOrPullRequest(number: Int!): IssueOrPullRequest

Returns a single issue-like object from the current repository by number.

Args

number: Int!

The number for the issue to be returned.

issues(orderBy: IssueOrder, labels: [String!], states: [IssueState!], filterBy: IssueFilters, after: String, before: String, first: Int, last: Int): IssueConnection!

A list of issues that have been opened in the repository.

Args

orderBy: IssueOrder

Ordering options for issues returned from the connection.

labels: [String!]

A list of label names to filter the pull requests by.

states: [IssueState!]

A list of states to filter the issues by.

filterBy: IssueFilters

Filtering options for issues returned from the connection.

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.

label(name: String!): Label

Returns a single label by name

Args

name: String!

Label name

labels(orderBy: LabelOrder = {field: CREATED_AT, direction: ASC}, after: String, before: String, first: Int, last: Int, query: String): LabelConnection

A list of labels associated with the repository.

Args

orderBy: LabelOrder = {field: CREATED_AT, direction: ASC}

Ordering options for labels returned from the connection.

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

If provided, searches labels by name and description.

languages(after: String, before: String, first: Int, last: Int, orderBy: LanguageOrder): LanguageConnection

A list containing a breakdown of the language composition of the repository.

Args

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

licenseInfo: License

The license associated with the repository

lockReason: RepositoryLockReason

The reason the repository has been locked.

mentionableUsers(query: String, after: String, before: String, first: Int, last: Int): UserConnection!

A list of Users that can be mentioned in the context of the repository.

Args

query: String

Filters users with query on user name and login

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.

mergeCommitAllowed: Boolean!

Whether or not PRs are merged with a merge commit on this repository.

milestone(number: Int!): Milestone

Returns a single milestone from the current repository by number.

Args

number: Int!

The number for the milestone to be returned.

milestones(after: String, before: String, first: Int, last: Int, states: [MilestoneState!], orderBy: MilestoneOrder, query: String): MilestoneConnection

A list of milestones associated with the repository.

Args

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.

states: [MilestoneState!]

Filter by the state of the milestones.

orderBy: MilestoneOrder

Ordering options for milestones.

query: String

Filters milestones with a query on the title

mirrorUrl: URI

The repository's original mirror URL.

name: String!

The name of the repository.

nameWithOwner: String!

The repository's name with owner.

object(oid: GitObjectID, expression: String): GitObject

A Git object in the repository

Args

oid: GitObjectID

The Git object ID

expression: String

A Git revision expression suitable for rev-parse

openGraphImageUrl: URI!

The image used to represent this repository in Open Graph data.

owner: RepositoryOwner!

The User owner of the repository.

packages(after: String, before: String, first: Int, last: Int, names: [String], repositoryId: ID, packageType: PackageType, orderBy: PackageOrder = {field: CREATED_AT, direction: DESC}): PackageConnection!

A list of packages under the owner.

Args

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.

repositoryId: ID

Find packages in a repository by ID.

packageType: PackageType

Filter registry package by type.

orderBy: PackageOrder = {field: CREATED_AT, direction: DESC}

Ordering of the returned packages.

parent: Repository

The repository parent, if this is a fork.

primaryLanguage: Language

The primary language of the repository's code.

project(number: Int!): Project

Find project by number.

Args

number: Int!

The project number to find.

projects(orderBy: ProjectOrder, search: String, states: [ProjectState!], after: String, before: String, first: Int, last: Int): ProjectConnection!

A list of projects under the owner.

Args

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.

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.

projectsResourcePath: URI!

The HTTP path listing the repository's projects

projectsUrl: URI!

The HTTP URL listing the repository's projects

pullRequest(number: Int!): PullRequest

Returns a single pull request from the current repository by number.

Args

number: Int!

The number for the pull request to be returned.

pullRequests(states: [PullRequestState!], labels: [String!], headRefName: String, baseRefName: String, orderBy: IssueOrder, after: String, before: String, first: Int, last: Int): PullRequestConnection!

A list of pull requests that have been opened in the repository.

Args

states: [PullRequestState!]

A list of states to filter the pull requests by.

labels: [String!]

A list of label names to filter the pull requests by.

headRefName: String

The head ref name to filter the pull requests by.

baseRefName: String

The base ref name to filter the pull requests by.

orderBy: IssueOrder

Ordering options for pull requests returned from the connection.

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.

pushedAt: DateTime

Identifies when the repository was last pushed to.

rebaseMergeAllowed: Boolean!

Whether or not rebase-merging is enabled on this repository.

ref(qualifiedName: String!): Ref

Fetch a given ref from the repository

Args

qualifiedName: String!

The ref to retrieve. Fully qualified matches are checked in order (refs/heads/master) before falling back onto checks for short name matches (master).

refs(query: String, after: String, before: String, first: Int, last: Int, refPrefix: String!, direction: OrderDirection, orderBy: RefOrder): RefConnection

Fetch a list of refs from the repository

Args

query: String

Filters refs with query on name

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.

refPrefix: String!

A ref name prefix like refs/heads/, refs/tags/, etc.

direction: OrderDirection

DEPRECATED: use orderBy. The ordering direction.

orderBy: RefOrder

Ordering options for refs returned from the connection.

release(tagName: String!): Release

Lookup a single release given various criteria.

Args

tagName: String!

The name of the Tag the Release was created from

releases(after: String, before: String, first: Int, last: Int, orderBy: ReleaseOrder): ReleaseConnection!

List of releases which are dependent on this repository.

Args

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

repositoryTopics(after: String, before: String, first: Int, last: Int): RepositoryTopicConnection!

A list of applied repository-topic associations for this repository.

Args

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.

resourcePath: URI!

The HTTP path for this repository

shortDescriptionHTML(limit: Int = 200): HTML!

A description of the repository, rendered to HTML without any links in it.

Args

limit: Int = 200

How many characters to return.

squashMergeAllowed: Boolean!

Whether or not squash-merging is enabled on this repository.

sshUrl: GitSSHRemote!

The SSH URL to clone this repository

stargazers(after: String, before: String, first: Int, last: Int, orderBy: StarOrder): StargazerConnection!

A list of users who have starred this starrable.

Args

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

submodules(after: String, before: String, first: Int, last: Int): SubmoduleConnection!

Returns a list of all submodules in this repository parsed from the .gitmodules file as of the default branch's HEAD commit.

Args

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.

tempCloneToken: String

Temporary authentication token for cloning this repository.

templateRepository: Repository

The repository from which this repository was generated, if any.

updatedAt: DateTime!

Identifies the date and time when the object was last updated.

url: URI!

The HTTP URL for this repository

usesCustomOpenGraphImage: Boolean!

Whether this repository has a custom image to use with Open Graph as opposed to being represented by the owner's avatar.

viewerCanAdminister: Boolean!

Indicates whether the viewer has admin permissions on this repository.

viewerCanCreateProjects: Boolean!

Can the current viewer create new projects on this owner.

viewerCanSubscribe: Boolean!

Check if the viewer is able to change their subscription status for the repository.

viewerCanUpdateTopics: Boolean!

Indicates whether the viewer can update the topics of this repository.

viewerDefaultCommitEmail: String

The last commit email for the viewer.

viewerDefaultMergeMethod: PullRequestMergeMethod!

The last used merge method by the viewer or the default for the repository.

viewerHasStarred: Boolean!

Returns a boolean indicating whether the viewing user has starred this starrable.

viewerPermission: RepositoryPermission

The users permission level on the repository. Will return null if authenticated as an GitHub App.

viewerPossibleCommitEmails: [String!]

A list of emails this viewer can commit with.

viewerSubscription: SubscriptionState

Identifies if the viewer is watching, not watching, or ignoring the subscribable entity.

vulnerabilityAlerts(after: String, before: String, first: Int, last: Int): RepositoryVulnerabilityAlertConnection

A list of vulnerability alerts that are on this repository.

Args

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.

watchers(after: String, before: String, first: Int, last: Int): UserConnection!

A list of users watching the repository.

Args

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.

Uses

ArchiveRepositoryPayload.repository

Blob.repository

BranchProtectionRule.repository

CloneTemplateRepositoryPayload.repository

Commit.repository

CommitComment.repository

CommitCommentThread.repository

CommitContributionsByRepository.repository

CreateRepositoryPayload.repository

CreatedCommitContribution.repository

CreatedPullRequestReviewContribution.repository

CreatedRepositoryContribution.repository

DeleteIssuePayload.repository

Deployment.repository

Issue.repository

IssueComment.repository

IssueContributionsByRepository.repository

Label.repository

LinkRepositoryToProjectPayload.repository

Milestone.repository

OrgRestoreMemberMembershipRepositoryAuditEntryData.repository

Organization.repository

Package.repository

PrivateRepositoryForkingDisableAuditEntry.repository

PrivateRepositoryForkingEnableAuditEntry.repository

PullRequest.baseRepository

PullRequest.headRepository

PullRequest.repository

PullRequestCommitCommentThread.repository

PullRequestContributionsByRepository.repository

PullRequestReview.repository

PullRequestReviewComment.repository

PullRequestReviewContributionsByRepository.repository

PullRequestReviewThread.repository

Query.repository

Ref.repository

ReferencedEvent.commitRepository

RepoAccessAuditEntry.repository

RepoAddMemberAuditEntry.repository

RepoAddTopicAuditEntry.repository

RepoArchivedAuditEntry.repository

RepoChangeMergeSettingAuditEntry.repository

RepoConfigDisableAnonymousGitAccessAuditEntry.repository

RepoConfigDisableCollaboratorsOnlyAuditEntry.repository

RepoConfigDisableContributorsOnlyAuditEntry.repository

RepoConfigDisableSockpuppetDisallowedAuditEntry.repository

RepoConfigEnableAnonymousGitAccessAuditEntry.repository

RepoConfigEnableCollaboratorsOnlyAuditEntry.repository

RepoConfigEnableContributorsOnlyAuditEntry.repository

RepoConfigEnableSockpuppetDisallowedAuditEntry.repository

RepoConfigLockAnonymousGitAccessAuditEntry.repository

RepoConfigUnlockAnonymousGitAccessAuditEntry.repository

RepoCreateAuditEntry.repository

RepoDestroyAuditEntry.repository

RepoRemoveMemberAuditEntry.repository

RepoRemoveTopicAuditEntry.repository

Repository.parent

Repository.templateRepository

RepositoryConnection.nodes

RepositoryEdge.node

RepositoryVulnerabilityAlert.repository

StarredRepositoryConnection.nodes

StarredRepositoryEdge.node

Tag.repository

TeamAddRepositoryAuditEntry.repository

TeamRemoveRepositoryAuditEntry.repository

TeamRepositoryConnection.nodes

TeamRepositoryEdge.node

TransferredEvent.fromRepository

Tree.repository

TreeEntry.repository

UnarchiveRepositoryPayload.repository

UnlinkRepositoryFromProjectPayload.repository

UpdateRepositoryPayload.repository

UpdateTopicsPayload.repository

User.repository

GitObject.repository

RepositoryAuditEntryData.repository

RepositoryNode.repository

RepositoryOwner.repository

PermissionGranter

PinnableItem

SearchResultItem

Node

PackageOwner

ProjectOwner

RepositoryInfo

Starrable

Subscribable

UniformResourceLocatable