GitHub · Arazzo Workflow

GitHub Verify a Branch and Merge It

Version 1.0.0

Confirm a head branch exists, then merge it into a base branch.

1 workflow 1 source API 1 provider
View Spec View on GitHub CodePipelinesPlatformSoftware DevelopmentSource ControlT1ArazzoWorkflows

Provider

github

Workflows

verify-and-merge-branch
Verify a head branch exists then merge it into a base branch.
Reads the head branch to confirm it exists and then merges it into the base branch with a custom commit message.
2 steps inputs: baseBranch, commitMessage, githubToken, headBranch, owner, repo outputs: headSha, mergeSha, mergeUrl
1
verifyHeadBranch
Read the head branch to confirm it exists before attempting the merge.
2
mergeIntoBase
Merge the verified head branch into the base branch with the supplied commit message.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: GitHub Verify a Branch and Merge It
  summary: Confirm a head branch exists, then merge it into a base branch.
  description: >-
    A server-side branch integration pattern that does not require a pull
    request. The workflow verifies the head branch exists and reads its tip
    commit, then performs a merge of that head branch into the base branch.
    Every step spells out its request inline so the flow can be read and
    executed without opening the underlying OpenAPI description.
  version: 1.0.0
  x-realizes-capability-ids:
  - BC-4200.40
  x-capability-derivation:
    method: 'deterministic join: sourceDescriptions -> per-tag OpenAPI -> tag/capability edge. No classification at this step.'
    min_confidence: 0.7
    sources:
    - capability_id: BC-4200.40
      capability_name: Software Construction Management
      spec: github-repos-api-openapi.yml
      confidence: 0.75
    model: Turbo EA Capabilities by Vincent Verdet — Turbo EA, https://github.com/vincentmakes/turbo-ea-capabilities, CC BY 4.0
sourceDescriptions:
- name: reposApi
  url: ../openapi/github-repos-api-openapi.yml
  type: openapi
workflows:
- workflowId: verify-and-merge-branch
  summary: Verify a head branch exists then merge it into a base branch.
  description: >-
    Reads the head branch to confirm it exists and then merges it into the base
    branch with a custom commit message.
  inputs:
    type: object
    required:
    - githubToken
    - owner
    - repo
    - headBranch
    - baseBranch
    properties:
      githubToken:
        type: string
        description: A GitHub token with repo scope, passed as a Bearer credential.
      owner:
        type: string
        description: The account owner of the repository.
      repo:
        type: string
        description: The name of the repository.
      headBranch:
        type: string
        description: The branch to merge in (the head of the merge).
      baseBranch:
        type: string
        description: The branch to receive the merge (the base of the merge).
      commitMessage:
        type: string
        description: The commit message to use for the merge commit.
  steps:
  - stepId: verifyHeadBranch
    description: >-
      Read the head branch to confirm it exists before attempting the merge.
    operationId: repos/get-branch
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.githubToken
    - name: owner
      in: path
      value: $inputs.owner
    - name: repo
      in: path
      value: $inputs.repo
    - name: branch
      in: path
      value: $inputs.headBranch
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      headSha: $response.body#/commit/sha
  - stepId: mergeIntoBase
    description: >-
      Merge the verified head branch into the base branch with the supplied
      commit message.
    operationId: repos/merge
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.githubToken
    - name: owner
      in: path
      value: $inputs.owner
    - name: repo
      in: path
      value: $inputs.repo
    requestBody:
      contentType: application/json
      payload:
        base: $inputs.baseBranch
        head: $inputs.headBranch
        commit_message: $inputs.commitMessage
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      mergeSha: $response.body#/sha
      mergeUrl: $response.body#/html_url
  outputs:
    headSha: $steps.verifyHeadBranch.outputs.headSha
    mergeSha: $steps.mergeIntoBase.outputs.mergeSha
    mergeUrl: $steps.mergeIntoBase.outputs.mergeUrl

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/github-verify-and-merge-branch-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.