Start monitoring an installed GitHub repository
POST
/v1/security/repositoriesCreates safe default policy and threat-model versions. Remediation and repository writes are disabled by default. Requires an owner, administrator, or developer role and security:write.
How to call this endpoint
Every ACP API request uses bearer authentication. The examples here show the actual request path, auth header, and body shape that the platform expects.
Path, query, and header parameters
These parameters control which ACP object the endpoint acts on and how the request is processed.
Path parameters
None.
Query parameters
None.
Header parameters
| Name | Location | Type | Required | Description |
|---|---|---|---|---|
| X-Computer-Agents-Organization | header | string | No | Active organization context. If omitted, the authenticated user's personal organization is used. |
Body schema
Content type: application/json · Required
| Field | Type | Required | Description |
|---|---|---|---|
| githubRepositoryId | string | Yes | Internal ID returned by `/github/security/repositories` |
| permissionSet | object | No | — |
| metadata | object | No | Free-form metadata object. |
What the API returns
Each response code below includes the documented payload shape for the ACP API.
201Monitored repositoryapplication/json
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | Unique identifier. |
| githubRepositoryId | string | Yes | — |
| githubInstallationId | string | Yes | — |
| githubNumericRepositoryId | string | No | — |
| githubNumericInstallationId | string | No | — |
| fullName | string | Yes | — |
| defaultBranch | string | Yes | — |
| private | boolean | Yes | — |
| archived | boolean | Yes | — |
| status | active | paused | disconnected | Yes | Current lifecycle status. |
| currentPolicyVersionId | string | No | — |
| currentThreatModelVersionId | string | No | — |
| permissionSet | object | No | — |
| lastRunId | string | No | — |
| lastRunAt | string | No | — |
| nextScanAt | string | No | — |
| metadata | object | No | Free-form metadata object. |
| findingCounts | object | Yes | — |
| findingCounts.open | integer | Yes | — |
| findingCounts.critical | integer | Yes | — |
| findingCounts.high | integer | Yes | — |
| lastRunStatus | queued | running | waiting_approval | succeeded | partial | failed | cancelled | No | — |
| lastRunStage | ingest | checkout | inventory | scan | validate | triage | remediate | verify | publish | complete | No | — |
| createdAt | string | Yes | ISO 8601 timestamp. |
| updatedAt | string | Yes | ISO 8601 timestamp. |
402Insufficient budgetapplication/json
| Field | Type | Required | Description |
|---|---|---|---|
| error | string | No | — |
| message | string | No | Message text. |
| currentBudget | number | No | — |
Start monitoring an installed GitHub repository
Loading...
Response 201
Loading...