/api/v1/reposEndpoint 1 · listConnectedReposList every GitHub repo Bracework is connected to for the signed-in tenant, ordered by most-recent scan.
Cookie gate — send the better-auth session.
Send the better-auth session cookie set after /login or /signup as `Cookie:`. Endpoints return 401 {"error":"Unauthorized"} when the cookie is missing, expired, or invalid. Bracework v1 ships with cookie auth today — there is no bearer-token issuance, no API key surface, and no separate token endpoint.
Worked curl and response examples for /api/v1/repos
# Set HOST to your Bracework deployment before running curl.
# Production: export HOST="https://bracework.example.com"
# Local dev: export HOST="http://localhost:3000"
# Session cookie: copy from the browser dev tools after logging in at /login.
# export COOKIE="better-auth.session_token=…"
curl -b "$COOKIE" "$HOST/api/v1/repos"[
{
"id": "cm0repo000000000000000000r1",
"owner": "acme",
"repo": "core-api",
"defaultBranch": "main",
"isDemoRow": false,
"lastScan": {
"id": "cm0scan000000000000000000s1",
"startedAt": "2026-08-15T03:00:04.221Z",
"finishedAt": "2026-08-15T03:02:51.117Z",
"status": "succeeded",
"findingsSeen": 7,
"draftsOpened": 2,
"error": null
},
"scanStatusBadge": "green",
"openPrCount": 1,
"status": "triage_in_progress",
"openAdvisoryCount": 5,
"lastScanAt": "2026-08-15T03:00:04.221Z",
"lastScanRelative": "yesterday",
"hasOpenFixPr": true,
"openFixDraftId": "cm0find000000000000000000f9",
"ownerInitial": "ac"
}
]{
"error": "Unauthorized"
}