Replace a source's details
better-auth.session_token<token>Better Auth session cookie. Production uses the __Secure- prefixed name.
sourceId*stringuuidIdempotency-Key?stringMakes retries safe. A repeated key with the same request returns the first result and sets
Idempotent-Replayed: true. The same key with a different request answers 409
idempotency.key_reused, and while the first request is still running 409
idempotency.in_progress. Results are kept for 24 hours. Server errors and refusals for lack
of sign-in or permission are not kept, so a retry runs again.
^[A-Za-z0-9_.:-]+$1 <= length <= 255application/json- body
name*string1 <= length <= 63kind*SourceKind"git""oci"url*stringA git URL (https://host/repo, ssh://host/repo or user@host:repo) or an OCI reference (oci://host/path). It never holds a password.
1 <= length <= 2048path?stringlength <= 512""credentialsRef?stringThe name of a secret in the secret store, a GitHub App installation (github-app:<installation id>), or a git host connection (githost:<connection id>, from connectGitHost).
length <= 256""The updated source.
application/json- response
id*stringuuidname*stringkind*SourceKind"git""oci"url*stringThe repository URL, or the OCI reference.
path*stringThe directory inside the repository that holds the manifests. Empty for the root, and for OCI.
credentialsRef*stringThe name of the secret in the secret store that holds the credentials. Empty for none.
createdAt*stringdate-timeupdatedAt*stringdate-timecurl -X PUT 'https://wardn.example.com/api/v1/sources/497f6eca-6276-4993-bfeb-53cbbbba6f08' \ -H 'Content-Type: application/json' \ -d '{ "name": "string", "kind": "git", "url": "string"}'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "kind": "git", "url": "string", "path": "string", "credentialsRef": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Delete a source DELETE
A source that an app still uses cannot be deleted.
List the branches of a git source GET
The branches the repository has now, by name, each with the commit it points at. Asked of the repository itself, so a deployment form can offer the real branches. An OCI source has none and answers Invalid. A repository that cannot be reached answers Unavailable.