Provision and Inspect a Git Repository
A 3-step recipe with Azure DevOps. We can help you get access.
Recipe · 3 steps
Provision and Inspect a Git Repository
with Azure DevOps · Software Construction Management
Create a repository, confirm it, and list its branches.
- Create the Git repository in the target project. The response carries the new repository ID used by later steps.
- Fetch the repository by ID to confirm it exists and capture its default branch and web URL.
- List the repository refs filtered to heads/ so the initial branches are visible after provisioning.
What you'll need to have ready
- apiVersion: Azure DevOps REST API version (e.g. 7.1).
- repositoryName: Name for the new Git repository.
- projectId: GUID of the project to create the repository in.
- accessToken: Azure DevOps bearer (OAuth 2.0) access token.
For your developer
Arazzo workflow microsoft-azure-devops:provision-and-inspect-repository, 3 operations: repositories_create → repositories_get → refs_list. Specs on APIs.io.