Create Git configuration
Create a new Git configuration for a shared model.
Authorizations
Can be either an Organization API Key or Personal Access Token (PAT).
Include in the Authorization header as: Bearer YOUR_TOKEN
Path Parameters
The unique identifier of the shared model.
Body
Clone URL of the git repository. Varies depending on the authMethod:
ssh- A string starting withgit@...https_token- A string starting withhttps://...
"git@github.com:org/repo.git"
The authentication method to use:
sshfor deploy keyhttps_tokenfor deploy token/PAT
ssh, https_token "ssh"
Deprecated. Use cloneUrl instead. The SSH URL of the git repository.
"git@github.com:org/repo.git"
Required when authMethod: https_token. HTTPS token for authentication (deploy token value, PAT, etc.).
1000^[a-zA-Z0-9_\\-.]+$The target branch for Omni pull requests.
"main"
If true, all pull requests will create a branch in Omni, even those created outside of the tool.
false
If true, the shared model is read-only and can only be updated by merging pull requests to the baseBranch.
false
The git provider type. Use auto for automatic detection based on the SSH URL.
auto- Automatically detect the providergithub- GitHubgitlab- GitLabazure_devops- Azure DevOpsbitbucket- Bitbucket Cloudbitbucket_datacenter- Bitbucket Data Center (self-hosted)
auto, github, gitlab, azure_devops, bitbucket, bitbucket_datacenter "github"
Path to model files within the repository.
"omni/blobs_r_us"
Controls when pull requests are required for changes:
always- Required for all changesusers-only- Required only for user-initiated changesnever- Never required
always, users-only, never "users-only"
Custom web URL for the git repository. Use when the cloneUrl goes through a tunnel/VPC and differs from the inferred HTTPS address.
"https://github.com/org/repo"
Applicable to SSH authentication. Supply your own RSA or ED25519 private key in PEM format (OpenSSH, PKCS#1, or PKCS#8) instead of using an Omni-generated keypair. Authorize the matching public key with your first, then set it here. See Rotate Git SSH keys with the API for step-by-step instructions.
"-----BEGIN OPENSSH PRIVATE KEY-----\n..."
Applicable to SSH authentication. Passphrase used to decrypt an encrypted deployPrivateKey. Omni uses it once to decrypt the key, then stores the key under its own encryption at rest. The passphrase itself is not retained. See Rotate Git SSH keys with the API for step-by-step instructions.
"my-secure-passphrase"
Response
Git configuration created successfully
Authentication method. ssh for deploy key, https_token for deploy token/PAT.
ssh, https_token "ssh"
Clone URL of the git repository (SSH or HTTPS)
"git@github.com:org/repo.git"
The target branch for Omni pull requests.
"main"
If true, all pull requests will create a branch in Omni, even those created outside of the tool.
false
If true, the shared model is read-only and can only be updated by merging pull requests to the base branch.
false
The git provider type.
github- GitHubgitlab- GitLabazure_devops- Azure DevOpsbitbucket- Bitbucket
github, gitlab, azure_devops, bitbucket "github"
Path to model files in the repository.
"omni/blobs_r_us"
SSH public key for repository access (deploy key). Null for HTTPS token auth (authMethod: https_token).
"ssh-ed25519 AAAA..."
Controls when pull requests are required for changes:
always- Required for all changesusers-only- Required only for user-initiated changesnever- Never required
always, users-only, never "users-only"
Deprecated. Use cloneUrl instead. SSH URL of the git repository.
"git@github.com:org/repo.git"
Custom web URL for the git repository, or null if not set.
"https://github.com/org/repo"
Webhook secret for signature verification. Only included if requested via ?include=webhookSecret.
Webhook URL to configure in your git provider.
"https://app.omni.co/api/webhooks/model/..."

