Skip to main content

refs

Overview

Namerefs
TypeResource
Idgithub.git.refs

Fields

NameDatatype
refstring
urlstring
node_idstring
objectobject

Methods

NameAccessible byRequired ParamsDescription
get_refSELECTowner, ref, repoReturns a single reference from your Git database. The :ref in the URL must be formatted as heads/<branch name> for branches and tags/<tag name> for tags. If the :ref doesn't match an existing ref, a 404 is returned.

Note: You need to explicitly request a pull request to trigger a test merge commit, which checks the mergeability of pull requests. For more information, see "Checking mergeability of pull requests".
create_refINSERTowner, repo, data__ref, data__shaCreates a reference for your repository. You are unable to create new references for empty repositories, even if the commit SHA-1 hash used exists. Empty repositories are repositories without branches.
delete_refDELETEowner, ref, repo
update_refEXECowner, ref, repo, data__sha