Rotate webhook secret
This endpoint requires Modeler permissions or higher.
Rotate the pull request webhook signing secret for a shared model’s Git configuration, and return the updated Git configuration with the new secret. The previous secret stops validating webhook deliveries immediately.
If the git repository is shared across multiple models, the secret belongs to whichever model owns the shared configuration. Rotating the secret for any of the sharing models rotates the one shared secret for all of them.
This is the only endpoint that returns the new secret value. Call GET /v1/models/{modelId}/git?include=webhookSecret to retrieve it after the rotation, if needed.
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.
Response
Webhook secret rotated successfully. The response includes the new webhook secret.
Authentication method. "ssh" for deploy key, "https_token" for deploy token/PAT, "github_app" for a GitHub App installation.
ssh, https_token, github_app "ssh"
The target branch for Omni pull requests
"main"
If true, all pull requests will create a branch in Omni
false
Clone URL of the git repository (SSH or HTTPS)
"git@github.com:org/repo.git"
Committer email written into signed commits (github_app auth). Null when signing is not configured.
"omni-bot@example.com"
Committer display name written into signed commits (github_app auth). Null when signing is not configured.
"Omni Bot"
SSHSIG signing public key to register on the committer's GitHub user (github_app auth). Null for other auth methods.
"ssh-ed25519 AAAA..."
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"
GitHub App installation ID. Null unless github_app auth.
"12345678"
Path to model files in the repository
"omni/my_model"
SSH public key for repository access (deploy key). Null for HTTPS token auth.
"ssh-ed25519 AAAA..."
When pull requests are required: always for all changes, users-only for user-initiated changes only, never for direct commits.
always, users-only, never "users-only"
Deprecated — use cloneUrl. Clone URL of the git repository.
Custom web URL for the git repository, or null if not set
"https://github.com/org/repo"
The new webhook secret. Returned only here — read it back later with GET /git?include=webhookSecret.
Webhook URL to configure in your git provider
"https://app.omni.co/api/webhooks/model/..."

