API

RepoVc

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
POST /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/commit_file create Success
POST /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge create Bookmark merge result
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/blame load Per line file blame
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/tree load Success
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/archive.zip load Materialized trunk snapshot without repository history or VCS metadata
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/blob load Success
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge_policy load Current policy and GitHub-primary eligibility
GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/trunk_tip load Trunk tip summary
PATCH /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge_policy update Updated policy

Fields

Field Type Required Description

create

POST /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/commit_file

Operation ID: api_v1_org_repo_vcs_commit_file.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
402: The organization's billing limit refuses this usage; see error.upgrade_path

application/json

Property Type Required Description
error object Yes
error.code enum: billing_limit_exceeded Yes
error.dimension_value string,null Yes
error.limit number or string Yes Decimal quantities are serialized as strings
error.message string Yes
error.meter_key string Yes A billing meter key
error.reason enum: payment_required, hard_cap, allowance_exhausted, budget_exhausted, suspended, seat_limit Yes
error.requested number or string Yes
error.upgrade_path string Yes Frontend path of the organization's billing page
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

POST /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge

Operation ID: api_v1_org_repo_vcs_merge.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Request body

application/json

Property Type Required Description
from string Yes
into string Yes

Responses

200: Bookmark merge result

application/json

Property Type Required Description
fast_forward boolean Yes
from string No
into string No
message string No
ok boolean Yes
tip_id string Yes
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

load

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/blame

Operation ID: api_v1_org_repo_vcs_blame.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes
ref query string Yes
path query string Yes

Responses

200: Per line file blame

application/json

Property Type Required Description
blame object Yes
blame.line_count integer Yes
blame.lines array of object Yes
blame.lines[].commit_id string Yes
blame.lines[].content string Yes
blame.lines[].number integer Yes
blame.truncated boolean Yes
path string Yes
ref object Yes
ref.default_branch string No
ref.name string Yes
ref.resolved_commit_id string Yes
revisions array of object Yes
revisions[].author_date string (date-time) Yes
revisions[].author_date_label string Yes
revisions[].author_email string Yes
revisions[].author_name string Yes
revisions[].id string Yes
revisions[].short_id string Yes
revisions[].summary string Yes
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/tree

Operation ID: api_v1_org_repo_vcs_tree.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes
ref query string Yes
path query string No

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/archive.zip

Operation ID: api_v1_org_repo_vcs_archive.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Responses

200: Materialized trunk snapshot without repository history or VCS metadata

application/zip

The response is string (binary).

400: Invalid virtual-repository path scope

application/json

Property Type Required Description
error string Yes
401: Authentication required

application/json

Property Type Required Description
error string Yes
403: Repository read access denied

application/json

Property Type Required Description
error string Yes
404: Repository or trunk ref not found

application/json

Property Type Required Description
error string Yes
413: Archive exceeds a configured direct-download limit

application/json

Property Type Required Description
error string Yes

application/json

Property Type Required Description
error string Yes
502: Backend repository read failed

application/json

Property Type Required Description
error string Yes
503: Archive generation exceeded its configured deadline

application/json

Property Type Required Description
error string Yes

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/blob

Operation ID: api_v1_org_repo_vcs_blob.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge_policy

Operation ID: get_api_v1_organizations_org_slug_repos_repo_slug_vcs_merge_policy.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Responses

200: Current policy and GitHub-primary eligibility

application/json

Property Type Required Description
policy object Yes
policy.auto_land_enabled boolean Yes
policy.github_connections array of object Yes
policy.github_connections[].id string Yes
policy.github_connections[].name string Yes
policy.github_merge_gate enum: branch_protection, vex_checks Yes
policy.github_primary_eligible boolean Yes
policy.merge_authority enum: vex_primary, github_primary Yes
policy.merge_authority_version integer Yes
policy.merge_github_repository_connection_id string Yes
policy.merge_policy_version integer Yes
policy.queue_concurrency integer Yes
policy.queue_concurrency_label string No
policy.queue_validation_mode enum: top_only, per_pr Yes
policy.repository_id string Yes
policy.repository_queue_concurrency integer Yes
policy.switch_blockers array of string Yes
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

GET /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/trunk_tip

Operation ID: api_v1_org_repo_vcs_trunk_tip.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Responses

200: Trunk tip summary

application/json

Property Type Required Description
trunk_tip object or null Yes
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

update

PATCH /api/v1/organizations/{org_slug}/repos/{repo_slug}/vcs/merge_policy

Operation ID: patch_api_v1_organizations_org_slug_repos_repo_slug_vcs_merge_policy.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
org_slug path string Yes
repo_slug path string Yes

Request body

application/json

Property Type Required Description
auto_land_enabled boolean No
expected_version integer Yes
github_merge_gate enum: branch_protection, vex_checks No
merge_authority enum: vex_primary, github_primary No
merge_github_repository_connection_id string No
queue_concurrency integer No
queue_validation_mode enum: top_only, per_pr No

Responses

200: Updated policy

application/json

Property Type Required Description
policy object Yes
policy.auto_land_enabled boolean Yes
policy.github_connections array of object Yes
policy.github_connections[].id string Yes
policy.github_connections[].name string Yes
policy.github_merge_gate enum: branch_protection, vex_checks Yes
policy.github_primary_eligible boolean Yes
policy.merge_authority enum: vex_primary, github_primary Yes
policy.merge_authority_version integer Yes
policy.merge_github_repository_connection_id string Yes
policy.merge_policy_version integer Yes
policy.queue_concurrency integer Yes
policy.queue_concurrency_label string No
policy.queue_validation_mode enum: top_only, per_pr Yes
policy.repository_id string Yes
policy.repository_queue_concurrency integer Yes
policy.switch_blockers array of string Yes
401: Unauthorized
403: Organization admin or owner membership is required
404: Not found
409: The policy version changed
422: The authority switch is blocked or the policy is invalid
502: Bad gateway