github.getBranch gets one repository branch.
automations/get-github-branch.automation.ts
owner, repository, and the branch name without refs/heads/. Returns the branch name and head commit sha. Requires Contents read permission.Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Get one GitHub branch and its protection metadata.
github.getBranch gets one repository branch.
import { automation } from "automate.ax"
import { github } from "automate.ax/github"
export default automation("Get main branch", () => {
const branch = github.getBranch({
branch: "main",
owner: "SentsCo",
repository: "automate.ax",
})
})
owner, repository, and the branch name without refs/heads/. Returns the branch name and head commit sha. Requires Contents read permission.