Github API

Getting access, Developing, Testing

Back to Github

Update a reference

Input

type: object properties: parameters: type: object properties: owner: type: string description: The account owner of the repository. The name is not case sensitive. repo: type: string description: The name of the repository. The name is not case sensitive. ref: type: string description: >- The name of the fully qualified reference to update. For example, `refs/heads/master`. If the value doesn't start with `refs` and have at least two slashes, it will be rejected. required: - owner - repo - ref title: Parameters data: type: object properties: sha: type: string description: The SHA1 value to set this reference to force: type: boolean description: >- Indicates whether to force the update or to make sure the update is a fast-forward update. Leaving this out or setting it to `false` will make sure you're not overwriting work. default: false title: Data

Output

type: object title: Git Reference properties: ref: type: string node_id: type: string url: type: string format: uri object: type: object properties: type: type: string sha: description: SHA for the reference example: 7638417db6d59f3c431d3e1f261cc637155684cd type: string minLength: 40 maxLength: 40 url: type: string format: uri