| 1 | { |
| 2 | "device_code": { |
| 3 | "request": { |
| 4 | "client_name": "Claude Code" |
| 5 | }, |
| 6 | "response": { |
| 7 | "device_code": "Gm3k…", |
| 8 | "user_code": "WDJB-MJHT", |
| 9 | "verification_uri": "https://g1t.sh/device", |
| 10 | "verification_uri_complete": "https://g1t.sh/device?code=WDJB-MJHT", |
| 11 | "expires_in": 900, |
| 12 | "interval": 5 |
| 13 | } |
| 14 | }, |
| 15 | "device_token": { |
| 16 | "request": { |
| 17 | "device_code": "Gm3k…" |
| 18 | }, |
| 19 | "response": { |
| 20 | "status": "approved", |
| 21 | "token": "g1t_…", |
| 22 | "username": "syntaqx", |
| 23 | "verified": true |
| 24 | } |
| 25 | }, |
| 26 | "whoami": { |
| 27 | "response": { |
| 28 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 29 | "username": "syntaqx", |
| 30 | "kind": "user", |
| 31 | "verified": true, |
| 32 | "workspaces": [ |
| 33 | { |
| 34 | "slug": "acme", |
| 35 | "role": "member", |
| 36 | "base_permission": "write" |
| 37 | }, |
| 38 | { |
| 39 | "slug": "flagon-io", |
| 40 | "role": "owner", |
| 41 | "base_permission": "write" |
| 42 | } |
| 43 | ], |
| 44 | "token": { |
| 45 | "token_id": "tok_01kkntd3p2v8x6ym5r0c1q7a9e", |
| 46 | "scopes": [ |
| 47 | "repo:read", |
| 48 | "issues:read", |
| 49 | "issues:write", |
| 50 | "pull_requests:read", |
| 51 | "pull_requests:write" |
| 52 | ] |
| 53 | } |
| 54 | }, |
| 55 | "notes": "`token` is what the access token you called with may do: its `scopes` (left out for full access) and `legacy` when it was made before tokens had scopes. A token reaches every workspace and repository whoever it acts as can; its scopes say what it may do there. See [Scopes](/guides/authentication/#scopes). `kind` is `user`, `workspace` for a [workspace access token](/guides/workspaces/#workspace-access-tokens), or `agent` for the token a g1t agent works with. For a workspace token, `username` is the workspace's slug and `workspaces` holds only that workspace. Each workspace carries its `base_permission`: what a member gets on each of its repositories (owners have Admin). Roles given on single repositories are in `grants`, each with `repo_id`, `workspace` and `role`; it is left out when there are none. See [Access and roles](/guides/access-and-roles/)." |
| 56 | }, |
| 57 | "create_workspace": { |
| 58 | "request": { |
| 59 | "slug": "acme-labs", |
| 60 | "name": "Acme Labs" |
| 61 | }, |
| 62 | "response": { |
| 63 | "id": "wsp_01m43teqa9em6bje0bhvdj4jkb", |
| 64 | "slug": "acme-labs", |
| 65 | "name": "Acme Labs", |
| 66 | "description": null, |
| 67 | "created_at": "2026-10-04T16:02:51.337Z", |
| 68 | "member_count": 1, |
| 69 | "base_permission": "write", |
| 70 | "team_creation": "members" |
| 71 | }, |
| 72 | "notes": "`base_permission` is what every member gets on each of its repositories: `write` until an owner changes it with `PATCH /workspaces/{workspace}` or `PUT /workspaces/{workspace}/base_permission`. See [Access and roles](/guides/access-and-roles/). `team_creation` is who may create its teams: `members` (any member) until an owner sets `owners` with `PATCH /workspaces/{workspace}`. A new workspace is free, and each person owns at most one free workspace: while you own one, this answers `402` with `payment_required` and says which, until it is on the plan or deleted. See [One free workspace per person](/guides/usage-and-billing/#one-free-workspace-per-person)." |
| 73 | }, |
| 74 | "get_workspace": { |
| 75 | "params": { |
| 76 | "workspace": "acme-labs" |
| 77 | }, |
| 78 | "response": { |
| 79 | "id": "wsp_01m43teqa9em6bje0bhvdj4jkb", |
| 80 | "slug": "acme-labs", |
| 81 | "name": "Acme Labs", |
| 82 | "description": "Rockets, and the software that flies them.", |
| 83 | "created_at": "2026-10-04T16:02:51.337Z", |
| 84 | "member_count": 3, |
| 85 | "base_permission": "write", |
| 86 | "team_creation": "members" |
| 87 | }, |
| 88 | "notes": "`team_creation` is who may create its teams: `members` (any member, the default) or `owners`. Change it, and the rest, with [`PATCH /workspaces/{workspace}`](/reference/api/workspaces/update-workspace/). `404` for anyone who is not a member. See [Workspaces](/guides/workspaces/)." |
| 89 | }, |
| 90 | "update_workspace": { |
| 91 | "params": { |
| 92 | "workspace": "acme-labs" |
| 93 | }, |
| 94 | "request": { |
| 95 | "name": "Acme Labs", |
| 96 | "description": "Rockets, and the software that flies them.", |
| 97 | "team_creation": "owners" |
| 98 | }, |
| 99 | "response": { |
| 100 | "id": "wsp_01m43teqa9em6bje0bhvdj4jkb", |
| 101 | "slug": "acme-labs", |
| 102 | "name": "Acme Labs", |
| 103 | "description": "Rockets, and the software that flies them.", |
| 104 | "created_at": "2026-10-04T16:02:51.337Z", |
| 105 | "member_count": 3, |
| 106 | "base_permission": "write", |
| 107 | "team_creation": "owners" |
| 108 | }, |
| 109 | "notes": "Only the fields given change. `name` is the display name; the slug, the first part of the workspace's addresses, stays as it is. `base_permission` needs the `access:admin` scope as well as `workspace:admin`; [`set_base_permission`](/reference/api/access/set-base-permission/) sets it alone. `team_creation` is `members` (any member may create a team, the default) or `owners`; teams already made stay. Refused with `403` for anyone but an owner signed in as a person. Recorded in the [audit log](/guides/audit-log/). See [Workspaces](/guides/workspaces/)." |
| 110 | }, |
| 111 | "delete_workspace": { |
| 112 | "request": { |
| 113 | "confirm": "acme-labs" |
| 114 | }, |
| 115 | "response": true, |
| 116 | "notes": "Refused with `402` while billing cannot settle it, with a message that says what to do, and with `403` for anyone but an owner signed in as a person, or for a protected workspace. Its repositories, projects and apps go with it; g1t's support can restore it for 30 days. See [Delete a workspace](/guides/workspaces/#delete-a-workspace)." |
| 117 | }, |
| 118 | "list_emails": { |
| 119 | "response": { |
| 120 | "emails": [ |
| 121 | { |
| 122 | "email": "ada@example.com", |
| 123 | "verified": true, |
| 124 | "primary": true, |
| 125 | "backup": false, |
| 126 | "created_at": "2026-09-01T10:00:00.000Z", |
| 127 | "verified_at": "2026-09-01T10:02:11.000Z" |
| 128 | }, |
| 129 | { |
| 130 | "email": "ada@acme.com", |
| 131 | "verified": true, |
| 132 | "primary": false, |
| 133 | "backup": true, |
| 134 | "created_at": "2026-10-02T09:30:00.000Z", |
| 135 | "verified_at": "2026-10-02T09:31:40.000Z" |
| 136 | }, |
| 137 | { |
| 138 | "email": "ada.l@example.org", |
| 139 | "verified": false, |
| 140 | "primary": false, |
| 141 | "backup": false, |
| 142 | "created_at": "2026-10-05T14:12:03.000Z", |
| 143 | "verified_at": null |
| 144 | } |
| 145 | ], |
| 146 | "private_email": true, |
| 147 | "block_private_pushes": false, |
| 148 | "noreply": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 149 | "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 150 | "limit": 10 |
| 151 | }, |
| 152 | "notes": "Your primary address comes first, then confirmed addresses, then unconfirmed ones. Any confirmed address signs you in, can reset your password and attributes commits to you. See [Email addresses](/guides/authentication/#email-addresses)." |
| 153 | }, |
| 154 | "add_email": { |
| 155 | "request": { |
| 156 | "email": "ada.l@example.org", |
| 157 | "password": "…" |
| 158 | }, |
| 159 | "response": { |
| 160 | "emails": [ |
| 161 | { |
| 162 | "email": "ada@example.com", |
| 163 | "verified": true, |
| 164 | "primary": true, |
| 165 | "backup": false, |
| 166 | "created_at": "2026-09-01T10:00:00.000Z", |
| 167 | "verified_at": "2026-09-01T10:02:11.000Z" |
| 168 | }, |
| 169 | { |
| 170 | "email": "ada@acme.com", |
| 171 | "verified": true, |
| 172 | "primary": false, |
| 173 | "backup": true, |
| 174 | "created_at": "2026-10-02T09:30:00.000Z", |
| 175 | "verified_at": "2026-10-02T09:31:40.000Z" |
| 176 | }, |
| 177 | { |
| 178 | "email": "ada.l@example.org", |
| 179 | "verified": false, |
| 180 | "primary": false, |
| 181 | "backup": false, |
| 182 | "created_at": "2026-10-05T14:12:03.000Z", |
| 183 | "verified_at": null |
| 184 | } |
| 185 | ], |
| 186 | "private_email": true, |
| 187 | "block_private_pushes": false, |
| 188 | "noreply": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 189 | "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 190 | "limit": 10 |
| 191 | }, |
| 192 | "notes": "Answers `403` with code `reauth_required` when `password` is missing or wrong, and `409` when another account has confirmed the address. The new address stays unconfirmed until its link is followed." |
| 193 | }, |
| 194 | "remove_email": { |
| 195 | "request": { |
| 196 | "password": "…" |
| 197 | }, |
| 198 | "response": { |
| 199 | "emails": [ |
| 200 | { |
| 201 | "email": "ada@example.com", |
| 202 | "verified": true, |
| 203 | "primary": true, |
| 204 | "backup": false, |
| 205 | "created_at": "2026-09-01T10:00:00.000Z", |
| 206 | "verified_at": "2026-09-01T10:02:11.000Z" |
| 207 | }, |
| 208 | { |
| 209 | "email": "ada@acme.com", |
| 210 | "verified": true, |
| 211 | "primary": false, |
| 212 | "backup": true, |
| 213 | "created_at": "2026-10-02T09:30:00.000Z", |
| 214 | "verified_at": "2026-10-02T09:31:40.000Z" |
| 215 | }, |
| 216 | { |
| 217 | "email": "ada.l@example.org", |
| 218 | "verified": false, |
| 219 | "primary": false, |
| 220 | "backup": false, |
| 221 | "created_at": "2026-10-05T14:12:03.000Z", |
| 222 | "verified_at": null |
| 223 | } |
| 224 | ], |
| 225 | "private_email": true, |
| 226 | "block_private_pushes": false, |
| 227 | "noreply": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 228 | "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 229 | "limit": 10 |
| 230 | }, |
| 231 | "notes": "Give the address in the path, URL-encoded: `DELETE /user/emails/ada.l%40example.org`. Answers `409` for your primary address or your last confirmed one." |
| 232 | }, |
| 233 | "update_email_settings": { |
| 234 | "request": { |
| 235 | "primary": "ada@acme.com", |
| 236 | "password": "…" |
| 237 | }, |
| 238 | "response": { |
| 239 | "emails": [ |
| 240 | { |
| 241 | "email": "ada@example.com", |
| 242 | "verified": true, |
| 243 | "primary": true, |
| 244 | "backup": false, |
| 245 | "created_at": "2026-09-01T10:00:00.000Z", |
| 246 | "verified_at": "2026-09-01T10:02:11.000Z" |
| 247 | }, |
| 248 | { |
| 249 | "email": "ada@acme.com", |
| 250 | "verified": true, |
| 251 | "primary": false, |
| 252 | "backup": true, |
| 253 | "created_at": "2026-10-02T09:30:00.000Z", |
| 254 | "verified_at": "2026-10-02T09:31:40.000Z" |
| 255 | }, |
| 256 | { |
| 257 | "email": "ada.l@example.org", |
| 258 | "verified": false, |
| 259 | "primary": false, |
| 260 | "backup": false, |
| 261 | "created_at": "2026-10-05T14:12:03.000Z", |
| 262 | "verified_at": null |
| 263 | } |
| 264 | ], |
| 265 | "private_email": true, |
| 266 | "block_private_pushes": false, |
| 267 | "noreply": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 268 | "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh", |
| 269 | "limit": 10 |
| 270 | }, |
| 271 | "notes": "Only the fields given change. `primary` and `backup` need `password`; `private_email` and `block_private_pushes` do not." |
| 272 | }, |
| 273 | "list_invites": { |
| 274 | "response": { |
| 275 | "mode": "invite", |
| 276 | "allowance": { |
| 277 | "limit": 5, |
| 278 | "used": 2, |
| 279 | "remaining": 3 |
| 280 | }, |
| 281 | "workspaces": [ |
| 282 | { |
| 283 | "slug": "acme-labs", |
| 284 | "allowance": { |
| 285 | "limit": 20, |
| 286 | "used": 4, |
| 287 | "remaining": 16 |
| 288 | } |
| 289 | } |
| 290 | ], |
| 291 | "invites": [ |
| 292 | { |
| 293 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 294 | "code": "g1t-k7m2-q9xd-4hpw-…", |
| 295 | "hint": "g1t-k7m2", |
| 296 | "email": "ada@example.com", |
| 297 | "kind": "account", |
| 298 | "workspace": null, |
| 299 | "status": "pending", |
| 300 | "charged_to": "user", |
| 301 | "invited_by": "syntaqx", |
| 302 | "redeemed_by": null, |
| 303 | "created_at": "2026-10-05T17:00:00.000Z", |
| 304 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 305 | "redeemed_at": null, |
| 306 | "revoked_at": null |
| 307 | }, |
| 308 | { |
| 309 | "id": "inv_01kp1v3c4d5e6f7g8h9j0k1m2n", |
| 310 | "code": null, |
| 311 | "hint": "g1t-p3rt", |
| 312 | "email": null, |
| 313 | "kind": "account", |
| 314 | "workspace": null, |
| 315 | "status": "redeemed", |
| 316 | "charged_to": "user", |
| 317 | "invited_by": "syntaqx", |
| 318 | "redeemed_by": "grace", |
| 319 | "created_at": "2026-10-02T09:12:40.000Z", |
| 320 | "expires_at": "2026-11-01T09:12:40.000Z", |
| 321 | "redeemed_at": "2026-10-02T11:30:05.000Z", |
| 322 | "revoked_at": null |
| 323 | } |
| 324 | ] |
| 325 | }, |
| 326 | "notes": "`allowance.limit` and `allowance.remaining` are null when you have no limit. A revoked or expired invite that was never used is not counted. Ask for more at hey@flagon.io with the subject `[g1t Invites]`. See [Invites](/guides/authentication/#invites)." |
| 327 | }, |
| 328 | "create_invite": { |
| 329 | "request": { |
| 330 | "email": "ada@example.com" |
| 331 | }, |
| 332 | "response": { |
| 333 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 334 | "code": "g1t-k7m2-q9xd-4hpw-…", |
| 335 | "hint": "g1t-k7m2", |
| 336 | "email": "ada@example.com", |
| 337 | "kind": "account", |
| 338 | "workspace": null, |
| 339 | "status": "pending", |
| 340 | "charged_to": "user", |
| 341 | "invited_by": "syntaqx", |
| 342 | "redeemed_by": null, |
| 343 | "created_at": "2026-10-05T17:00:00.000Z", |
| 344 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 345 | "redeemed_at": null, |
| 346 | "revoked_at": null |
| 347 | }, |
| 348 | "notes": "Refused with `402` (`limit`) when you have no invites left, with `409` when you already have a pending invite for that address or it already has a g1t account, and with `403` for an agent's or a workspace's token. The code is returned in full; send people the link `https://g1t.sh/invite/<code>`." |
| 349 | }, |
| 350 | "revoke_invite": { |
| 351 | "response": { |
| 352 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 353 | "code": null, |
| 354 | "hint": "g1t-k7m2", |
| 355 | "email": "ada@example.com", |
| 356 | "kind": "account", |
| 357 | "workspace": null, |
| 358 | "status": "revoked", |
| 359 | "charged_to": "user", |
| 360 | "invited_by": "syntaqx", |
| 361 | "redeemed_by": null, |
| 362 | "created_at": "2026-10-05T17:00:00.000Z", |
| 363 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 364 | "redeemed_at": null, |
| 365 | "revoked_at": "2026-10-06T08:00:00.000Z" |
| 366 | } |
| 367 | }, |
| 368 | "list_workspace_invites": { |
| 369 | "response": [ |
| 370 | { |
| 371 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 372 | "code": "g1t-k7m2-q9xd-4hpw-…", |
| 373 | "hint": "g1t-k7m2", |
| 374 | "email": "ada@example.com", |
| 375 | "kind": "account", |
| 376 | "workspace": "acme-labs", |
| 377 | "status": "pending", |
| 378 | "charged_to": "workspace", |
| 379 | "invited_by": "syntaqx", |
| 380 | "redeemed_by": null, |
| 381 | "created_at": "2026-10-05T17:00:00.000Z", |
| 382 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 383 | "redeemed_at": null, |
| 384 | "revoked_at": null |
| 385 | }, |
| 386 | { |
| 387 | "id": "inv_01kp1z9y8x7w6v5t4s3r2q1p0n", |
| 388 | "code": "g1t-k7m2-q9xd-4hpw-…", |
| 389 | "hint": "g1t-w2vb", |
| 390 | "email": "linus@example.com", |
| 391 | "kind": "workspace", |
| 392 | "workspace": "acme-labs", |
| 393 | "status": "pending", |
| 394 | "charged_to": "none", |
| 395 | "invited_by": "syntaqx", |
| 396 | "redeemed_by": null, |
| 397 | "created_at": "2026-10-05T17:00:00.000Z", |
| 398 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 399 | "redeemed_at": null, |
| 400 | "revoked_at": null |
| 401 | } |
| 402 | ] |
| 403 | }, |
| 404 | "invite_member": { |
| 405 | "request": { |
| 406 | "email": "ada@example.com" |
| 407 | }, |
| 408 | "response": { |
| 409 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 410 | "code": "g1t-k7m2-q9xd-4hpw-…", |
| 411 | "hint": "g1t-k7m2", |
| 412 | "email": "ada@example.com", |
| 413 | "kind": "account", |
| 414 | "workspace": "acme-labs", |
| 415 | "status": "pending", |
| 416 | "charged_to": "workspace", |
| 417 | "invited_by": "syntaqx", |
| 418 | "redeemed_by": null, |
| 419 | "created_at": "2026-10-05T17:00:00.000Z", |
| 420 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 421 | "redeemed_at": null, |
| 422 | "revoked_at": null |
| 423 | }, |
| 424 | "notes": "`kind` is `workspace` when the address already has a g1t account (`charged_to` is then `none`), and `account` when accepting makes one. Both answers look alike to the caller on purpose: the invite is emailed either way. A free workspace cannot invite anyone: `402` with `payment_required`, until it starts the g1t plan." |
| 425 | }, |
| 426 | "revoke_workspace_invite": { |
| 427 | "response": { |
| 428 | "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y", |
| 429 | "code": null, |
| 430 | "hint": "g1t-k7m2", |
| 431 | "email": "ada@example.com", |
| 432 | "kind": "account", |
| 433 | "workspace": "acme-labs", |
| 434 | "status": "revoked", |
| 435 | "charged_to": "workspace", |
| 436 | "invited_by": "syntaqx", |
| 437 | "redeemed_by": null, |
| 438 | "created_at": "2026-10-05T17:00:00.000Z", |
| 439 | "expires_at": "2026-11-04T17:00:00.000Z", |
| 440 | "redeemed_at": null, |
| 441 | "revoked_at": "2026-10-06T08:00:00.000Z" |
| 442 | } |
| 443 | }, |
| 444 | "list_repos": { |
| 445 | "query": { |
| 446 | "q": "hello" |
| 447 | }, |
| 448 | "response": [ |
| 449 | { |
| 450 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 451 | "namespace": "flagon-io", |
| 452 | "name": "hello", |
| 453 | "description": "A tiny service that says hello.", |
| 454 | "is_private": false, |
| 455 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 456 | "default_branch": "main", |
| 457 | "fork_of": null, |
| 458 | "protected": true, |
| 459 | "created_at": "2026-09-28T14:11:52.640Z", |
| 460 | "website": "https://hello.g1t.page", |
| 461 | "archived_at": null |
| 462 | } |
| 463 | ], |
| 464 | "notes": "Returns at most 50 repositories, newest first. Forks made for pull requests are left out." |
| 465 | }, |
| 466 | "create_repo": { |
| 467 | "request": { |
| 468 | "workspace": "flagon-io", |
| 469 | "name": "hello-cli", |
| 470 | "description": "Command-line client for hello.", |
| 471 | "private": false |
| 472 | }, |
| 473 | "response": { |
| 474 | "id": "rep_01m43tk1jhehztx23drs87f5fc", |
| 475 | "namespace": "flagon-io", |
| 476 | "name": "hello-cli", |
| 477 | "description": "Command-line client for hello.", |
| 478 | "is_private": false, |
| 479 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 480 | "default_branch": "main", |
| 481 | "fork_of": null, |
| 482 | "protected": false, |
| 483 | "created_at": "2026-10-04T16:05:12.913Z", |
| 484 | "website": "https://hello.g1t.page", |
| 485 | "archived_at": null |
| 486 | }, |
| 487 | "notes": "`owner_id` is the id of the person who created the repository. With `import_url`, `default_branch` is the default branch of the repository copied." |
| 488 | }, |
| 489 | "get_repo": { |
| 490 | "response": { |
| 491 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 492 | "namespace": "flagon-io", |
| 493 | "name": "hello", |
| 494 | "description": "A tiny service that says hello.", |
| 495 | "is_private": false, |
| 496 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 497 | "default_branch": "main", |
| 498 | "fork_of": null, |
| 499 | "protected": true, |
| 500 | "created_at": "2026-09-28T14:11:52.640Z", |
| 501 | "website": "https://hello.g1t.page", |
| 502 | "archived_at": null |
| 503 | } |
| 504 | }, |
| 505 | "update_repo": { |
| 506 | "request": { |
| 507 | "description": "Says hello, politely.", |
| 508 | "website": "hello.g1t.page", |
| 509 | "default_branch": "trunk", |
| 510 | "protected": true |
| 511 | }, |
| 512 | "response": { |
| 513 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 514 | "namespace": "flagon-io", |
| 515 | "name": "hello", |
| 516 | "description": "Says hello, politely.", |
| 517 | "is_private": false, |
| 518 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 519 | "default_branch": "trunk", |
| 520 | "fork_of": null, |
| 521 | "protected": true, |
| 522 | "created_at": "2026-09-28T14:11:52.640Z", |
| 523 | "topics": [ |
| 524 | "http", |
| 525 | "example" |
| 526 | ], |
| 527 | "website": "https://hello.g1t.page", |
| 528 | "archived_at": null |
| 529 | }, |
| 530 | "notes": "Only the fields given change. `website` gets `https://` when no scheme is given; an empty string clears it. `default_branch` must name a branch that exists (`422` otherwise); it is changed after the other fields. `description`, `website`, `topics` and `protected` need the Maintain role or higher, and `private` and `default_branch` the Admin role (`403` otherwise, saying which role). Changing `private` here needs no confirmation; `POST /repos/{owner}/{name}/visibility` asks for one. Making it private is refused with `402` when a free workspace's private storage has no room for it. See [Managing a repository](/guides/managing-repositories/) and [Access and roles](/guides/access-and-roles/)." |
| 531 | }, |
| 532 | "transfer_repo": { |
| 533 | "request": { |
| 534 | "to": "flagon-io" |
| 535 | }, |
| 536 | "response": { |
| 537 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 538 | "namespace": "flagon-io", |
| 539 | "name": "hello", |
| 540 | "description": "A tiny service that says hello.", |
| 541 | "is_private": false, |
| 542 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 543 | "default_branch": "main", |
| 544 | "fork_of": null, |
| 545 | "protected": true, |
| 546 | "created_at": "2026-09-28T14:11:52.640Z", |
| 547 | "website": "https://hello.g1t.page", |
| 548 | "archived_at": null |
| 549 | }, |
| 550 | "notes": "The repository at its new address. Refused with `409` when the destination already has a repository of that name, `403` unless you own both workspaces, and `402` when a free destination has no room for a private repository. The old address redirects. See [Transferring a repository](/guides/transferring-repositories/)." |
| 551 | }, |
| 552 | "rename_repo": { |
| 553 | "request": { |
| 554 | "name": "greeter" |
| 555 | }, |
| 556 | "response": { |
| 557 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 558 | "namespace": "flagon-io", |
| 559 | "name": "greeter", |
| 560 | "description": "A tiny service that says hello.", |
| 561 | "is_private": false, |
| 562 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 563 | "default_branch": "main", |
| 564 | "fork_of": null, |
| 565 | "protected": true, |
| 566 | "created_at": "2026-09-28T14:11:52.640Z", |
| 567 | "topics": [ |
| 568 | "http", |
| 569 | "example" |
| 570 | ], |
| 571 | "website": "https://hello.g1t.page", |
| 572 | "archived_at": null |
| 573 | }, |
| 574 | "notes": "The repository under its new name. Needs the Admin role (`403` otherwise). Refused with `409` when the workspace already has a repository of that name, a recently deleted one included, and with `422` when the name is not valid. The old address redirects. See [Rename a repository](/guides/managing-repositories/#rename-a-repository)." |
| 575 | }, |
| 576 | "rename_branch": { |
| 577 | "params": { |
| 578 | "owner": "flagon-io", |
| 579 | "name": "hello", |
| 580 | "branch": "feature/login" |
| 581 | }, |
| 582 | "request": { |
| 583 | "new_name": "feature/sign-in" |
| 584 | }, |
| 585 | "response": { |
| 586 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 587 | "namespace": "flagon-io", |
| 588 | "name": "hello", |
| 589 | "description": "A tiny service that says hello.", |
| 590 | "is_private": false, |
| 591 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 592 | "default_branch": "main", |
| 593 | "fork_of": null, |
| 594 | "protected": true, |
| 595 | "created_at": "2026-09-28T14:11:52.640Z", |
| 596 | "topics": [ |
| 597 | "http", |
| 598 | "example" |
| 599 | ], |
| 600 | "website": "https://hello.g1t.page", |
| 601 | "archived_at": null |
| 602 | }, |
| 603 | "notes": "The repository after the rename; renaming the default branch changes `default_branch`. Send a branch name with slashes URL-encoded, as one path segment. Refused with `404` when there is no such branch, `409` when a branch named `new_name` exists, `422` when `new_name` is not a valid branch name, and `403` without the Write role, or without the Admin role for the default branch. See [Rename a branch](/guides/managing-repositories/#rename-a-branch)." |
| 604 | }, |
| 605 | "set_repo_visibility": { |
| 606 | "request": { |
| 607 | "private": true, |
| 608 | "confirm": "flagon-io/hello" |
| 609 | }, |
| 610 | "response": { |
| 611 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 612 | "namespace": "flagon-io", |
| 613 | "name": "hello", |
| 614 | "description": "A tiny service that says hello.", |
| 615 | "is_private": true, |
| 616 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 617 | "default_branch": "main", |
| 618 | "fork_of": null, |
| 619 | "protected": true, |
| 620 | "created_at": "2026-09-28T14:11:52.640Z", |
| 621 | "topics": [ |
| 622 | "http", |
| 623 | "example" |
| 624 | ], |
| 625 | "website": "https://hello.g1t.page", |
| 626 | "archived_at": null |
| 627 | }, |
| 628 | "notes": "Needs the Admin role (`403` otherwise). Refused with `422` when `confirm` is not the repository's full name, and with `402` when a free workspace's private storage has no room for it. See [Change who can see a repository](/guides/managing-repositories/#change-who-can-see-a-repository)." |
| 629 | }, |
| 630 | "archive_repo": { |
| 631 | "response": { |
| 632 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 633 | "namespace": "flagon-io", |
| 634 | "name": "hello", |
| 635 | "description": "A tiny service that says hello.", |
| 636 | "is_private": false, |
| 637 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 638 | "default_branch": "main", |
| 639 | "fork_of": null, |
| 640 | "protected": true, |
| 641 | "created_at": "2026-09-28T14:11:52.640Z", |
| 642 | "topics": [ |
| 643 | "http", |
| 644 | "example" |
| 645 | ], |
| 646 | "website": "https://hello.g1t.page", |
| 647 | "archived_at": "2026-10-05T09:30:00.000Z" |
| 648 | }, |
| 649 | "notes": "The repository, with `archived_at` set. Needs the Admin role (`403` otherwise). See [Archive a repository](/guides/managing-repositories/#archive-a-repository)." |
| 650 | }, |
| 651 | "unarchive_repo": { |
| 652 | "response": { |
| 653 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 654 | "namespace": "flagon-io", |
| 655 | "name": "hello", |
| 656 | "description": "A tiny service that says hello.", |
| 657 | "is_private": false, |
| 658 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 659 | "default_branch": "main", |
| 660 | "fork_of": null, |
| 661 | "protected": true, |
| 662 | "created_at": "2026-09-28T14:11:52.640Z", |
| 663 | "topics": [ |
| 664 | "http", |
| 665 | "example" |
| 666 | ], |
| 667 | "website": "https://hello.g1t.page", |
| 668 | "archived_at": null |
| 669 | }, |
| 670 | "notes": "The repository, with `archived_at` null. Needs the Admin role (`403` otherwise)." |
| 671 | }, |
| 672 | "delete_repo": { |
| 673 | "request": { |
| 674 | "confirm": "flagon-io/hello" |
| 675 | }, |
| 676 | "response": { |
| 677 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 678 | "namespace": "flagon-io", |
| 679 | "name": "hello", |
| 680 | "description": "A tiny service that says hello.", |
| 681 | "is_private": false, |
| 682 | "deleted_at": "2026-10-05T09:30:00.000Z", |
| 683 | "deleted_by": "syntaqx", |
| 684 | "purge_after": "2026-11-04T09:30:00.000Z" |
| 685 | }, |
| 686 | "notes": "The deleted repository and when it will be purged, 30 days on. Owners of the workspace only (`403`), whatever their role on the repository. Refused with `422` when `confirm` is not its full name. Its name stays taken until it is purged. See [Delete a repository](/guides/managing-repositories/#delete-a-repository)." |
| 687 | }, |
| 688 | "list_deleted_repos": { |
| 689 | "params": { |
| 690 | "workspace": "flagon-io" |
| 691 | }, |
| 692 | "response": [ |
| 693 | { |
| 694 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 695 | "namespace": "flagon-io", |
| 696 | "name": "hello", |
| 697 | "description": "A tiny service that says hello.", |
| 698 | "is_private": false, |
| 699 | "deleted_at": "2026-10-05T09:30:00.000Z", |
| 700 | "deleted_by": "syntaqx", |
| 701 | "purge_after": "2026-11-04T09:30:00.000Z" |
| 702 | } |
| 703 | ], |
| 704 | "notes": "Newest first. Empty for anyone who is not an owner of the workspace." |
| 705 | }, |
| 706 | "restore_repo": { |
| 707 | "response": { |
| 708 | "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 709 | "namespace": "flagon-io", |
| 710 | "name": "hello", |
| 711 | "description": "A tiny service that says hello.", |
| 712 | "is_private": false, |
| 713 | "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 714 | "default_branch": "main", |
| 715 | "fork_of": null, |
| 716 | "protected": true, |
| 717 | "created_at": "2026-09-28T14:11:52.640Z", |
| 718 | "topics": [ |
| 719 | "http", |
| 720 | "example" |
| 721 | ], |
| 722 | "website": "https://hello.g1t.page", |
| 723 | "archived_at": null |
| 724 | }, |
| 725 | "notes": "The repository, back at its address. Name it by the path it had. Owners only (`403`); `404` when no deleted repository had that path, or it has been purged. See [Restore a repository](/guides/managing-repositories/#restore-a-repository)." |
| 726 | }, |
| 727 | "purge_repo": { |
| 728 | "request": { |
| 729 | "confirm": "flagon-io/hello" |
| 730 | }, |
| 731 | "response": true, |
| 732 | "notes": "Permanent: it cannot be restored afterwards, and its name is free again. Only a deleted repository can be purged (`404` otherwise). Owners only (`403`); `422` when `confirm` is not its full name." |
| 733 | }, |
| 734 | "get_repo_settings": { |
| 735 | "response": { |
| 736 | "auto_merge": false, |
| 737 | "required_checks": [ |
| 738 | "CI" |
| 739 | ], |
| 740 | "require_up_to_date": false, |
| 741 | "required_approvals": 0, |
| 742 | "count_agent_approvals": true, |
| 743 | "allow_ignoring_checks": true, |
| 744 | "agent_review": true, |
| 745 | "max_revisions": 2, |
| 746 | "merge_queue": false, |
| 747 | "hold_low_confidence": true, |
| 748 | "require_code_owner_review": false, |
| 749 | "updated_by": null, |
| 750 | "updated_at": null |
| 751 | } |
| 752 | }, |
| 753 | "update_repo_settings": { |
| 754 | "request": { |
| 755 | "required_checks": [ |
| 756 | "CI", |
| 757 | "g1t / deploy" |
| 758 | ], |
| 759 | "required_approvals": 1, |
| 760 | "count_agent_approvals": false, |
| 761 | "merge_queue": true, |
| 762 | "require_code_owner_review": true |
| 763 | }, |
| 764 | "response": { |
| 765 | "auto_merge": false, |
| 766 | "required_checks": [ |
| 767 | "CI", |
| 768 | "g1t / deploy" |
| 769 | ], |
| 770 | "require_up_to_date": false, |
| 771 | "required_approvals": 1, |
| 772 | "count_agent_approvals": false, |
| 773 | "allow_ignoring_checks": true, |
| 774 | "agent_review": true, |
| 775 | "max_revisions": 2, |
| 776 | "merge_queue": true, |
| 777 | "hold_low_confidence": true, |
| 778 | "require_code_owner_review": true, |
| 779 | "updated_by": "syntaqx", |
| 780 | "updated_at": "2026-10-04T16:20:37.508Z" |
| 781 | }, |
| 782 | "notes": "`required_checks` replaces the whole list: at most 20 names, each a workflow's name or another status's context, as [`list_check_names`](/reference/api/repositories/list-check-names/) gives them. A pull request merges only once each passes on its head; one nothing has reported holds it too. With the merge queue on, each must also pass on the queued state, so the workflows behind them need `merge_group` in their `on:`. `required_approvals` is at most 6 and `max_revisions` at most 5. See [what a repository can ask for](/guides/working-with-g1t/#what-a-repository-can-ask-for). `hold_low_confidence` is on unless turned off: see [confidence](/guides/working-with-g1t/#how-sure-the-agent-is). With `require_code_owner_review`, a pull request into the default branch merges only once the code owners of every file it changes have approved it, as many as each section of its CODEOWNERS file asks: see [Code owners](/guides/codeowners/)." |
| 783 | }, |
| 784 | "list_check_names": { |
| 785 | "response": [ |
| 786 | { |
| 787 | "name": "CI", |
| 788 | "events": [ |
| 789 | "pull_request", |
| 790 | "merge_group", |
| 791 | "push" |
| 792 | ], |
| 793 | "last_seen": "2026-10-06T09:14:02.118Z" |
| 794 | }, |
| 795 | { |
| 796 | "name": "g1t / deploy", |
| 797 | "events": [], |
| 798 | "last_seen": "2026-10-06T08:51:40.006Z" |
| 799 | } |
| 800 | ], |
| 801 | "notes": "The names reported on the repository's commits in the last 30 days, most recent first. A workflow reports a check named after it (`CI`), for each event it ran for; another tool, such as a deployment, reports its own name (`g1t / deploy`). Empty until something has reported on a commit: add a workflow in `.g1t/workflows` first." |
| 802 | }, |
| 803 | "get_codeowners_errors": { |
| 804 | "params": { |
| 805 | "owner": "flagon-io", |
| 806 | "name": "hello" |
| 807 | }, |
| 808 | "query": { |
| 809 | "ref": "main" |
| 810 | }, |
| 811 | "response": { |
| 812 | "path": ".github/CODEOWNERS", |
| 813 | "ref": "main", |
| 814 | "size": 412, |
| 815 | "rules": 9, |
| 816 | "sections": [ |
| 817 | "Docs" |
| 818 | ], |
| 819 | "errors": [ |
| 820 | { |
| 821 | "line": 4, |
| 822 | "kind": "unknown_team", |
| 823 | "token": "@flagon-io/platform", |
| 824 | "message": "@flagon-io/platform is not a team of flagon-io." |
| 825 | }, |
| 826 | { |
| 827 | "line": 7, |
| 828 | "kind": "negation", |
| 829 | "token": "!docs/internal/", |
| 830 | "message": "!docs/internal/ starts with !, and negation is not supported; this line is skipped. Give the path a later rule with no owners instead." |
| 831 | } |
| 832 | ] |
| 833 | }, |
| 834 | "notes": "The file is the first of `.g1t/CODEOWNERS`, `.github/CODEOWNERS`, `CODEOWNERS`, `docs/CODEOWNERS` and `.gitlab/CODEOWNERS` found on `ref` (the default branch when left out); `path` is null when there is none, with no errors. Each error has its `line` (0 for the file as a whole), the `token` at fault, a `message`, and a `kind`:\n\n| `kind` | |\n| --- | --- |\n| `too_large` | The file is over 3 MB and was ignored. |\n| `negation` | A pattern starting with `!`; the line was skipped. |\n| `character_range` | A pattern with `[` or `]`; the line was skipped. |\n| `bad_pattern` | A pattern that names no path; the line was skipped. |\n| `bad_owner` | An owner that is not `@user`, `@workspace/team` or an email address. |\n| `bad_section` | A section header that could not be read. |\n| `unknown_user` | No account has that username. |\n| `unknown_team` | The workspace has no team of that slug. |\n| `unknown_email` | No account has confirmed that address. |\n| `no_write_access` | The person cannot write to the repository. |\n| `team_no_access` | The team has no write access to the repository. |\n\nSee [Code owners](/guides/codeowners/)." |
| 835 | }, |
| 836 | "list_events": { |
| 837 | "query": { |
| 838 | "before": "evt_01m43t2a6c9e3g7j1m5q9t3x7b" |
| 839 | }, |
| 840 | "response": [ |
| 841 | { |
| 842 | "id": "evt_01m43smh3ve52vkcna207vqctf", |
| 843 | "type": "pull.opened", |
| 844 | "source": "work", |
| 845 | "time": "2026-10-01T18:20:02.117Z", |
| 846 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 847 | "actor": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 848 | "data": { |
| 849 | "pull_id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 850 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 851 | "number": 14, |
| 852 | "issue": 12, |
| 853 | "agent": "claude-code" |
| 854 | } |
| 855 | }, |
| 856 | { |
| 857 | "id": "evt_01m43shrzpf2vt5rxbb02z0xjt", |
| 858 | "type": "issue.opened", |
| 859 | "source": "work", |
| 860 | "time": "2026-10-01T18:04:11.482Z", |
| 861 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 862 | "actor": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 863 | "data": { |
| 864 | "issue_id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 865 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 866 | "number": 12, |
| 867 | "title": "Greeting should name the caller" |
| 868 | } |
| 869 | } |
| 870 | ], |
| 871 | "notes": "Returns 50 events a page. To page back, send the `id` of the last event you have as `before`. `actor` is a user id, and `data` depends on `type`." |
| 872 | }, |
| 873 | "list_issues": { |
| 874 | "query": { |
| 875 | "state": "open", |
| 876 | "label": "feature" |
| 877 | }, |
| 878 | "response": [ |
| 879 | { |
| 880 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 881 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 882 | "number": 12, |
| 883 | "title": "Greeting should name the caller", |
| 884 | "body": "Take a name from the first argument; fall back to world.", |
| 885 | "labels": [ |
| 886 | "feature" |
| 887 | ], |
| 888 | "state": "open", |
| 889 | "reason": null, |
| 890 | "resolved_by": null, |
| 891 | "author": { |
| 892 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 893 | "username": "syntaqx", |
| 894 | "kind": "user", |
| 895 | "verified": false, |
| 896 | "workspaces": [] |
| 897 | }, |
| 898 | "requested_by": null, |
| 899 | "created_at": "2026-10-01T18:04:11.482Z", |
| 900 | "updated_at": "2026-10-01T18:04:11.482Z", |
| 901 | "closed_at": null, |
| 902 | "pull_count": 1, |
| 903 | "comment_count": 0, |
| 904 | "assignees": [], |
| 905 | "blocked_by": [], |
| 906 | "queued": false, |
| 907 | "agent": "claude-code", |
| 908 | "milestone": null |
| 909 | } |
| 910 | ], |
| 911 | "notes": "Returns at most 100 issues, newest first. `comment_count` counts comments, not events such as \"opened #14 for this\"." |
| 912 | }, |
| 913 | "create_issue": { |
| 914 | "request": { |
| 915 | "title": "Greeting should name the caller", |
| 916 | "body": "Take a name from the first argument; fall back to world.", |
| 917 | "labels": [ |
| 918 | "feature" |
| 919 | ] |
| 920 | }, |
| 921 | "response": { |
| 922 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 923 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 924 | "number": 12, |
| 925 | "title": "Greeting should name the caller", |
| 926 | "body": "Take a name from the first argument; fall back to world.", |
| 927 | "labels": [ |
| 928 | "feature" |
| 929 | ], |
| 930 | "state": "open", |
| 931 | "reason": null, |
| 932 | "resolved_by": null, |
| 933 | "author": { |
| 934 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 935 | "username": "syntaqx", |
| 936 | "kind": "user", |
| 937 | "verified": false, |
| 938 | "workspaces": [] |
| 939 | }, |
| 940 | "requested_by": null, |
| 941 | "created_at": "2026-10-01T18:04:11.482Z", |
| 942 | "updated_at": "2026-10-01T18:04:11.482Z", |
| 943 | "closed_at": null, |
| 944 | "pull_count": 0, |
| 945 | "comment_count": 0, |
| 946 | "assignees": [], |
| 947 | "blocked_by": [], |
| 948 | "queued": false, |
| 949 | "agent": null, |
| 950 | "milestone": null |
| 951 | }, |
| 952 | "notes": "Labels are lowercased. A label not used before is created." |
| 953 | }, |
| 954 | "get_issue": { |
| 955 | "response": { |
| 956 | "issue": { |
| 957 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 958 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 959 | "number": 12, |
| 960 | "title": "Greeting should name the caller", |
| 961 | "body": "Take a name from the first argument; fall back to world.", |
| 962 | "labels": [ |
| 963 | "feature" |
| 964 | ], |
| 965 | "state": "closed", |
| 966 | "reason": "completed", |
| 967 | "resolved_by": 14, |
| 968 | "author": { |
| 969 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 970 | "username": "syntaqx", |
| 971 | "kind": "user", |
| 972 | "verified": false, |
| 973 | "workspaces": [] |
| 974 | }, |
| 975 | "requested_by": null, |
| 976 | "created_at": "2026-10-01T18:04:11.482Z", |
| 977 | "updated_at": "2026-10-01T18:52:17.093Z", |
| 978 | "closed_at": "2026-10-01T18:52:17.093Z", |
| 979 | "pull_count": 2, |
| 980 | "comment_count": 0, |
| 981 | "assignees": [], |
| 982 | "blocked_by": [], |
| 983 | "queued": false, |
| 984 | "agent": null, |
| 985 | "milestone": null |
| 986 | }, |
| 987 | "pulls": [ |
| 988 | { |
| 989 | "id": "pr_01m43sjq8tcz5rbm2a7k4d9e6w", |
| 990 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 991 | "number": 13, |
| 992 | "issue": 12, |
| 993 | "title": "Greeting should name the caller", |
| 994 | "body": null, |
| 995 | "agent": "claude-code", |
| 996 | "runtime": "external", |
| 997 | "status": "closed", |
| 998 | "fork": { |
| 999 | "namespace": "pulls", |
| 1000 | "name": "pr_01m43sjq8tcz5rbm2a7k4d9e6w" |
| 1001 | }, |
| 1002 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1003 | "branch": null, |
| 1004 | "head_commit": null, |
| 1005 | "merge_base": null, |
| 1006 | "merged_by": null, |
| 1007 | "merged_at": null, |
| 1008 | "superseded_by": 14, |
| 1009 | "check_status": null, |
| 1010 | "files": [], |
| 1011 | "assignees": [], |
| 1012 | "reviewers": [], |
| 1013 | "labels": [], |
| 1014 | "milestone": null, |
| 1015 | "base": "main", |
| 1016 | "author": { |
| 1017 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1018 | "username": "syntaqx", |
| 1019 | "kind": "user", |
| 1020 | "verified": false, |
| 1021 | "workspaces": [] |
| 1022 | }, |
| 1023 | "requested_by": null, |
| 1024 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1025 | "updated_at": "2026-10-01T18:20:02.117Z" |
| 1026 | }, |
| 1027 | { |
| 1028 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1029 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1030 | "number": 14, |
| 1031 | "issue": 12, |
| 1032 | "title": "Greeting should name the caller", |
| 1033 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 1034 | "agent": "claude-code", |
| 1035 | "runtime": "external", |
| 1036 | "status": "merged", |
| 1037 | "fork": { |
| 1038 | "namespace": "pulls", |
| 1039 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1040 | }, |
| 1041 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1042 | "branch": null, |
| 1043 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1044 | "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c", |
| 1045 | "merged_by": "syntaqx", |
| 1046 | "merged_at": "2026-10-01T18:52:17.093Z", |
| 1047 | "superseded_by": null, |
| 1048 | "check_status": "passed", |
| 1049 | "files": [ |
| 1050 | { |
| 1051 | "path": "src/main.rs", |
| 1052 | "additions": 6, |
| 1053 | "deletions": 2 |
| 1054 | } |
| 1055 | ], |
| 1056 | "assignees": [], |
| 1057 | "reviewers": [ |
| 1058 | "ana" |
| 1059 | ], |
| 1060 | "labels": [], |
| 1061 | "milestone": null, |
| 1062 | "base": "main", |
| 1063 | "author": { |
| 1064 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1065 | "username": "syntaqx", |
| 1066 | "kind": "user", |
| 1067 | "verified": false, |
| 1068 | "workspaces": [] |
| 1069 | }, |
| 1070 | "requested_by": null, |
| 1071 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1072 | "updated_at": "2026-10-01T18:52:17.093Z" |
| 1073 | } |
| 1074 | ], |
| 1075 | "comments": [ |
| 1076 | { |
| 1077 | "id": "cmt_01m43sr2b7d5f0j6k3n8p1q4v9", |
| 1078 | "kind": "event", |
| 1079 | "author": { |
| 1080 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1081 | "username": "syntaqx", |
| 1082 | "kind": "user", |
| 1083 | "verified": false, |
| 1084 | "workspaces": [] |
| 1085 | }, |
| 1086 | "body": "opened #14 for this", |
| 1087 | "path": null, |
| 1088 | "line": null, |
| 1089 | "verdict": null, |
| 1090 | "created_at": "2026-10-01T18:20:02.141Z" |
| 1091 | } |
| 1092 | ] |
| 1093 | }, |
| 1094 | "notes": "A closed issue says how it was closed: `reason` is `completed` or `not_planned`, and `resolved_by` is the number of the pull request whose merge closed it. Each pull request made for it is listed; one closed because another was merged has `superseded_by` set." |
| 1095 | }, |
| 1096 | "update_issue": { |
| 1097 | "request": { |
| 1098 | "labels": [ |
| 1099 | "feature", |
| 1100 | "good first issue" |
| 1101 | ], |
| 1102 | "assignees": [ |
| 1103 | "syntaqx" |
| 1104 | ], |
| 1105 | "milestone": 3 |
| 1106 | }, |
| 1107 | "response": { |
| 1108 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 1109 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1110 | "number": 12, |
| 1111 | "title": "Greeting should name the caller", |
| 1112 | "body": "Take a name from the first argument; fall back to world.", |
| 1113 | "labels": [ |
| 1114 | "feature", |
| 1115 | "good first issue" |
| 1116 | ], |
| 1117 | "state": "open", |
| 1118 | "reason": null, |
| 1119 | "resolved_by": null, |
| 1120 | "author": { |
| 1121 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1122 | "username": "syntaqx", |
| 1123 | "kind": "user", |
| 1124 | "verified": false, |
| 1125 | "workspaces": [] |
| 1126 | }, |
| 1127 | "requested_by": null, |
| 1128 | "created_at": "2026-10-01T18:04:11.482Z", |
| 1129 | "updated_at": "2026-10-01T18:09:47.305Z", |
| 1130 | "closed_at": null, |
| 1131 | "pull_count": 0, |
| 1132 | "comment_count": 0, |
| 1133 | "assignees": [ |
| 1134 | "syntaqx" |
| 1135 | ], |
| 1136 | "blocked_by": [], |
| 1137 | "queued": false, |
| 1138 | "agent": null, |
| 1139 | "milestone": { |
| 1140 | "number": 3, |
| 1141 | "title": "Launch" |
| 1142 | } |
| 1143 | } |
| 1144 | }, |
| 1145 | "close_issue": { |
| 1146 | "request": { |
| 1147 | "reason": "not_planned" |
| 1148 | }, |
| 1149 | "response": { |
| 1150 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 1151 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1152 | "number": 12, |
| 1153 | "title": "Greeting should name the caller", |
| 1154 | "body": "Take a name from the first argument; fall back to world.", |
| 1155 | "labels": [ |
| 1156 | "feature" |
| 1157 | ], |
| 1158 | "state": "closed", |
| 1159 | "reason": "not_planned", |
| 1160 | "resolved_by": null, |
| 1161 | "author": { |
| 1162 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1163 | "username": "syntaqx", |
| 1164 | "kind": "user", |
| 1165 | "verified": false, |
| 1166 | "workspaces": [] |
| 1167 | }, |
| 1168 | "requested_by": null, |
| 1169 | "created_at": "2026-10-01T18:04:11.482Z", |
| 1170 | "updated_at": "2026-10-01T19:30:00.214Z", |
| 1171 | "closed_at": "2026-10-01T19:30:00.214Z", |
| 1172 | "pull_count": 0, |
| 1173 | "comment_count": 0, |
| 1174 | "assignees": [], |
| 1175 | "blocked_by": [], |
| 1176 | "queued": false, |
| 1177 | "agent": null, |
| 1178 | "milestone": null |
| 1179 | } |
| 1180 | }, |
| 1181 | "reopen_issue": { |
| 1182 | "response": { |
| 1183 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 1184 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1185 | "number": 12, |
| 1186 | "title": "Greeting should name the caller", |
| 1187 | "body": "Take a name from the first argument; fall back to world.", |
| 1188 | "labels": [ |
| 1189 | "feature" |
| 1190 | ], |
| 1191 | "state": "open", |
| 1192 | "reason": null, |
| 1193 | "resolved_by": null, |
| 1194 | "author": { |
| 1195 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1196 | "username": "syntaqx", |
| 1197 | "kind": "user", |
| 1198 | "verified": false, |
| 1199 | "workspaces": [] |
| 1200 | }, |
| 1201 | "requested_by": null, |
| 1202 | "created_at": "2026-10-01T18:04:11.482Z", |
| 1203 | "updated_at": "2026-10-01T19:41:52.830Z", |
| 1204 | "closed_at": null, |
| 1205 | "pull_count": 0, |
| 1206 | "comment_count": 0, |
| 1207 | "assignees": [], |
| 1208 | "blocked_by": [], |
| 1209 | "queued": false, |
| 1210 | "agent": null, |
| 1211 | "milestone": null |
| 1212 | } |
| 1213 | }, |
| 1214 | "assign_issue": { |
| 1215 | "request": { |
| 1216 | "instructions": "Keep the change to src/main.rs." |
| 1217 | }, |
| 1218 | "response": { |
| 1219 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1220 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1221 | "number": 14, |
| 1222 | "issue": 12, |
| 1223 | "title": "Greeting should name the caller", |
| 1224 | "body": null, |
| 1225 | "agent": "g1t", |
| 1226 | "runtime": "hosted", |
| 1227 | "status": "draft", |
| 1228 | "fork": { |
| 1229 | "namespace": "pulls", |
| 1230 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1231 | }, |
| 1232 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1233 | "branch": null, |
| 1234 | "head_commit": null, |
| 1235 | "merge_base": null, |
| 1236 | "merged_by": null, |
| 1237 | "merged_at": null, |
| 1238 | "superseded_by": null, |
| 1239 | "check_status": null, |
| 1240 | "files": [], |
| 1241 | "assignees": [], |
| 1242 | "reviewers": [], |
| 1243 | "labels": [], |
| 1244 | "milestone": null, |
| 1245 | "base": "main", |
| 1246 | "author": { |
| 1247 | "id": "usr_g1t_agent", |
| 1248 | "username": "g1t", |
| 1249 | "kind": "agent", |
| 1250 | "verified": false, |
| 1251 | "workspaces": [] |
| 1252 | }, |
| 1253 | "requested_by": { |
| 1254 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1255 | "username": "syntaqx", |
| 1256 | "kind": "user", |
| 1257 | "verified": false, |
| 1258 | "workspaces": [] |
| 1259 | }, |
| 1260 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1261 | "updated_at": "2026-10-01T18:20:02.117Z", |
| 1262 | "confidence": null |
| 1263 | }, |
| 1264 | "notes": "The response is the pull request g1t opened, still a draft. g1t is its `author` and you are its `requested_by`: you may manage it as if you had opened it, and cannot approve it yourself. Follow it with [get a pull request](/reference/api/pull-requests/get-pull-request/): `lifecycle` says what the agent is doing." |
| 1265 | }, |
| 1266 | "delegate": { |
| 1267 | "request": { |
| 1268 | "title": "Retry webhooks with exponential backoff", |
| 1269 | "body": "Deliveries that fail are dropped today. Retry them with exponential backoff, up to six times, then mark the delivery failed.\n\n## Definition of done\n\n- A delivery that fails is retried after 1, 2, 4, 8, 16 and 32 seconds.\n- After the sixth failure it is marked failed and shows on the webhook's page." |
| 1270 | }, |
| 1271 | "response": { |
| 1272 | "issue": { |
| 1273 | "id": "iss_01m4a2c8v1t7k3q9x5n0r2w6yd", |
| 1274 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1275 | "number": 41, |
| 1276 | "title": "Retry webhooks with exponential backoff", |
| 1277 | "body": "Deliveries that fail are dropped today. Retry them with exponential backoff, up to six times, then mark the delivery failed.", |
| 1278 | "labels": [], |
| 1279 | "state": "open", |
| 1280 | "reason": null, |
| 1281 | "resolved_by": null, |
| 1282 | "author": { |
| 1283 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1284 | "username": "syntaqx", |
| 1285 | "kind": "user", |
| 1286 | "verified": false, |
| 1287 | "workspaces": [] |
| 1288 | }, |
| 1289 | "requested_by": null, |
| 1290 | "created_at": "2026-10-05T14:02:11.204Z", |
| 1291 | "updated_at": "2026-10-05T14:02:11.204Z", |
| 1292 | "closed_at": null, |
| 1293 | "pull_count": 1, |
| 1294 | "comment_count": 0, |
| 1295 | "assignees": [], |
| 1296 | "blocked_by": [], |
| 1297 | "queued": false, |
| 1298 | "agent": "g1t", |
| 1299 | "milestone": null |
| 1300 | }, |
| 1301 | "pull": { |
| 1302 | "id": "pr_01m4a2c9b6e0h4m8q2t6x0a4d8", |
| 1303 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1304 | "number": 42, |
| 1305 | "issue": 41, |
| 1306 | "title": "Retry webhooks with exponential backoff", |
| 1307 | "body": null, |
| 1308 | "agent": "g1t", |
| 1309 | "runtime": "hosted", |
| 1310 | "status": "draft", |
| 1311 | "fork": { |
| 1312 | "namespace": "pulls", |
| 1313 | "name": "pr_01m4a2c9b6e0h4m8q2t6x0a4d8" |
| 1314 | }, |
| 1315 | "fork_repo_id": "rep_01m4a2c9d2g6k0n4r8v2z6c0f4", |
| 1316 | "branch": null, |
| 1317 | "head_commit": null, |
| 1318 | "merge_base": null, |
| 1319 | "merged_by": null, |
| 1320 | "merged_at": null, |
| 1321 | "superseded_by": null, |
| 1322 | "check_status": null, |
| 1323 | "files": [], |
| 1324 | "assignees": [], |
| 1325 | "reviewers": [], |
| 1326 | "labels": [], |
| 1327 | "milestone": null, |
| 1328 | "base": "main", |
| 1329 | "author": { |
| 1330 | "id": "usr_g1t_agent", |
| 1331 | "username": "g1t", |
| 1332 | "kind": "agent", |
| 1333 | "verified": false, |
| 1334 | "workspaces": [] |
| 1335 | }, |
| 1336 | "requested_by": { |
| 1337 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1338 | "username": "syntaqx", |
| 1339 | "kind": "user", |
| 1340 | "verified": false, |
| 1341 | "workspaces": [] |
| 1342 | }, |
| 1343 | "created_at": "2026-10-05T14:02:12.880Z", |
| 1344 | "updated_at": "2026-10-05T14:02:12.880Z", |
| 1345 | "confidence": null |
| 1346 | }, |
| 1347 | "agent": { |
| 1348 | "status": "started", |
| 1349 | "code": null, |
| 1350 | "message": null, |
| 1351 | "fix_url": null |
| 1352 | } |
| 1353 | }, |
| 1354 | "notes": "The issue is opened whatever becomes of the agent. When the workspace's plan does not let it start, `pull` is null and `agent` says why and where to fix it, for example `{ \"status\": \"not_started\", \"code\": \"not_paid\", \"message\": \"Agents need a paid workspace. Start the $20 plan or try it with $5 of free usage after a card check: /acme/-/billing\", \"fix_url\": \"https://g1t.sh/acme/-/billing\" }`. With every agent slot busy, `status` is `queued` and it starts by itself when one frees up. See [putting an agent on something](/guides/working-with-g1t/#put-an-agent-on-it-in-one-step)." |
| 1355 | }, |
| 1356 | "add_comment": { |
| 1357 | "request": { |
| 1358 | "body": "Should an empty name fall back to \"world\"?" |
| 1359 | }, |
| 1360 | "response": { |
| 1361 | "id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1", |
| 1362 | "kind": "comment", |
| 1363 | "author": { |
| 1364 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1365 | "username": "syntaqx", |
| 1366 | "kind": "user", |
| 1367 | "verified": true, |
| 1368 | "workspaces": [ |
| 1369 | { |
| 1370 | "slug": "flagon-io", |
| 1371 | "role": "owner" |
| 1372 | } |
| 1373 | ] |
| 1374 | }, |
| 1375 | "body": "Should an empty name fall back to \"world\"?", |
| 1376 | "path": null, |
| 1377 | "line": null, |
| 1378 | "verdict": null, |
| 1379 | "created_at": "2026-10-01T18:12:30.551Z" |
| 1380 | } |
| 1381 | }, |
| 1382 | "list_labels": { |
| 1383 | "response": [ |
| 1384 | { |
| 1385 | "name": "bug", |
| 1386 | "color": "d73a4a", |
| 1387 | "description": "Something isn't working", |
| 1388 | "issues": 4, |
| 1389 | "pulls": 1 |
| 1390 | }, |
| 1391 | { |
| 1392 | "name": "dependencies", |
| 1393 | "color": "0366d6", |
| 1394 | "description": "Updates a dependency", |
| 1395 | "issues": 0, |
| 1396 | "pulls": 6 |
| 1397 | }, |
| 1398 | { |
| 1399 | "name": "good first issue", |
| 1400 | "color": "7057ff", |
| 1401 | "description": "Good for newcomers", |
| 1402 | "issues": 2, |
| 1403 | "pulls": 0 |
| 1404 | } |
| 1405 | ], |
| 1406 | "notes": "By name. A new repository starts with the default labels; add_default_labels adds those an older one is missing." |
| 1407 | }, |
| 1408 | "plan_work": { |
| 1409 | "request": { |
| 1410 | "brief": "Greet people by name, from the command line and the web page." |
| 1411 | }, |
| 1412 | "response": { |
| 1413 | "plan_id": "pln_01m43s9c4e8g2j6m0q4t8x2b6d" |
| 1414 | } |
| 1415 | }, |
| 1416 | "get_plan": { |
| 1417 | "params": { |
| 1418 | "plan": "pln_01m43s9c4e8g2j6m0q4t8x2b6d" |
| 1419 | }, |
| 1420 | "response": { |
| 1421 | "id": "pln_01m43s9c4e8g2j6m0q4t8x2b6d", |
| 1422 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1423 | "brief": "Greet people by name, from the command line and the web page.", |
| 1424 | "status": "ready", |
| 1425 | "summary": "Name parsing first, then the two places that print the greeting.", |
| 1426 | "issues": [ |
| 1427 | { |
| 1428 | "title": "Greeting should name the caller", |
| 1429 | "body": "Accept an optional name in `greet()` and use it.", |
| 1430 | "labels": [ |
| 1431 | "feature" |
| 1432 | ], |
| 1433 | "done": [ |
| 1434 | "`greet` prints \"Hello, ana!\" when given \"ana\", and \"Hello, world!\" with no argument." |
| 1435 | ], |
| 1436 | "files": [ |
| 1437 | "src/greet.rs" |
| 1438 | ], |
| 1439 | "depends_on": [], |
| 1440 | "number": null |
| 1441 | }, |
| 1442 | { |
| 1443 | "title": "Show the caller's name on the web page", |
| 1444 | "body": "Read `?name=` and pass it to `greet()`.", |
| 1445 | "labels": [ |
| 1446 | "feature" |
| 1447 | ], |
| 1448 | "done": [ |
| 1449 | "The page at / shows the name given in ?name=, escaped." |
| 1450 | ], |
| 1451 | "files": [ |
| 1452 | "src/web.rs" |
| 1453 | ], |
| 1454 | "depends_on": [ |
| 1455 | 1 |
| 1456 | ], |
| 1457 | "number": null |
| 1458 | } |
| 1459 | ], |
| 1460 | "error": null, |
| 1461 | "author": { |
| 1462 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1463 | "username": "syntaqx", |
| 1464 | "kind": "user", |
| 1465 | "verified": false, |
| 1466 | "workspaces": [] |
| 1467 | }, |
| 1468 | "created_at": "2026-10-01T17:58:40.006Z", |
| 1469 | "finished_at": "2026-10-01T18:01:12.774Z", |
| 1470 | "progress": [], |
| 1471 | "exchanges": [] |
| 1472 | }, |
| 1473 | "notes": "A plan still `planning` after 20 minutes is reported as `failed`. `progress` follows each issue once the plan is applied." |
| 1474 | }, |
| 1475 | "apply_plan": { |
| 1476 | "params": { |
| 1477 | "plan": "pln_01m43s9c4e8g2j6m0q4t8x2b6d" |
| 1478 | }, |
| 1479 | "request": { |
| 1480 | "assign": true |
| 1481 | }, |
| 1482 | "response": { |
| 1483 | "id": "pln_01m43s9c4e8g2j6m0q4t8x2b6d", |
| 1484 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1485 | "brief": "Greet people by name, from the command line and the web page.", |
| 1486 | "status": "applied", |
| 1487 | "summary": "Name parsing first, then the two places that print the greeting.", |
| 1488 | "issues": [ |
| 1489 | { |
| 1490 | "title": "Greeting should name the caller", |
| 1491 | "body": "Accept an optional name in `greet()` and use it.", |
| 1492 | "labels": [ |
| 1493 | "feature" |
| 1494 | ], |
| 1495 | "done": [ |
| 1496 | "`greet` prints \"Hello, ana!\" when given \"ana\", and \"Hello, world!\" with no argument." |
| 1497 | ], |
| 1498 | "files": [ |
| 1499 | "src/greet.rs" |
| 1500 | ], |
| 1501 | "depends_on": [], |
| 1502 | "number": 12 |
| 1503 | }, |
| 1504 | { |
| 1505 | "title": "Show the caller's name on the web page", |
| 1506 | "body": "Read `?name=` and pass it to `greet()`.", |
| 1507 | "labels": [ |
| 1508 | "feature" |
| 1509 | ], |
| 1510 | "done": [ |
| 1511 | "The page at / shows the name given in ?name=, escaped." |
| 1512 | ], |
| 1513 | "files": [ |
| 1514 | "src/web.rs" |
| 1515 | ], |
| 1516 | "depends_on": [ |
| 1517 | 1 |
| 1518 | ], |
| 1519 | "number": 13 |
| 1520 | } |
| 1521 | ], |
| 1522 | "error": null, |
| 1523 | "author": { |
| 1524 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1525 | "username": "syntaqx", |
| 1526 | "kind": "user", |
| 1527 | "verified": false, |
| 1528 | "workspaces": [] |
| 1529 | }, |
| 1530 | "created_at": "2026-10-01T17:58:40.006Z", |
| 1531 | "finished_at": "2026-10-01T18:01:12.774Z", |
| 1532 | "progress": [], |
| 1533 | "exchanges": [] |
| 1534 | }, |
| 1535 | "notes": "Each opened issue's `number` is filled in. Issues left out with `keep` stay `null`." |
| 1536 | }, |
| 1537 | "list_pull_requests": { |
| 1538 | "query": { |
| 1539 | "state": "open" |
| 1540 | }, |
| 1541 | "response": [ |
| 1542 | { |
| 1543 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1544 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1545 | "number": 14, |
| 1546 | "issue": 12, |
| 1547 | "title": "Greeting should name the caller", |
| 1548 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 1549 | "agent": "claude-code", |
| 1550 | "runtime": "external", |
| 1551 | "status": "open", |
| 1552 | "fork": { |
| 1553 | "namespace": "pulls", |
| 1554 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1555 | }, |
| 1556 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1557 | "branch": null, |
| 1558 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1559 | "merge_base": null, |
| 1560 | "merged_by": null, |
| 1561 | "merged_at": null, |
| 1562 | "superseded_by": null, |
| 1563 | "check_status": "passed", |
| 1564 | "files": [ |
| 1565 | { |
| 1566 | "path": "src/main.rs", |
| 1567 | "additions": 6, |
| 1568 | "deletions": 2 |
| 1569 | } |
| 1570 | ], |
| 1571 | "assignees": [], |
| 1572 | "reviewers": [ |
| 1573 | "ana" |
| 1574 | ], |
| 1575 | "team_reviewers": [], |
| 1576 | "author": { |
| 1577 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1578 | "username": "syntaqx", |
| 1579 | "kind": "user", |
| 1580 | "verified": false, |
| 1581 | "workspaces": [] |
| 1582 | }, |
| 1583 | "requested_by": null, |
| 1584 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1585 | "updated_at": "2026-10-01T18:35:44.902Z", |
| 1586 | "labels": [], |
| 1587 | "milestone": null, |
| 1588 | "base": "main" |
| 1589 | } |
| 1590 | ], |
| 1591 | "notes": "Returns at most 100 pull requests, newest first. `check_status` is `queued`, `running`, `passed`, `failed`, `errored`, or `null` when no checks have run against the head." |
| 1592 | }, |
| 1593 | "create_pull_request": { |
| 1594 | "request": { |
| 1595 | "issue": 12, |
| 1596 | "agent": "claude-code" |
| 1597 | }, |
| 1598 | "response": { |
| 1599 | "pull": { |
| 1600 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1601 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1602 | "number": 14, |
| 1603 | "issue": 12, |
| 1604 | "title": "Greeting should name the caller", |
| 1605 | "body": null, |
| 1606 | "agent": "claude-code", |
| 1607 | "runtime": "external", |
| 1608 | "status": "draft", |
| 1609 | "fork": { |
| 1610 | "namespace": "pulls", |
| 1611 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1612 | }, |
| 1613 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1614 | "branch": null, |
| 1615 | "head_commit": null, |
| 1616 | "merge_base": null, |
| 1617 | "merged_by": null, |
| 1618 | "merged_at": null, |
| 1619 | "superseded_by": null, |
| 1620 | "check_status": null, |
| 1621 | "files": [], |
| 1622 | "assignees": [], |
| 1623 | "reviewers": [], |
| 1624 | "labels": [], |
| 1625 | "milestone": null, |
| 1626 | "base": "main", |
| 1627 | "author": { |
| 1628 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1629 | "username": "syntaqx", |
| 1630 | "kind": "user", |
| 1631 | "verified": false, |
| 1632 | "workspaces": [] |
| 1633 | }, |
| 1634 | "requested_by": null, |
| 1635 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1636 | "updated_at": "2026-10-01T18:20:02.117Z" |
| 1637 | }, |
| 1638 | "git": { |
| 1639 | "remote": "https://g1t.sh/pulls/pr_01m43smh3vexsr5pmp60qwv0vs.git", |
| 1640 | "username": "syntaqx", |
| 1641 | "password": "your g1t access token" |
| 1642 | } |
| 1643 | }, |
| 1644 | "notes": "`title` defaults to the issue's title, and is required when there is no `issue`. Push to `git.remote` with your username and an access token as the password.\n\nSend `branch` to open the pull request from a branch already pushed to the repository. No fork is made, `fork` is `null`, `git.remote` is the repository itself, and the pull request is `open` at once." |
| 1645 | }, |
| 1646 | "get_pull_request": { |
| 1647 | "response": { |
| 1648 | "pull": { |
| 1649 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1650 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1651 | "number": 14, |
| 1652 | "issue": 12, |
| 1653 | "title": "Greeting should name the caller", |
| 1654 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 1655 | "agent": "claude-code", |
| 1656 | "runtime": "external", |
| 1657 | "status": "open", |
| 1658 | "fork": { |
| 1659 | "namespace": "pulls", |
| 1660 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1661 | }, |
| 1662 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1663 | "branch": null, |
| 1664 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1665 | "merge_base": null, |
| 1666 | "merged_by": null, |
| 1667 | "merged_at": null, |
| 1668 | "superseded_by": null, |
| 1669 | "check_status": "passed", |
| 1670 | "files": [ |
| 1671 | { |
| 1672 | "path": "src/main.rs", |
| 1673 | "additions": 6, |
| 1674 | "deletions": 2 |
| 1675 | } |
| 1676 | ], |
| 1677 | "assignees": [], |
| 1678 | "reviewers": [ |
| 1679 | "ana" |
| 1680 | ], |
| 1681 | "team_reviewers": [ |
| 1682 | "flagon-io/backend" |
| 1683 | ], |
| 1684 | "author": { |
| 1685 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1686 | "username": "syntaqx", |
| 1687 | "kind": "user", |
| 1688 | "verified": false, |
| 1689 | "workspaces": [] |
| 1690 | }, |
| 1691 | "requested_by": null, |
| 1692 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1693 | "updated_at": "2026-10-01T18:35:44.902Z", |
| 1694 | "confidence": null, |
| 1695 | "labels": [], |
| 1696 | "milestone": null, |
| 1697 | "base": "main" |
| 1698 | }, |
| 1699 | "issue": { |
| 1700 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 1701 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1702 | "number": 12, |
| 1703 | "title": "Greeting should name the caller", |
| 1704 | "body": "Take a name from the first argument; fall back to world.", |
| 1705 | "labels": [ |
| 1706 | "feature" |
| 1707 | ], |
| 1708 | "state": "open", |
| 1709 | "reason": null, |
| 1710 | "resolved_by": null, |
| 1711 | "author": { |
| 1712 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1713 | "username": "syntaqx", |
| 1714 | "kind": "user", |
| 1715 | "verified": false, |
| 1716 | "workspaces": [] |
| 1717 | }, |
| 1718 | "requested_by": null, |
| 1719 | "created_at": "2026-10-01T18:04:11.482Z", |
| 1720 | "updated_at": "2026-10-01T18:20:02.117Z", |
| 1721 | "closed_at": null, |
| 1722 | "pull_count": 1, |
| 1723 | "comment_count": 0, |
| 1724 | "assignees": [], |
| 1725 | "blocked_by": [], |
| 1726 | "queued": false, |
| 1727 | "agent": "claude-code", |
| 1728 | "milestone": null |
| 1729 | }, |
| 1730 | "comments": [ |
| 1731 | { |
| 1732 | "id": "cmt_01m43st6d0f4h8k2n6r0v4z8c2", |
| 1733 | "kind": "event", |
| 1734 | "author": { |
| 1735 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1736 | "username": "syntaqx", |
| 1737 | "kind": "user", |
| 1738 | "verified": false, |
| 1739 | "workspaces": [] |
| 1740 | }, |
| 1741 | "body": "marked this ready for review", |
| 1742 | "path": null, |
| 1743 | "line": null, |
| 1744 | "verdict": null, |
| 1745 | "created_at": "2026-10-01T18:33:10.420Z" |
| 1746 | } |
| 1747 | ], |
| 1748 | "checks": null, |
| 1749 | "overlaps": [], |
| 1750 | "behind": false, |
| 1751 | "review_pending": false, |
| 1752 | "lifecycle": null, |
| 1753 | "landing": false, |
| 1754 | "stalled": null, |
| 1755 | "messages": [ |
| 1756 | { |
| 1757 | "id": "msg_01m43tx5egeh4t3f9zcnjenqvz", |
| 1758 | "author": "syntaqx", |
| 1759 | "body": "Keep \"world\" as the default when no name is given.", |
| 1760 | "created_at": "2026-10-01T18:25:00.310Z", |
| 1761 | "delivered_at": "2026-10-01T18:25:31.007Z", |
| 1762 | "kind": "message", |
| 1763 | "from_number": null, |
| 1764 | "to_number": 14, |
| 1765 | "answer": null, |
| 1766 | "declined": false |
| 1767 | } |
| 1768 | ], |
| 1769 | "statuses": [ |
| 1770 | { |
| 1771 | "context": "CI / pull_request", |
| 1772 | "state": "success", |
| 1773 | "description": "CI passed", |
| 1774 | "target_url": "https://g1t.sh/syntaqx/hello/actions/runs/run_01m43sw8e2g6j0m4q8t2x6a0c4", |
| 1775 | "updated_at": "2026-10-01T18:35:44.902Z" |
| 1776 | } |
| 1777 | ], |
| 1778 | "required_checks": [ |
| 1779 | { |
| 1780 | "name": "CI", |
| 1781 | "state": "success", |
| 1782 | "description": "CI passed", |
| 1783 | "target_url": "https://g1t.sh/syntaqx/hello/actions/runs/run_01m43sw8e2g6j0m4q8t2x6a0c4" |
| 1784 | } |
| 1785 | ], |
| 1786 | "code_owners": { |
| 1787 | "path": ".github/CODEOWNERS", |
| 1788 | "required": true, |
| 1789 | "reviews": [ |
| 1790 | { |
| 1791 | "section": null, |
| 1792 | "line": 3, |
| 1793 | "pattern": "/src/", |
| 1794 | "owners": [ |
| 1795 | "@flagon-io/backend" |
| 1796 | ], |
| 1797 | "files": [ |
| 1798 | "src/main.rs" |
| 1799 | ], |
| 1800 | "optional": false, |
| 1801 | "required": 1, |
| 1802 | "approved_by": [], |
| 1803 | "changes_requested_by": [], |
| 1804 | "satisfied": false |
| 1805 | } |
| 1806 | ], |
| 1807 | "missing": "Code owners have not approved: @flagon-io/backend for /src/.", |
| 1808 | "errors": 0 |
| 1809 | } |
| 1810 | }, |
| 1811 | "notes": "| Field | |\n| --- | --- |\n| `pull.files` | The files it changes, with lines added and removed. |\n| `statuses` | Its checks: what each workflow run (or another tool, such as a deployment) reported on its head, as `pending`, `success`, `failure` or `error`, with a link to the run. |\n| `required_checks` | Each check the default branch requires (see [`update_repo_settings`](/reference/api/repositories/update-repo-settings/)), as it stands on the head: `success`, `failure`, `pending`, or `expected` when nothing has reported it yet. It merges only once all are `success`. |\n| `checks` | Set when the merge queue took it out, with why in `error`. Older pull requests may show a run of commands from their issue here, from before checks were workflows. |\n| `overlaps` | Other pull requests in progress that change the same files. |\n| `behind` | Whether the default branch has moved since it was made. |\n| `landing` | Whether it is being brought up to date to land. |\n| `lifecycle` | For a pull request g1t is seeing through: its stage, such as `working`, `checking`, `reviewing` or `needs_you`. |\n| `comments` | Comments, reviews and events, with `path`, `line` and `verdict`. |\n| `messages` | Messages sent to the agent working on it. |\n| `pull.reviewers`, `pull.team_reviewers` | The people asked to review it, `g1t` among them when a g1t agent was, and the teams, as `workspace/team`. Change them with [`request_reviewers`](/reference/api/pull-requests/request-reviewers/). |\n| `code_owners` | Present when the branch it merges into has a CODEOWNERS file: its `path`, whether code owners' approval is `required` there, `reviews` (one per section and rule that owns a changed file: `section`, `line`, `pattern`, `owners`, `files`, `optional`, the approvals `required`, `approved_by`, `changes_requested_by` and `satisfied`), what is still `missing`, as the merge box says it, and how many `errors` the file has; [`get_codeowners_errors`](/reference/api/repositories/get-codeowners-errors/) lists them. |\n| `mergeable` | Whether it merges cleanly into its target: `clean`, `conflicting`, `checking` (being worked out) or `unknown`. Worked out ahead of time whenever it or its target moves. |\n| `conflicts` | When `mergeable` is `conflicting`, the files that conflict. Resolve them by merging the target in, or have g1t do it. |\n| `earlier_checks` | Earlier records like `checks`, newest first. |\n\nChecks are the repository's workflows: they run on `pull_request` events when it is opened, marked ready and pushed to. Read why one failed with [`get_workflow_run`](/reference/api/actions/get-workflow-run/) and [`get_job_logs`](/reference/api/actions/get-job-logs/)." |
| 1812 | }, |
| 1813 | "get_pull_request_changes": { |
| 1814 | "response": { |
| 1815 | "base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c", |
| 1816 | "head": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1817 | "files": [ |
| 1818 | { |
| 1819 | "path": "src/main.rs", |
| 1820 | "status": "modified", |
| 1821 | "additions": 1, |
| 1822 | "deletions": 1, |
| 1823 | "binary": false, |
| 1824 | "hunks": [ |
| 1825 | { |
| 1826 | "lines": [ |
| 1827 | { |
| 1828 | "kind": "context", |
| 1829 | "old": 3, |
| 1830 | "new": 3, |
| 1831 | "text": "fn main() {" |
| 1832 | }, |
| 1833 | { |
| 1834 | "kind": "delete", |
| 1835 | "old": 4, |
| 1836 | "new": null, |
| 1837 | "text": " println!(\"Hello, world!\");" |
| 1838 | }, |
| 1839 | { |
| 1840 | "kind": "add", |
| 1841 | "old": null, |
| 1842 | "new": 4, |
| 1843 | "text": " println!(\"Hello, {}!\", std::env::args().nth(1).unwrap_or(\"world\".into()));" |
| 1844 | }, |
| 1845 | { |
| 1846 | "kind": "context", |
| 1847 | "old": 5, |
| 1848 | "new": 5, |
| 1849 | "text": "}" |
| 1850 | } |
| 1851 | ] |
| 1852 | } |
| 1853 | ] |
| 1854 | } |
| 1855 | ], |
| 1856 | "truncated": false |
| 1857 | }, |
| 1858 | "notes": "A file's `status` is `added`, `modified` or `deleted`. A binary file has no `hunks`. In a line, `old` is `null` when it was added and `new` is `null` when it was deleted." |
| 1859 | }, |
| 1860 | "mark_pull_request_ready": { |
| 1861 | "request": { |
| 1862 | "summary": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\"." |
| 1863 | }, |
| 1864 | "response": { |
| 1865 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1866 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1867 | "number": 14, |
| 1868 | "issue": 12, |
| 1869 | "title": "Greeting should name the caller", |
| 1870 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 1871 | "agent": "claude-code", |
| 1872 | "runtime": "external", |
| 1873 | "status": "open", |
| 1874 | "fork": { |
| 1875 | "namespace": "pulls", |
| 1876 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1877 | }, |
| 1878 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1879 | "branch": null, |
| 1880 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1881 | "merge_base": null, |
| 1882 | "merged_by": null, |
| 1883 | "merged_at": null, |
| 1884 | "superseded_by": null, |
| 1885 | "check_status": null, |
| 1886 | "files": [ |
| 1887 | { |
| 1888 | "path": "src/main.rs", |
| 1889 | "additions": 6, |
| 1890 | "deletions": 2 |
| 1891 | } |
| 1892 | ], |
| 1893 | "assignees": [], |
| 1894 | "reviewers": [], |
| 1895 | "labels": [], |
| 1896 | "milestone": null, |
| 1897 | "base": "main", |
| 1898 | "author": { |
| 1899 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1900 | "username": "syntaqx", |
| 1901 | "kind": "user", |
| 1902 | "verified": false, |
| 1903 | "workspaces": [] |
| 1904 | }, |
| 1905 | "requested_by": null, |
| 1906 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1907 | "updated_at": "2026-10-01T18:33:10.398Z" |
| 1908 | } |
| 1909 | }, |
| 1910 | "review_pull_request": { |
| 1911 | "request": { |
| 1912 | "verdict": "request_changes", |
| 1913 | "body": "Trim the name before using it." |
| 1914 | }, |
| 1915 | "response": { |
| 1916 | "id": "cmt_01m43sx9f3h7k1n5r9v3z7d1g5", |
| 1917 | "kind": "comment", |
| 1918 | "author": { |
| 1919 | "id": "usr_01kz9d3f7h1k5n9r3v7z1c5g9b", |
| 1920 | "username": "ana", |
| 1921 | "kind": "user", |
| 1922 | "verified": true, |
| 1923 | "workspaces": [ |
| 1924 | { |
| 1925 | "slug": "flagon-io", |
| 1926 | "role": "member" |
| 1927 | } |
| 1928 | ] |
| 1929 | }, |
| 1930 | "body": "Trim the name before using it.", |
| 1931 | "path": null, |
| 1932 | "line": null, |
| 1933 | "verdict": "request_changes", |
| 1934 | "created_at": "2026-10-01T18:40:05.019Z" |
| 1935 | } |
| 1936 | }, |
| 1937 | "request_reviewers": { |
| 1938 | "params": { |
| 1939 | "owner": "flagon-io", |
| 1940 | "name": "hello", |
| 1941 | "number": 14 |
| 1942 | }, |
| 1943 | "request": { |
| 1944 | "reviewers": [ |
| 1945 | "bo" |
| 1946 | ], |
| 1947 | "team_reviewers": [ |
| 1948 | "backend" |
| 1949 | ] |
| 1950 | }, |
| 1951 | "response": { |
| 1952 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 1953 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 1954 | "number": 14, |
| 1955 | "issue": 12, |
| 1956 | "title": "Greeting should name the caller", |
| 1957 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 1958 | "agent": "claude-code", |
| 1959 | "runtime": "external", |
| 1960 | "status": "open", |
| 1961 | "fork": { |
| 1962 | "namespace": "pulls", |
| 1963 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 1964 | }, |
| 1965 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 1966 | "branch": null, |
| 1967 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 1968 | "merge_base": null, |
| 1969 | "merged_by": null, |
| 1970 | "merged_at": null, |
| 1971 | "superseded_by": null, |
| 1972 | "check_status": "passed", |
| 1973 | "files": [ |
| 1974 | { |
| 1975 | "path": "src/main.rs", |
| 1976 | "additions": 6, |
| 1977 | "deletions": 2 |
| 1978 | } |
| 1979 | ], |
| 1980 | "assignees": [], |
| 1981 | "reviewers": [ |
| 1982 | "ana", |
| 1983 | "bo" |
| 1984 | ], |
| 1985 | "team_reviewers": [ |
| 1986 | "flagon-io/backend" |
| 1987 | ], |
| 1988 | "author": { |
| 1989 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 1990 | "username": "syntaqx", |
| 1991 | "kind": "user", |
| 1992 | "verified": false, |
| 1993 | "workspaces": [] |
| 1994 | }, |
| 1995 | "requested_by": null, |
| 1996 | "created_at": "2026-10-01T18:20:02.117Z", |
| 1997 | "updated_at": "2026-10-01T18:40:12.331Z" |
| 1998 | }, |
| 1999 | "notes": "Adds to who is asked: `reviewers` by username (`g1t` asks a g1t agent), `team_reviewers` as `workspace/team`, or a team's slug in the repository's workspace. A team with review assignment on has the people it picks added to `reviewers`, and stays in `team_reviewers`. Each is told in their inbox. Nobody is asked to review their own pull request. `422` for someone who is not an account, or a team that does not exist or that you cannot see. Whoever opened it, or the Triage role or higher, while it is open. See [Pull requests](/guides/pull-requests/) and [Teams](/guides/teams/)." |
| 2000 | }, |
| 2001 | "remove_requested_reviewers": { |
| 2002 | "params": { |
| 2003 | "owner": "flagon-io", |
| 2004 | "name": "hello", |
| 2005 | "number": 14 |
| 2006 | }, |
| 2007 | "request": { |
| 2008 | "reviewers": [ |
| 2009 | "bo" |
| 2010 | ], |
| 2011 | "team_reviewers": [ |
| 2012 | "flagon-io/backend" |
| 2013 | ] |
| 2014 | }, |
| 2015 | "response": { |
| 2016 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 2017 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 2018 | "number": 14, |
| 2019 | "issue": 12, |
| 2020 | "title": "Greeting should name the caller", |
| 2021 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 2022 | "agent": "claude-code", |
| 2023 | "runtime": "external", |
| 2024 | "status": "open", |
| 2025 | "fork": { |
| 2026 | "namespace": "pulls", |
| 2027 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 2028 | }, |
| 2029 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 2030 | "branch": null, |
| 2031 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2032 | "merge_base": null, |
| 2033 | "merged_by": null, |
| 2034 | "merged_at": null, |
| 2035 | "superseded_by": null, |
| 2036 | "check_status": "passed", |
| 2037 | "files": [ |
| 2038 | { |
| 2039 | "path": "src/main.rs", |
| 2040 | "additions": 6, |
| 2041 | "deletions": 2 |
| 2042 | } |
| 2043 | ], |
| 2044 | "assignees": [], |
| 2045 | "reviewers": [ |
| 2046 | "ana" |
| 2047 | ], |
| 2048 | "team_reviewers": [], |
| 2049 | "author": { |
| 2050 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 2051 | "username": "syntaqx", |
| 2052 | "kind": "user", |
| 2053 | "verified": false, |
| 2054 | "workspaces": [] |
| 2055 | }, |
| 2056 | "requested_by": null, |
| 2057 | "created_at": "2026-10-01T18:20:02.117Z", |
| 2058 | "updated_at": "2026-10-01T18:41:30.904Z" |
| 2059 | }, |
| 2060 | "notes": "Takes them off who is asked; anyone not asked is ignored. Reviews they already gave stay, as do the people a team's review assignment picked: remove them by username." |
| 2061 | }, |
| 2062 | "merge_pull_request": { |
| 2063 | "request": { |
| 2064 | "keep_issue_open": false |
| 2065 | }, |
| 2066 | "response": { |
| 2067 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 2068 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 2069 | "number": 14, |
| 2070 | "issue": 12, |
| 2071 | "title": "Greeting should name the caller", |
| 2072 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 2073 | "agent": "claude-code", |
| 2074 | "runtime": "external", |
| 2075 | "status": "merged", |
| 2076 | "fork": { |
| 2077 | "namespace": "pulls", |
| 2078 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 2079 | }, |
| 2080 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 2081 | "branch": null, |
| 2082 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2083 | "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c", |
| 2084 | "merged_by": "syntaqx", |
| 2085 | "merged_at": "2026-10-01T18:52:17.093Z", |
| 2086 | "superseded_by": null, |
| 2087 | "check_status": "passed", |
| 2088 | "files": [ |
| 2089 | { |
| 2090 | "path": "src/main.rs", |
| 2091 | "additions": 6, |
| 2092 | "deletions": 2 |
| 2093 | } |
| 2094 | ], |
| 2095 | "assignees": [], |
| 2096 | "reviewers": [ |
| 2097 | "ana" |
| 2098 | ], |
| 2099 | "labels": [], |
| 2100 | "milestone": null, |
| 2101 | "base": "main", |
| 2102 | "author": { |
| 2103 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 2104 | "username": "syntaqx", |
| 2105 | "kind": "user", |
| 2106 | "verified": false, |
| 2107 | "workspaces": [] |
| 2108 | }, |
| 2109 | "requested_by": null, |
| 2110 | "created_at": "2026-10-01T18:20:02.117Z", |
| 2111 | "updated_at": "2026-10-01T18:52:17.093Z" |
| 2112 | }, |
| 2113 | "notes": "A draft, or one whose checks have not passed, answers `409`. A pull request still `open` in the response has not landed yet: `landing` is true on it while it is brought up to date, and [get the merge queue](/reference/api/pull-requests/get-merge-queue/) shows it waiting in the [merge queue](/guides/merge-queue/). Merging records the pull request in the issue's `resolved_by` and sets `superseded_by` on the pull requests it closes." |
| 2114 | }, |
| 2115 | "close_pull_request": { |
| 2116 | "response": { |
| 2117 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 2118 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 2119 | "number": 14, |
| 2120 | "issue": 12, |
| 2121 | "title": "Greeting should name the caller", |
| 2122 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 2123 | "agent": "claude-code", |
| 2124 | "runtime": "external", |
| 2125 | "status": "closed", |
| 2126 | "fork": { |
| 2127 | "namespace": "pulls", |
| 2128 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 2129 | }, |
| 2130 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 2131 | "branch": null, |
| 2132 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2133 | "merge_base": null, |
| 2134 | "merged_by": null, |
| 2135 | "merged_at": null, |
| 2136 | "superseded_by": null, |
| 2137 | "check_status": null, |
| 2138 | "files": [ |
| 2139 | { |
| 2140 | "path": "src/main.rs", |
| 2141 | "additions": 6, |
| 2142 | "deletions": 2 |
| 2143 | } |
| 2144 | ], |
| 2145 | "assignees": [], |
| 2146 | "reviewers": [], |
| 2147 | "labels": [], |
| 2148 | "milestone": null, |
| 2149 | "base": "main", |
| 2150 | "author": { |
| 2151 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 2152 | "username": "syntaqx", |
| 2153 | "kind": "user", |
| 2154 | "verified": false, |
| 2155 | "workspaces": [] |
| 2156 | }, |
| 2157 | "requested_by": null, |
| 2158 | "created_at": "2026-10-01T18:20:02.117Z", |
| 2159 | "updated_at": "2026-10-01T19:02:48.760Z" |
| 2160 | } |
| 2161 | }, |
| 2162 | "get_merge_queue": { |
| 2163 | "response": { |
| 2164 | "enabled": true, |
| 2165 | "active": [ |
| 2166 | { |
| 2167 | "id": "qen_01m43rn0qsft1tpap1awkewzbb", |
| 2168 | "number": 14, |
| 2169 | "title": "Greeting should name the caller", |
| 2170 | "agent": "claude-code", |
| 2171 | "state": "testing", |
| 2172 | "ahead": [], |
| 2173 | "base_commit": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c", |
| 2174 | "combined_commit": null, |
| 2175 | "error": null, |
| 2176 | "results": [], |
| 2177 | "enqueued_by": "syntaqx", |
| 2178 | "created_at": "2026-10-04T15:31:20.441Z", |
| 2179 | "finished_at": null |
| 2180 | } |
| 2181 | ], |
| 2182 | "recent": [ |
| 2183 | { |
| 2184 | "id": "qen_01m43khqjmeb5a1magayrnk63z", |
| 2185 | "number": 11, |
| 2186 | "title": "Fix trailing newline in greeting", |
| 2187 | "agent": "g1t", |
| 2188 | "state": "landed", |
| 2189 | "ahead": [], |
| 2190 | "base_commit": "4b1d7e9c2a5f8e3d6c0b9a7e5d3c1b8a6f4e2d0c", |
| 2191 | "combined_commit": "c3e8a1f6d4b2097e5c3a1f8d6b4e2c0a9f7d5b3e", |
| 2192 | "error": null, |
| 2193 | "results": [ |
| 2194 | { |
| 2195 | "command": "cargo test", |
| 2196 | "passed": true, |
| 2197 | "exit_code": 0, |
| 2198 | "output": "test result: ok. 12 passed; 0 failed\n", |
| 2199 | "duration_ms": 48211 |
| 2200 | } |
| 2201 | ], |
| 2202 | "enqueued_by": "g1t", |
| 2203 | "created_at": "2026-10-04T14:02:09.876Z", |
| 2204 | "finished_at": "2026-10-04T14:09:55.102Z" |
| 2205 | } |
| 2206 | ] |
| 2207 | }, |
| 2208 | "notes": "An entry's `state` is `waiting`, `testing`, `passed`, `failed`, `landed` or `removed`. `active` is in queue order; `recent` holds at most 20, newest first." |
| 2209 | }, |
| 2210 | "message_agent": { |
| 2211 | "request": { |
| 2212 | "body": "Keep \"world\" as the default when no name is given." |
| 2213 | }, |
| 2214 | "response": { |
| 2215 | "id": "msg_01m43tx5egeh4t3f9zcnjenqvz", |
| 2216 | "author": "syntaqx", |
| 2217 | "body": "Keep \"world\" as the default when no name is given.", |
| 2218 | "created_at": "2026-10-01T18:25:00.310Z", |
| 2219 | "delivered_at": null, |
| 2220 | "kind": "message", |
| 2221 | "from_number": null, |
| 2222 | "to_number": 14, |
| 2223 | "answer": null, |
| 2224 | "declined": false |
| 2225 | }, |
| 2226 | "notes": "The response is the message. `delivered_at` is set once the agent has read it." |
| 2227 | }, |
| 2228 | "answer_message": { |
| 2229 | "params": { |
| 2230 | "id": "msg_01m43t66tde8hs2vpxhh3v8tqw" |
| 2231 | }, |
| 2232 | "request": { |
| 2233 | "body": "No. greet() keeps its name; only greet_named() is added." |
| 2234 | }, |
| 2235 | "response": { |
| 2236 | "id": "msg_01m43t66tde8hs2vpxhh3v8tqw", |
| 2237 | "author": "g1t", |
| 2238 | "body": "Are you renaming greet() in src/lib.rs? I need to call it from #16.", |
| 2239 | "created_at": "2026-10-01T18:58:12.301Z", |
| 2240 | "delivered_at": "2026-10-01T18:58:40.117Z", |
| 2241 | "kind": "question", |
| 2242 | "from_number": 16, |
| 2243 | "to_number": 14, |
| 2244 | "answer": "No. greet() keeps its name; only greet_named() is added.", |
| 2245 | "declined": false |
| 2246 | }, |
| 2247 | "notes": "The response is the question or handoff that was answered, with `answer` and `declined` filled in." |
| 2248 | }, |
| 2249 | "take_messages": { |
| 2250 | "response": [ |
| 2251 | { |
| 2252 | "id": "msg_01m43tx5egeh4t3f9zcnjenqvz", |
| 2253 | "author": "syntaqx", |
| 2254 | "body": "Keep \"world\" as the default when no name is given.", |
| 2255 | "created_at": "2026-10-01T18:25:00.310Z", |
| 2256 | "delivered_at": "2026-10-01T18:25:31.007Z", |
| 2257 | "kind": "message", |
| 2258 | "from_number": null, |
| 2259 | "to_number": 14, |
| 2260 | "answer": null, |
| 2261 | "declined": false |
| 2262 | } |
| 2263 | ], |
| 2264 | "notes": "Only a g1t agent's token can take messages. They come oldest first, and each is marked delivered." |
| 2265 | }, |
| 2266 | "read_session": { |
| 2267 | "query": { |
| 2268 | "after": 0 |
| 2269 | }, |
| 2270 | "response": [ |
| 2271 | { |
| 2272 | "seq": 1, |
| 2273 | "kind": "prompt", |
| 2274 | "text": "Make the greeting name the caller (issue #12).", |
| 2275 | "tool": null, |
| 2276 | "commit": null, |
| 2277 | "at": "2026-10-01T18:21:00.004Z" |
| 2278 | }, |
| 2279 | { |
| 2280 | "seq": 2, |
| 2281 | "kind": "tool_call", |
| 2282 | "text": "cargo test", |
| 2283 | "tool": "bash", |
| 2284 | "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2285 | "at": "2026-10-01T18:30:12.660Z" |
| 2286 | } |
| 2287 | ] |
| 2288 | }, |
| 2289 | "record_session": { |
| 2290 | "request": { |
| 2291 | "entries": [ |
| 2292 | { |
| 2293 | "kind": "message", |
| 2294 | "text": "Reading src/main.rs." |
| 2295 | }, |
| 2296 | { |
| 2297 | "kind": "tool_call", |
| 2298 | "text": "cargo test", |
| 2299 | "tool": "bash" |
| 2300 | } |
| 2301 | ] |
| 2302 | }, |
| 2303 | "response": { |
| 2304 | "count": 2 |
| 2305 | }, |
| 2306 | "notes": "Up to 200 entries can be appended per request. Each is recorded against the pull request's head commit at the time. See [sessions and why-blame](/guides/why-blame/)." |
| 2307 | }, |
| 2308 | "list_workflows": { |
| 2309 | "response": [ |
| 2310 | { |
| 2311 | "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2312 | "path": ".g1t/workflows/ci.yml", |
| 2313 | "name": "CI", |
| 2314 | "events": [ |
| 2315 | "push", |
| 2316 | "pull_request", |
| 2317 | "workflow_dispatch" |
| 2318 | ], |
| 2319 | "state": "active", |
| 2320 | "error": null, |
| 2321 | "notes": [ |
| 2322 | { |
| 2323 | "severity": "unsupported", |
| 2324 | "job": "test", |
| 2325 | "message": "`services` containers (such as a database) are not started on g1t yet." |
| 2326 | } |
| 2327 | ], |
| 2328 | "dispatch": { |
| 2329 | "debug": { |
| 2330 | "description": "Verbose logs", |
| 2331 | "type": "boolean", |
| 2332 | "default": false |
| 2333 | } |
| 2334 | }, |
| 2335 | "last_run": { |
| 2336 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2337 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2338 | "path": ".g1t/workflows/ci.yml", |
| 2339 | "name": "CI", |
| 2340 | "title": "Greeting should name the caller", |
| 2341 | "number": 12, |
| 2342 | "attempt": 1, |
| 2343 | "event": "push", |
| 2344 | "ref": "refs/heads/main", |
| 2345 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2346 | "pull": null, |
| 2347 | "status": "completed", |
| 2348 | "conclusion": "success", |
| 2349 | "error": null, |
| 2350 | "actor": "syntaqx", |
| 2351 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2352 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2353 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2354 | } |
| 2355 | }, |
| 2356 | { |
| 2357 | "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq", |
| 2358 | "path": ".g1t/workflows/nightly.yml", |
| 2359 | "name": "Nightly", |
| 2360 | "events": [ |
| 2361 | "schedule" |
| 2362 | ], |
| 2363 | "state": "disabled", |
| 2364 | "error": null, |
| 2365 | "notes": [], |
| 2366 | "dispatch": null, |
| 2367 | "last_run": null |
| 2368 | } |
| 2369 | ], |
| 2370 | "notes": "`state` is `active` or `disabled`. `dispatch` holds the `workflow_dispatch` inputs, or is `null` when the workflow cannot be run by hand. See [GitHub Actions](/guides/actions/)." |
| 2371 | }, |
| 2372 | "list_workflow_runs": { |
| 2373 | "query": { |
| 2374 | "workflow": "ci.yml", |
| 2375 | "branch": "main", |
| 2376 | "per_page": 20 |
| 2377 | }, |
| 2378 | "response": [ |
| 2379 | { |
| 2380 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2381 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2382 | "path": ".g1t/workflows/ci.yml", |
| 2383 | "name": "CI", |
| 2384 | "title": "Greeting should name the caller", |
| 2385 | "number": 12, |
| 2386 | "attempt": 1, |
| 2387 | "event": "push", |
| 2388 | "ref": "refs/heads/main", |
| 2389 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2390 | "pull": null, |
| 2391 | "status": "completed", |
| 2392 | "conclusion": "success", |
| 2393 | "error": null, |
| 2394 | "actor": "syntaqx", |
| 2395 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2396 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2397 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2398 | } |
| 2399 | ], |
| 2400 | "notes": "A run's `status` is `queued`, `pending` (waiting for its concurrency group), `in_progress` or `completed`; `conclusion` is set once it completes." |
| 2401 | }, |
| 2402 | "list_runs_of_workflow": { |
| 2403 | "params": { |
| 2404 | "workflow": "ci.yml" |
| 2405 | }, |
| 2406 | "query": { |
| 2407 | "branch": "main", |
| 2408 | "per_page": 20 |
| 2409 | }, |
| 2410 | "response": [ |
| 2411 | { |
| 2412 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2413 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2414 | "path": ".g1t/workflows/ci.yml", |
| 2415 | "name": "CI", |
| 2416 | "title": "Greeting should name the caller", |
| 2417 | "number": 12, |
| 2418 | "attempt": 1, |
| 2419 | "event": "push", |
| 2420 | "ref": "refs/heads/main", |
| 2421 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2422 | "pull": null, |
| 2423 | "status": "completed", |
| 2424 | "conclusion": "success", |
| 2425 | "error": null, |
| 2426 | "actor": "syntaqx", |
| 2427 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2428 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2429 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2430 | } |
| 2431 | ] |
| 2432 | }, |
| 2433 | "get_workflow_run": { |
| 2434 | "params": { |
| 2435 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr" |
| 2436 | }, |
| 2437 | "response": { |
| 2438 | "run": { |
| 2439 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2440 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2441 | "path": ".g1t/workflows/ci.yml", |
| 2442 | "name": "CI", |
| 2443 | "title": "Greeting should name the caller", |
| 2444 | "number": 12, |
| 2445 | "attempt": 1, |
| 2446 | "event": "push", |
| 2447 | "ref": "refs/heads/main", |
| 2448 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2449 | "pull": null, |
| 2450 | "status": "completed", |
| 2451 | "conclusion": "failure", |
| 2452 | "error": null, |
| 2453 | "actor": "syntaqx", |
| 2454 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2455 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2456 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2457 | }, |
| 2458 | "jobs": [ |
| 2459 | { |
| 2460 | "id": "job_01kpx7b3d0e4f8g2h6j0k4m8ns", |
| 2461 | "run_id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2462 | "key": "test", |
| 2463 | "name": "test", |
| 2464 | "needs": [], |
| 2465 | "status": "completed", |
| 2466 | "conclusion": "failure", |
| 2467 | "steps": [ |
| 2468 | { |
| 2469 | "number": 1, |
| 2470 | "name": "Run actions/checkout@v4", |
| 2471 | "status": "completed", |
| 2472 | "conclusion": "success", |
| 2473 | "started_at": "2026-10-04T15:42:10.101Z", |
| 2474 | "finished_at": "2026-10-04T15:42:12.433Z" |
| 2475 | }, |
| 2476 | { |
| 2477 | "number": 2, |
| 2478 | "name": "Run cargo test", |
| 2479 | "status": "completed", |
| 2480 | "conclusion": "failure", |
| 2481 | "started_at": "2026-10-04T15:42:12.440Z", |
| 2482 | "finished_at": "2026-10-04T15:44:30.902Z" |
| 2483 | } |
| 2484 | ], |
| 2485 | "annotations": [ |
| 2486 | { |
| 2487 | "level": "error", |
| 2488 | "message": "assertion failed: greeting names the caller", |
| 2489 | "title": "greet", |
| 2490 | "file": "src/main.rs", |
| 2491 | "line": 41 |
| 2492 | } |
| 2493 | ], |
| 2494 | "reason": null, |
| 2495 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2496 | "finished_at": "2026-10-04T15:44:31.002Z" |
| 2497 | }, |
| 2498 | { |
| 2499 | "id": "job_01kpx7b3d0e4f8g2h6j0k4m8nt", |
| 2500 | "run_id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2501 | "key": "deploy", |
| 2502 | "name": "deploy", |
| 2503 | "needs": [ |
| 2504 | "test" |
| 2505 | ], |
| 2506 | "status": "completed", |
| 2507 | "conclusion": "skipped", |
| 2508 | "steps": [], |
| 2509 | "annotations": [], |
| 2510 | "reason": "A job it needs did not succeed.", |
| 2511 | "started_at": null, |
| 2512 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2513 | } |
| 2514 | ], |
| 2515 | "notes": [ |
| 2516 | { |
| 2517 | "severity": "unsupported", |
| 2518 | "job": "test", |
| 2519 | "message": "`services` containers (such as a database) are not started on g1t yet." |
| 2520 | } |
| 2521 | ] |
| 2522 | } |
| 2523 | }, |
| 2524 | "get_job_logs": { |
| 2525 | "params": { |
| 2526 | "job": "job_01kpx7b3d0e4f8g2h6j0k4m8ns" |
| 2527 | }, |
| 2528 | "query": { |
| 2529 | "after": 0 |
| 2530 | }, |
| 2531 | "response": { |
| 2532 | "chunks": [ |
| 2533 | { |
| 2534 | "seq": 1, |
| 2535 | "step": 0, |
| 2536 | "text": "Preparing the sandbox\n" |
| 2537 | }, |
| 2538 | { |
| 2539 | "seq": 2, |
| 2540 | "step": 2, |
| 2541 | "text": "> cargo test\ntest greet ... FAILED\n" |
| 2542 | } |
| 2543 | ], |
| 2544 | "done": true |
| 2545 | }, |
| 2546 | "notes": "Returns at most 500 chunks. Step 0 is the job's setup. While `done` is false, call again with the last `seq` as `after`." |
| 2547 | }, |
| 2548 | "dispatch_workflow": { |
| 2549 | "params": { |
| 2550 | "workflow": "ci.yml" |
| 2551 | }, |
| 2552 | "request": { |
| 2553 | "ref": "main", |
| 2554 | "inputs": { |
| 2555 | "debug": true |
| 2556 | } |
| 2557 | }, |
| 2558 | "response": { |
| 2559 | "id": "run_01kpx8d4e7f0g3h6j9k2m5n8pq", |
| 2560 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2561 | "path": ".g1t/workflows/ci.yml", |
| 2562 | "name": "CI", |
| 2563 | "title": "CI run by syntaqx", |
| 2564 | "number": 13, |
| 2565 | "attempt": 1, |
| 2566 | "event": "workflow_dispatch", |
| 2567 | "ref": "refs/heads/main", |
| 2568 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2569 | "pull": null, |
| 2570 | "status": "queued", |
| 2571 | "conclusion": null, |
| 2572 | "error": null, |
| 2573 | "actor": "syntaqx", |
| 2574 | "created_at": "2026-10-04T16:30:00.512Z", |
| 2575 | "started_at": null, |
| 2576 | "finished_at": null |
| 2577 | } |
| 2578 | }, |
| 2579 | "cancel_workflow_run": { |
| 2580 | "params": { |
| 2581 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr" |
| 2582 | }, |
| 2583 | "response": { |
| 2584 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2585 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2586 | "path": ".g1t/workflows/ci.yml", |
| 2587 | "name": "CI", |
| 2588 | "title": "Greeting should name the caller", |
| 2589 | "number": 12, |
| 2590 | "attempt": 1, |
| 2591 | "event": "push", |
| 2592 | "ref": "refs/heads/main", |
| 2593 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2594 | "pull": null, |
| 2595 | "status": "completed", |
| 2596 | "conclusion": "cancelled", |
| 2597 | "error": null, |
| 2598 | "actor": "syntaqx", |
| 2599 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2600 | "started_at": "2026-10-04T15:42:09.020Z", |
| 2601 | "finished_at": "2026-10-04T15:44:31.877Z" |
| 2602 | } |
| 2603 | }, |
| 2604 | "rerun_workflow_run": { |
| 2605 | "params": { |
| 2606 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr" |
| 2607 | }, |
| 2608 | "request": { |
| 2609 | "failed_only": true |
| 2610 | }, |
| 2611 | "response": { |
| 2612 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2613 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2614 | "path": ".g1t/workflows/ci.yml", |
| 2615 | "name": "CI", |
| 2616 | "title": "Greeting should name the caller", |
| 2617 | "number": 12, |
| 2618 | "attempt": 2, |
| 2619 | "event": "push", |
| 2620 | "ref": "refs/heads/main", |
| 2621 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2622 | "pull": null, |
| 2623 | "status": "queued", |
| 2624 | "conclusion": null, |
| 2625 | "error": null, |
| 2626 | "actor": "syntaqx", |
| 2627 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2628 | "started_at": null, |
| 2629 | "finished_at": null |
| 2630 | }, |
| 2631 | "notes": "The run keeps its id; `attempt` goes up by one." |
| 2632 | }, |
| 2633 | "rerun_failed_jobs": { |
| 2634 | "params": { |
| 2635 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr" |
| 2636 | }, |
| 2637 | "response": { |
| 2638 | "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr", |
| 2639 | "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np", |
| 2640 | "path": ".g1t/workflows/ci.yml", |
| 2641 | "name": "CI", |
| 2642 | "title": "Greeting should name the caller", |
| 2643 | "number": 12, |
| 2644 | "attempt": 2, |
| 2645 | "event": "push", |
| 2646 | "ref": "refs/heads/main", |
| 2647 | "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 2648 | "pull": null, |
| 2649 | "status": "queued", |
| 2650 | "conclusion": null, |
| 2651 | "error": null, |
| 2652 | "actor": "syntaqx", |
| 2653 | "created_at": "2026-10-04T15:42:07.318Z", |
| 2654 | "started_at": null, |
| 2655 | "finished_at": null |
| 2656 | } |
| 2657 | }, |
| 2658 | "update_workflow": { |
| 2659 | "params": { |
| 2660 | "workflow": "nightly.yml" |
| 2661 | }, |
| 2662 | "request": { |
| 2663 | "enabled": false |
| 2664 | }, |
| 2665 | "response": { |
| 2666 | "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq", |
| 2667 | "path": ".g1t/workflows/nightly.yml", |
| 2668 | "name": "Nightly", |
| 2669 | "events": [ |
| 2670 | "schedule" |
| 2671 | ], |
| 2672 | "state": "disabled", |
| 2673 | "error": null, |
| 2674 | "notes": [], |
| 2675 | "dispatch": null, |
| 2676 | "last_run": null |
| 2677 | } |
| 2678 | }, |
| 2679 | "enable_workflow": { |
| 2680 | "params": { |
| 2681 | "workflow": "nightly.yml" |
| 2682 | }, |
| 2683 | "response": { |
| 2684 | "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq", |
| 2685 | "path": ".g1t/workflows/nightly.yml", |
| 2686 | "name": "Nightly", |
| 2687 | "events": [ |
| 2688 | "schedule" |
| 2689 | ], |
| 2690 | "state": "active", |
| 2691 | "error": null, |
| 2692 | "notes": [], |
| 2693 | "dispatch": null, |
| 2694 | "last_run": null |
| 2695 | } |
| 2696 | }, |
| 2697 | "disable_workflow": { |
| 2698 | "params": { |
| 2699 | "workflow": "nightly.yml" |
| 2700 | }, |
| 2701 | "response": { |
| 2702 | "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq", |
| 2703 | "path": ".g1t/workflows/nightly.yml", |
| 2704 | "name": "Nightly", |
| 2705 | "events": [ |
| 2706 | "schedule" |
| 2707 | ], |
| 2708 | "state": "disabled", |
| 2709 | "error": null, |
| 2710 | "notes": [], |
| 2711 | "dispatch": null, |
| 2712 | "last_run": null |
| 2713 | } |
| 2714 | }, |
| 2715 | "list_actions_secrets": { |
| 2716 | "response": [ |
| 2717 | { |
| 2718 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ab", |
| 2719 | "name": "NPM_TOKEN", |
| 2720 | "kind": "secret", |
| 2721 | "value": null, |
| 2722 | "scope": "workspace", |
| 2723 | "updated_at": "2026-10-01T09:12:44.020Z", |
| 2724 | "available_to": [ |
| 2725 | "workflows" |
| 2726 | ], |
| 2727 | "environments": [], |
| 2728 | "projects": [], |
| 2729 | "note": null, |
| 2730 | "updated_by": "syntaqx" |
| 2731 | }, |
| 2732 | { |
| 2733 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac", |
| 2734 | "name": "STRIPE_KEY", |
| 2735 | "kind": "secret", |
| 2736 | "value": null, |
| 2737 | "scope": "project", |
| 2738 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2739 | "available_to": [ |
| 2740 | "workflows", |
| 2741 | "deployments" |
| 2742 | ], |
| 2743 | "environments": [ |
| 2744 | "production" |
| 2745 | ], |
| 2746 | "projects": [], |
| 2747 | "note": "Rotate in the Stripe dashboard.", |
| 2748 | "updated_by": "syntaqx" |
| 2749 | } |
| 2750 | ], |
| 2751 | "notes": "Values are never returned. A repository's list includes the workspace's rows that reach it, with `scope` set to `workspace`. Empty `environments` means every environment." |
| 2752 | }, |
| 2753 | "list_actions_secrets_for_workspace": { |
| 2754 | "params": { |
| 2755 | "workspace": "flagon-io" |
| 2756 | }, |
| 2757 | "response": [ |
| 2758 | { |
| 2759 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ab", |
| 2760 | "name": "NPM_TOKEN", |
| 2761 | "kind": "secret", |
| 2762 | "value": null, |
| 2763 | "scope": "workspace", |
| 2764 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2765 | "available_to": [ |
| 2766 | "workflows" |
| 2767 | ], |
| 2768 | "environments": [], |
| 2769 | "projects": [], |
| 2770 | "note": null, |
| 2771 | "updated_by": "syntaqx" |
| 2772 | } |
| 2773 | ], |
| 2774 | "notes": "Values are never returned. A repository's list includes the workspace's rows that reach it, with `scope` set to `workspace`. Empty `environments` means every environment." |
| 2775 | }, |
| 2776 | "set_actions_secret": { |
| 2777 | "params": { |
| 2778 | "setting": "STRIPE_KEY" |
| 2779 | }, |
| 2780 | "request": { |
| 2781 | "value": "sk_live_…", |
| 2782 | "available_to": [ |
| 2783 | "workflows", |
| 2784 | "deployments" |
| 2785 | ], |
| 2786 | "environments": [ |
| 2787 | "production" |
| 2788 | ] |
| 2789 | }, |
| 2790 | "response": { |
| 2791 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac", |
| 2792 | "name": "STRIPE_KEY", |
| 2793 | "kind": "secret", |
| 2794 | "value": null, |
| 2795 | "scope": "project", |
| 2796 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2797 | "available_to": [ |
| 2798 | "workflows", |
| 2799 | "deployments" |
| 2800 | ], |
| 2801 | "environments": [ |
| 2802 | "production" |
| 2803 | ], |
| 2804 | "projects": [], |
| 2805 | "note": null, |
| 2806 | "updated_by": "syntaqx" |
| 2807 | }, |
| 2808 | "notes": "Keys are uppercased. See [secrets and variables](/guides/secrets-and-variables/)." |
| 2809 | }, |
| 2810 | "set_actions_secret_for_workspace": { |
| 2811 | "params": { |
| 2812 | "workspace": "flagon-io", |
| 2813 | "setting": "NPM_TOKEN" |
| 2814 | }, |
| 2815 | "request": { |
| 2816 | "value": "npm_…", |
| 2817 | "projects": [ |
| 2818 | "hello" |
| 2819 | ] |
| 2820 | }, |
| 2821 | "response": { |
| 2822 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac", |
| 2823 | "name": "NPM_TOKEN", |
| 2824 | "kind": "secret", |
| 2825 | "value": null, |
| 2826 | "scope": "workspace", |
| 2827 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2828 | "available_to": [ |
| 2829 | "workflows" |
| 2830 | ], |
| 2831 | "environments": [], |
| 2832 | "projects": [ |
| 2833 | "hello" |
| 2834 | ], |
| 2835 | "note": null, |
| 2836 | "updated_by": "syntaqx" |
| 2837 | } |
| 2838 | }, |
| 2839 | "delete_actions_secret": { |
| 2840 | "params": { |
| 2841 | "setting": "STRIPE_KEY" |
| 2842 | }, |
| 2843 | "response": true |
| 2844 | }, |
| 2845 | "delete_actions_secret_for_workspace": { |
| 2846 | "params": { |
| 2847 | "workspace": "flagon-io", |
| 2848 | "setting": "NPM_TOKEN" |
| 2849 | }, |
| 2850 | "response": true |
| 2851 | }, |
| 2852 | "list_actions_variables": { |
| 2853 | "response": [ |
| 2854 | { |
| 2855 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2856 | "name": "NODE_VERSION", |
| 2857 | "kind": "variable", |
| 2858 | "value": "20", |
| 2859 | "scope": "project", |
| 2860 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2861 | "available_to": [ |
| 2862 | "workflows", |
| 2863 | "deployments" |
| 2864 | ], |
| 2865 | "environments": [], |
| 2866 | "projects": [], |
| 2867 | "note": null, |
| 2868 | "updated_by": "syntaqx" |
| 2869 | } |
| 2870 | ], |
| 2871 | "notes": "A repository's list includes the workspace's rows that reach it, with `scope` set to `workspace`. Empty `environments` means every environment." |
| 2872 | }, |
| 2873 | "list_actions_variables_for_workspace": { |
| 2874 | "params": { |
| 2875 | "workspace": "flagon-io" |
| 2876 | }, |
| 2877 | "response": [ |
| 2878 | { |
| 2879 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2880 | "name": "NODE_VERSION", |
| 2881 | "kind": "variable", |
| 2882 | "value": "20", |
| 2883 | "scope": "workspace", |
| 2884 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2885 | "available_to": [ |
| 2886 | "workflows", |
| 2887 | "deployments" |
| 2888 | ], |
| 2889 | "environments": [], |
| 2890 | "projects": [], |
| 2891 | "note": null, |
| 2892 | "updated_by": "syntaqx" |
| 2893 | } |
| 2894 | ] |
| 2895 | }, |
| 2896 | "set_actions_variable": { |
| 2897 | "request": { |
| 2898 | "setting": "NODE_VERSION", |
| 2899 | "value": "20" |
| 2900 | }, |
| 2901 | "response": { |
| 2902 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2903 | "name": "NODE_VERSION", |
| 2904 | "kind": "variable", |
| 2905 | "value": "20", |
| 2906 | "scope": "project", |
| 2907 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2908 | "available_to": [ |
| 2909 | "workflows", |
| 2910 | "deployments" |
| 2911 | ], |
| 2912 | "environments": [], |
| 2913 | "projects": [], |
| 2914 | "note": null, |
| 2915 | "updated_by": "syntaqx" |
| 2916 | }, |
| 2917 | "notes": "GitHub's clients send the key as `name`; that is accepted too." |
| 2918 | }, |
| 2919 | "set_actions_variable_for_workspace": { |
| 2920 | "params": { |
| 2921 | "workspace": "flagon-io" |
| 2922 | }, |
| 2923 | "request": { |
| 2924 | "setting": "NODE_VERSION", |
| 2925 | "value": "20" |
| 2926 | }, |
| 2927 | "response": { |
| 2928 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2929 | "name": "NODE_VERSION", |
| 2930 | "kind": "variable", |
| 2931 | "value": "20", |
| 2932 | "scope": "workspace", |
| 2933 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2934 | "available_to": [ |
| 2935 | "workflows", |
| 2936 | "deployments" |
| 2937 | ], |
| 2938 | "environments": [], |
| 2939 | "projects": [], |
| 2940 | "note": null, |
| 2941 | "updated_by": "syntaqx" |
| 2942 | } |
| 2943 | }, |
| 2944 | "update_actions_variable": { |
| 2945 | "params": { |
| 2946 | "setting": "NODE_VERSION" |
| 2947 | }, |
| 2948 | "request": { |
| 2949 | "value": "22" |
| 2950 | }, |
| 2951 | "response": { |
| 2952 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2953 | "name": "NODE_VERSION", |
| 2954 | "kind": "variable", |
| 2955 | "value": "22", |
| 2956 | "scope": "project", |
| 2957 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2958 | "available_to": [ |
| 2959 | "workflows", |
| 2960 | "deployments" |
| 2961 | ], |
| 2962 | "environments": [], |
| 2963 | "projects": [], |
| 2964 | "note": null, |
| 2965 | "updated_by": "syntaqx" |
| 2966 | } |
| 2967 | }, |
| 2968 | "update_actions_variable_for_workspace": { |
| 2969 | "params": { |
| 2970 | "workspace": "flagon-io", |
| 2971 | "setting": "NODE_VERSION" |
| 2972 | }, |
| 2973 | "request": { |
| 2974 | "value": "22" |
| 2975 | }, |
| 2976 | "response": { |
| 2977 | "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad", |
| 2978 | "name": "NODE_VERSION", |
| 2979 | "kind": "variable", |
| 2980 | "value": "22", |
| 2981 | "scope": "workspace", |
| 2982 | "updated_at": "2026-10-04T15:42:07.318Z", |
| 2983 | "available_to": [ |
| 2984 | "workflows", |
| 2985 | "deployments" |
| 2986 | ], |
| 2987 | "environments": [], |
| 2988 | "projects": [], |
| 2989 | "note": null, |
| 2990 | "updated_by": "syntaqx" |
| 2991 | } |
| 2992 | }, |
| 2993 | "delete_actions_variable": { |
| 2994 | "params": { |
| 2995 | "setting": "NODE_VERSION" |
| 2996 | }, |
| 2997 | "response": true |
| 2998 | }, |
| 2999 | "delete_actions_variable_for_workspace": { |
| 3000 | "params": { |
| 3001 | "workspace": "flagon-io", |
| 3002 | "setting": "NODE_VERSION" |
| 3003 | }, |
| 3004 | "response": true |
| 3005 | }, |
| 3006 | "list_runners": { |
| 3007 | "response": [ |
| 3008 | { |
| 3009 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z", |
| 3010 | "name": "build-01", |
| 3011 | "workspace": "flagon-io", |
| 3012 | "repo": null, |
| 3013 | "group": "Default", |
| 3014 | "labels": [ |
| 3015 | "self-hosted", |
| 3016 | "linux", |
| 3017 | "x64", |
| 3018 | "gpu" |
| 3019 | ], |
| 3020 | "os": "linux", |
| 3021 | "arch": "x64", |
| 3022 | "version": "0.2.0", |
| 3023 | "ephemeral": false, |
| 3024 | "status": "busy", |
| 3025 | "work": { |
| 3026 | "kind": "workflow", |
| 3027 | "id": "job_01kq2m9b1d4g7j0m3p6s9v2y5b", |
| 3028 | "name": "test (linux, 24)", |
| 3029 | "repo": "flagon-io/hello", |
| 3030 | "run_id": "run_01kq2m9a8c1f4h7k0n3q6t9w2z", |
| 3031 | "started_at": "2026-10-06T14:02:11.000Z" |
| 3032 | }, |
| 3033 | "last_seen_at": "2026-10-06T14:05:40.512Z", |
| 3034 | "created_at": "2026-10-02T09:30:00.000Z", |
| 3035 | "created_by": null |
| 3036 | }, |
| 3037 | { |
| 3038 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w9a", |
| 3039 | "name": "mac-mini", |
| 3040 | "workspace": "flagon-io", |
| 3041 | "repo": null, |
| 3042 | "group": "Default", |
| 3043 | "labels": [ |
| 3044 | "self-hosted", |
| 3045 | "macos", |
| 3046 | "arm64" |
| 3047 | ], |
| 3048 | "os": "macos", |
| 3049 | "arch": "arm64", |
| 3050 | "version": "0.2.0", |
| 3051 | "ephemeral": false, |
| 3052 | "status": "online", |
| 3053 | "work": null, |
| 3054 | "last_seen_at": "2026-10-06T14:05:40.512Z", |
| 3055 | "created_at": "2026-10-02T09:30:00.000Z", |
| 3056 | "created_by": null |
| 3057 | } |
| 3058 | ], |
| 3059 | "notes": "A repository's list holds its own runners (`repo` set) and the workspace's that its runner group lets it use. A runner is `offline` when it has not polled for 90 seconds." |
| 3060 | }, |
| 3061 | "list_runners_for_workspace": { |
| 3062 | "params": { |
| 3063 | "workspace": "flagon-io" |
| 3064 | }, |
| 3065 | "response": [ |
| 3066 | { |
| 3067 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z", |
| 3068 | "name": "build-01", |
| 3069 | "workspace": "flagon-io", |
| 3070 | "repo": null, |
| 3071 | "group": "Default", |
| 3072 | "labels": [ |
| 3073 | "self-hosted", |
| 3074 | "linux", |
| 3075 | "x64", |
| 3076 | "gpu" |
| 3077 | ], |
| 3078 | "os": "linux", |
| 3079 | "arch": "x64", |
| 3080 | "version": "0.2.0", |
| 3081 | "ephemeral": false, |
| 3082 | "status": "busy", |
| 3083 | "work": { |
| 3084 | "kind": "workflow", |
| 3085 | "id": "job_01kq2m9b1d4g7j0m3p6s9v2y5b", |
| 3086 | "name": "test (linux, 24)", |
| 3087 | "repo": "flagon-io/hello", |
| 3088 | "run_id": "run_01kq2m9a8c1f4h7k0n3q6t9w2z", |
| 3089 | "started_at": "2026-10-06T14:02:11.000Z" |
| 3090 | }, |
| 3091 | "last_seen_at": "2026-10-06T14:05:40.512Z", |
| 3092 | "created_at": "2026-10-02T09:30:00.000Z", |
| 3093 | "created_by": null |
| 3094 | }, |
| 3095 | { |
| 3096 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w9a", |
| 3097 | "name": "mac-mini", |
| 3098 | "workspace": "flagon-io", |
| 3099 | "repo": null, |
| 3100 | "group": "Default", |
| 3101 | "labels": [ |
| 3102 | "self-hosted", |
| 3103 | "macos", |
| 3104 | "arm64" |
| 3105 | ], |
| 3106 | "os": "macos", |
| 3107 | "arch": "arm64", |
| 3108 | "version": "0.2.0", |
| 3109 | "ephemeral": false, |
| 3110 | "status": "online", |
| 3111 | "work": null, |
| 3112 | "last_seen_at": "2026-10-06T14:05:40.512Z", |
| 3113 | "created_at": "2026-10-02T09:30:00.000Z", |
| 3114 | "created_by": null |
| 3115 | } |
| 3116 | ] |
| 3117 | }, |
| 3118 | "create_runner_registration_token": { |
| 3119 | "response": { |
| 3120 | "token": "g1trt_…", |
| 3121 | "expires_at": "2026-10-06T15:04:00.000Z", |
| 3122 | "workspace": "flagon-io", |
| 3123 | "repo": "flagon-io/hello", |
| 3124 | "group": null, |
| 3125 | "url": "https://g1t.sh" |
| 3126 | }, |
| 3127 | "notes": "Pass it to `g1t-runner register --url https://g1t.sh --token …` within the hour. See [self-hosted runners](/guides/self-hosted-runners/)." |
| 3128 | }, |
| 3129 | "create_runner_registration_token_for_workspace": { |
| 3130 | "params": { |
| 3131 | "workspace": "flagon-io" |
| 3132 | }, |
| 3133 | "request": { |
| 3134 | "group": "Default" |
| 3135 | }, |
| 3136 | "response": { |
| 3137 | "token": "g1trt_…", |
| 3138 | "expires_at": "2026-10-06T15:04:00.000Z", |
| 3139 | "workspace": "flagon-io", |
| 3140 | "repo": null, |
| 3141 | "group": "Default", |
| 3142 | "url": "https://g1t.sh" |
| 3143 | } |
| 3144 | }, |
| 3145 | "remove_runner": { |
| 3146 | "params": { |
| 3147 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z" |
| 3148 | }, |
| 3149 | "response": true |
| 3150 | }, |
| 3151 | "remove_runner_for_workspace": { |
| 3152 | "params": { |
| 3153 | "workspace": "flagon-io", |
| 3154 | "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z" |
| 3155 | }, |
| 3156 | "response": true |
| 3157 | }, |
| 3158 | "get_runner_settings": { |
| 3159 | "response": { |
| 3160 | "agents_on_self_hosted": false, |
| 3161 | "agent_labels": [ |
| 3162 | "self-hosted", |
| 3163 | "linux" |
| 3164 | ], |
| 3165 | "fork_pull_requests": false, |
| 3166 | "inherited": true |
| 3167 | } |
| 3168 | }, |
| 3169 | "get_runner_settings_for_workspace": { |
| 3170 | "params": { |
| 3171 | "workspace": "flagon-io" |
| 3172 | }, |
| 3173 | "response": { |
| 3174 | "agents_on_self_hosted": true, |
| 3175 | "agent_labels": [ |
| 3176 | "self-hosted", |
| 3177 | "linux" |
| 3178 | ], |
| 3179 | "fork_pull_requests": false, |
| 3180 | "inherited": false |
| 3181 | } |
| 3182 | }, |
| 3183 | "update_runner_settings": { |
| 3184 | "request": { |
| 3185 | "inherit": true |
| 3186 | }, |
| 3187 | "response": { |
| 3188 | "agents_on_self_hosted": false, |
| 3189 | "agent_labels": [ |
| 3190 | "self-hosted", |
| 3191 | "linux" |
| 3192 | ], |
| 3193 | "fork_pull_requests": false, |
| 3194 | "inherited": true |
| 3195 | } |
| 3196 | }, |
| 3197 | "update_runner_settings_for_workspace": { |
| 3198 | "params": { |
| 3199 | "workspace": "flagon-io" |
| 3200 | }, |
| 3201 | "request": { |
| 3202 | "agents_on_self_hosted": true, |
| 3203 | "agent_labels": [ |
| 3204 | "linux" |
| 3205 | ] |
| 3206 | }, |
| 3207 | "response": { |
| 3208 | "agents_on_self_hosted": true, |
| 3209 | "agent_labels": [ |
| 3210 | "self-hosted", |
| 3211 | "linux" |
| 3212 | ], |
| 3213 | "fork_pull_requests": false, |
| 3214 | "inherited": false |
| 3215 | }, |
| 3216 | "notes": "Agent work on your runners still uses g1t's model proxy, paid as before, unless the workspace has its own model provider." |
| 3217 | }, |
| 3218 | "list_runner_groups": { |
| 3219 | "params": { |
| 3220 | "workspace": "flagon-io" |
| 3221 | }, |
| 3222 | "response": [ |
| 3223 | { |
| 3224 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6y", |
| 3225 | "name": "Default", |
| 3226 | "default": true, |
| 3227 | "repositories": [], |
| 3228 | "runners": 2, |
| 3229 | "updated_at": "2026-10-02T09:30:00.000Z" |
| 3230 | }, |
| 3231 | { |
| 3232 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z", |
| 3233 | "name": "GPU", |
| 3234 | "default": false, |
| 3235 | "repositories": [ |
| 3236 | "hello", |
| 3237 | "models" |
| 3238 | ], |
| 3239 | "runners": 1, |
| 3240 | "updated_at": "2026-10-05T11:20:00.000Z" |
| 3241 | } |
| 3242 | ] |
| 3243 | }, |
| 3244 | "create_runner_group": { |
| 3245 | "params": { |
| 3246 | "workspace": "flagon-io" |
| 3247 | }, |
| 3248 | "request": { |
| 3249 | "name": "GPU", |
| 3250 | "repositories": [ |
| 3251 | "hello", |
| 3252 | "models" |
| 3253 | ] |
| 3254 | }, |
| 3255 | "response": { |
| 3256 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z", |
| 3257 | "name": "GPU", |
| 3258 | "default": false, |
| 3259 | "repositories": [ |
| 3260 | "hello", |
| 3261 | "models" |
| 3262 | ], |
| 3263 | "runners": 1, |
| 3264 | "updated_at": "2026-10-05T11:20:00.000Z" |
| 3265 | } |
| 3266 | }, |
| 3267 | "update_runner_group": { |
| 3268 | "params": { |
| 3269 | "workspace": "flagon-io", |
| 3270 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z" |
| 3271 | }, |
| 3272 | "request": { |
| 3273 | "repositories": [] |
| 3274 | }, |
| 3275 | "response": { |
| 3276 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z", |
| 3277 | "name": "GPU", |
| 3278 | "default": false, |
| 3279 | "repositories": [], |
| 3280 | "runners": 1, |
| 3281 | "updated_at": "2026-10-05T11:20:00.000Z" |
| 3282 | } |
| 3283 | }, |
| 3284 | "delete_runner_group": { |
| 3285 | "params": { |
| 3286 | "workspace": "flagon-io", |
| 3287 | "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z" |
| 3288 | }, |
| 3289 | "response": true |
| 3290 | }, |
| 3291 | "list_webhooks": { |
| 3292 | "response": [ |
| 3293 | { |
| 3294 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3295 | "scope": "repo", |
| 3296 | "workspace": "flagon-io", |
| 3297 | "repo": "flagon-io/hello", |
| 3298 | "url": "https://hooks.example.com/g1t", |
| 3299 | "events": [ |
| 3300 | "git.push", |
| 3301 | "pull.merged" |
| 3302 | ], |
| 3303 | "active": true, |
| 3304 | "secret_hint": "…9c2e", |
| 3305 | "created_by": "syntaqx", |
| 3306 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3307 | "last_status": "delivered", |
| 3308 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3309 | } |
| 3310 | ] |
| 3311 | }, |
| 3312 | "list_webhooks_for_workspace": { |
| 3313 | "params": { |
| 3314 | "workspace": "flagon-io" |
| 3315 | }, |
| 3316 | "response": [ |
| 3317 | { |
| 3318 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3319 | "scope": "workspace", |
| 3320 | "workspace": "flagon-io", |
| 3321 | "repo": null, |
| 3322 | "url": "https://hooks.example.com/g1t", |
| 3323 | "events": [ |
| 3324 | "git.push", |
| 3325 | "pull.merged" |
| 3326 | ], |
| 3327 | "active": true, |
| 3328 | "secret_hint": "…9c2e", |
| 3329 | "created_by": "syntaqx", |
| 3330 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3331 | "last_status": "delivered", |
| 3332 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3333 | } |
| 3334 | ] |
| 3335 | }, |
| 3336 | "create_webhook": { |
| 3337 | "request": { |
| 3338 | "url": "https://hooks.example.com/g1t", |
| 3339 | "events": [ |
| 3340 | "git.push", |
| 3341 | "pull.merged" |
| 3342 | ] |
| 3343 | }, |
| 3344 | "response": { |
| 3345 | "hook": { |
| 3346 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3347 | "scope": "repo", |
| 3348 | "workspace": "flagon-io", |
| 3349 | "repo": "flagon-io/hello", |
| 3350 | "url": "https://hooks.example.com/g1t", |
| 3351 | "events": [ |
| 3352 | "git.push", |
| 3353 | "pull.merged" |
| 3354 | ], |
| 3355 | "active": true, |
| 3356 | "secret_hint": "…9c2e", |
| 3357 | "created_by": "syntaqx", |
| 3358 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3359 | "last_status": "delivered", |
| 3360 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3361 | }, |
| 3362 | "secret": "whsec_…" |
| 3363 | }, |
| 3364 | "notes": "A ping is sent before the response, so `last_status` is usually set already. When g1t made the signing secret, `secret` holds it: it is shown only this once. See [webhooks](/guides/webhooks/)." |
| 3365 | }, |
| 3366 | "create_webhook_for_workspace": { |
| 3367 | "params": { |
| 3368 | "workspace": "flagon-io" |
| 3369 | }, |
| 3370 | "request": { |
| 3371 | "url": "https://hooks.example.com/g1t" |
| 3372 | }, |
| 3373 | "response": { |
| 3374 | "hook": { |
| 3375 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3376 | "scope": "workspace", |
| 3377 | "workspace": "flagon-io", |
| 3378 | "repo": null, |
| 3379 | "url": "https://hooks.example.com/g1t", |
| 3380 | "events": [ |
| 3381 | "*" |
| 3382 | ], |
| 3383 | "active": true, |
| 3384 | "secret_hint": "…9c2e", |
| 3385 | "created_by": "syntaqx", |
| 3386 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3387 | "last_status": "delivered", |
| 3388 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3389 | }, |
| 3390 | "secret": "whsec_…" |
| 3391 | }, |
| 3392 | "notes": "A ping is sent before the response, so `last_status` is usually set already. When g1t made the signing secret, `secret` holds it: it is shown only this once. See [webhooks](/guides/webhooks/)." |
| 3393 | }, |
| 3394 | "update_webhook": { |
| 3395 | "params": { |
| 3396 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3397 | }, |
| 3398 | "request": { |
| 3399 | "active": false |
| 3400 | }, |
| 3401 | "response": { |
| 3402 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3403 | "scope": "repo", |
| 3404 | "workspace": "flagon-io", |
| 3405 | "repo": "flagon-io/hello", |
| 3406 | "url": "https://hooks.example.com/g1t", |
| 3407 | "events": [ |
| 3408 | "git.push", |
| 3409 | "pull.merged" |
| 3410 | ], |
| 3411 | "active": false, |
| 3412 | "secret_hint": "…9c2e", |
| 3413 | "created_by": "syntaqx", |
| 3414 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3415 | "last_status": "delivered", |
| 3416 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3417 | } |
| 3418 | }, |
| 3419 | "update_webhook_for_workspace": { |
| 3420 | "params": { |
| 3421 | "workspace": "flagon-io", |
| 3422 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3423 | }, |
| 3424 | "request": { |
| 3425 | "active": false |
| 3426 | }, |
| 3427 | "response": { |
| 3428 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3429 | "scope": "workspace", |
| 3430 | "workspace": "flagon-io", |
| 3431 | "repo": null, |
| 3432 | "url": "https://hooks.example.com/g1t", |
| 3433 | "events": [ |
| 3434 | "git.push", |
| 3435 | "pull.merged" |
| 3436 | ], |
| 3437 | "active": false, |
| 3438 | "secret_hint": "…9c2e", |
| 3439 | "created_by": "syntaqx", |
| 3440 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3441 | "last_status": "delivered", |
| 3442 | "last_delivered_at": "2026-10-04T15:42:07.611Z" |
| 3443 | } |
| 3444 | }, |
| 3445 | "delete_webhook": { |
| 3446 | "params": { |
| 3447 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3448 | }, |
| 3449 | "response": true |
| 3450 | }, |
| 3451 | "delete_webhook_for_workspace": { |
| 3452 | "params": { |
| 3453 | "workspace": "flagon-io", |
| 3454 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3455 | }, |
| 3456 | "response": true |
| 3457 | }, |
| 3458 | "ping_webhook": { |
| 3459 | "params": { |
| 3460 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3461 | }, |
| 3462 | "response": { |
| 3463 | "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st", |
| 3464 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3465 | "event_id": "", |
| 3466 | "event": "ping", |
| 3467 | "status": "delivered", |
| 3468 | "attempts": 1, |
| 3469 | "response_status": 200, |
| 3470 | "response_body": "ok", |
| 3471 | "error": null, |
| 3472 | "duration_ms": 184, |
| 3473 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3474 | "created_at": "2026-10-04T16:01:12.440Z", |
| 3475 | "delivered_at": "2026-10-04T16:01:12.631Z", |
| 3476 | "next_attempt_at": null |
| 3477 | }, |
| 3478 | "notes": "`payload` is the JSON that was sent, as a string." |
| 3479 | }, |
| 3480 | "ping_webhook_for_workspace": { |
| 3481 | "params": { |
| 3482 | "workspace": "flagon-io", |
| 3483 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3484 | }, |
| 3485 | "response": { |
| 3486 | "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st", |
| 3487 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3488 | "event_id": "", |
| 3489 | "event": "ping", |
| 3490 | "status": "delivered", |
| 3491 | "attempts": 1, |
| 3492 | "response_status": 200, |
| 3493 | "response_body": "ok", |
| 3494 | "error": null, |
| 3495 | "duration_ms": 184, |
| 3496 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3497 | "created_at": "2026-10-04T16:01:12.440Z", |
| 3498 | "delivered_at": "2026-10-04T16:01:12.631Z", |
| 3499 | "next_attempt_at": null |
| 3500 | } |
| 3501 | }, |
| 3502 | "list_webhook_deliveries": { |
| 3503 | "params": { |
| 3504 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3505 | }, |
| 3506 | "response": [ |
| 3507 | { |
| 3508 | "id": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz", |
| 3509 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3510 | "event_id": "", |
| 3511 | "event": "ping", |
| 3512 | "status": "pending", |
| 3513 | "attempts": 1, |
| 3514 | "response_status": 503, |
| 3515 | "response_body": "Service Unavailable", |
| 3516 | "error": null, |
| 3517 | "duration_ms": 212, |
| 3518 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3519 | "created_at": "2026-10-04T16:20:03.100Z", |
| 3520 | "delivered_at": null, |
| 3521 | "next_attempt_at": "2026-10-04T16:21:03.312Z" |
| 3522 | }, |
| 3523 | { |
| 3524 | "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st", |
| 3525 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3526 | "event_id": "", |
| 3527 | "event": "ping", |
| 3528 | "status": "delivered", |
| 3529 | "attempts": 1, |
| 3530 | "response_status": 200, |
| 3531 | "response_body": "ok", |
| 3532 | "error": null, |
| 3533 | "duration_ms": 184, |
| 3534 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3535 | "created_at": "2026-10-04T16:01:12.440Z", |
| 3536 | "delivered_at": "2026-10-04T16:01:12.631Z", |
| 3537 | "next_attempt_at": null |
| 3538 | } |
| 3539 | ], |
| 3540 | "notes": "Returns at most 50, newest first. `status` is `pending`, `delivered` or `failed`; `next_attempt_at` is set while it is pending." |
| 3541 | }, |
| 3542 | "list_webhook_deliveries_for_workspace": { |
| 3543 | "params": { |
| 3544 | "workspace": "flagon-io", |
| 3545 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd" |
| 3546 | }, |
| 3547 | "response": [ |
| 3548 | { |
| 3549 | "id": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz", |
| 3550 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3551 | "event_id": "", |
| 3552 | "event": "ping", |
| 3553 | "status": "pending", |
| 3554 | "attempts": 1, |
| 3555 | "response_status": 503, |
| 3556 | "response_body": "Service Unavailable", |
| 3557 | "error": null, |
| 3558 | "duration_ms": 212, |
| 3559 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3560 | "created_at": "2026-10-04T16:20:03.100Z", |
| 3561 | "delivered_at": null, |
| 3562 | "next_attempt_at": "2026-10-04T16:21:03.312Z" |
| 3563 | }, |
| 3564 | { |
| 3565 | "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st", |
| 3566 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3567 | "event_id": "", |
| 3568 | "event": "ping", |
| 3569 | "status": "delivered", |
| 3570 | "attempts": 1, |
| 3571 | "response_status": 200, |
| 3572 | "response_body": "ok", |
| 3573 | "error": null, |
| 3574 | "duration_ms": 184, |
| 3575 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3576 | "created_at": "2026-10-04T16:01:12.440Z", |
| 3577 | "delivered_at": "2026-10-04T16:01:12.631Z", |
| 3578 | "next_attempt_at": null |
| 3579 | } |
| 3580 | ] |
| 3581 | }, |
| 3582 | "redeliver_webhook": { |
| 3583 | "params": { |
| 3584 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3585 | "delivery": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz" |
| 3586 | }, |
| 3587 | "response": { |
| 3588 | "id": "dlv_01kpx6c8d1e2f3g4h5j6k7m8np", |
| 3589 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3590 | "event_id": "", |
| 3591 | "event": "ping", |
| 3592 | "status": "delivered", |
| 3593 | "attempts": 1, |
| 3594 | "response_status": 200, |
| 3595 | "response_body": "ok", |
| 3596 | "error": null, |
| 3597 | "duration_ms": 171, |
| 3598 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3599 | "created_at": "2026-10-04T16:25:40.007Z", |
| 3600 | "delivered_at": "2026-10-04T16:25:40.178Z", |
| 3601 | "next_attempt_at": null |
| 3602 | }, |
| 3603 | "notes": "The response is the new delivery." |
| 3604 | }, |
| 3605 | "redeliver_webhook_for_workspace": { |
| 3606 | "params": { |
| 3607 | "workspace": "flagon-io", |
| 3608 | "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3609 | "delivery": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz" |
| 3610 | }, |
| 3611 | "response": { |
| 3612 | "id": "dlv_01kpx6c8d1e2f3g4h5j6k7m8np", |
| 3613 | "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd", |
| 3614 | "event_id": "", |
| 3615 | "event": "ping", |
| 3616 | "status": "delivered", |
| 3617 | "attempts": 1, |
| 3618 | "response_status": 200, |
| 3619 | "response_body": "ok", |
| 3620 | "error": null, |
| 3621 | "duration_ms": 171, |
| 3622 | "payload": "{\"hook\":{\"events\":[\"git.push\",\"pull.merged\"],\"id\":\"hk_01kpx5p9s4h0t1w6x8y2a3b4cd\",\"url\":\"https://hooks.example.com/g1t\"},\"message\":\"g1t will send this webhook's events here.\",\"time\":\"2026-10-04T16:01:12.440Z\",\"type\":\"ping\"}", |
| 3623 | "created_at": "2026-10-04T16:25:40.007Z", |
| 3624 | "delivered_at": "2026-10-04T16:25:40.178Z", |
| 3625 | "next_attempt_at": null |
| 3626 | } |
| 3627 | }, |
| 3628 | "list_integrations": { |
| 3629 | "params": { |
| 3630 | "workspace": "flagon-io" |
| 3631 | }, |
| 3632 | "response": [ |
| 3633 | { |
| 3634 | "id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab", |
| 3635 | "workspace": "flagon-io", |
| 3636 | "provider": "anthropic", |
| 3637 | "kind": "models", |
| 3638 | "name": "Anthropic", |
| 3639 | "config": { |
| 3640 | "assign": false, |
| 3641 | "write_back": true |
| 3642 | }, |
| 3643 | "secret_hint": "…3f9a", |
| 3644 | "webhook_url": null, |
| 3645 | "created_by": "syntaqx", |
| 3646 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3647 | "last_used_at": "2026-10-04T15:42:08.102Z", |
| 3648 | "last_error": null, |
| 3649 | "models": [ |
| 3650 | "claude-haiku-4-5", |
| 3651 | "claude-sonnet-4-5" |
| 3652 | ] |
| 3653 | }, |
| 3654 | { |
| 3655 | "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bc", |
| 3656 | "workspace": "flagon-io", |
| 3657 | "provider": "jira", |
| 3658 | "kind": "tracker", |
| 3659 | "name": "Jira", |
| 3660 | "config": { |
| 3661 | "assign": false, |
| 3662 | "write_back": true, |
| 3663 | "site": "https://acme.atlassian.net", |
| 3664 | "email": "syntaqx@example.com", |
| 3665 | "keys": [ |
| 3666 | "TECH" |
| 3667 | ] |
| 3668 | }, |
| 3669 | "secret_hint": "…x7Qe", |
| 3670 | "webhook_url": null, |
| 3671 | "created_by": "syntaqx", |
| 3672 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3673 | "last_used_at": null, |
| 3674 | "last_error": null, |
| 3675 | "models": [] |
| 3676 | } |
| 3677 | ], |
| 3678 | "notes": "`kind` is `models`, `alerts` or `tracker`. `secret_hint` shows the end of the secret; the secret itself is never returned. `webhook_url` is where an alert source sends its alerts." |
| 3679 | }, |
| 3680 | "connect_integration": { |
| 3681 | "params": { |
| 3682 | "workspace": "flagon-io" |
| 3683 | }, |
| 3684 | "request": { |
| 3685 | "provider": "webhook", |
| 3686 | "config": { |
| 3687 | "repo": "flagon-io/hello", |
| 3688 | "label": "bug" |
| 3689 | } |
| 3690 | }, |
| 3691 | "response": { |
| 3692 | "connection": { |
| 3693 | "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bd", |
| 3694 | "workspace": "flagon-io", |
| 3695 | "provider": "webhook", |
| 3696 | "kind": "alerts", |
| 3697 | "name": "Webhook", |
| 3698 | "config": { |
| 3699 | "repo": "flagon-io/hello", |
| 3700 | "label": "bug", |
| 3701 | "assign": false, |
| 3702 | "write_back": true |
| 3703 | }, |
| 3704 | "secret_hint": null, |
| 3705 | "webhook_url": "https://api.g1t.sh/hooks/con_01kpx4n8r3g9s0v5w7x1z2a3bd", |
| 3706 | "created_by": "syntaqx", |
| 3707 | "created_at": "2026-10-04T15:42:07.318Z", |
| 3708 | "last_used_at": null, |
| 3709 | "last_error": null, |
| 3710 | "models": [] |
| 3711 | }, |
| 3712 | "signing_secret": "g1ts_9f2c4a7e1b0d3c6f8a2e5b7d9c1f4a6e8b0d2c4f6a8e1b3d" |
| 3713 | }, |
| 3714 | "notes": "`signing_secret` is set only when g1t made it, for `datadog` and `webhook`, and is shown only this once. A model provider is tested as it is connected. See [integrations](/guides/integrations/) and [model providers](/guides/models/)." |
| 3715 | }, |
| 3716 | "disconnect_integration": { |
| 3717 | "params": { |
| 3718 | "workspace": "flagon-io", |
| 3719 | "id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab" |
| 3720 | }, |
| 3721 | "response": true |
| 3722 | }, |
| 3723 | "test_integration": { |
| 3724 | "params": { |
| 3725 | "workspace": "flagon-io", |
| 3726 | "id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab" |
| 3727 | }, |
| 3728 | "response": { |
| 3729 | "ok": true, |
| 3730 | "message": "Anthropic accepted the key and offers 9 models." |
| 3731 | }, |
| 3732 | "notes": "Credentials that do not work still answer `200`, with `ok` false and `message` saying what went wrong." |
| 3733 | }, |
| 3734 | "get_model_routes": { |
| 3735 | "params": { |
| 3736 | "workspace": "flagon-io" |
| 3737 | }, |
| 3738 | "response": [ |
| 3739 | { |
| 3740 | "task": "default", |
| 3741 | "connection_id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab", |
| 3742 | "model": "claude-sonnet-4-5" |
| 3743 | }, |
| 3744 | { |
| 3745 | "task": "review", |
| 3746 | "connection_id": null, |
| 3747 | "model": null |
| 3748 | } |
| 3749 | ] |
| 3750 | }, |
| 3751 | "set_model_routes": { |
| 3752 | "params": { |
| 3753 | "workspace": "flagon-io" |
| 3754 | }, |
| 3755 | "request": { |
| 3756 | "routes": [ |
| 3757 | { |
| 3758 | "task": "default", |
| 3759 | "connection_id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab", |
| 3760 | "model": "claude-sonnet-4-5" |
| 3761 | }, |
| 3762 | { |
| 3763 | "task": "plan", |
| 3764 | "connection_id": null, |
| 3765 | "model": "frontier" |
| 3766 | }, |
| 3767 | { |
| 3768 | "task": "review", |
| 3769 | "connection_id": null |
| 3770 | } |
| 3771 | ] |
| 3772 | }, |
| 3773 | "response": [ |
| 3774 | { |
| 3775 | "task": "default", |
| 3776 | "connection_id": "con_01kpx3m7q2f8r9t4v6w0y1z2ab", |
| 3777 | "model": "claude-sonnet-4-5" |
| 3778 | }, |
| 3779 | { |
| 3780 | "task": "plan", |
| 3781 | "connection_id": null, |
| 3782 | "model": "frontier" |
| 3783 | }, |
| 3784 | { |
| 3785 | "task": "review", |
| 3786 | "connection_id": null, |
| 3787 | "model": null |
| 3788 | } |
| 3789 | ], |
| 3790 | "notes": "The response is the routes as saved, ordered by task. On g1t's hosted models (`connection_id` null), `model` is `small`, `large` or `frontier`, or null for Auto, which picks the cheapest model that can do each job and says why on the run." |
| 3791 | }, |
| 3792 | "get_context": { |
| 3793 | "query": { |
| 3794 | "reference": "TECH-1234" |
| 3795 | }, |
| 3796 | "response": { |
| 3797 | "provider": "jira", |
| 3798 | "key": "TECH-1234", |
| 3799 | "title": "Checkout fails for EU cards", |
| 3800 | "url": "https://acme.atlassian.net/browse/TECH-1234", |
| 3801 | "status": "In Progress", |
| 3802 | "body": "Customers with 3DS cards see a 500 at /pay.", |
| 3803 | "fetched_at": "2026-10-04T15:42:07.318Z" |
| 3804 | } |
| 3805 | }, |
| 3806 | "import_issue": { |
| 3807 | "request": { |
| 3808 | "reference": "TECH-1234" |
| 3809 | }, |
| 3810 | "response": { |
| 3811 | "number": 42, |
| 3812 | "item": { |
| 3813 | "provider": "jira", |
| 3814 | "key": "TECH-1234", |
| 3815 | "title": "Checkout fails for EU cards", |
| 3816 | "url": "https://acme.atlassian.net/browse/TECH-1234", |
| 3817 | "status": "In Progress", |
| 3818 | "body": "Customers with 3DS cards see a 500 at /pay.", |
| 3819 | "fetched_at": "2026-10-04T15:42:07.318Z" |
| 3820 | }, |
| 3821 | "created": true |
| 3822 | }, |
| 3823 | "notes": "`created` is false when the ticket was imported before; `number` is then that issue." |
| 3824 | }, |
| 3825 | "remember": { |
| 3826 | "request": { |
| 3827 | "text": "The tests need TZ=UTC or the date tests fail.", |
| 3828 | "scope": "project", |
| 3829 | "kind": "gotcha", |
| 3830 | "from_number": 14 |
| 3831 | }, |
| 3832 | "response": { |
| 3833 | "id": "mem_01m43v8q2w3e4r5t6y7u8i9o0p", |
| 3834 | "scope": "project", |
| 3835 | "workspace": "flagon-io", |
| 3836 | "repo": { |
| 3837 | "namespace": "flagon-io", |
| 3838 | "name": "hello" |
| 3839 | }, |
| 3840 | "text": "The tests need TZ=UTC or the date tests fail.", |
| 3841 | "kind": "gotcha", |
| 3842 | "source": { |
| 3843 | "kind": "run", |
| 3844 | "run_id": "arn_01m43v2c1p9k8d7e6f5a4b3c2d", |
| 3845 | "repo": { |
| 3846 | "namespace": "flagon-io", |
| 3847 | "name": "hello" |
| 3848 | }, |
| 3849 | "number": 14 |
| 3850 | }, |
| 3851 | "created_by": "g1t", |
| 3852 | "pinned": false, |
| 3853 | "created_at": "2026-10-01T18:40:12.000Z", |
| 3854 | "updated_at": "2026-10-01T18:40:12.000Z", |
| 3855 | "last_used_at": null |
| 3856 | }, |
| 3857 | "notes": "Text that looks like a key, a token or a password is refused with `invalid`: memory is read by every agent in the workspace. Saving the same text again in the same scope returns the memory already kept." |
| 3858 | }, |
| 3859 | "recall": { |
| 3860 | "query": { |
| 3861 | "q": "pnpm" |
| 3862 | }, |
| 3863 | "response": { |
| 3864 | "project": [], |
| 3865 | "workspace": [ |
| 3866 | { |
| 3867 | "id": "mem_01m43t0a1s2d3f4g5h6j7k8l9z", |
| 3868 | "scope": "workspace", |
| 3869 | "workspace": "flagon-io", |
| 3870 | "repo": null, |
| 3871 | "text": "We use pnpm everywhere, never npm or yarn.", |
| 3872 | "kind": "convention", |
| 3873 | "source": { |
| 3874 | "kind": "person", |
| 3875 | "run_id": null, |
| 3876 | "repo": null, |
| 3877 | "number": null |
| 3878 | }, |
| 3879 | "created_by": "syntaqx", |
| 3880 | "pinned": true, |
| 3881 | "created_at": "2026-10-01T18:40:12.000Z", |
| 3882 | "updated_at": "2026-10-01T18:40:12.000Z", |
| 3883 | "last_used_at": null |
| 3884 | } |
| 3885 | ] |
| 3886 | }, |
| 3887 | "notes": "Anyone who can read the repository gets its project memory; `workspace` is filled only for members of the workspace, and is empty for anyone else. Each memory returned is marked used, which keeps it near the front of what agents are given." |
| 3888 | }, |
| 3889 | "search": { |
| 3890 | "query": { |
| 3891 | "q": "parse_query language:rust repo:acme/web", |
| 3892 | "type": "code" |
| 3893 | }, |
| 3894 | "response": { |
| 3895 | "query": "parse_query repo:acme/web language:rust", |
| 3896 | "type": "code", |
| 3897 | "counts": { |
| 3898 | "repositories": 0, |
| 3899 | "code": 2, |
| 3900 | "issues": 0, |
| 3901 | "pulls": 0, |
| 3902 | "people": 0 |
| 3903 | }, |
| 3904 | "page": 1, |
| 3905 | "per_page": 20, |
| 3906 | "more": false, |
| 3907 | "hits": [ |
| 3908 | { |
| 3909 | "kind": "code", |
| 3910 | "title": "src/search/query.rs", |
| 3911 | "url": "/acme/web/blob/main/src/search/query.rs#L42", |
| 3912 | "repo": "acme/web", |
| 3913 | "private": false, |
| 3914 | "description": null, |
| 3915 | "snippet": [], |
| 3916 | "lines": [ |
| 3917 | { |
| 3918 | "number": 41, |
| 3919 | "parts": [ |
| 3920 | { |
| 3921 | "text": "/// Reads a query typed into the search box.", |
| 3922 | "highlight": false |
| 3923 | } |
| 3924 | ] |
| 3925 | }, |
| 3926 | { |
| 3927 | "number": 42, |
| 3928 | "parts": [ |
| 3929 | { |
| 3930 | "text": "pub fn ", |
| 3931 | "highlight": false |
| 3932 | }, |
| 3933 | { |
| 3934 | "text": "parse_query", |
| 3935 | "highlight": true |
| 3936 | }, |
| 3937 | { |
| 3938 | "text": "(text: &str) -> Query {", |
| 3939 | "highlight": false |
| 3940 | } |
| 3941 | ] |
| 3942 | }, |
| 3943 | { |
| 3944 | "number": 43, |
| 3945 | "parts": [ |
| 3946 | { |
| 3947 | "text": " let mut query = Query::default();", |
| 3948 | "highlight": false |
| 3949 | } |
| 3950 | ] |
| 3951 | } |
| 3952 | ], |
| 3953 | "path": "src/search/query.rs", |
| 3954 | "language": "rust", |
| 3955 | "ref": "main", |
| 3956 | "number": null, |
| 3957 | "state": null, |
| 3958 | "author": null, |
| 3959 | "requested_by": null, |
| 3960 | "labels": [], |
| 3961 | "topics": [], |
| 3962 | "slug": null, |
| 3963 | "avatar": null, |
| 3964 | "updated_at": null |
| 3965 | } |
| 3966 | ], |
| 3967 | "notes": [] |
| 3968 | }, |
| 3969 | "notes": "`q` takes words, `\"exact phrases\"`, `-words` to leave out, and qualifiers: `repo:owner/name`, `org:` (or `workspace:`), `language:`, `path:` (a glob when it has `*`), `is:issue`, `is:pr`, `is:open`, `is:closed`, `is:merged`, `is:draft`, `is:public`, `is:private`, `author:` and `label:`; most can be left out with a leading `-`, as in `-label:wontfix`. `type` is `repositories`, `code`, `issues`, `pulls` or `people`; without it, `path:` means code, `is:pr` pull requests, `is:open`, `author:` or `label:` issues, and anything else repositories. `counts` says how many results each type has, up to 1,000. Each result's `snippet` (or, for code, each of its `lines`) is a list of parts, `highlight` true where the query matched. Code is searched on default branches and needs a word of three characters or more, unless the query names a `repo:`. Public content is returned to anyone, without a token; private content only to people who can read it (members of its workspace, and people given a role on the repository), checked when the search runs, so a repository made private, or a role taken away, stops appearing at once. A g1t agent's token can search too. An issue or pull request g1t opened has `author` `g1t` and `requested_by` the person it was for; `author:` matches the author." |
| 3970 | }, |
| 3971 | "search_context": { |
| 3972 | "params": { |
| 3973 | "workspace": "acme" |
| 3974 | }, |
| 3975 | "query": { |
| 3976 | "q": "how do we run the web tests", |
| 3977 | "project": "web" |
| 3978 | }, |
| 3979 | "response": { |
| 3980 | "query": "how do we run the web tests", |
| 3981 | "mode": "semantic", |
| 3982 | "hits": [ |
| 3983 | { |
| 3984 | "kind": "memory", |
| 3985 | "id": "mem_01m4a0c2b7k3f9d1e5g8h2j6k4", |
| 3986 | "title": "Gotcha", |
| 3987 | "snippet": "The date tests fail unless TZ=UTC.", |
| 3988 | "project": "web", |
| 3989 | "url": "/acme/web/memory", |
| 3990 | "score": 0.82, |
| 3991 | "source": "AGENTS.md", |
| 3992 | "by": "g1t", |
| 3993 | "updated_at": "2026-10-04T21:10:02.000Z" |
| 3994 | }, |
| 3995 | { |
| 3996 | "kind": "doc", |
| 3997 | "id": "ent_5f0c2a9e41d7b3c86a1e2f40:2", |
| 3998 | "title": "Web (README.md)", |
| 3999 | "snippet": "## Testing Run npm test. The end-to-end tests need the api running locally…", |
| 4000 | "project": "web", |
| 4001 | "url": "/acme/web/blob/main/README.md", |
| 4002 | "score": 0.77, |
| 4003 | "source": "README.md", |
| 4004 | "by": null, |
| 4005 | "updated_at": "2026-10-04T20:58:41.000Z" |
| 4006 | }, |
| 4007 | { |
| 4008 | "kind": "project", |
| 4009 | "id": "ent_9b1d6f0a2c3e4b5d6e7f8a9b", |
| 4010 | "title": "web", |
| 4011 | "snippet": "The storefront. Written in TypeScript. Packages: @acme/web. Uses api. Owned by ana.", |
| 4012 | "project": "web", |
| 4013 | "url": "/acme/web", |
| 4014 | "score": 0.71, |
| 4015 | "source": "catalog", |
| 4016 | "by": null, |
| 4017 | "updated_at": "2026-10-04T20:58:41.000Z" |
| 4018 | } |
| 4019 | ] |
| 4020 | }, |
| 4021 | "notes": "Give `workspace`, or `repo` as `owner/name` for its workspace. `kinds` narrows to some of `project`, `app`, `api`, `package`, `language`, `owner`, `environment`, `integration`, `doc`, `memory`, `issue` and `pull`; in a URL, comma-separated. `mode` is `text` when the search index could not answer and words were matched instead. Memory is returned only to members of the workspace and its agents; anything from a private project, only to those who can read it (members, unless the base permission is None, and people given a role on its repository). A g1t agent searches its own workspace only." |
| 4022 | }, |
| 4023 | "get_entity": { |
| 4024 | "params": { |
| 4025 | "workspace": "acme", |
| 4026 | "kind": "project", |
| 4027 | "id": "web" |
| 4028 | }, |
| 4029 | "response": { |
| 4030 | "entity": { |
| 4031 | "id": "ent_9b1d6f0a2c3e4b5d6e7f8a9b", |
| 4032 | "workspace": "acme", |
| 4033 | "kind": "project", |
| 4034 | "key": "web", |
| 4035 | "name": "web", |
| 4036 | "summary": "The storefront. Written in TypeScript. Packages: @acme/web. Uses api. Owned by ana.", |
| 4037 | "project": "web", |
| 4038 | "private": true, |
| 4039 | "data": { |
| 4040 | "repo": "acme/web", |
| 4041 | "root_dir": "", |
| 4042 | "default_branch": "main", |
| 4043 | "languages": [ |
| 4044 | "TypeScript" |
| 4045 | ], |
| 4046 | "owners": [ |
| 4047 | "ana" |
| 4048 | ], |
| 4049 | "tests": true, |
| 4050 | "test_commands": [ |
| 4051 | "npm test" |
| 4052 | ], |
| 4053 | "production_url": "https://web--acme.g1t.page" |
| 4054 | }, |
| 4055 | "source": "scan", |
| 4056 | "ref": "/acme/web", |
| 4057 | "updated_at": "2026-10-04T20:58:41.000Z" |
| 4058 | }, |
| 4059 | "relations": [ |
| 4060 | { |
| 4061 | "kind": "depends_on", |
| 4062 | "direction": "out", |
| 4063 | "entity": { |
| 4064 | "id": "ent_0a7c3e5b9d1f2a4c6e8b0d2f", |
| 4065 | "workspace": "acme", |
| 4066 | "kind": "project", |
| 4067 | "key": "api", |
| 4068 | "name": "api", |
| 4069 | "summary": "The public API. Written in Rust.", |
| 4070 | "project": "api", |
| 4071 | "private": true, |
| 4072 | "data": {}, |
| 4073 | "source": "scan", |
| 4074 | "ref": "/acme/api", |
| 4075 | "updated_at": "2026-10-04T20:57:12.000Z" |
| 4076 | } |
| 4077 | }, |
| 4078 | { |
| 4079 | "kind": "owned_by", |
| 4080 | "direction": "out", |
| 4081 | "entity": { |
| 4082 | "id": "ent_3c5e7a9b1d2f4a6c8e0b2d4f", |
| 4083 | "workspace": "acme", |
| 4084 | "kind": "owner", |
| 4085 | "key": "ana", |
| 4086 | "name": "ana", |
| 4087 | "summary": null, |
| 4088 | "project": null, |
| 4089 | "private": false, |
| 4090 | "data": {}, |
| 4091 | "source": "scan", |
| 4092 | "ref": "/u/ana", |
| 4093 | "updated_at": "2026-10-04T20:58:41.000Z" |
| 4094 | } |
| 4095 | } |
| 4096 | ] |
| 4097 | }, |
| 4098 | "notes": "`id` is the entry's id, or its key: a project's or app's slug, `npm:<name>` (or `cargo:`, `go:`, `pypi:`) for a package, a username for an owner, `<project>/production` for an environment. `data` depends on the kind: a package's version and dependencies, an API's routes, an app's production address." |
| 4099 | }, |
| 4100 | "list_collaborators": { |
| 4101 | "response": { |
| 4102 | "repo": "flagon-io/hello", |
| 4103 | "base_permission": "write", |
| 4104 | "people": [ |
| 4105 | { |
| 4106 | "username": "syntaqx", |
| 4107 | "name": "Chase Pierce", |
| 4108 | "avatar": null, |
| 4109 | "role": "admin", |
| 4110 | "source": "owner", |
| 4111 | "direct": null, |
| 4112 | "workspace_role": "owner" |
| 4113 | }, |
| 4114 | { |
| 4115 | "username": "linus", |
| 4116 | "name": null, |
| 4117 | "avatar": null, |
| 4118 | "role": "maintain", |
| 4119 | "source": "direct", |
| 4120 | "direct": "maintain", |
| 4121 | "workspace_role": "member" |
| 4122 | }, |
| 4123 | { |
| 4124 | "username": "grace", |
| 4125 | "name": "Grace Hopper", |
| 4126 | "avatar": null, |
| 4127 | "role": "write", |
| 4128 | "source": "base", |
| 4129 | "direct": null, |
| 4130 | "workspace_role": "member" |
| 4131 | }, |
| 4132 | { |
| 4133 | "username": "ada", |
| 4134 | "name": "Ada Lovelace", |
| 4135 | "avatar": null, |
| 4136 | "role": "triage", |
| 4137 | "source": "direct", |
| 4138 | "direct": "triage", |
| 4139 | "workspace_role": null |
| 4140 | } |
| 4141 | ], |
| 4142 | "invitations": [ |
| 4143 | { |
| 4144 | "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p", |
| 4145 | "repo": "flagon-io/hello", |
| 4146 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4147 | "invitee": "alan", |
| 4148 | "email": null, |
| 4149 | "role": "write", |
| 4150 | "invited_by": "syntaqx", |
| 4151 | "inviter_avatar": null, |
| 4152 | "status": "pending", |
| 4153 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4154 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4155 | }, |
| 4156 | { |
| 4157 | "id": "rin_01kp3d7e8f9g0h1j2k3m4n5p6q", |
| 4158 | "repo": "flagon-io/hello", |
| 4159 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4160 | "invitee": null, |
| 4161 | "email": "joan@example.com", |
| 4162 | "role": "read", |
| 4163 | "invited_by": "syntaqx", |
| 4164 | "inviter_avatar": null, |
| 4165 | "status": "pending", |
| 4166 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4167 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4168 | } |
| 4169 | ], |
| 4170 | "viewer_role": "admin", |
| 4171 | "can_manage": true |
| 4172 | }, |
| 4173 | "notes": "Owners are listed with `source` `owner`, members with the base permission with `base`, and anyone given a role on this repository with `direct`; `role` is the highest of these, and `direct` shows a direct role even when ownership or the base permission gives more. `workspace_role` null means an outside collaborator. Anyone can read a public repository, which is not listed. `invitations` is empty unless you have the Admin role (`can_manage`). Refused with `403` below the Write role, and `404` for a private repository you cannot see. See [Access and roles](/guides/access-and-roles/)." |
| 4174 | }, |
| 4175 | "add_collaborator": { |
| 4176 | "request": { |
| 4177 | "invitee": "ada", |
| 4178 | "role": "triage" |
| 4179 | }, |
| 4180 | "response": { |
| 4181 | "result": "invited", |
| 4182 | "invitation": { |
| 4183 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r", |
| 4184 | "repo": "flagon-io/hello", |
| 4185 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4186 | "invitee": "ada", |
| 4187 | "email": null, |
| 4188 | "role": "triage", |
| 4189 | "invited_by": "syntaqx", |
| 4190 | "inviter_avatar": null, |
| 4191 | "status": "pending", |
| 4192 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4193 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4194 | } |
| 4195 | }, |
| 4196 | "notes": "`invitee` is a username or an email address. A member of the workspace answers `{\"result\": \"granted\", \"collaborator\": {…}}` with the role already given, shown as list_collaborators shows a person. Anyone else answers `{\"result\": \"invited\", \"invitation\": {…}}`: the invitation is emailed and waits 7 days, and the role is theirs once they accept it. An email address without an account gets an invitation with `email` set and `invitee` null, and an invite that makes the account and accepts in one step. Refused with `404` when no account has that username, `409` when they already have a role of their own or a pending invitation (change it with update_collaborator), and `403` without the Admin role, from an agent's or a workspace's token, or when the person does not meet what the workspace asks of everyone with access. collaborator_added` webhook event is sent once they have the role. See [Access and roles](/guides/access-and-roles/). On a free workspace, inviting anyone who is not a member answers `402` with `payment_required` until it starts the g1t plan." |
| 4197 | }, |
| 4198 | "update_collaborator": { |
| 4199 | "params": { |
| 4200 | "owner": "flagon-io", |
| 4201 | "name": "hello", |
| 4202 | "username": "ada" |
| 4203 | }, |
| 4204 | "request": { |
| 4205 | "role": "write" |
| 4206 | }, |
| 4207 | "response": { |
| 4208 | "username": "ada", |
| 4209 | "name": "Ada Lovelace", |
| 4210 | "avatar": null, |
| 4211 | "role": "write", |
| 4212 | "source": "direct", |
| 4213 | "direct": "write", |
| 4214 | "workspace_role": null |
| 4215 | }, |
| 4216 | "notes": "Changes a direct role, or the role of the person's pending invitation. `404` when they have neither: an owner's Admin and a member's base permission are not changed here. Changing a direct role sends the `repo.collaborator_role_changed` webhook event. See [Access and roles](/guides/access-and-roles/)." |
| 4217 | }, |
| 4218 | "remove_collaborator": { |
| 4219 | "params": { |
| 4220 | "owner": "flagon-io", |
| 4221 | "name": "hello", |
| 4222 | "username": "ada" |
| 4223 | }, |
| 4224 | "response": true, |
| 4225 | "notes": "Takes away a direct role. Anyone may remove their own, to leave a repository. `404` when the person has no role of their own on it. A member keeps the workspace's base permission. Sends the `repo.collaborator_removed` webhook event. See [Access and roles](/guides/access-and-roles/)." |
| 4226 | }, |
| 4227 | "get_collaborator_permission": { |
| 4228 | "params": { |
| 4229 | "owner": "flagon-io", |
| 4230 | "name": "hello", |
| 4231 | "username": "ada" |
| 4232 | }, |
| 4233 | "response": { |
| 4234 | "username": "ada", |
| 4235 | "role": "triage", |
| 4236 | "source": "direct", |
| 4237 | "capabilities": [ |
| 4238 | "read", |
| 4239 | "participate", |
| 4240 | "triage" |
| 4241 | ] |
| 4242 | }, |
| 4243 | "notes": "`capabilities` lists what the role allows, in the table's order: `read`, `participate`, `triage`, `push`, `merge`, `run`, `manage_settings`, `manage_protection`, `manage_integrations`, `manage_access`, `administer` and `delete` (which also takes an owner of the workspace). `role` and `source` are null, and `capabilities` empty, for someone with no role. Refused with `403` below the Write role, unless you ask about yourself. See [Access and roles](/guides/access-and-roles/)." |
| 4244 | }, |
| 4245 | "list_repo_invitations": { |
| 4246 | "response": [ |
| 4247 | { |
| 4248 | "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p", |
| 4249 | "repo": "flagon-io/hello", |
| 4250 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4251 | "invitee": "alan", |
| 4252 | "email": null, |
| 4253 | "role": "write", |
| 4254 | "invited_by": "syntaqx", |
| 4255 | "inviter_avatar": null, |
| 4256 | "status": "pending", |
| 4257 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4258 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4259 | }, |
| 4260 | { |
| 4261 | "id": "rin_01kp3d7e8f9g0h1j2k3m4n5p6q", |
| 4262 | "repo": "flagon-io/hello", |
| 4263 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4264 | "invitee": null, |
| 4265 | "email": "joan@example.com", |
| 4266 | "role": "read", |
| 4267 | "invited_by": "syntaqx", |
| 4268 | "inviter_avatar": null, |
| 4269 | "status": "pending", |
| 4270 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4271 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4272 | } |
| 4273 | ], |
| 4274 | "notes": "Pending invitations only, newest first. `email` is set for an invitation sent to an address that had no account. Refused with `403` without the Admin role. See [Access and roles](/guides/access-and-roles/)." |
| 4275 | }, |
| 4276 | "revoke_repo_invitation": { |
| 4277 | "params": { |
| 4278 | "owner": "flagon-io", |
| 4279 | "name": "hello", |
| 4280 | "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p" |
| 4281 | }, |
| 4282 | "response": { |
| 4283 | "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p", |
| 4284 | "repo": "flagon-io/hello", |
| 4285 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4286 | "invitee": "alan", |
| 4287 | "email": null, |
| 4288 | "role": "write", |
| 4289 | "invited_by": "syntaqx", |
| 4290 | "inviter_avatar": null, |
| 4291 | "status": "revoked", |
| 4292 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4293 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4294 | }, |
| 4295 | "notes": "`404` when there is no pending invitation with that id on this repository." |
| 4296 | }, |
| 4297 | "list_my_repo_invitations": { |
| 4298 | "response": [ |
| 4299 | { |
| 4300 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r", |
| 4301 | "repo": "flagon-io/hello", |
| 4302 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4303 | "invitee": "ada", |
| 4304 | "email": null, |
| 4305 | "role": "triage", |
| 4306 | "invited_by": "syntaqx", |
| 4307 | "inviter_avatar": null, |
| 4308 | "status": "pending", |
| 4309 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4310 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4311 | } |
| 4312 | ], |
| 4313 | "notes": "Invitations sent to your username, and to any of your confirmed addresses before you had an account, newest first. Accept one with `PATCH /user/repository_invitations/{id}`, or decline it with `DELETE`. Expired and answered ones are left out." |
| 4314 | }, |
| 4315 | "accept_repo_invitation": { |
| 4316 | "params": { |
| 4317 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r" |
| 4318 | }, |
| 4319 | "response": { |
| 4320 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r", |
| 4321 | "repo": "flagon-io/hello", |
| 4322 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4323 | "invitee": "ada", |
| 4324 | "email": null, |
| 4325 | "role": "triage", |
| 4326 | "invited_by": "syntaqx", |
| 4327 | "inviter_avatar": null, |
| 4328 | "status": "accepted", |
| 4329 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4330 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4331 | }, |
| 4332 | "notes": "The role is yours at once. `404` when you have no pending invitation with that id (it may have expired or been revoked), and `403` when your account does not meet what the workspace asks of everyone with access, such as two-factor authentication, with a message that says what to turn on. See [Access and roles](/guides/access-and-roles/)." |
| 4333 | }, |
| 4334 | "decline_repo_invitation": { |
| 4335 | "params": { |
| 4336 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r" |
| 4337 | }, |
| 4338 | "response": { |
| 4339 | "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r", |
| 4340 | "repo": "flagon-io/hello", |
| 4341 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4342 | "invitee": "ada", |
| 4343 | "email": null, |
| 4344 | "role": "triage", |
| 4345 | "invited_by": "syntaqx", |
| 4346 | "inviter_avatar": null, |
| 4347 | "status": "declined", |
| 4348 | "created_at": "2026-10-05T17:00:00.000Z", |
| 4349 | "expires_at": "2026-10-12T17:00:00.000Z" |
| 4350 | }, |
| 4351 | "notes": "`404` when you have no pending invitation with that id." |
| 4352 | }, |
| 4353 | "set_base_permission": { |
| 4354 | "params": { |
| 4355 | "workspace": "flagon-io" |
| 4356 | }, |
| 4357 | "request": { |
| 4358 | "base_permission": "read" |
| 4359 | }, |
| 4360 | "response": { |
| 4361 | "workspace": "flagon-io", |
| 4362 | "base_permission": "read" |
| 4363 | }, |
| 4364 | "notes": "`base_permission` is `none`, `read`, `write` (the default) or `admin`. Owners keep Admin, and a role given on a repository directly still counts where it is higher. Refused with `403` for anyone but an owner signed in as a person. See [Access and roles](/guides/access-and-roles/)." |
| 4365 | }, |
| 4366 | "list_outside_collaborators": { |
| 4367 | "params": { |
| 4368 | "workspace": "flagon-io" |
| 4369 | }, |
| 4370 | "response": [ |
| 4371 | { |
| 4372 | "username": "ada", |
| 4373 | "name": "Ada Lovelace", |
| 4374 | "avatar": null, |
| 4375 | "repos": [ |
| 4376 | { |
| 4377 | "repo": "flagon-io/docs", |
| 4378 | "role": "write" |
| 4379 | }, |
| 4380 | { |
| 4381 | "repo": "flagon-io/hello", |
| 4382 | "role": "triage" |
| 4383 | } |
| 4384 | ] |
| 4385 | } |
| 4386 | ], |
| 4387 | "notes": "By username, each with the repositories they have a role on. Refused with `403` for anyone but an owner. See [Access and roles](/guides/access-and-roles/)." |
| 4388 | }, |
| 4389 | "list_teams": { |
| 4390 | "params": { |
| 4391 | "workspace": "flagon-io" |
| 4392 | }, |
| 4393 | "query": { |
| 4394 | "q": "back" |
| 4395 | }, |
| 4396 | "response": [ |
| 4397 | { |
| 4398 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4399 | "workspace": "flagon-io", |
| 4400 | "slug": "backend", |
| 4401 | "name": "Backend", |
| 4402 | "description": "The API and the services behind it.", |
| 4403 | "visibility": "visible", |
| 4404 | "parent": { |
| 4405 | "slug": "engineering", |
| 4406 | "name": "Engineering" |
| 4407 | }, |
| 4408 | "notify": true, |
| 4409 | "review_assignment": { |
| 4410 | "enabled": false, |
| 4411 | "algorithm": "round_robin", |
| 4412 | "count": 1, |
| 4413 | "skip_busy": false, |
| 4414 | "busy_at": 5, |
| 4415 | "include_child_teams": false, |
| 4416 | "excluded": [], |
| 4417 | "notify_team": false |
| 4418 | }, |
| 4419 | "members_count": 4, |
| 4420 | "repos_count": 2, |
| 4421 | "child_teams_count": 1, |
| 4422 | "viewer_role": "maintainer", |
| 4423 | "can_manage": true, |
| 4424 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4425 | "updated_at": "2026-10-06T15:02:11.480Z" |
| 4426 | } |
| 4427 | ], |
| 4428 | "notes": "Teams you are in come first, then the rest by name. A secret team is listed only for its own people and the workspace's owners. `review_assignment` is what happens when the team is asked to review: see [`set_team_review_assignment`](/reference/api/teams/set-team-review-assignment/). `403` for anyone who is not a member of the workspace. See [Teams](/guides/teams/)." |
| 4429 | }, |
| 4430 | "create_team": { |
| 4431 | "params": { |
| 4432 | "workspace": "flagon-io" |
| 4433 | }, |
| 4434 | "request": { |
| 4435 | "name": "Backend", |
| 4436 | "description": "The API and the services behind it.", |
| 4437 | "visibility": "visible", |
| 4438 | "parent": "engineering", |
| 4439 | "members": [ |
| 4440 | "ana" |
| 4441 | ] |
| 4442 | }, |
| 4443 | "response": { |
| 4444 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4445 | "workspace": "flagon-io", |
| 4446 | "slug": "backend", |
| 4447 | "name": "Backend", |
| 4448 | "description": "The API and the services behind it.", |
| 4449 | "visibility": "visible", |
| 4450 | "parent": { |
| 4451 | "slug": "engineering", |
| 4452 | "name": "Engineering" |
| 4453 | }, |
| 4454 | "notify": true, |
| 4455 | "review_assignment": { |
| 4456 | "enabled": false, |
| 4457 | "algorithm": "round_robin", |
| 4458 | "count": 1, |
| 4459 | "skip_busy": false, |
| 4460 | "busy_at": 5, |
| 4461 | "include_child_teams": false, |
| 4462 | "excluded": [], |
| 4463 | "notify_team": false |
| 4464 | }, |
| 4465 | "members_count": 2, |
| 4466 | "repos_count": 0, |
| 4467 | "child_teams_count": 0, |
| 4468 | "viewer_role": "maintainer", |
| 4469 | "can_manage": true, |
| 4470 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4471 | "updated_at": "2026-10-06T15:02:11.480Z" |
| 4472 | }, |
| 4473 | "notes": "You become the team's maintainer. Refused with `403` for a member when the workspace's `team_creation` is `owners`. `slug` is made from `name` when left out (`Web & Mobile` becomes `web-mobile`), and `409` says one is taken. A workspace has at most 500 teams, nested at most 8 deep; `name` is at most 80 characters and `description` 280. A `secret` team cannot have a parent or child teams. Refused with `403` for an agent's or a workspace's token. See [Teams](/guides/teams/)." |
| 4474 | }, |
| 4475 | "get_team": { |
| 4476 | "params": { |
| 4477 | "workspace": "flagon-io", |
| 4478 | "team": "backend" |
| 4479 | }, |
| 4480 | "response": { |
| 4481 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4482 | "workspace": "flagon-io", |
| 4483 | "slug": "backend", |
| 4484 | "name": "Backend", |
| 4485 | "description": "The API and the services behind it.", |
| 4486 | "visibility": "visible", |
| 4487 | "parent": { |
| 4488 | "slug": "engineering", |
| 4489 | "name": "Engineering" |
| 4490 | }, |
| 4491 | "notify": true, |
| 4492 | "review_assignment": { |
| 4493 | "enabled": false, |
| 4494 | "algorithm": "round_robin", |
| 4495 | "count": 1, |
| 4496 | "skip_busy": false, |
| 4497 | "busy_at": 5, |
| 4498 | "include_child_teams": false, |
| 4499 | "excluded": [], |
| 4500 | "notify_team": false |
| 4501 | }, |
| 4502 | "members_count": 4, |
| 4503 | "repos_count": 2, |
| 4504 | "child_teams_count": 1, |
| 4505 | "viewer_role": "maintainer", |
| 4506 | "can_manage": true, |
| 4507 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4508 | "updated_at": "2026-10-06T15:02:11.480Z" |
| 4509 | }, |
| 4510 | "notes": "`404` for a team that does not exist, or a secret one you are not in, unless you are an owner." |
| 4511 | }, |
| 4512 | "update_team": { |
| 4513 | "params": { |
| 4514 | "workspace": "flagon-io", |
| 4515 | "team": "backend" |
| 4516 | }, |
| 4517 | "request": { |
| 4518 | "description": "The API, the services behind it, and their on-call.", |
| 4519 | "visibility": "secret", |
| 4520 | "parent": "" |
| 4521 | }, |
| 4522 | "response": { |
| 4523 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4524 | "workspace": "flagon-io", |
| 4525 | "slug": "backend", |
| 4526 | "name": "Backend", |
| 4527 | "description": "The API, the services behind it, and their on-call.", |
| 4528 | "visibility": "secret", |
| 4529 | "parent": null, |
| 4530 | "notify": true, |
| 4531 | "review_assignment": { |
| 4532 | "enabled": false, |
| 4533 | "algorithm": "round_robin", |
| 4534 | "count": 1, |
| 4535 | "skip_busy": false, |
| 4536 | "busy_at": 5, |
| 4537 | "include_child_teams": false, |
| 4538 | "excluded": [], |
| 4539 | "notify_team": false |
| 4540 | }, |
| 4541 | "members_count": 4, |
| 4542 | "repos_count": 2, |
| 4543 | "child_teams_count": 1, |
| 4544 | "viewer_role": "maintainer", |
| 4545 | "can_manage": true, |
| 4546 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4547 | "updated_at": "2026-10-07T09:41:52.006Z" |
| 4548 | }, |
| 4549 | "notes": "Only the fields given change. `parent` set to `\"\"` takes the team out from under its parent; a team cannot be nested under itself or one of its own child teams. A new `slug` changes how it is mentioned: `@flagon-io/backend` no longer reaches it. `review_assignment` takes the fields [`set_team_review_assignment`](/reference/api/teams/set-team-review-assignment/) does. Owners of the workspace and the team's maintainers (`403` otherwise)." |
| 4550 | }, |
| 4551 | "delete_team": { |
| 4552 | "params": { |
| 4553 | "workspace": "flagon-io", |
| 4554 | "team": "backend" |
| 4555 | }, |
| 4556 | "response": true, |
| 4557 | "notes": "Its child teams move up to its parent, or to the top when it has none. The roles it gave on repositories are taken away, and it is no longer asked to review. Owners of the workspace and the team's maintainers (`403` otherwise)." |
| 4558 | }, |
| 4559 | "list_team_members": { |
| 4560 | "params": { |
| 4561 | "workspace": "flagon-io", |
| 4562 | "team": "backend" |
| 4563 | }, |
| 4564 | "query": { |
| 4565 | "include_child_teams": "true" |
| 4566 | }, |
| 4567 | "response": [ |
| 4568 | { |
| 4569 | "username": "syntaqx", |
| 4570 | "name": "Chase Pierce", |
| 4571 | "avatar": null, |
| 4572 | "role": "maintainer", |
| 4573 | "via": null |
| 4574 | }, |
| 4575 | { |
| 4576 | "username": "ana", |
| 4577 | "name": "Ana Lima", |
| 4578 | "avatar": null, |
| 4579 | "role": "member", |
| 4580 | "via": null |
| 4581 | }, |
| 4582 | { |
| 4583 | "username": "bo", |
| 4584 | "name": null, |
| 4585 | "avatar": null, |
| 4586 | "role": "member", |
| 4587 | "via": "payments" |
| 4588 | } |
| 4589 | ], |
| 4590 | "notes": "Maintainers come first, then members, each by username. With `include_child_teams`, the people of its child teams (and theirs) follow, each with `via`, the child team they are in; someone in both is listed once, as the team's own." |
| 4591 | }, |
| 4592 | "set_team_member": { |
| 4593 | "params": { |
| 4594 | "workspace": "flagon-io", |
| 4595 | "team": "backend", |
| 4596 | "username": "ana" |
| 4597 | }, |
| 4598 | "request": { |
| 4599 | "role": "maintainer" |
| 4600 | }, |
| 4601 | "response": { |
| 4602 | "username": "ana", |
| 4603 | "name": "Ana Lima", |
| 4604 | "avatar": null, |
| 4605 | "role": "maintainer", |
| 4606 | "via": null |
| 4607 | }, |
| 4608 | "notes": "`role` is `member` (the default) or `maintainer`. `422` when they are not a member of the workspace: add them to it first. Owners of the workspace and the team's maintainers (`403` otherwise)." |
| 4609 | }, |
| 4610 | "remove_team_member": { |
| 4611 | "params": { |
| 4612 | "workspace": "flagon-io", |
| 4613 | "team": "backend", |
| 4614 | "username": "ana" |
| 4615 | }, |
| 4616 | "response": true, |
| 4617 | "notes": "Anyone may take themselves out of a team. Leaving the workspace takes a person out of all its teams." |
| 4618 | }, |
| 4619 | "list_child_teams": { |
| 4620 | "params": { |
| 4621 | "workspace": "flagon-io", |
| 4622 | "team": "engineering" |
| 4623 | }, |
| 4624 | "response": [ |
| 4625 | { |
| 4626 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4627 | "workspace": "flagon-io", |
| 4628 | "slug": "backend", |
| 4629 | "name": "Backend", |
| 4630 | "description": "The API and the services behind it.", |
| 4631 | "visibility": "visible", |
| 4632 | "parent": { |
| 4633 | "slug": "engineering", |
| 4634 | "name": "Engineering" |
| 4635 | }, |
| 4636 | "notify": true, |
| 4637 | "review_assignment": { |
| 4638 | "enabled": false, |
| 4639 | "algorithm": "round_robin", |
| 4640 | "count": 1, |
| 4641 | "skip_busy": false, |
| 4642 | "busy_at": 5, |
| 4643 | "include_child_teams": false, |
| 4644 | "excluded": [], |
| 4645 | "notify_team": false |
| 4646 | }, |
| 4647 | "members_count": 4, |
| 4648 | "repos_count": 2, |
| 4649 | "child_teams_count": 0, |
| 4650 | "viewer_role": "maintainer", |
| 4651 | "can_manage": true, |
| 4652 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4653 | "updated_at": "2026-10-06T15:02:11.480Z" |
| 4654 | } |
| 4655 | ], |
| 4656 | "notes": "Only the teams directly under it; read each one's own with this again. A child team inherits its parent's roles on repositories, and a mention or review request for the parent reaches its people too." |
| 4657 | }, |
| 4658 | "list_team_repos": { |
| 4659 | "params": { |
| 4660 | "workspace": "flagon-io", |
| 4661 | "team": "backend" |
| 4662 | }, |
| 4663 | "response": [ |
| 4664 | { |
| 4665 | "repo": "flagon-io/hello", |
| 4666 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4667 | "role": "write", |
| 4668 | "inherited_from": null |
| 4669 | }, |
| 4670 | { |
| 4671 | "repo": "flagon-io/docs", |
| 4672 | "repo_id": "rep_01m3m5r2a8c4e6g8j0m2p4r6t8", |
| 4673 | "role": "read", |
| 4674 | "inherited_from": "engineering" |
| 4675 | } |
| 4676 | ], |
| 4677 | "notes": "A role inherited from a parent team names it in `inherited_from`. Where the team has a role of its own on the same repository, the higher one is listed. Only repositories you can see are listed." |
| 4678 | }, |
| 4679 | "set_team_repo": { |
| 4680 | "params": { |
| 4681 | "workspace": "flagon-io", |
| 4682 | "team": "backend", |
| 4683 | "repo": "hello" |
| 4684 | }, |
| 4685 | "request": { |
| 4686 | "role": "maintain" |
| 4687 | }, |
| 4688 | "response": { |
| 4689 | "repo": "flagon-io/hello", |
| 4690 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 4691 | "role": "maintain", |
| 4692 | "inherited_from": null |
| 4693 | }, |
| 4694 | "notes": "`repo` in the path is the repository's name in the team's workspace; a team has roles only on its own workspace's repositories. `role` is `read`, `triage`, `write`, `maintain` or `admin`. Everyone in the team and its child teams gets it; someone with a higher role otherwise keeps that. Needs the Admin role on the repository (`403` otherwise), and the `access:admin` scope. See [Access and roles](/guides/access-and-roles/)." |
| 4695 | }, |
| 4696 | "remove_team_repo": { |
| 4697 | "params": { |
| 4698 | "workspace": "flagon-io", |
| 4699 | "team": "backend", |
| 4700 | "repo": "hello" |
| 4701 | }, |
| 4702 | "response": true, |
| 4703 | "notes": "A role the team inherits from a parent is taken away on the parent. Needs the Admin role on the repository, or to be an owner or one of the team's maintainers." |
| 4704 | }, |
| 4705 | "set_team_review_assignment": { |
| 4706 | "params": { |
| 4707 | "workspace": "flagon-io", |
| 4708 | "team": "backend" |
| 4709 | }, |
| 4710 | "request": { |
| 4711 | "enabled": true, |
| 4712 | "algorithm": "load_balance", |
| 4713 | "count": 2, |
| 4714 | "skip_busy": true, |
| 4715 | "busy_at": 5, |
| 4716 | "excluded": [ |
| 4717 | "syntaqx" |
| 4718 | ] |
| 4719 | }, |
| 4720 | "response": { |
| 4721 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4722 | "workspace": "flagon-io", |
| 4723 | "slug": "backend", |
| 4724 | "name": "Backend", |
| 4725 | "description": "The API and the services behind it.", |
| 4726 | "visibility": "visible", |
| 4727 | "parent": { |
| 4728 | "slug": "engineering", |
| 4729 | "name": "Engineering" |
| 4730 | }, |
| 4731 | "notify": true, |
| 4732 | "review_assignment": { |
| 4733 | "enabled": true, |
| 4734 | "algorithm": "load_balance", |
| 4735 | "count": 2, |
| 4736 | "skip_busy": true, |
| 4737 | "busy_at": 5, |
| 4738 | "include_child_teams": false, |
| 4739 | "excluded": [ |
| 4740 | "syntaqx" |
| 4741 | ], |
| 4742 | "notify_team": false |
| 4743 | }, |
| 4744 | "members_count": 4, |
| 4745 | "repos_count": 2, |
| 4746 | "child_teams_count": 1, |
| 4747 | "viewer_role": "maintainer", |
| 4748 | "can_manage": true, |
| 4749 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4750 | "updated_at": "2026-10-07T09:44:03.512Z" |
| 4751 | }, |
| 4752 | "notes": "| Field | |\n| --- | --- |\n| `enabled` | Off, everyone in the team is asked. On, `count` people are picked and asked, and the team stays shown as asked beside them. |\n| `algorithm` | `round_robin`: whoever this team asked least recently. `load_balance`: whoever has the fewest pull requests waiting on their review. |\n| `count` | How many to pick, 1 to 10. People from the team already asked count towards it. |\n| `skip_busy`, `busy_at` | Leave out anyone with `busy_at` (1 to 100) or more pull requests waiting on their review. |\n| `include_child_teams` | Also pick from its child teams' people. |\n| `excluded` | Usernames never picked. Replaces the whole list. |\n| `notify_team` | Also tell the rest of the team when people are picked. |\n\nFields left out keep their value. The pull request's author is never picked. See [Teams](/guides/teams/)." |
| 4753 | }, |
| 4754 | "list_user_teams": { |
| 4755 | "params": { |
| 4756 | "workspace": "flagon-io", |
| 4757 | "username": "ana" |
| 4758 | }, |
| 4759 | "response": [ |
| 4760 | { |
| 4761 | "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g", |
| 4762 | "workspace": "flagon-io", |
| 4763 | "slug": "backend", |
| 4764 | "name": "Backend", |
| 4765 | "description": "The API and the services behind it.", |
| 4766 | "visibility": "visible", |
| 4767 | "parent": { |
| 4768 | "slug": "engineering", |
| 4769 | "name": "Engineering" |
| 4770 | }, |
| 4771 | "notify": true, |
| 4772 | "review_assignment": { |
| 4773 | "enabled": false, |
| 4774 | "algorithm": "round_robin", |
| 4775 | "count": 1, |
| 4776 | "skip_busy": false, |
| 4777 | "busy_at": 5, |
| 4778 | "include_child_teams": false, |
| 4779 | "excluded": [], |
| 4780 | "notify_team": false |
| 4781 | }, |
| 4782 | "members_count": 4, |
| 4783 | "repos_count": 2, |
| 4784 | "child_teams_count": 1, |
| 4785 | "viewer_role": null, |
| 4786 | "can_manage": false, |
| 4787 | "created_at": "2026-10-06T15:02:11.480Z", |
| 4788 | "updated_at": "2026-10-06T15:02:11.480Z" |
| 4789 | } |
| 4790 | ], |
| 4791 | "notes": "Only the teams they are in themselves, not the parents those teams are under. Secret teams you are not in are left out unless you are an owner. `403` for anyone who is not a member of the workspace." |
| 4792 | }, |
| 4793 | "list_security_alerts": { |
| 4794 | "params": { |
| 4795 | "owner": "flagon-io", |
| 4796 | "name": "hello" |
| 4797 | }, |
| 4798 | "query": { |
| 4799 | "state": "open" |
| 4800 | }, |
| 4801 | "response": [ |
| 4802 | { |
| 4803 | "kind": "secret", |
| 4804 | "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m", |
| 4805 | "state": "dismissed", |
| 4806 | "secret_type": "aws_access_key", |
| 4807 | "label": "an AWS access key", |
| 4808 | "path": "test/fixtures/aws.env", |
| 4809 | "line": 3, |
| 4810 | "commit": "9f2c1e04b7d3a8e6f5c2b1a0d9e8f7c6b5a4d3e2", |
| 4811 | "preview": "AKIA…MPLE", |
| 4812 | "status": "allowed", |
| 4813 | "source": "history", |
| 4814 | "test_value": "the documented example key", |
| 4815 | "found_by": null, |
| 4816 | "found_at": "2026-10-01T12:00:00.000Z", |
| 4817 | "dismissed_reason": "used_in_tests", |
| 4818 | "dismissed_comment": "Only in the test fixtures.", |
| 4819 | "dismissed_by": "syntaqx", |
| 4820 | "dismissed_at": "2026-10-02T09:15:00.000Z" |
| 4821 | }, |
| 4822 | { |
| 4823 | "kind": "dependency", |
| 4824 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 4825 | "state": "open", |
| 4826 | "ecosystem": "npm", |
| 4827 | "package": "lodash", |
| 4828 | "version": "4.17.20", |
| 4829 | "manifest": "package-lock.json", |
| 4830 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 4831 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 4832 | "summary": "Command Injection in lodash", |
| 4833 | "severity": "high", |
| 4834 | "fixed_version": "4.17.21", |
| 4835 | "fixed_at": null, |
| 4836 | "update": { |
| 4837 | "state": "open", |
| 4838 | "target": "4.17.21", |
| 4839 | "branch": "g1t/security/lodash-4.17.21", |
| 4840 | "pull": 42, |
| 4841 | "issue": null, |
| 4842 | "error": null, |
| 4843 | "updated_at": "2026-10-01T12:20:00.000Z" |
| 4844 | }, |
| 4845 | "found_at": "2026-10-01T12:00:00.000Z", |
| 4846 | "dismissed_reason": null, |
| 4847 | "dismissed_comment": null, |
| 4848 | "dismissed_by": null, |
| 4849 | "dismissed_at": null |
| 4850 | } |
| 4851 | ], |
| 4852 | "notes": "Secrets come first, then dependencies. Fields only one kind has are left out of the other: a secret has `secret_type`, `label`, `path`, `line`, `commit`, `preview`, `status` (`open`, `blocked`, `allowed` or `resolved`), `source` (`push` or `history`), `test_value` and `found_by`; a dependency has `ecosystem`, `package`, `version`, `manifest`, `advisory`, `osv_id`, `summary`, `severity`, `fixed_version` (null when no patched version is available), `fixed_at` and `update`, the pull request g1t opens to upgrade it. `dismissed_reason`, `dismissed_comment`, `dismissed_by` and `dismissed_at` are null while an alert is open; a secret fixed by being revoked keeps them. `422` for a `state` or `kind` it does not know, and `404` for anyone without the Write role. See [Security](/guides/security/)." |
| 4853 | }, |
| 4854 | "dismiss_security_alert": { |
| 4855 | "params": { |
| 4856 | "owner": "flagon-io", |
| 4857 | "name": "hello", |
| 4858 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n" |
| 4859 | }, |
| 4860 | "request": { |
| 4861 | "reason": "tolerable_risk", |
| 4862 | "comment": "Only the build uses it, on trusted input." |
| 4863 | }, |
| 4864 | "response": { |
| 4865 | "kind": "dependency", |
| 4866 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 4867 | "state": "dismissed", |
| 4868 | "ecosystem": "npm", |
| 4869 | "package": "lodash", |
| 4870 | "version": "4.17.20", |
| 4871 | "manifest": "package-lock.json", |
| 4872 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 4873 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 4874 | "summary": "Command Injection in lodash", |
| 4875 | "severity": "high", |
| 4876 | "fixed_version": "4.17.21", |
| 4877 | "fixed_at": null, |
| 4878 | "update": { |
| 4879 | "state": "open", |
| 4880 | "target": "4.17.21", |
| 4881 | "branch": "g1t/security/lodash-4.17.21", |
| 4882 | "pull": 42, |
| 4883 | "issue": null, |
| 4884 | "error": null, |
| 4885 | "updated_at": "2026-10-01T12:20:00.000Z" |
| 4886 | }, |
| 4887 | "found_at": "2026-10-01T12:00:00.000Z", |
| 4888 | "dismissed_reason": "tolerable_risk", |
| 4889 | "dismissed_comment": "Only the build uses it, on trusted input.", |
| 4890 | "dismissed_by": "syntaqx", |
| 4891 | "dismissed_at": "2026-10-06T10:00:00.000Z" |
| 4892 | }, |
| 4893 | "notes": "| Kind | Reasons |\n| --- | --- |\n| `secret` | `false_positive`, `used_in_tests`, `revoked`, `wont_fix` |\n| `dependency` | `fix_started`, `no_bandwidth`, `tolerable_risk`, `inaccurate`, `not_used` |\n\nA reason for the other kind of alert, or one not in the table, is refused with `422`. A secret dismissed as `revoked` becomes `fixed`; with any other reason it becomes `dismissed` and pushes that carry it go through. Dismissing a secret needs the Admin role on the repository; a dependency needs the Write role. A token needs `repo:admin` for either, and a g1t agent’s token never dismisses alerts." |
| 4894 | }, |
| 4895 | "reopen_security_alert": { |
| 4896 | "params": { |
| 4897 | "owner": "flagon-io", |
| 4898 | "name": "hello", |
| 4899 | "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m" |
| 4900 | }, |
| 4901 | "response": { |
| 4902 | "kind": "secret", |
| 4903 | "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m", |
| 4904 | "state": "open", |
| 4905 | "secret_type": "aws_access_key", |
| 4906 | "label": "an AWS access key", |
| 4907 | "path": "test/fixtures/aws.env", |
| 4908 | "line": 3, |
| 4909 | "commit": "9f2c1e04b7d3a8e6f5c2b1a0d9e8f7c6b5a4d3e2", |
| 4910 | "preview": "AKIA…MPLE", |
| 4911 | "status": "open", |
| 4912 | "source": "history", |
| 4913 | "test_value": "the documented example key", |
| 4914 | "found_by": null, |
| 4915 | "found_at": "2026-10-01T12:00:00.000Z", |
| 4916 | "dismissed_reason": null, |
| 4917 | "dismissed_comment": null, |
| 4918 | "dismissed_by": null, |
| 4919 | "dismissed_at": null |
| 4920 | }, |
| 4921 | "notes": "The alert is `open` again, and a reopened secret stops pushes that carry it. The same roles as dismissing: Admin for a secret, Write for a dependency." |
| 4922 | }, |
| 4923 | "list_notifications": { |
| 4924 | "query": { |
| 4925 | "participating": "true" |
| 4926 | }, |
| 4927 | "response": { |
| 4928 | "items": [ |
| 4929 | { |
| 4930 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 4931 | "reason": "review_requested", |
| 4932 | "severity": "warning", |
| 4933 | "title": "ada asked you to review flagon-io/hello#14", |
| 4934 | "body": "Add a greeting to the README", |
| 4935 | "event": "pull.review_requested", |
| 4936 | "repo": "flagon-io/hello", |
| 4937 | "workspace": "flagon-io", |
| 4938 | "subject": "pull", |
| 4939 | "number": 14, |
| 4940 | "url": "/flagon-io/hello/pull/14", |
| 4941 | "actor": "ada", |
| 4942 | "count": 3, |
| 4943 | "created_at": "2026-10-06T15:02:11.000Z", |
| 4944 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 4945 | "read_at": null, |
| 4946 | "done_at": null, |
| 4947 | "saved": false, |
| 4948 | "snoozed_until": null |
| 4949 | }, |
| 4950 | { |
| 4951 | "id": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k", |
| 4952 | "reason": "ci_activity", |
| 4953 | "severity": "error", |
| 4954 | "title": "Production of hello failed to deploy", |
| 4955 | "body": "The build failed: npm run build exited with 1.", |
| 4956 | "event": "deployment.failed", |
| 4957 | "repo": "flagon-io/hello", |
| 4958 | "workspace": "flagon-io", |
| 4959 | "subject": "deploy", |
| 4960 | "number": null, |
| 4961 | "url": "/flagon-io/hello/deployments/dpl_01kp7k8z7y6x5w4v3t2s1r0q9p", |
| 4962 | "actor": "syntaqx", |
| 4963 | "count": 1, |
| 4964 | "created_at": "2026-10-07T08:12:40.000Z", |
| 4965 | "updated_at": "2026-10-07T08:12:40.000Z", |
| 4966 | "read_at": null, |
| 4967 | "done_at": null, |
| 4968 | "saved": false, |
| 4969 | "snoozed_until": null |
| 4970 | } |
| 4971 | ], |
| 4972 | "next": null |
| 4973 | }, |
| 4974 | "notes": "Unread threads only, unless `all=true`. Threads that wait on you (an agent, or a review asked of you) have severity `warning`.\n\n| `reason` | You were told because |\n| --- | --- |\n| `agent` | An agent is waiting on you: it asked a question, or g1t stopped until a person steps in |\n| `review_requested` | You were asked to review |\n| `assign` | You were assigned |\n| `mention` | Someone mentioned you by `@username` |\n| `ci_activity` | Checks, a workflow or a deployment on your work finished |\n| `security_alert` | A security alert on a repository you look after |\n| `state_change` | It was closed, reopened or merged |\n| `author` | You opened it, or asked g1t for it |\n| `comment` | You commented on it |\n| `manual` | You subscribed to it by hand |\n| `subscribed` | You watch its repository |\n\nWith `participating=true`, threads you only follow (`manual`, `subscribed`) are left out. For the next page, pass `next` as `cursor`; `next` is null on the last." |
| 4975 | }, |
| 4976 | "list_repo_notifications": { |
| 4977 | "params": { |
| 4978 | "owner": "flagon-io", |
| 4979 | "name": "hello" |
| 4980 | }, |
| 4981 | "query": { |
| 4982 | "all": "true" |
| 4983 | }, |
| 4984 | "response": { |
| 4985 | "items": [ |
| 4986 | { |
| 4987 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 4988 | "reason": "review_requested", |
| 4989 | "severity": "warning", |
| 4990 | "title": "ada asked you to review flagon-io/hello#14", |
| 4991 | "body": "Add a greeting to the README", |
| 4992 | "event": "pull.review_requested", |
| 4993 | "repo": "flagon-io/hello", |
| 4994 | "workspace": "flagon-io", |
| 4995 | "subject": "pull", |
| 4996 | "number": 14, |
| 4997 | "url": "/flagon-io/hello/pull/14", |
| 4998 | "actor": "ada", |
| 4999 | "count": 3, |
| 5000 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5001 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5002 | "read_at": "2026-10-07T09:50:00.000Z", |
| 5003 | "done_at": null, |
| 5004 | "saved": false, |
| 5005 | "snoozed_until": null |
| 5006 | }, |
| 5007 | { |
| 5008 | "id": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k", |
| 5009 | "reason": "ci_activity", |
| 5010 | "severity": "error", |
| 5011 | "title": "Production of hello failed to deploy", |
| 5012 | "body": "The build failed: npm run build exited with 1.", |
| 5013 | "event": "deployment.failed", |
| 5014 | "repo": "flagon-io/hello", |
| 5015 | "workspace": "flagon-io", |
| 5016 | "subject": "deploy", |
| 5017 | "number": null, |
| 5018 | "url": "/flagon-io/hello/deployments/dpl_01kp7k8z7y6x5w4v3t2s1r0q9p", |
| 5019 | "actor": "syntaqx", |
| 5020 | "count": 1, |
| 5021 | "created_at": "2026-10-07T08:12:40.000Z", |
| 5022 | "updated_at": "2026-10-07T08:12:40.000Z", |
| 5023 | "read_at": null, |
| 5024 | "done_at": null, |
| 5025 | "saved": false, |
| 5026 | "snoozed_until": null |
| 5027 | } |
| 5028 | ], |
| 5029 | "next": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k" |
| 5030 | }, |
| 5031 | "notes": "The same as `GET /notifications`, for one repository you can read." |
| 5032 | }, |
| 5033 | "mark_notifications_read": { |
| 5034 | "request": { |
| 5035 | "last_read_at": "2026-10-07T10:00:00Z" |
| 5036 | }, |
| 5037 | "response": { |
| 5038 | "marked": 12, |
| 5039 | "last_read_at": "2026-10-07T10:00:00.000Z" |
| 5040 | }, |
| 5041 | "notes": "Threads with activity after `last_read_at` stay unread, so send the time you last listed them." |
| 5042 | }, |
| 5043 | "mark_repo_notifications_read": { |
| 5044 | "params": { |
| 5045 | "owner": "flagon-io", |
| 5046 | "name": "hello" |
| 5047 | }, |
| 5048 | "request": {}, |
| 5049 | "response": { |
| 5050 | "marked": 3, |
| 5051 | "last_read_at": "2026-10-07T10:02:41.512Z" |
| 5052 | } |
| 5053 | }, |
| 5054 | "get_notification_thread": { |
| 5055 | "params": { |
| 5056 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5057 | }, |
| 5058 | "response": { |
| 5059 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5060 | "reason": "review_requested", |
| 5061 | "severity": "warning", |
| 5062 | "title": "ada asked you to review flagon-io/hello#14", |
| 5063 | "body": "Add a greeting to the README", |
| 5064 | "event": "pull.review_requested", |
| 5065 | "repo": "flagon-io/hello", |
| 5066 | "workspace": "flagon-io", |
| 5067 | "subject": "pull", |
| 5068 | "number": 14, |
| 5069 | "url": "/flagon-io/hello/pull/14", |
| 5070 | "actor": "ada", |
| 5071 | "count": 3, |
| 5072 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5073 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5074 | "read_at": null, |
| 5075 | "done_at": null, |
| 5076 | "saved": false, |
| 5077 | "snoozed_until": null, |
| 5078 | "activity": [ |
| 5079 | { |
| 5080 | "reason": "review_requested", |
| 5081 | "severity": "warning", |
| 5082 | "title": "ada asked you to review flagon-io/hello#14", |
| 5083 | "body": "Add a greeting to the README", |
| 5084 | "event": "pull.review_requested", |
| 5085 | "actor": "ada", |
| 5086 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5087 | }, |
| 5088 | { |
| 5089 | "reason": "comment", |
| 5090 | "severity": "info", |
| 5091 | "title": "ada commented on flagon-io/hello#14", |
| 5092 | "body": "Pushed the fix for the heading.", |
| 5093 | "event": "comment.created", |
| 5094 | "actor": "ada", |
| 5095 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5096 | }, |
| 5097 | { |
| 5098 | "reason": "comment", |
| 5099 | "severity": "info", |
| 5100 | "title": "g1t commented on flagon-io/hello#14", |
| 5101 | "body": "The heading level is off by one.", |
| 5102 | "event": "comment.created", |
| 5103 | "actor": "g1t", |
| 5104 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5105 | } |
| 5106 | ], |
| 5107 | "subscription": { |
| 5108 | "subscribed": true, |
| 5109 | "ignored": false, |
| 5110 | "reason": "review_requested", |
| 5111 | "repo": "flagon-io/hello", |
| 5112 | "number": 14, |
| 5113 | "updated_at": null |
| 5114 | } |
| 5115 | }, |
| 5116 | "notes": "`activity` keeps the last 10 things that happened on the thread, newest first; `count` is how many there have been. `subscription` is null for a workflow or a deployment, which nobody subscribes to." |
| 5117 | }, |
| 5118 | "mark_thread_read": { |
| 5119 | "params": { |
| 5120 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5121 | }, |
| 5122 | "request": {}, |
| 5123 | "response": { |
| 5124 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5125 | "reason": "review_requested", |
| 5126 | "severity": "warning", |
| 5127 | "title": "ada asked you to review flagon-io/hello#14", |
| 5128 | "body": "Add a greeting to the README", |
| 5129 | "event": "pull.review_requested", |
| 5130 | "repo": "flagon-io/hello", |
| 5131 | "workspace": "flagon-io", |
| 5132 | "subject": "pull", |
| 5133 | "number": 14, |
| 5134 | "url": "/flagon-io/hello/pull/14", |
| 5135 | "actor": "ada", |
| 5136 | "count": 3, |
| 5137 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5138 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5139 | "read_at": "2026-10-07T10:03:00.000Z", |
| 5140 | "done_at": null, |
| 5141 | "saved": false, |
| 5142 | "snoozed_until": null, |
| 5143 | "activity": [ |
| 5144 | { |
| 5145 | "reason": "review_requested", |
| 5146 | "severity": "warning", |
| 5147 | "title": "ada asked you to review flagon-io/hello#14", |
| 5148 | "body": "Add a greeting to the README", |
| 5149 | "event": "pull.review_requested", |
| 5150 | "actor": "ada", |
| 5151 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5152 | }, |
| 5153 | { |
| 5154 | "reason": "comment", |
| 5155 | "severity": "info", |
| 5156 | "title": "ada commented on flagon-io/hello#14", |
| 5157 | "body": "Pushed the fix for the heading.", |
| 5158 | "event": "comment.created", |
| 5159 | "actor": "ada", |
| 5160 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5161 | }, |
| 5162 | { |
| 5163 | "reason": "comment", |
| 5164 | "severity": "info", |
| 5165 | "title": "g1t commented on flagon-io/hello#14", |
| 5166 | "body": "The heading level is off by one.", |
| 5167 | "event": "comment.created", |
| 5168 | "actor": "g1t", |
| 5169 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5170 | } |
| 5171 | ], |
| 5172 | "subscription": { |
| 5173 | "subscribed": true, |
| 5174 | "ignored": false, |
| 5175 | "reason": "review_requested", |
| 5176 | "repo": "flagon-io/hello", |
| 5177 | "number": 14, |
| 5178 | "updated_at": null |
| 5179 | } |
| 5180 | } |
| 5181 | }, |
| 5182 | "mark_thread_done": { |
| 5183 | "params": { |
| 5184 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5185 | }, |
| 5186 | "response": { |
| 5187 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5188 | "reason": "review_requested", |
| 5189 | "severity": "warning", |
| 5190 | "title": "ada asked you to review flagon-io/hello#14", |
| 5191 | "body": "Add a greeting to the README", |
| 5192 | "event": "pull.review_requested", |
| 5193 | "repo": "flagon-io/hello", |
| 5194 | "workspace": "flagon-io", |
| 5195 | "subject": "pull", |
| 5196 | "number": 14, |
| 5197 | "url": "/flagon-io/hello/pull/14", |
| 5198 | "actor": "ada", |
| 5199 | "count": 3, |
| 5200 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5201 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5202 | "read_at": "2026-10-07T10:03:00.000Z", |
| 5203 | "done_at": "2026-10-07T10:03:00.000Z", |
| 5204 | "saved": false, |
| 5205 | "snoozed_until": null, |
| 5206 | "activity": [ |
| 5207 | { |
| 5208 | "reason": "review_requested", |
| 5209 | "severity": "warning", |
| 5210 | "title": "ada asked you to review flagon-io/hello#14", |
| 5211 | "body": "Add a greeting to the README", |
| 5212 | "event": "pull.review_requested", |
| 5213 | "actor": "ada", |
| 5214 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5215 | }, |
| 5216 | { |
| 5217 | "reason": "comment", |
| 5218 | "severity": "info", |
| 5219 | "title": "ada commented on flagon-io/hello#14", |
| 5220 | "body": "Pushed the fix for the heading.", |
| 5221 | "event": "comment.created", |
| 5222 | "actor": "ada", |
| 5223 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5224 | }, |
| 5225 | { |
| 5226 | "reason": "comment", |
| 5227 | "severity": "info", |
| 5228 | "title": "g1t commented on flagon-io/hello#14", |
| 5229 | "body": "The heading level is off by one.", |
| 5230 | "event": "comment.created", |
| 5231 | "actor": "g1t", |
| 5232 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5233 | } |
| 5234 | ], |
| 5235 | "subscription": { |
| 5236 | "subscribed": true, |
| 5237 | "ignored": false, |
| 5238 | "reason": "review_requested", |
| 5239 | "repo": "flagon-io/hello", |
| 5240 | "number": 14, |
| 5241 | "updated_at": null |
| 5242 | } |
| 5243 | }, |
| 5244 | "notes": "New activity on a done thread brings it back to the inbox, unread." |
| 5245 | }, |
| 5246 | "save_thread": { |
| 5247 | "params": { |
| 5248 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5249 | }, |
| 5250 | "request": {}, |
| 5251 | "response": { |
| 5252 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5253 | "reason": "review_requested", |
| 5254 | "severity": "warning", |
| 5255 | "title": "ada asked you to review flagon-io/hello#14", |
| 5256 | "body": "Add a greeting to the README", |
| 5257 | "event": "pull.review_requested", |
| 5258 | "repo": "flagon-io/hello", |
| 5259 | "workspace": "flagon-io", |
| 5260 | "subject": "pull", |
| 5261 | "number": 14, |
| 5262 | "url": "/flagon-io/hello/pull/14", |
| 5263 | "actor": "ada", |
| 5264 | "count": 3, |
| 5265 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5266 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5267 | "read_at": null, |
| 5268 | "done_at": null, |
| 5269 | "saved": true, |
| 5270 | "snoozed_until": null, |
| 5271 | "activity": [ |
| 5272 | { |
| 5273 | "reason": "review_requested", |
| 5274 | "severity": "warning", |
| 5275 | "title": "ada asked you to review flagon-io/hello#14", |
| 5276 | "body": "Add a greeting to the README", |
| 5277 | "event": "pull.review_requested", |
| 5278 | "actor": "ada", |
| 5279 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5280 | }, |
| 5281 | { |
| 5282 | "reason": "comment", |
| 5283 | "severity": "info", |
| 5284 | "title": "ada commented on flagon-io/hello#14", |
| 5285 | "body": "Pushed the fix for the heading.", |
| 5286 | "event": "comment.created", |
| 5287 | "actor": "ada", |
| 5288 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5289 | }, |
| 5290 | { |
| 5291 | "reason": "comment", |
| 5292 | "severity": "info", |
| 5293 | "title": "g1t commented on flagon-io/hello#14", |
| 5294 | "body": "The heading level is off by one.", |
| 5295 | "event": "comment.created", |
| 5296 | "actor": "g1t", |
| 5297 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5298 | } |
| 5299 | ], |
| 5300 | "subscription": { |
| 5301 | "subscribed": true, |
| 5302 | "ignored": false, |
| 5303 | "reason": "review_requested", |
| 5304 | "repo": "flagon-io/hello", |
| 5305 | "number": 14, |
| 5306 | "updated_at": null |
| 5307 | } |
| 5308 | } |
| 5309 | }, |
| 5310 | "unsave_thread": { |
| 5311 | "params": { |
| 5312 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5313 | }, |
| 5314 | "response": { |
| 5315 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5316 | "reason": "review_requested", |
| 5317 | "severity": "warning", |
| 5318 | "title": "ada asked you to review flagon-io/hello#14", |
| 5319 | "body": "Add a greeting to the README", |
| 5320 | "event": "pull.review_requested", |
| 5321 | "repo": "flagon-io/hello", |
| 5322 | "workspace": "flagon-io", |
| 5323 | "subject": "pull", |
| 5324 | "number": 14, |
| 5325 | "url": "/flagon-io/hello/pull/14", |
| 5326 | "actor": "ada", |
| 5327 | "count": 3, |
| 5328 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5329 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5330 | "read_at": null, |
| 5331 | "done_at": null, |
| 5332 | "saved": false, |
| 5333 | "snoozed_until": null, |
| 5334 | "activity": [ |
| 5335 | { |
| 5336 | "reason": "review_requested", |
| 5337 | "severity": "warning", |
| 5338 | "title": "ada asked you to review flagon-io/hello#14", |
| 5339 | "body": "Add a greeting to the README", |
| 5340 | "event": "pull.review_requested", |
| 5341 | "actor": "ada", |
| 5342 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5343 | }, |
| 5344 | { |
| 5345 | "reason": "comment", |
| 5346 | "severity": "info", |
| 5347 | "title": "ada commented on flagon-io/hello#14", |
| 5348 | "body": "Pushed the fix for the heading.", |
| 5349 | "event": "comment.created", |
| 5350 | "actor": "ada", |
| 5351 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5352 | }, |
| 5353 | { |
| 5354 | "reason": "comment", |
| 5355 | "severity": "info", |
| 5356 | "title": "g1t commented on flagon-io/hello#14", |
| 5357 | "body": "The heading level is off by one.", |
| 5358 | "event": "comment.created", |
| 5359 | "actor": "g1t", |
| 5360 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5361 | } |
| 5362 | ], |
| 5363 | "subscription": { |
| 5364 | "subscribed": true, |
| 5365 | "ignored": false, |
| 5366 | "reason": "review_requested", |
| 5367 | "repo": "flagon-io/hello", |
| 5368 | "number": 14, |
| 5369 | "updated_at": null |
| 5370 | } |
| 5371 | } |
| 5372 | }, |
| 5373 | "snooze_thread": { |
| 5374 | "params": { |
| 5375 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5376 | }, |
| 5377 | "request": { |
| 5378 | "until": "2026-10-08T09:00:00Z" |
| 5379 | }, |
| 5380 | "response": { |
| 5381 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5382 | "reason": "review_requested", |
| 5383 | "severity": "warning", |
| 5384 | "title": "ada asked you to review flagon-io/hello#14", |
| 5385 | "body": "Add a greeting to the README", |
| 5386 | "event": "pull.review_requested", |
| 5387 | "repo": "flagon-io/hello", |
| 5388 | "workspace": "flagon-io", |
| 5389 | "subject": "pull", |
| 5390 | "number": 14, |
| 5391 | "url": "/flagon-io/hello/pull/14", |
| 5392 | "actor": "ada", |
| 5393 | "count": 3, |
| 5394 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5395 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5396 | "read_at": "2026-10-07T10:03:00.000Z", |
| 5397 | "done_at": null, |
| 5398 | "saved": false, |
| 5399 | "snoozed_until": "2026-10-08T09:00:00.000Z", |
| 5400 | "activity": [ |
| 5401 | { |
| 5402 | "reason": "review_requested", |
| 5403 | "severity": "warning", |
| 5404 | "title": "ada asked you to review flagon-io/hello#14", |
| 5405 | "body": "Add a greeting to the README", |
| 5406 | "event": "pull.review_requested", |
| 5407 | "actor": "ada", |
| 5408 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5409 | }, |
| 5410 | { |
| 5411 | "reason": "comment", |
| 5412 | "severity": "info", |
| 5413 | "title": "ada commented on flagon-io/hello#14", |
| 5414 | "body": "Pushed the fix for the heading.", |
| 5415 | "event": "comment.created", |
| 5416 | "actor": "ada", |
| 5417 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5418 | }, |
| 5419 | { |
| 5420 | "reason": "comment", |
| 5421 | "severity": "info", |
| 5422 | "title": "g1t commented on flagon-io/hello#14", |
| 5423 | "body": "The heading level is off by one.", |
| 5424 | "event": "comment.created", |
| 5425 | "actor": "g1t", |
| 5426 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5427 | } |
| 5428 | ], |
| 5429 | "subscription": { |
| 5430 | "subscribed": true, |
| 5431 | "ignored": false, |
| 5432 | "reason": "review_requested", |
| 5433 | "repo": "flagon-io/hello", |
| 5434 | "number": 14, |
| 5435 | "updated_at": null |
| 5436 | } |
| 5437 | } |
| 5438 | }, |
| 5439 | "unsnooze_thread": { |
| 5440 | "params": { |
| 5441 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5442 | }, |
| 5443 | "response": { |
| 5444 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a", |
| 5445 | "reason": "review_requested", |
| 5446 | "severity": "warning", |
| 5447 | "title": "ada asked you to review flagon-io/hello#14", |
| 5448 | "body": "Add a greeting to the README", |
| 5449 | "event": "pull.review_requested", |
| 5450 | "repo": "flagon-io/hello", |
| 5451 | "workspace": "flagon-io", |
| 5452 | "subject": "pull", |
| 5453 | "number": 14, |
| 5454 | "url": "/flagon-io/hello/pull/14", |
| 5455 | "actor": "ada", |
| 5456 | "count": 3, |
| 5457 | "created_at": "2026-10-06T15:02:11.000Z", |
| 5458 | "updated_at": "2026-10-07T09:41:30.000Z", |
| 5459 | "read_at": "2026-10-07T10:03:00.000Z", |
| 5460 | "done_at": null, |
| 5461 | "saved": false, |
| 5462 | "snoozed_until": null, |
| 5463 | "activity": [ |
| 5464 | { |
| 5465 | "reason": "review_requested", |
| 5466 | "severity": "warning", |
| 5467 | "title": "ada asked you to review flagon-io/hello#14", |
| 5468 | "body": "Add a greeting to the README", |
| 5469 | "event": "pull.review_requested", |
| 5470 | "actor": "ada", |
| 5471 | "created_at": "2026-10-07T09:41:30.000Z" |
| 5472 | }, |
| 5473 | { |
| 5474 | "reason": "comment", |
| 5475 | "severity": "info", |
| 5476 | "title": "ada commented on flagon-io/hello#14", |
| 5477 | "body": "Pushed the fix for the heading.", |
| 5478 | "event": "comment.created", |
| 5479 | "actor": "ada", |
| 5480 | "created_at": "2026-10-06T18:20:02.000Z" |
| 5481 | }, |
| 5482 | { |
| 5483 | "reason": "comment", |
| 5484 | "severity": "info", |
| 5485 | "title": "g1t commented on flagon-io/hello#14", |
| 5486 | "body": "The heading level is off by one.", |
| 5487 | "event": "comment.created", |
| 5488 | "actor": "g1t", |
| 5489 | "created_at": "2026-10-06T15:02:11.000Z" |
| 5490 | } |
| 5491 | ], |
| 5492 | "subscription": { |
| 5493 | "subscribed": true, |
| 5494 | "ignored": false, |
| 5495 | "reason": "review_requested", |
| 5496 | "repo": "flagon-io/hello", |
| 5497 | "number": 14, |
| 5498 | "updated_at": null |
| 5499 | } |
| 5500 | } |
| 5501 | }, |
| 5502 | "get_thread_subscription": { |
| 5503 | "params": { |
| 5504 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5505 | }, |
| 5506 | "response": { |
| 5507 | "subscribed": true, |
| 5508 | "ignored": false, |
| 5509 | "reason": "review_requested", |
| 5510 | "repo": "flagon-io/hello", |
| 5511 | "number": 14, |
| 5512 | "updated_at": null |
| 5513 | } |
| 5514 | }, |
| 5515 | "set_thread_subscription": { |
| 5516 | "params": { |
| 5517 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5518 | }, |
| 5519 | "request": { |
| 5520 | "ignored": true |
| 5521 | }, |
| 5522 | "response": { |
| 5523 | "subscribed": false, |
| 5524 | "ignored": true, |
| 5525 | "reason": null, |
| 5526 | "repo": "flagon-io/hello", |
| 5527 | "number": 14, |
| 5528 | "updated_at": "2026-10-07T10:04:00.000Z" |
| 5529 | }, |
| 5530 | "notes": "| Body | Then |\n| --- | --- |\n| `{}` or `{\"subscribed\": true}` | You hear of what happens on it |\n| `{\"subscribed\": false}` | You hear only of what is asked of you |\n| `{\"ignored\": true}` | You hear of nothing on it, not even a mention |" |
| 5531 | }, |
| 5532 | "delete_thread_subscription": { |
| 5533 | "params": { |
| 5534 | "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a" |
| 5535 | }, |
| 5536 | "response": { |
| 5537 | "subscribed": false, |
| 5538 | "ignored": false, |
| 5539 | "reason": null, |
| 5540 | "repo": "flagon-io/hello", |
| 5541 | "number": 14, |
| 5542 | "updated_at": "2026-10-07T10:04:00.000Z" |
| 5543 | } |
| 5544 | }, |
| 5545 | "get_issue_subscription": { |
| 5546 | "params": { |
| 5547 | "owner": "flagon-io", |
| 5548 | "name": "hello", |
| 5549 | "number": 14 |
| 5550 | }, |
| 5551 | "response": { |
| 5552 | "subscribed": true, |
| 5553 | "ignored": false, |
| 5554 | "reason": "author", |
| 5555 | "repo": null, |
| 5556 | "number": 14, |
| 5557 | "updated_at": null |
| 5558 | } |
| 5559 | }, |
| 5560 | "set_issue_subscription": { |
| 5561 | "params": { |
| 5562 | "owner": "flagon-io", |
| 5563 | "name": "hello", |
| 5564 | "number": 14 |
| 5565 | }, |
| 5566 | "request": { |
| 5567 | "subscribed": true |
| 5568 | }, |
| 5569 | "response": { |
| 5570 | "subscribed": true, |
| 5571 | "ignored": false, |
| 5572 | "reason": "manual", |
| 5573 | "repo": null, |
| 5574 | "number": 14, |
| 5575 | "updated_at": "2026-10-07T10:05:00.000Z" |
| 5576 | } |
| 5577 | }, |
| 5578 | "delete_issue_subscription": { |
| 5579 | "params": { |
| 5580 | "owner": "flagon-io", |
| 5581 | "name": "hello", |
| 5582 | "number": 14 |
| 5583 | }, |
| 5584 | "response": { |
| 5585 | "subscribed": false, |
| 5586 | "ignored": false, |
| 5587 | "reason": null, |
| 5588 | "repo": null, |
| 5589 | "number": 14, |
| 5590 | "updated_at": "2026-10-07T10:05:30.000Z" |
| 5591 | } |
| 5592 | }, |
| 5593 | "get_repo_subscription": { |
| 5594 | "params": { |
| 5595 | "owner": "flagon-io", |
| 5596 | "name": "hello" |
| 5597 | }, |
| 5598 | "response": { |
| 5599 | "repo": "flagon-io/hello", |
| 5600 | "level": "participating", |
| 5601 | "events": [], |
| 5602 | "subscribed": false, |
| 5603 | "ignored": false, |
| 5604 | "updated_at": null |
| 5605 | } |
| 5606 | }, |
| 5607 | "set_repo_subscription": { |
| 5608 | "params": { |
| 5609 | "owner": "flagon-io", |
| 5610 | "name": "hello" |
| 5611 | }, |
| 5612 | "request": { |
| 5613 | "level": "custom", |
| 5614 | "events": [ |
| 5615 | "pulls", |
| 5616 | "deployments" |
| 5617 | ] |
| 5618 | }, |
| 5619 | "response": { |
| 5620 | "repo": "flagon-io/hello", |
| 5621 | "level": "custom", |
| 5622 | "events": [ |
| 5623 | "pulls", |
| 5624 | "deployments" |
| 5625 | ], |
| 5626 | "subscribed": true, |
| 5627 | "ignored": false, |
| 5628 | "updated_at": "2026-10-07T10:06:00.000Z" |
| 5629 | }, |
| 5630 | "notes": "| `level` | You hear of |\n| --- | --- |\n| `participating` | What you take part in, or are mentioned in (the default) |\n| `all` | Every issue and pull request opened, commented on, closed or merged, and every deployment |\n| `custom` | What you take part in, and the kinds in `events`: `issues`, `pulls`, `deployments`, `security` |\n| `ignore` | Nothing, not even a mention |\n\nInstead of `level`, `{\"subscribed\": true}` is `all`, `{\"subscribed\": false}` is `participating` and `{\"ignored\": true}` is `ignore`." |
| 5631 | }, |
| 5632 | "delete_repo_subscription": { |
| 5633 | "params": { |
| 5634 | "owner": "flagon-io", |
| 5635 | "name": "hello" |
| 5636 | }, |
| 5637 | "response": { |
| 5638 | "repo": "flagon-io/hello", |
| 5639 | "level": "participating", |
| 5640 | "events": [], |
| 5641 | "subscribed": false, |
| 5642 | "ignored": false, |
| 5643 | "updated_at": null |
| 5644 | } |
| 5645 | }, |
| 5646 | "list_watched_repos": { |
| 5647 | "response": [ |
| 5648 | { |
| 5649 | "repo": "flagon-io/hello", |
| 5650 | "level": "all", |
| 5651 | "events": [], |
| 5652 | "subscribed": true, |
| 5653 | "ignored": false, |
| 5654 | "updated_at": "2026-10-07T10:00:00.000Z" |
| 5655 | }, |
| 5656 | { |
| 5657 | "repo": "flagon-io/docs", |
| 5658 | "level": "ignore", |
| 5659 | "events": [], |
| 5660 | "subscribed": false, |
| 5661 | "ignored": true, |
| 5662 | "updated_at": "2026-10-05T14:30:00.000Z" |
| 5663 | } |
| 5664 | ] |
| 5665 | }, |
| 5666 | "get_usage": { |
| 5667 | "params": { |
| 5668 | "workspace": "flagon-io" |
| 5669 | }, |
| 5670 | "query": { |
| 5671 | "from": "2026-10-01", |
| 5672 | "until": "2026-10-07", |
| 5673 | "group_by": "project" |
| 5674 | }, |
| 5675 | "response": { |
| 5676 | "from": "2026-10-01", |
| 5677 | "until": "2026-10-07", |
| 5678 | "totals": { |
| 5679 | "price_micros": 48210000, |
| 5680 | "discount_micros": 0, |
| 5681 | "included_micros": 20000000, |
| 5682 | "credits_micros": 18000000, |
| 5683 | "charged_micros": 10210000, |
| 5684 | "pending_micros": 1340000, |
| 5685 | "cost_micros": 40100000 |
| 5686 | }, |
| 5687 | "days": [ |
| 5688 | { |
| 5689 | "day": "2026-10-06", |
| 5690 | "product": "agent", |
| 5691 | "micros": 12400000 |
| 5692 | }, |
| 5693 | { |
| 5694 | "day": "2026-10-06", |
| 5695 | "product": "sandboxes", |
| 5696 | "micros": 2100000 |
| 5697 | }, |
| 5698 | { |
| 5699 | "day": "2026-10-07", |
| 5700 | "product": "agent", |
| 5701 | "micros": 9800000 |
| 5702 | } |
| 5703 | ], |
| 5704 | "products": [ |
| 5705 | { |
| 5706 | "key": "agent", |
| 5707 | "label": "Agent", |
| 5708 | "micros": 41000000, |
| 5709 | "meters": [ |
| 5710 | { |
| 5711 | "key": "agent_models", |
| 5712 | "label": "Models", |
| 5713 | "product": "agent", |
| 5714 | "unit": "tokens", |
| 5715 | "quantity": 9120000, |
| 5716 | "micros": 41000000, |
| 5717 | "pending_micros": 0, |
| 5718 | "daily": [ |
| 5719 | 3100000, |
| 5720 | 5200000, |
| 5721 | 4400000, |
| 5722 | 6000000, |
| 5723 | 0, |
| 5724 | 12400000, |
| 5725 | 9800000 |
| 5726 | ], |
| 5727 | "allowance": null, |
| 5728 | "by_project": [ |
| 5729 | { |
| 5730 | "project": "flagon-io/g1t", |
| 5731 | "micros": 36000000, |
| 5732 | "quantity": 8010000 |
| 5733 | }, |
| 5734 | { |
| 5735 | "project": "flagon-io/hello", |
| 5736 | "micros": 5000000, |
| 5737 | "quantity": 1110000 |
| 5738 | } |
| 5739 | ] |
| 5740 | } |
| 5741 | ], |
| 5742 | "features": [ |
| 5743 | { |
| 5744 | "key": "runs", |
| 5745 | "label": "Runs", |
| 5746 | "micros": 33000000, |
| 5747 | "count": 14 |
| 5748 | }, |
| 5749 | { |
| 5750 | "key": "reviews", |
| 5751 | "label": "Reviews", |
| 5752 | "micros": 8000000, |
| 5753 | "count": 9 |
| 5754 | } |
| 5755 | ] |
| 5756 | }, |
| 5757 | { |
| 5758 | "key": "sandboxes", |
| 5759 | "label": "Sandboxes", |
| 5760 | "micros": 7210000, |
| 5761 | "meters": [ |
| 5762 | { |
| 5763 | "key": "sandbox", |
| 5764 | "label": "Sandbox time", |
| 5765 | "product": "sandboxes", |
| 5766 | "unit": "seconds", |
| 5767 | "quantity": 41300, |
| 5768 | "micros": 7210000, |
| 5769 | "pending_micros": 0, |
| 5770 | "daily": [ |
| 5771 | 900000, |
| 5772 | 1200000, |
| 5773 | 800000, |
| 5774 | 1100000, |
| 5775 | 0, |
| 5776 | 2100000, |
| 5777 | 1110000 |
| 5778 | ], |
| 5779 | "allowance": { |
| 5780 | "used": 41300, |
| 5781 | "of": 108000, |
| 5782 | "unit": "seconds" |
| 5783 | }, |
| 5784 | "by_project": [ |
| 5785 | { |
| 5786 | "project": "flagon-io/g1t", |
| 5787 | "micros": 7210000, |
| 5788 | "quantity": 41300 |
| 5789 | } |
| 5790 | ] |
| 5791 | } |
| 5792 | ], |
| 5793 | "features": [] |
| 5794 | } |
| 5795 | ], |
| 5796 | "projects": [ |
| 5797 | "flagon-io/g1t", |
| 5798 | "flagon-io/hello" |
| 5799 | ], |
| 5800 | "models": [ |
| 5801 | { |
| 5802 | "model": "claude-sonnet-5-5", |
| 5803 | "input": 310000, |
| 5804 | "output": 420000, |
| 5805 | "cache_read": 7800000, |
| 5806 | "cache_write": 590000 |
| 5807 | } |
| 5808 | ], |
| 5809 | "included": { |
| 5810 | "used": 20, |
| 5811 | "of": 20, |
| 5812 | "unit": "dollars" |
| 5813 | }, |
| 5814 | "discount_percent": null, |
| 5815 | "ai_credit_micros": 62000000, |
| 5816 | "credit_micros": 0, |
| 5817 | "trial_micros": null, |
| 5818 | "plan": "pro", |
| 5819 | "free": false, |
| 5820 | "group_by": "project", |
| 5821 | "groups": [ |
| 5822 | { |
| 5823 | "key": "flagon-io/g1t", |
| 5824 | "micros": 43210000 |
| 5825 | }, |
| 5826 | { |
| 5827 | "key": "flagon-io/hello", |
| 5828 | "micros": 5000000 |
| 5829 | } |
| 5830 | ] |
| 5831 | }, |
| 5832 | "notes": "Every product family is listed, in order, even with nothing used; this example shows two. `daily` has one amount for each day of the range, oldest first. `projects` and `products` take several values separated by commas: `?products=agent,sandboxes`. A range of more than 400 days, or one that ends before it starts, is refused with `invalid`." |
| 5833 | }, |
| 5834 | "get_budget": { |
| 5835 | "params": { |
| 5836 | "workspace": "flagon-io" |
| 5837 | }, |
| 5838 | "response": { |
| 5839 | "workspace": "flagon-io", |
| 5840 | "amount_micros": 500000000, |
| 5841 | "automatic": false, |
| 5842 | "spent_micros": 132450000, |
| 5843 | "max_amount_micros": 2000000000, |
| 5844 | "alerts": [ |
| 5845 | 50, |
| 5846 | 75, |
| 5847 | 90, |
| 5848 | 100 |
| 5849 | ], |
| 5850 | "pause_at_limit": true, |
| 5851 | "webhook": "https://ops.example.com/g1t/budget", |
| 5852 | "state": "ok", |
| 5853 | "message": null |
| 5854 | }, |
| 5855 | "notes": "All amounts are whole millionths of a dollar: 500000000 is $500. `max_amount_micros` is null for g1t's own workspaces, which have no ceiling. When `state` is `stopped`, new sandboxes, builds and app requests wait until the limit is raised or the month closes." |
| 5856 | }, |
| 5857 | "set_budget": { |
| 5858 | "params": { |
| 5859 | "workspace": "flagon-io" |
| 5860 | }, |
| 5861 | "request": { |
| 5862 | "amount_micros": 500000000, |
| 5863 | "alerts": [ |
| 5864 | 50, |
| 5865 | 75, |
| 5866 | 90, |
| 5867 | 100 |
| 5868 | ], |
| 5869 | "webhook": "https://ops.example.com/g1t/budget" |
| 5870 | }, |
| 5871 | "response": { |
| 5872 | "workspace": "flagon-io", |
| 5873 | "amount_micros": 500000000, |
| 5874 | "automatic": false, |
| 5875 | "spent_micros": 132450000, |
| 5876 | "max_amount_micros": 2000000000, |
| 5877 | "alerts": [ |
| 5878 | 50, |
| 5879 | 75, |
| 5880 | 90, |
| 5881 | 100 |
| 5882 | ], |
| 5883 | "pause_at_limit": true, |
| 5884 | "webhook": "https://ops.example.com/g1t/budget", |
| 5885 | "state": "ok", |
| 5886 | "message": null |
| 5887 | }, |
| 5888 | "notes": "Fields left out keep their value. A limit above `max_amount_micros` is refused with `invalid`. Called by anyone but an owner signed in as a person, or by a workspace's own token or one of g1t's agents, it is refused with `forbidden`. Each alert is sent once a month, to the owners by email and, with `webhook`, as a JSON POST." |
| 5889 | }, |
| 5890 | "get_ai_credit": { |
| 5891 | "params": { |
| 5892 | "workspace": "flagon-io" |
| 5893 | }, |
| 5894 | "response": { |
| 5895 | "balance_micros": 62000000, |
| 5896 | "purchased_micros": 50000000, |
| 5897 | "given_micros": 12000000, |
| 5898 | "grants": [ |
| 5899 | { |
| 5900 | "id": "crd_01kkr2m4c8f1t7qh3d6n9w5p0x", |
| 5901 | "workspace": "flagon-io", |
| 5902 | "kind": "purchase", |
| 5903 | "amount_micros": 50000000, |
| 5904 | "used_micros": 0, |
| 5905 | "left_micros": 50000000, |
| 5906 | "note": "AI credit bought", |
| 5907 | "refund_for": null, |
| 5908 | "refund_day": null, |
| 5909 | "expires_at": "2027-10-02T00:00:00.000Z", |
| 5910 | "created_by": "ana", |
| 5911 | "created_at": "2026-10-02T16:20:00.000Z", |
| 5912 | "state": "open", |
| 5913 | "closed_at": null, |
| 5914 | "closed_note": null, |
| 5915 | "closed_by": null |
| 5916 | } |
| 5917 | ], |
| 5918 | "free_via_discount": false, |
| 5919 | "postpaid": false, |
| 5920 | "blocked": false, |
| 5921 | "can_buy": true, |
| 5922 | "presets_cents": [ |
| 5923 | 2500, |
| 5924 | 5000, |
| 5925 | 10000, |
| 5926 | 25000 |
| 5927 | ], |
| 5928 | "min_cents": 1000, |
| 5929 | "max_cents": 100000, |
| 5930 | "card_fee": { |
| 5931 | "on": true, |
| 5932 | "percent_micros": 29000, |
| 5933 | "fixed_cents": 30 |
| 5934 | }, |
| 5935 | "reload": { |
| 5936 | "enabled": false, |
| 5937 | "threshold_micros": 10000000, |
| 5938 | "target_micros": 50000000, |
| 5939 | "monthly_max_micros": 200000000, |
| 5940 | "reloaded_micros": 0, |
| 5941 | "failed_at": null, |
| 5942 | "error": null |
| 5943 | }, |
| 5944 | "agent_rate_micros": 3.6, |
| 5945 | "model_markup_percent": 10, |
| 5946 | "gateway_markup_percent": 5, |
| 5947 | "upgrade_credit_micros": 10000000, |
| 5948 | "expires_days": 365 |
| 5949 | }, |
| 5950 | "notes": "`card_fee.percent_micros` is per dollar charged, in millionths: 29000 is 2.9%. `blocked` is true when the credit has run out and new runs on g1t's models wait for more; runs on a model provider the workspace connected itself never need it." |
| 5951 | }, |
| 5952 | "buy_ai_credit": { |
| 5953 | "params": { |
| 5954 | "workspace": "flagon-io" |
| 5955 | }, |
| 5956 | "request": { |
| 5957 | "amount_cents": 5000 |
| 5958 | }, |
| 5959 | "response": { |
| 5960 | "url": "https://checkout.example.com/c/pay/cs_test_a1b2c3" |
| 5961 | }, |
| 5962 | "notes": "Open `url` in a browser to pay. Nothing is charged until the payment is made there; the credit then shows in get_ai_credit. An amount outside `min_cents` to `max_cents`, or not in whole dollars, is refused with `invalid`; a workspace that cannot buy credit (see `can_buy`) gets `conflict` or `payment_required`." |
| 5963 | }, |
| 5964 | "list_gateway_requests": { |
| 5965 | "params": { |
| 5966 | "workspace": "flagon-io" |
| 5967 | }, |
| 5968 | "query": { |
| 5969 | "limit": 2 |
| 5970 | }, |
| 5971 | "response": { |
| 5972 | "requests": [ |
| 5973 | { |
| 5974 | "id": "gw_5f0c2a9e7b1d4c3a8e6f0b12", |
| 5975 | "created_at": "2026-10-07T14:02:11.000Z", |
| 5976 | "model": "claude-sonnet-5-5", |
| 5977 | "token_id": "tok_01kkr4w7d2c9e5f8h1j3m6n0p2", |
| 5978 | "token_name": "release-notes", |
| 5979 | "input": 1840, |
| 5980 | "output": 512, |
| 5981 | "cache_read": 12000, |
| 5982 | "cache_write": 0, |
| 5983 | "cost_micros": 11200, |
| 5984 | "charged_micros": 11200, |
| 5985 | "status": 200, |
| 5986 | "own_key": false, |
| 5987 | "streamed": true, |
| 5988 | "duration_ms": 4210, |
| 5989 | "error": null |
| 5990 | }, |
| 5991 | { |
| 5992 | "id": "gw_1a7e3c5b9d2f4e6a8c0b2d41", |
| 5993 | "created_at": "2026-10-07T13:58:40.000Z", |
| 5994 | "model": "claude-opus-5-5", |
| 5995 | "token_id": "tok_01kkr4w7d2c9e5f8h1j3m6n0p2", |
| 5996 | "token_name": "release-notes", |
| 5997 | "input": 0, |
| 5998 | "output": 0, |
| 5999 | "cache_read": 0, |
| 6000 | "cache_write": 0, |
| 6001 | "cost_micros": 0, |
| 6002 | "charged_micros": 0, |
| 6003 | "status": 402, |
| 6004 | "own_key": false, |
| 6005 | "streamed": false, |
| 6006 | "duration_ms": 38, |
| 6007 | "error": "The flagon-io workspace is out of AI credit and has used this month's included usage, so the AI Gateway refuses requests to g1t's models. An owner can buy AI credit or turn on auto-reload at /flagon-io/-/billing#ai-credit." |
| 6008 | } |
| 6009 | ], |
| 6010 | "next": "gw_1a7e3c5b9d2f4e6a8c0b2d41", |
| 6011 | "retention_days": 30 |
| 6012 | }, |
| 6013 | "notes": "To send requests, see the AI Gateway guide: POST https://models.g1t.sh/anthropic/v1/messages with a workspace access token that has `models:write`. `charged_micros` is what the request was charged before included usage and AI credit paid for it; the payment itself is on the statement as AI Gateway. Pass `next` as `before` for the next page; it is null on the last." |
| 6014 | }, |
| 6015 | "list_invoices": { |
| 6016 | "params": { |
| 6017 | "workspace": "flagon-io" |
| 6018 | }, |
| 6019 | "response": { |
| 6020 | "invoices": [ |
| 6021 | { |
| 6022 | "id": "in_1Q2w3E4r5T6y7U8i", |
| 6023 | "number": "FLAGON-0004", |
| 6024 | "status": "paid", |
| 6025 | "total_cents": 4210, |
| 6026 | "currency": "usd", |
| 6027 | "created_at": "2026-10-01T00:05:00.000Z", |
| 6028 | "description": "Usage for 2026-09", |
| 6029 | "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i", |
| 6030 | "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf" |
| 6031 | } |
| 6032 | ], |
| 6033 | "usage_invoices": [ |
| 6034 | { |
| 6035 | "id": "inv_01kkqz8d3c6f9t2wq5n8h1m4r7", |
| 6036 | "workspace": "flagon-io", |
| 6037 | "reason": "month", |
| 6038 | "period": "2026-09", |
| 6039 | "amount_micros": 42100000, |
| 6040 | "status": "paid", |
| 6041 | "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i", |
| 6042 | "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf", |
| 6043 | "lines": [ |
| 6044 | { |
| 6045 | "description": "Agent: models", |
| 6046 | "amount_micros": 35900000 |
| 6047 | }, |
| 6048 | { |
| 6049 | "description": "Sandbox time", |
| 6050 | "amount_micros": 6200000 |
| 6051 | } |
| 6052 | ], |
| 6053 | "created_at": "2026-10-01T00:05:00.000Z" |
| 6054 | }, |
| 6055 | { |
| 6056 | "id": "inv_01kkqz8d3c6f9t2wq5n8h1m4r7", |
| 6057 | "workspace": "flagon-io", |
| 6058 | "reason": "month", |
| 6059 | "period": "2026-09", |
| 6060 | "amount_micros": 42100000, |
| 6061 | "status": "paid", |
| 6062 | "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i", |
| 6063 | "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf", |
| 6064 | "lines": [ |
| 6065 | { |
| 6066 | "description": "Agent: models", |
| 6067 | "amount_micros": 35900000 |
| 6068 | }, |
| 6069 | { |
| 6070 | "description": "Sandbox time", |
| 6071 | "amount_micros": 6200000 |
| 6072 | } |
| 6073 | ], |
| 6074 | "created_at": "2026-10-01T00:05:00.000Z", |
| 6075 | "fee_micros": 1600000, |
| 6076 | "tax_micros": 3510000 |
| 6077 | } |
| 6078 | ], |
| 6079 | "upcoming": { |
| 6080 | "closes_at": "2026-11-01T00:00:00.000Z", |
| 6081 | "subscriptions_micros": 20000000, |
| 6082 | "usage_micros": 10210000, |
| 6083 | "total_micros": 30210000 |
| 6084 | }, |
| 6085 | "unavailable": null |
| 6086 | }, |
| 6087 | "notes": "`invoices` are in cents (`total_cents`); `usage_invoices` and `upcoming` in millionths of a dollar. A usage invoice's `reason` is `month` (the month closed) or `threshold` (charged near the limit), and its `status` `paid`, `open`, `failed` or `void`. An invoice's `status` is `paid`, `open`, `void`, `uncollectible` or `draft`." |
| 6088 | }, |
| 6089 | "get_billing_details": { |
| 6090 | "params": { |
| 6091 | "workspace": "flagon-io" |
| 6092 | }, |
| 6093 | "response": { |
| 6094 | "customer": true, |
| 6095 | "email": "billing@flagon.example.com", |
| 6096 | "name": "Flagon, Inc.", |
| 6097 | "address": { |
| 6098 | "line1": "100 Market Street", |
| 6099 | "line2": "", |
| 6100 | "city": "San Francisco", |
| 6101 | "state": "CA", |
| 6102 | "postal_code": "94105", |
| 6103 | "country": "US" |
| 6104 | }, |
| 6105 | "tax_id_type": "us_ein", |
| 6106 | "tax_id": "12-3456789", |
| 6107 | "po_number": null, |
| 6108 | "language": "en", |
| 6109 | "payment_method": { |
| 6110 | "kind": "card", |
| 6111 | "brand": "visa", |
| 6112 | "last4": "4242", |
| 6113 | "exp_month": 12, |
| 6114 | "exp_year": 2028 |
| 6115 | }, |
| 6116 | "tax_location": true, |
| 6117 | "tax_address_needed_at": null, |
| 6118 | "tax_id_status": "unavailable", |
| 6119 | "tax_exempt": "none" |
| 6120 | }, |
| 6121 | "notes": "Owners change these on the workspace's billing page. `payment_method` is null until a card or other way to pay is saved. Tax is worked out from the address: `tax_location` is false until it has at least a country (and in the US a ZIP code), and `tax_address_needed_at` is set while a charge waits for one." |
| 6122 | }, |
| 6123 | "list_pinned_projects": { |
| 6124 | "params": { |
| 6125 | "workspace": "flagon-io" |
| 6126 | }, |
| 6127 | "response": [ |
| 6128 | { |
| 6129 | "position": 0, |
| 6130 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6131 | "workspace": "flagon-io", |
| 6132 | "slug": "g1t", |
| 6133 | "name": "g1t", |
| 6134 | "description": null, |
| 6135 | "private": false, |
| 6136 | "archived": false, |
| 6137 | "kind": "app", |
| 6138 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6139 | "pushed_at": "2026-10-07T10:00:00.000Z", |
| 6140 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6141 | }, |
| 6142 | { |
| 6143 | "position": 1, |
| 6144 | "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z", |
| 6145 | "workspace": "flagon-io", |
| 6146 | "slug": "lab-api", |
| 6147 | "name": "lab-api", |
| 6148 | "description": null, |
| 6149 | "private": true, |
| 6150 | "archived": false, |
| 6151 | "kind": "app", |
| 6152 | "url": "https://g1t.sh/flagon-io/lab-api", |
| 6153 | "pushed_at": "2026-10-06T18:40:00.000Z", |
| 6154 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6155 | }, |
| 6156 | { |
| 6157 | "position": 2, |
| 6158 | "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y", |
| 6159 | "workspace": "flagon-io", |
| 6160 | "slug": "hello", |
| 6161 | "name": "hello", |
| 6162 | "description": "Greets people from the command line.", |
| 6163 | "private": false, |
| 6164 | "archived": false, |
| 6165 | "kind": "library", |
| 6166 | "url": "https://g1t.sh/flagon-io/hello", |
| 6167 | "pushed_at": null, |
| 6168 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6169 | } |
| 6170 | ], |
| 6171 | "notes": "In your order: `position` 0 first. The sidebar shows these, then the projects you opened last. `pushed_at` is null until the project's repository is pushed to." |
| 6172 | }, |
| 6173 | "pin_project": { |
| 6174 | "params": { |
| 6175 | "workspace": "flagon-io", |
| 6176 | "project": "hello" |
| 6177 | }, |
| 6178 | "request": { |
| 6179 | "position": 0 |
| 6180 | }, |
| 6181 | "response": [ |
| 6182 | { |
| 6183 | "position": 0, |
| 6184 | "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y", |
| 6185 | "workspace": "flagon-io", |
| 6186 | "slug": "hello", |
| 6187 | "name": "hello", |
| 6188 | "description": "Greets people from the command line.", |
| 6189 | "private": false, |
| 6190 | "archived": false, |
| 6191 | "kind": "library", |
| 6192 | "url": "https://g1t.sh/flagon-io/hello", |
| 6193 | "pushed_at": null, |
| 6194 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6195 | }, |
| 6196 | { |
| 6197 | "position": 1, |
| 6198 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6199 | "workspace": "flagon-io", |
| 6200 | "slug": "g1t", |
| 6201 | "name": "g1t", |
| 6202 | "description": null, |
| 6203 | "private": false, |
| 6204 | "archived": false, |
| 6205 | "kind": "app", |
| 6206 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6207 | "pushed_at": "2026-10-07T10:00:00.000Z", |
| 6208 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6209 | }, |
| 6210 | { |
| 6211 | "position": 2, |
| 6212 | "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z", |
| 6213 | "workspace": "flagon-io", |
| 6214 | "slug": "lab-api", |
| 6215 | "name": "lab-api", |
| 6216 | "description": null, |
| 6217 | "private": true, |
| 6218 | "archived": false, |
| 6219 | "kind": "app", |
| 6220 | "url": "https://g1t.sh/flagon-io/lab-api", |
| 6221 | "pushed_at": "2026-10-06T18:40:00.000Z", |
| 6222 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6223 | } |
| 6224 | ], |
| 6225 | "notes": "A ninth pin in a workspace is refused with `409 conflict`: unpin one first." |
| 6226 | }, |
| 6227 | "unpin_project": { |
| 6228 | "params": { |
| 6229 | "workspace": "flagon-io", |
| 6230 | "project": "lab-api" |
| 6231 | }, |
| 6232 | "response": [ |
| 6233 | { |
| 6234 | "position": 0, |
| 6235 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6236 | "workspace": "flagon-io", |
| 6237 | "slug": "g1t", |
| 6238 | "name": "g1t", |
| 6239 | "description": null, |
| 6240 | "private": false, |
| 6241 | "archived": false, |
| 6242 | "kind": "app", |
| 6243 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6244 | "pushed_at": "2026-10-07T10:00:00.000Z", |
| 6245 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6246 | }, |
| 6247 | { |
| 6248 | "position": 1, |
| 6249 | "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y", |
| 6250 | "workspace": "flagon-io", |
| 6251 | "slug": "hello", |
| 6252 | "name": "hello", |
| 6253 | "description": "Greets people from the command line.", |
| 6254 | "private": false, |
| 6255 | "archived": false, |
| 6256 | "kind": "library", |
| 6257 | "url": "https://g1t.sh/flagon-io/hello", |
| 6258 | "pushed_at": null, |
| 6259 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6260 | } |
| 6261 | ] |
| 6262 | }, |
| 6263 | "reorder_pinned_projects": { |
| 6264 | "params": { |
| 6265 | "workspace": "flagon-io" |
| 6266 | }, |
| 6267 | "request": { |
| 6268 | "projects": [ |
| 6269 | "lab-api", |
| 6270 | "g1t", |
| 6271 | "hello" |
| 6272 | ] |
| 6273 | }, |
| 6274 | "response": [ |
| 6275 | { |
| 6276 | "position": 0, |
| 6277 | "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z", |
| 6278 | "workspace": "flagon-io", |
| 6279 | "slug": "lab-api", |
| 6280 | "name": "lab-api", |
| 6281 | "description": null, |
| 6282 | "private": true, |
| 6283 | "archived": false, |
| 6284 | "kind": "app", |
| 6285 | "url": "https://g1t.sh/flagon-io/lab-api", |
| 6286 | "pushed_at": "2026-10-06T18:40:00.000Z", |
| 6287 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6288 | }, |
| 6289 | { |
| 6290 | "position": 1, |
| 6291 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6292 | "workspace": "flagon-io", |
| 6293 | "slug": "g1t", |
| 6294 | "name": "g1t", |
| 6295 | "description": null, |
| 6296 | "private": false, |
| 6297 | "archived": false, |
| 6298 | "kind": "app", |
| 6299 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6300 | "pushed_at": "2026-10-07T10:00:00.000Z", |
| 6301 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6302 | }, |
| 6303 | { |
| 6304 | "position": 2, |
| 6305 | "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y", |
| 6306 | "workspace": "flagon-io", |
| 6307 | "slug": "hello", |
| 6308 | "name": "hello", |
| 6309 | "description": "Greets people from the command line.", |
| 6310 | "private": false, |
| 6311 | "archived": false, |
| 6312 | "kind": "library", |
| 6313 | "url": "https://g1t.sh/flagon-io/hello", |
| 6314 | "pushed_at": null, |
| 6315 | "updated_at": "2026-10-01T09:12:00.000Z" |
| 6316 | } |
| 6317 | ], |
| 6318 | "notes": "Name every pinned project once; anything else is refused with `422 invalid`." |
| 6319 | }, |
| 6320 | "list_projects": { |
| 6321 | "params": { |
| 6322 | "workspace": "flagon-io" |
| 6323 | }, |
| 6324 | "response": [ |
| 6325 | { |
| 6326 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6327 | "workspace": "flagon-io", |
| 6328 | "slug": "g1t", |
| 6329 | "name": "g1t", |
| 6330 | "description": "Git hosting where people and agents work together.", |
| 6331 | "description_inherited": true, |
| 6332 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6333 | "repository": "flagon-io/g1t", |
| 6334 | "root_dir": "", |
| 6335 | "default_branch": "main", |
| 6336 | "private": false, |
| 6337 | "archived": false, |
| 6338 | "primary": true, |
| 6339 | "kind": "app", |
| 6340 | "kind_reason": { |
| 6341 | "by": "set", |
| 6342 | "detail": "Set to an app that runs elsewhere." |
| 6343 | }, |
| 6344 | "runs": "elsewhere", |
| 6345 | "production_url": "https://g1t.sh", |
| 6346 | "setting": { |
| 6347 | "kind": "app", |
| 6348 | "runs": "elsewhere" |
| 6349 | }, |
| 6350 | "detected": { |
| 6351 | "kind": "app", |
| 6352 | "reason": { |
| 6353 | "by": "files", |
| 6354 | "detail": "wrangler.jsonc at its root makes it an app." |
| 6355 | } |
| 6356 | }, |
| 6357 | "ecosystem": null, |
| 6358 | "links": { |
| 6359 | "homepage": "https://g1t.sh", |
| 6360 | "homepage_inherited": true, |
| 6361 | "docs": "https://docs.g1t.sh", |
| 6362 | "custom": [ |
| 6363 | { |
| 6364 | "label": "Status", |
| 6365 | "url": "https://status.g1t.sh" |
| 6366 | } |
| 6367 | ] |
| 6368 | }, |
| 6369 | "created_at": "2026-09-01T10:00:00.000Z", |
| 6370 | "updated_at": "2026-10-07T11:20:00.000Z", |
| 6371 | "pushed_at": "2026-10-07T10:00:00.000Z" |
| 6372 | }, |
| 6373 | { |
| 6374 | "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y", |
| 6375 | "workspace": "flagon-io", |
| 6376 | "slug": "hello", |
| 6377 | "name": "hello", |
| 6378 | "description": "Greets people from the command line.", |
| 6379 | "description_inherited": false, |
| 6380 | "url": "https://g1t.sh/flagon-io/hello", |
| 6381 | "repository": "flagon-io/hello", |
| 6382 | "root_dir": "", |
| 6383 | "default_branch": "main", |
| 6384 | "private": false, |
| 6385 | "archived": false, |
| 6386 | "primary": true, |
| 6387 | "kind": "library", |
| 6388 | "kind_reason": { |
| 6389 | "by": "files", |
| 6390 | "detail": "composer.json says it is a library." |
| 6391 | }, |
| 6392 | "runs": null, |
| 6393 | "production_url": null, |
| 6394 | "setting": { |
| 6395 | "kind": null, |
| 6396 | "runs": null |
| 6397 | }, |
| 6398 | "detected": { |
| 6399 | "kind": "library", |
| 6400 | "reason": { |
| 6401 | "by": "files", |
| 6402 | "detail": "composer.json says it is a library." |
| 6403 | } |
| 6404 | }, |
| 6405 | "ecosystem": "composer", |
| 6406 | "links": { |
| 6407 | "homepage": null, |
| 6408 | "homepage_inherited": false, |
| 6409 | "docs": null, |
| 6410 | "custom": [] |
| 6411 | }, |
| 6412 | "created_at": "2026-09-12T14:30:00.000Z", |
| 6413 | "updated_at": "2026-10-01T09:12:00.000Z", |
| 6414 | "pushed_at": null |
| 6415 | } |
| 6416 | ], |
| 6417 | "notes": "By name. Projects whose repository you cannot see are left out; without a token you see public ones only. `kind` is what the project is, from `setting` where a person set it and from detection otherwise (`detected`, shown beside it); `kind_reason` says why. `runs` is null for what is not deployed. `homepage_inherited` is true while the homepage is its repository's website. `pushed_at` is null until its repository is pushed to. See [Projects](/guides/projects/)." |
| 6418 | }, |
| 6419 | "get_project": { |
| 6420 | "params": { |
| 6421 | "workspace": "flagon-io", |
| 6422 | "project": "g1t" |
| 6423 | }, |
| 6424 | "response": { |
| 6425 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6426 | "workspace": "flagon-io", |
| 6427 | "slug": "g1t", |
| 6428 | "name": "g1t", |
| 6429 | "description": "Git hosting where people and agents work together.", |
| 6430 | "description_inherited": true, |
| 6431 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6432 | "repository": "flagon-io/g1t", |
| 6433 | "root_dir": "", |
| 6434 | "default_branch": "main", |
| 6435 | "private": false, |
| 6436 | "archived": false, |
| 6437 | "primary": true, |
| 6438 | "kind": "app", |
| 6439 | "kind_reason": { |
| 6440 | "by": "set", |
| 6441 | "detail": "Set to an app that runs elsewhere." |
| 6442 | }, |
| 6443 | "runs": "elsewhere", |
| 6444 | "production_url": "https://g1t.sh", |
| 6445 | "setting": { |
| 6446 | "kind": "app", |
| 6447 | "runs": "elsewhere" |
| 6448 | }, |
| 6449 | "detected": { |
| 6450 | "kind": "app", |
| 6451 | "reason": { |
| 6452 | "by": "files", |
| 6453 | "detail": "wrangler.jsonc at its root makes it an app." |
| 6454 | } |
| 6455 | }, |
| 6456 | "ecosystem": null, |
| 6457 | "links": { |
| 6458 | "homepage": "https://g1t.sh", |
| 6459 | "homepage_inherited": true, |
| 6460 | "docs": "https://docs.g1t.sh", |
| 6461 | "custom": [ |
| 6462 | { |
| 6463 | "label": "Status", |
| 6464 | "url": "https://status.g1t.sh" |
| 6465 | } |
| 6466 | ] |
| 6467 | }, |
| 6468 | "created_at": "2026-09-01T10:00:00.000Z", |
| 6469 | "updated_at": "2026-10-07T11:20:00.000Z", |
| 6470 | "pushed_at": "2026-10-07T10:00:00.000Z" |
| 6471 | }, |
| 6472 | "notes": "`404` for a project that does not exist or whose repository you cannot see. `setting` holds what a person set, each part null while it is left to detection. `ecosystem` is where a library's files say it is published (`composer`, `npm`, `cargo`, `go` or `python`), or null. See [What a project is](/guides/projects/#what-a-project-is)." |
| 6473 | }, |
| 6474 | "update_project": { |
| 6475 | "params": { |
| 6476 | "workspace": "flagon-io", |
| 6477 | "project": "g1t" |
| 6478 | }, |
| 6479 | "request": { |
| 6480 | "kind": "app", |
| 6481 | "runs": "elsewhere", |
| 6482 | "production_url": "https://g1t.sh", |
| 6483 | "docs_url": "https://docs.g1t.sh", |
| 6484 | "links": [ |
| 6485 | { |
| 6486 | "label": "Status", |
| 6487 | "url": "https://status.g1t.sh" |
| 6488 | } |
| 6489 | ] |
| 6490 | }, |
| 6491 | "response": { |
| 6492 | "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x", |
| 6493 | "workspace": "flagon-io", |
| 6494 | "slug": "g1t", |
| 6495 | "name": "g1t", |
| 6496 | "description": "Git hosting where people and agents work together.", |
| 6497 | "description_inherited": true, |
| 6498 | "url": "https://g1t.sh/flagon-io/g1t", |
| 6499 | "repository": "flagon-io/g1t", |
| 6500 | "root_dir": "", |
| 6501 | "default_branch": "main", |
| 6502 | "private": false, |
| 6503 | "archived": false, |
| 6504 | "primary": true, |
| 6505 | "kind": "app", |
| 6506 | "kind_reason": { |
| 6507 | "by": "set", |
| 6508 | "detail": "Set to an app that runs elsewhere." |
| 6509 | }, |
| 6510 | "runs": "elsewhere", |
| 6511 | "production_url": "https://g1t.sh", |
| 6512 | "setting": { |
| 6513 | "kind": "app", |
| 6514 | "runs": "elsewhere" |
| 6515 | }, |
| 6516 | "detected": { |
| 6517 | "kind": "app", |
| 6518 | "reason": { |
| 6519 | "by": "files", |
| 6520 | "detail": "wrangler.jsonc at its root makes it an app." |
| 6521 | } |
| 6522 | }, |
| 6523 | "ecosystem": null, |
| 6524 | "links": { |
| 6525 | "homepage": "https://g1t.sh", |
| 6526 | "homepage_inherited": true, |
| 6527 | "docs": "https://docs.g1t.sh", |
| 6528 | "custom": [ |
| 6529 | { |
| 6530 | "label": "Status", |
| 6531 | "url": "https://status.g1t.sh" |
| 6532 | } |
| 6533 | ] |
| 6534 | }, |
| 6535 | "created_at": "2026-09-01T10:00:00.000Z", |
| 6536 | "updated_at": "2026-10-07T11:20:00.000Z", |
| 6537 | "pushed_at": "2026-10-07T10:00:00.000Z" |
| 6538 | }, |
| 6539 | "notes": "Only the fields given change. `kind` and `runs` take `auto` to go back to detection. Setting `runs` makes the project an app unless it is docs. Making it a `library`, `tool` or `other` while [Deployments](/guides/deployments/) are on is refused with `409 conflict`: turn them off first. `description` and `homepage` given as null or `\"\"` follow the repository's again; `production_url` and `docs_url` given as null or `\"\"` are cleared. `links` replaces the project's other links: at most 10, each with a `label` of up to 40 characters and an http or https `url` (`https://` is added when you leave the scheme out); anything else is refused with `422 invalid`. Needs the Maintain role or higher on the project's repository. Recorded in the [audit log](/guides/audit-log/). See [Settings](/guides/projects/#settings)." |
| 6540 | }, |
| 6541 | "list_secret_scanning_alerts": { |
| 6542 | "params": { |
| 6543 | "owner": "flagon-io", |
| 6544 | "name": "hello" |
| 6545 | }, |
| 6546 | "query": { |
| 6547 | "state": "open" |
| 6548 | }, |
| 6549 | "response": [ |
| 6550 | { |
| 6551 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6552 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6553 | "kind": "github_token", |
| 6554 | "label": "a GitHub token", |
| 6555 | "path": "scripts/release.sh", |
| 6556 | "line": 12, |
| 6557 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6558 | "preview": "ghp_X7…", |
| 6559 | "status": "open", |
| 6560 | "source": "push", |
| 6561 | "found_by": "syntaqx", |
| 6562 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6563 | "decided_by": null, |
| 6564 | "reason": null, |
| 6565 | "decided_at": null, |
| 6566 | "dismissed_reason": null, |
| 6567 | "test_value": null, |
| 6568 | "state": "open", |
| 6569 | "validity": "active", |
| 6570 | "validity_checked_at": "2026-10-06T09:20:41.502Z", |
| 6571 | "bypass": { |
| 6572 | "reason": "will_fix_later", |
| 6573 | "comment": "Rotating it this afternoon.", |
| 6574 | "by": "syntaqx", |
| 6575 | "at": "2026-10-06T09:14:02.118Z", |
| 6576 | "approved_by": null |
| 6577 | }, |
| 6578 | "pattern_id": null, |
| 6579 | "pattern_name": null, |
| 6580 | "locations": 1 |
| 6581 | } |
| 6582 | ], |
| 6583 | "notes": "| Filter | Values |\n| --- | --- |\n| `state` | `open` (in the history, or blocked at a push), `dismissed`, `fixed` |\n| `secret_type` | `aws_access_key`, `github_token`, `custom_pattern`, … |\n| `validity` | `active`, `inactive`, `unknown`, `unsupported` |\n| `bypassed` | `true` or `false` |\n\nThe secret itself is never returned: `preview` is enough to recognise it. `status` says where it stands: `open`, `blocked` (stopped at a push, never landed), `allowed` or `resolved`." |
| 6584 | }, |
| 6585 | "list_secret_scanning_alerts_for_workspace": { |
| 6586 | "params": { |
| 6587 | "workspace": "flagon-io" |
| 6588 | }, |
| 6589 | "query": { |
| 6590 | "state": "open" |
| 6591 | }, |
| 6592 | "response": [ |
| 6593 | { |
| 6594 | "repo": "hello", |
| 6595 | "secret": { |
| 6596 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6597 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6598 | "kind": "github_token", |
| 6599 | "label": "a GitHub token", |
| 6600 | "path": "scripts/release.sh", |
| 6601 | "line": 12, |
| 6602 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6603 | "preview": "ghp_X7…", |
| 6604 | "status": "open", |
| 6605 | "source": "push", |
| 6606 | "found_by": "syntaqx", |
| 6607 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6608 | "decided_by": null, |
| 6609 | "reason": null, |
| 6610 | "decided_at": null, |
| 6611 | "dismissed_reason": null, |
| 6612 | "test_value": null, |
| 6613 | "state": "open", |
| 6614 | "validity": "active", |
| 6615 | "validity_checked_at": "2026-10-06T09:20:41.502Z", |
| 6616 | "bypass": { |
| 6617 | "reason": "will_fix_later", |
| 6618 | "comment": "Rotating it this afternoon.", |
| 6619 | "by": "syntaqx", |
| 6620 | "at": "2026-10-06T09:14:02.118Z", |
| 6621 | "approved_by": null |
| 6622 | }, |
| 6623 | "pattern_id": null, |
| 6624 | "pattern_name": null, |
| 6625 | "locations": 1 |
| 6626 | } |
| 6627 | } |
| 6628 | ], |
| 6629 | "notes": "Every repository whose findings you may see, each alert with its repository's name." |
| 6630 | }, |
| 6631 | "get_secret_scanning_alert": { |
| 6632 | "params": { |
| 6633 | "owner": "flagon-io", |
| 6634 | "name": "hello", |
| 6635 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p" |
| 6636 | }, |
| 6637 | "response": { |
| 6638 | "secret": { |
| 6639 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6640 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6641 | "kind": "github_token", |
| 6642 | "label": "a GitHub token", |
| 6643 | "path": "scripts/release.sh", |
| 6644 | "line": 12, |
| 6645 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6646 | "preview": "ghp_X7…", |
| 6647 | "status": "blocked", |
| 6648 | "source": "push", |
| 6649 | "found_by": "syntaqx", |
| 6650 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6651 | "decided_by": null, |
| 6652 | "reason": null, |
| 6653 | "decided_at": null, |
| 6654 | "dismissed_reason": null, |
| 6655 | "test_value": null, |
| 6656 | "state": "open", |
| 6657 | "validity": null, |
| 6658 | "validity_checked_at": null, |
| 6659 | "bypass": null, |
| 6660 | "pattern_id": null, |
| 6661 | "pattern_name": null, |
| 6662 | "locations": 1 |
| 6663 | }, |
| 6664 | "locations": [ |
| 6665 | { |
| 6666 | "path": "scripts/release.sh", |
| 6667 | "line": 12, |
| 6668 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6669 | "source": "push", |
| 6670 | "found_at": "2026-10-06T09:14:02.118Z" |
| 6671 | } |
| 6672 | ], |
| 6673 | "activity": [], |
| 6674 | "requests": [], |
| 6675 | "checkable": true, |
| 6676 | "can_bypass": true, |
| 6677 | "can_request_bypass": false |
| 6678 | } |
| 6679 | }, |
| 6680 | "update_secret_scanning_alert": { |
| 6681 | "params": { |
| 6682 | "owner": "flagon-io", |
| 6683 | "name": "hello", |
| 6684 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p" |
| 6685 | }, |
| 6686 | "request": { |
| 6687 | "state": "dismissed", |
| 6688 | "reason": "revoked", |
| 6689 | "comment": "Rotated in the issuer's settings." |
| 6690 | }, |
| 6691 | "response": { |
| 6692 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6693 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6694 | "kind": "github_token", |
| 6695 | "label": "a GitHub token", |
| 6696 | "path": "scripts/release.sh", |
| 6697 | "line": 12, |
| 6698 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6699 | "preview": "ghp_X7…", |
| 6700 | "status": "resolved", |
| 6701 | "source": "push", |
| 6702 | "found_by": "syntaqx", |
| 6703 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6704 | "decided_by": "syntaqx", |
| 6705 | "reason": "Rotated in the issuer's settings.", |
| 6706 | "decided_at": "2026-10-06T09:20:41.502Z", |
| 6707 | "dismissed_reason": "revoked", |
| 6708 | "test_value": null, |
| 6709 | "state": "fixed", |
| 6710 | "validity": "active", |
| 6711 | "validity_checked_at": "2026-10-06T09:20:41.502Z", |
| 6712 | "bypass": { |
| 6713 | "reason": "will_fix_later", |
| 6714 | "comment": "Rotating it this afternoon.", |
| 6715 | "by": "syntaqx", |
| 6716 | "at": "2026-10-06T09:14:02.118Z", |
| 6717 | "approved_by": null |
| 6718 | }, |
| 6719 | "pattern_id": null, |
| 6720 | "pattern_name": null, |
| 6721 | "locations": 1 |
| 6722 | }, |
| 6723 | "notes": "Takes the Admin role: a dismissed secret is let through push protection, unless it was `revoked`, which marks it fixed. `state` `open` reopens it." |
| 6724 | }, |
| 6725 | "list_secret_scanning_locations": { |
| 6726 | "params": { |
| 6727 | "owner": "flagon-io", |
| 6728 | "name": "hello", |
| 6729 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p" |
| 6730 | }, |
| 6731 | "response": [ |
| 6732 | { |
| 6733 | "path": "scripts/release.sh", |
| 6734 | "line": 12, |
| 6735 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6736 | "source": "push", |
| 6737 | "found_at": "2026-10-06T09:14:02.118Z" |
| 6738 | } |
| 6739 | ] |
| 6740 | }, |
| 6741 | "bypass_push_protection": { |
| 6742 | "params": { |
| 6743 | "owner": "flagon-io", |
| 6744 | "name": "hello", |
| 6745 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p" |
| 6746 | }, |
| 6747 | "request": { |
| 6748 | "reason": "will_fix_later", |
| 6749 | "comment": "Rotating it this afternoon." |
| 6750 | }, |
| 6751 | "response": { |
| 6752 | "secret": { |
| 6753 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6754 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6755 | "kind": "github_token", |
| 6756 | "label": "a GitHub token", |
| 6757 | "path": "scripts/release.sh", |
| 6758 | "line": 12, |
| 6759 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6760 | "preview": "ghp_X7…", |
| 6761 | "status": "open", |
| 6762 | "source": "push", |
| 6763 | "found_by": "syntaqx", |
| 6764 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6765 | "decided_by": null, |
| 6766 | "reason": null, |
| 6767 | "decided_at": null, |
| 6768 | "dismissed_reason": null, |
| 6769 | "test_value": null, |
| 6770 | "state": "open", |
| 6771 | "validity": null, |
| 6772 | "validity_checked_at": null, |
| 6773 | "bypass": { |
| 6774 | "reason": "will_fix_later", |
| 6775 | "comment": "Rotating it this afternoon.", |
| 6776 | "by": "syntaqx", |
| 6777 | "at": "2026-10-06T09:14:02.118Z", |
| 6778 | "approved_by": null |
| 6779 | }, |
| 6780 | "pattern_id": null, |
| 6781 | "pattern_name": null, |
| 6782 | "locations": 1 |
| 6783 | }, |
| 6784 | "request": null |
| 6785 | }, |
| 6786 | "notes": "| Reason | The alert |\n| --- | --- |\n| `false_positive` | Closed as a false positive |\n| `used_in_tests` | Closed as used in tests |\n| `will_fix_later` | Stays open, to be rotated |\n\nWith delegated bypass on, a call from someone who does not review bypasses makes a request instead: `request` is set and the secret is still blocked until an owner or admin approves it. Push again once it is bypassed." |
| 6787 | }, |
| 6788 | "check_secret_validity": { |
| 6789 | "params": { |
| 6790 | "owner": "flagon-io", |
| 6791 | "name": "hello", |
| 6792 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p" |
| 6793 | }, |
| 6794 | "response": { |
| 6795 | "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6796 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6797 | "kind": "github_token", |
| 6798 | "label": "a GitHub token", |
| 6799 | "path": "scripts/release.sh", |
| 6800 | "line": 12, |
| 6801 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 6802 | "preview": "ghp_X7…", |
| 6803 | "status": "open", |
| 6804 | "source": "push", |
| 6805 | "found_by": "syntaqx", |
| 6806 | "found_at": "2026-10-06T09:14:02.118Z", |
| 6807 | "decided_by": null, |
| 6808 | "reason": null, |
| 6809 | "decided_at": null, |
| 6810 | "dismissed_reason": null, |
| 6811 | "test_value": null, |
| 6812 | "state": "open", |
| 6813 | "validity": "active", |
| 6814 | "validity_checked_at": "2026-10-06T09:20:41.502Z", |
| 6815 | "bypass": { |
| 6816 | "reason": "will_fix_later", |
| 6817 | "comment": "Rotating it this afternoon.", |
| 6818 | "by": "syntaqx", |
| 6819 | "at": "2026-10-06T09:14:02.118Z", |
| 6820 | "approved_by": null |
| 6821 | }, |
| 6822 | "pattern_id": null, |
| 6823 | "pattern_name": null, |
| 6824 | "locations": 1 |
| 6825 | }, |
| 6826 | "notes": "Made for GitHub, GitLab, Stripe, Slack, npm, OpenAI, Anthropic and SendGrid tokens, with the issuer's own read-only call. Other formats answer `unsupported`; a secret that never landed answers `unknown`." |
| 6827 | }, |
| 6828 | "list_bypass_requests": { |
| 6829 | "params": { |
| 6830 | "workspace": "flagon-io" |
| 6831 | }, |
| 6832 | "query": { |
| 6833 | "state": "pending" |
| 6834 | }, |
| 6835 | "response": [ |
| 6836 | { |
| 6837 | "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q", |
| 6838 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6839 | "workspace": "flagon-io", |
| 6840 | "repo": "hello", |
| 6841 | "secret_id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6842 | "label": "a GitHub token", |
| 6843 | "path": "scripts/release.sh", |
| 6844 | "line": 12, |
| 6845 | "preview": "ghp_X7…", |
| 6846 | "requester": "ana", |
| 6847 | "reason": "used_in_tests", |
| 6848 | "comment": "A token from the test fixtures, never issued.", |
| 6849 | "state": "pending", |
| 6850 | "reviewer": null, |
| 6851 | "review_comment": null, |
| 6852 | "created_at": "2026-10-06T09:14:02.118Z", |
| 6853 | "reviewed_at": null |
| 6854 | } |
| 6855 | ] |
| 6856 | }, |
| 6857 | "review_bypass_request": { |
| 6858 | "params": { |
| 6859 | "workspace": "flagon-io", |
| 6860 | "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q" |
| 6861 | }, |
| 6862 | "request": { |
| 6863 | "decision": "approve", |
| 6864 | "comment": "A fixture." |
| 6865 | }, |
| 6866 | "response": { |
| 6867 | "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q", |
| 6868 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 6869 | "workspace": "flagon-io", |
| 6870 | "repo": "hello", |
| 6871 | "secret_id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p", |
| 6872 | "label": "a GitHub token", |
| 6873 | "path": "scripts/release.sh", |
| 6874 | "line": 12, |
| 6875 | "preview": "ghp_X7…", |
| 6876 | "requester": "ana", |
| 6877 | "reason": "used_in_tests", |
| 6878 | "comment": "A token from the test fixtures, never issued.", |
| 6879 | "state": "approved", |
| 6880 | "reviewer": "syntaqx", |
| 6881 | "review_comment": "A fixture.", |
| 6882 | "created_at": "2026-10-06T09:14:02.118Z", |
| 6883 | "reviewed_at": "2026-10-06T09:20:41.502Z" |
| 6884 | } |
| 6885 | }, |
| 6886 | "list_custom_patterns": { |
| 6887 | "params": { |
| 6888 | "owner": "flagon-io", |
| 6889 | "name": "hello" |
| 6890 | }, |
| 6891 | "response": { |
| 6892 | "patterns": [ |
| 6893 | { |
| 6894 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 6895 | "scope": "repository", |
| 6896 | "workspace": "flagon-io", |
| 6897 | "repo": "hello", |
| 6898 | "name": "Acme API key", |
| 6899 | "pattern": "acme_[a-z0-9]{32}", |
| 6900 | "before": null, |
| 6901 | "after": null, |
| 6902 | "test_strings": [ |
| 6903 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 6904 | ], |
| 6905 | "state": "published", |
| 6906 | "created_by": "syntaqx", |
| 6907 | "created_at": "2026-10-06T09:14:02.118Z", |
| 6908 | "updated_by": "syntaqx", |
| 6909 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 6910 | "open_alerts": 0 |
| 6911 | } |
| 6912 | ], |
| 6913 | "entitled": true |
| 6914 | }, |
| 6915 | "notes": "A repository's list includes its workspace's patterns, with `scope` `workspace`. `entitled` says whether they run here: always on a public repository, and on a private one with the Security and quality activation." |
| 6916 | }, |
| 6917 | "list_custom_patterns_for_workspace": { |
| 6918 | "params": { |
| 6919 | "workspace": "flagon-io" |
| 6920 | }, |
| 6921 | "response": { |
| 6922 | "patterns": [ |
| 6923 | { |
| 6924 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 6925 | "scope": "workspace", |
| 6926 | "workspace": "flagon-io", |
| 6927 | "repo": null, |
| 6928 | "name": "Acme API key", |
| 6929 | "pattern": "acme_[a-z0-9]{32}", |
| 6930 | "before": null, |
| 6931 | "after": null, |
| 6932 | "test_strings": [ |
| 6933 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 6934 | ], |
| 6935 | "state": "published", |
| 6936 | "created_by": "syntaqx", |
| 6937 | "created_at": "2026-10-06T09:14:02.118Z", |
| 6938 | "updated_by": "syntaqx", |
| 6939 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 6940 | "open_alerts": 0 |
| 6941 | } |
| 6942 | ], |
| 6943 | "entitled": true |
| 6944 | } |
| 6945 | }, |
| 6946 | "create_custom_pattern": { |
| 6947 | "params": { |
| 6948 | "owner": "flagon-io", |
| 6949 | "name": "hello" |
| 6950 | }, |
| 6951 | "request": { |
| 6952 | "pattern_name": "Acme API key", |
| 6953 | "pattern": "acme_[a-z0-9]{32}", |
| 6954 | "test_strings": [ |
| 6955 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 6956 | ], |
| 6957 | "publish": true |
| 6958 | }, |
| 6959 | "response": { |
| 6960 | "pattern": { |
| 6961 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 6962 | "scope": "repository", |
| 6963 | "workspace": "flagon-io", |
| 6964 | "repo": "hello", |
| 6965 | "name": "Acme API key", |
| 6966 | "pattern": "acme_[a-z0-9]{32}", |
| 6967 | "before": null, |
| 6968 | "after": null, |
| 6969 | "test_strings": [ |
| 6970 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 6971 | ], |
| 6972 | "state": "published", |
| 6973 | "created_by": "syntaqx", |
| 6974 | "created_at": "2026-10-06T09:14:02.118Z", |
| 6975 | "updated_by": "syntaqx", |
| 6976 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 6977 | "open_alerts": 0 |
| 6978 | }, |
| 6979 | "tests": [ |
| 6980 | [ |
| 6981 | 9, |
| 6982 | 46 |
| 6983 | ] |
| 6984 | ] |
| 6985 | }, |
| 6986 | "notes": "`tests` gives, for each test string, where the pattern matched (start and end, in characters), or `null`. A pattern that does not compile, matches an empty string, or is too complex is refused with `422` and says why." |
| 6987 | }, |
| 6988 | "create_custom_pattern_for_workspace": { |
| 6989 | "params": { |
| 6990 | "workspace": "flagon-io" |
| 6991 | }, |
| 6992 | "request": { |
| 6993 | "pattern_name": "Acme API key", |
| 6994 | "pattern": "acme_[a-z0-9]{32}", |
| 6995 | "publish": false |
| 6996 | }, |
| 6997 | "response": { |
| 6998 | "pattern": { |
| 6999 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 7000 | "scope": "workspace", |
| 7001 | "workspace": "flagon-io", |
| 7002 | "repo": null, |
| 7003 | "name": "Acme API key", |
| 7004 | "pattern": "acme_[a-z0-9]{32}", |
| 7005 | "before": null, |
| 7006 | "after": null, |
| 7007 | "test_strings": [], |
| 7008 | "state": "draft", |
| 7009 | "created_by": "syntaqx", |
| 7010 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7011 | "updated_by": "syntaqx", |
| 7012 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7013 | "open_alerts": 0 |
| 7014 | }, |
| 7015 | "tests": [] |
| 7016 | } |
| 7017 | }, |
| 7018 | "update_custom_pattern": { |
| 7019 | "params": { |
| 7020 | "owner": "flagon-io", |
| 7021 | "name": "hello", |
| 7022 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r" |
| 7023 | }, |
| 7024 | "request": { |
| 7025 | "pattern_name": "Acme API key", |
| 7026 | "pattern": "acme_[a-z0-9]{32,40}", |
| 7027 | "publish": true |
| 7028 | }, |
| 7029 | "response": { |
| 7030 | "pattern": { |
| 7031 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 7032 | "scope": "repository", |
| 7033 | "workspace": "flagon-io", |
| 7034 | "repo": "hello", |
| 7035 | "name": "Acme API key", |
| 7036 | "pattern": "acme_[a-z0-9]{32,40}", |
| 7037 | "before": null, |
| 7038 | "after": null, |
| 7039 | "test_strings": [ |
| 7040 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 7041 | ], |
| 7042 | "state": "published", |
| 7043 | "created_by": "syntaqx", |
| 7044 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7045 | "updated_by": "syntaqx", |
| 7046 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7047 | "open_alerts": 0 |
| 7048 | }, |
| 7049 | "tests": [ |
| 7050 | [ |
| 7051 | 9, |
| 7052 | 46 |
| 7053 | ] |
| 7054 | ] |
| 7055 | } |
| 7056 | }, |
| 7057 | "update_custom_pattern_for_workspace": { |
| 7058 | "params": { |
| 7059 | "workspace": "flagon-io", |
| 7060 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r" |
| 7061 | }, |
| 7062 | "request": { |
| 7063 | "pattern_name": "Acme API key", |
| 7064 | "pattern": "acme_[a-z0-9]{32}", |
| 7065 | "publish": true |
| 7066 | }, |
| 7067 | "response": { |
| 7068 | "pattern": { |
| 7069 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r", |
| 7070 | "scope": "workspace", |
| 7071 | "workspace": "flagon-io", |
| 7072 | "repo": null, |
| 7073 | "name": "Acme API key", |
| 7074 | "pattern": "acme_[a-z0-9]{32}", |
| 7075 | "before": null, |
| 7076 | "after": null, |
| 7077 | "test_strings": [ |
| 7078 | "ACME_KEY=acme_0123456789abcdef0123456789abcdef" |
| 7079 | ], |
| 7080 | "state": "published", |
| 7081 | "created_by": "syntaqx", |
| 7082 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7083 | "updated_by": "syntaqx", |
| 7084 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7085 | "open_alerts": 0 |
| 7086 | }, |
| 7087 | "tests": [ |
| 7088 | [ |
| 7089 | 9, |
| 7090 | 46 |
| 7091 | ] |
| 7092 | ] |
| 7093 | } |
| 7094 | }, |
| 7095 | "delete_custom_pattern": { |
| 7096 | "params": { |
| 7097 | "owner": "flagon-io", |
| 7098 | "name": "hello", |
| 7099 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r" |
| 7100 | }, |
| 7101 | "response": { |
| 7102 | "deleted": true |
| 7103 | } |
| 7104 | }, |
| 7105 | "delete_custom_pattern_for_workspace": { |
| 7106 | "params": { |
| 7107 | "workspace": "flagon-io", |
| 7108 | "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r" |
| 7109 | }, |
| 7110 | "response": { |
| 7111 | "deleted": true |
| 7112 | } |
| 7113 | }, |
| 7114 | "dry_run_custom_pattern": { |
| 7115 | "params": { |
| 7116 | "owner": "flagon-io", |
| 7117 | "name": "hello" |
| 7118 | }, |
| 7119 | "request": { |
| 7120 | "pattern": "acme_[a-z0-9]{32}" |
| 7121 | }, |
| 7122 | "response": { |
| 7123 | "repos": [ |
| 7124 | { |
| 7125 | "name": "hello", |
| 7126 | "files_scanned": 214, |
| 7127 | "matches": [ |
| 7128 | { |
| 7129 | "path": "config/dev.env", |
| 7130 | "line": 3, |
| 7131 | "preview": "ACME_KEY=acme_01••••••••••••••••••••••••" |
| 7132 | } |
| 7133 | ], |
| 7134 | "truncated": false, |
| 7135 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291" |
| 7136 | } |
| 7137 | ] |
| 7138 | }, |
| 7139 | "notes": "Reads up to 2,000 files and 20 MB of the default branch, skipping what secret scanning skips. Nothing is recorded." |
| 7140 | }, |
| 7141 | "dry_run_custom_pattern_for_workspace": { |
| 7142 | "params": { |
| 7143 | "workspace": "flagon-io" |
| 7144 | }, |
| 7145 | "request": { |
| 7146 | "pattern": "acme_[a-z0-9]{32}", |
| 7147 | "repos": [ |
| 7148 | "hello" |
| 7149 | ] |
| 7150 | }, |
| 7151 | "response": { |
| 7152 | "repos": [ |
| 7153 | { |
| 7154 | "name": "hello", |
| 7155 | "files_scanned": 214, |
| 7156 | "matches": [], |
| 7157 | "truncated": false, |
| 7158 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291" |
| 7159 | } |
| 7160 | ] |
| 7161 | } |
| 7162 | }, |
| 7163 | "list_code_scanning_alerts": { |
| 7164 | "params": { |
| 7165 | "owner": "flagon-io", |
| 7166 | "name": "hello" |
| 7167 | }, |
| 7168 | "query": { |
| 7169 | "state": "open", |
| 7170 | "severity": "high" |
| 7171 | }, |
| 7172 | "response": [ |
| 7173 | { |
| 7174 | "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s", |
| 7175 | "number": 4, |
| 7176 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7177 | "tool": "Semgrep OSS", |
| 7178 | "category": "Semgrep OSS", |
| 7179 | "rule_id": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7180 | "rule_name": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7181 | "rule_description": "Detected calls to child_process from a function argument.", |
| 7182 | "help": null, |
| 7183 | "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process", |
| 7184 | "tags": [ |
| 7185 | "security", |
| 7186 | "CWE-78" |
| 7187 | ], |
| 7188 | "level": "error", |
| 7189 | "security_severity": null, |
| 7190 | "severity": "high", |
| 7191 | "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.", |
| 7192 | "path": "src/server.js", |
| 7193 | "start_line": 6, |
| 7194 | "end_line": 6, |
| 7195 | "start_column": 3, |
| 7196 | "end_column": 60, |
| 7197 | "state": "open", |
| 7198 | "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6", |
| 7199 | "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7200 | "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7201 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7202 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7203 | "fixed_at": null, |
| 7204 | "dismissed_by": null, |
| 7205 | "dismissed_reason": null, |
| 7206 | "dismissed_comment": null, |
| 7207 | "dismissed_at": null, |
| 7208 | "issue": null |
| 7209 | } |
| 7210 | ], |
| 7211 | "notes": "`severity` is the rule's security severity when it has one (from its `security-severity` score), else from the result's level: `error` high, `warning` medium, `note` low." |
| 7212 | }, |
| 7213 | "list_code_scanning_alerts_for_workspace": { |
| 7214 | "params": { |
| 7215 | "workspace": "flagon-io" |
| 7216 | }, |
| 7217 | "query": { |
| 7218 | "state": "open" |
| 7219 | }, |
| 7220 | "response": [ |
| 7221 | { |
| 7222 | "repo": "hello", |
| 7223 | "code": { |
| 7224 | "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s", |
| 7225 | "number": 4, |
| 7226 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7227 | "tool": "Semgrep OSS", |
| 7228 | "category": "Semgrep OSS", |
| 7229 | "rule_id": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7230 | "rule_name": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7231 | "rule_description": "Detected calls to child_process from a function argument.", |
| 7232 | "help": null, |
| 7233 | "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process", |
| 7234 | "tags": [ |
| 7235 | "security", |
| 7236 | "CWE-78" |
| 7237 | ], |
| 7238 | "level": "error", |
| 7239 | "security_severity": null, |
| 7240 | "severity": "high", |
| 7241 | "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.", |
| 7242 | "path": "src/server.js", |
| 7243 | "start_line": 6, |
| 7244 | "end_line": 6, |
| 7245 | "start_column": 3, |
| 7246 | "end_column": 60, |
| 7247 | "state": "open", |
| 7248 | "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6", |
| 7249 | "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7250 | "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7251 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7252 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7253 | "fixed_at": null, |
| 7254 | "dismissed_by": null, |
| 7255 | "dismissed_reason": null, |
| 7256 | "dismissed_comment": null, |
| 7257 | "dismissed_at": null, |
| 7258 | "issue": null |
| 7259 | } |
| 7260 | } |
| 7261 | ] |
| 7262 | }, |
| 7263 | "get_code_scanning_alert": { |
| 7264 | "params": { |
| 7265 | "owner": "flagon-io", |
| 7266 | "name": "hello", |
| 7267 | "number": 4 |
| 7268 | }, |
| 7269 | "response": { |
| 7270 | "alert": { |
| 7271 | "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s", |
| 7272 | "number": 4, |
| 7273 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7274 | "tool": "Semgrep OSS", |
| 7275 | "category": "Semgrep OSS", |
| 7276 | "rule_id": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7277 | "rule_name": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7278 | "rule_description": "Detected calls to child_process from a function argument.", |
| 7279 | "help": null, |
| 7280 | "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process", |
| 7281 | "tags": [ |
| 7282 | "security", |
| 7283 | "CWE-78" |
| 7284 | ], |
| 7285 | "level": "error", |
| 7286 | "security_severity": null, |
| 7287 | "severity": "high", |
| 7288 | "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.", |
| 7289 | "path": "src/server.js", |
| 7290 | "start_line": 6, |
| 7291 | "end_line": 6, |
| 7292 | "start_column": 3, |
| 7293 | "end_column": 60, |
| 7294 | "state": "open", |
| 7295 | "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6", |
| 7296 | "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7297 | "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7298 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7299 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7300 | "fixed_at": null, |
| 7301 | "dismissed_by": null, |
| 7302 | "dismissed_reason": null, |
| 7303 | "dismissed_comment": null, |
| 7304 | "dismissed_at": null, |
| 7305 | "issue": null |
| 7306 | }, |
| 7307 | "activity": [], |
| 7308 | "analyses": [ |
| 7309 | { |
| 7310 | "id": "ana_01kq2rbh8j9k0m1n2p3q4r5s6t", |
| 7311 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7312 | "sarif_id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v", |
| 7313 | "tool": "Semgrep OSS", |
| 7314 | "tool_version": "1.140.0", |
| 7315 | "category": "Semgrep OSS", |
| 7316 | "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7317 | "git_ref": "refs/heads/main", |
| 7318 | "pull": null, |
| 7319 | "results": 7, |
| 7320 | "new_alerts": 2, |
| 7321 | "fixed_alerts": 1, |
| 7322 | "dropped": 0, |
| 7323 | "created_at": "2026-10-06T09:14:02.118Z" |
| 7324 | } |
| 7325 | ] |
| 7326 | } |
| 7327 | }, |
| 7328 | "update_code_scanning_alert": { |
| 7329 | "params": { |
| 7330 | "owner": "flagon-io", |
| 7331 | "name": "hello", |
| 7332 | "number": 4 |
| 7333 | }, |
| 7334 | "request": { |
| 7335 | "state": "dismissed", |
| 7336 | "dismissed_reason": "false_positive", |
| 7337 | "dismissed_comment": "The argument is a constant." |
| 7338 | }, |
| 7339 | "response": { |
| 7340 | "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s", |
| 7341 | "number": 4, |
| 7342 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7343 | "tool": "Semgrep OSS", |
| 7344 | "category": "Semgrep OSS", |
| 7345 | "rule_id": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7346 | "rule_name": "javascript.lang.security.detect-child-process.detect-child-process", |
| 7347 | "rule_description": "Detected calls to child_process from a function argument.", |
| 7348 | "help": null, |
| 7349 | "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process", |
| 7350 | "tags": [ |
| 7351 | "security", |
| 7352 | "CWE-78" |
| 7353 | ], |
| 7354 | "level": "error", |
| 7355 | "security_severity": null, |
| 7356 | "severity": "high", |
| 7357 | "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.", |
| 7358 | "path": "src/server.js", |
| 7359 | "start_line": 6, |
| 7360 | "end_line": 6, |
| 7361 | "start_column": 3, |
| 7362 | "end_column": 60, |
| 7363 | "state": "dismissed", |
| 7364 | "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6", |
| 7365 | "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7366 | "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7367 | "created_at": "2026-10-06T09:14:02.118Z", |
| 7368 | "updated_at": "2026-10-06T09:14:02.118Z", |
| 7369 | "fixed_at": null, |
| 7370 | "dismissed_by": "syntaqx", |
| 7371 | "dismissed_reason": "false_positive", |
| 7372 | "dismissed_comment": "The argument is a constant.", |
| 7373 | "dismissed_at": "2026-10-06T09:20:41.502Z", |
| 7374 | "issue": null |
| 7375 | } |
| 7376 | }, |
| 7377 | "list_code_scanning_analyses": { |
| 7378 | "params": { |
| 7379 | "owner": "flagon-io", |
| 7380 | "name": "hello" |
| 7381 | }, |
| 7382 | "response": [ |
| 7383 | { |
| 7384 | "id": "ana_01kq2rbh8j9k0m1n2p3q4r5s6t", |
| 7385 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7386 | "sarif_id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v", |
| 7387 | "tool": "Semgrep OSS", |
| 7388 | "tool_version": "1.140.0", |
| 7389 | "category": "Semgrep OSS", |
| 7390 | "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7391 | "git_ref": "refs/heads/main", |
| 7392 | "pull": null, |
| 7393 | "results": 7, |
| 7394 | "new_alerts": 2, |
| 7395 | "fixed_alerts": 1, |
| 7396 | "dropped": 0, |
| 7397 | "created_at": "2026-10-06T09:14:02.118Z" |
| 7398 | } |
| 7399 | ] |
| 7400 | }, |
| 7401 | "upload_sarif": { |
| 7402 | "params": { |
| 7403 | "owner": "flagon-io", |
| 7404 | "name": "hello" |
| 7405 | }, |
| 7406 | "request": { |
| 7407 | "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7408 | "ref": "refs/heads/main", |
| 7409 | "sarif": "H4sIAAAAAAAA…", |
| 7410 | "checkout_uri": "file:///home/runner/work/repo" |
| 7411 | }, |
| 7412 | "response": { |
| 7413 | "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v", |
| 7414 | "processing_status": "complete", |
| 7415 | "analyses": [ |
| 7416 | "ana_01kq2rbh8j9k0m1n2p3q4r5s6t" |
| 7417 | ], |
| 7418 | "errors": [], |
| 7419 | "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7420 | "git_ref": "refs/heads/main", |
| 7421 | "created_at": "2026-10-06T09:14:02.118Z" |
| 7422 | }, |
| 7423 | "notes": "`sarif` is the SARIF 2.1.0 file gzipped, then base64-encoded: `gzip -c results.sarif | base64 -w0`. The upload is read at once: `processing_status` is `complete` or `failed`, with `errors` saying why. For `refs/pull/<number>/head`, the results become the pull request's `Code scanning` check instead of alerts." |
| 7424 | }, |
| 7425 | "get_sarif_upload": { |
| 7426 | "params": { |
| 7427 | "owner": "flagon-io", |
| 7428 | "name": "hello", |
| 7429 | "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v" |
| 7430 | }, |
| 7431 | "response": { |
| 7432 | "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v", |
| 7433 | "processing_status": "complete", |
| 7434 | "analyses": [ |
| 7435 | "ana_01kq2rbh8j9k0m1n2p3q4r5s6t" |
| 7436 | ], |
| 7437 | "errors": [], |
| 7438 | "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7439 | "git_ref": "refs/heads/main", |
| 7440 | "created_at": "2026-10-06T09:14:02.118Z" |
| 7441 | } |
| 7442 | }, |
| 7443 | "list_vulnerability_alerts": { |
| 7444 | "params": { |
| 7445 | "owner": "flagon-io", |
| 7446 | "name": "hello" |
| 7447 | }, |
| 7448 | "query": { |
| 7449 | "state": "open" |
| 7450 | }, |
| 7451 | "response": [ |
| 7452 | { |
| 7453 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 7454 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7455 | "ecosystem": "npm", |
| 7456 | "package": "lodash", |
| 7457 | "version": "4.17.20", |
| 7458 | "manifest": "package-lock.json", |
| 7459 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 7460 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 7461 | "summary": "Command Injection in lodash", |
| 7462 | "severity": "high", |
| 7463 | "fixed_version": "4.17.21", |
| 7464 | "status": "open", |
| 7465 | "issue": null, |
| 7466 | "found_at": "2026-10-06T09:14:02.118Z", |
| 7467 | "fixed_at": null, |
| 7468 | "state": "open", |
| 7469 | "dismissed_by": null, |
| 7470 | "dismissed_reason": null, |
| 7471 | "dismissed_comment": null, |
| 7472 | "dismissed_at": null, |
| 7473 | "update": null |
| 7474 | } |
| 7475 | ] |
| 7476 | }, |
| 7477 | "list_vulnerability_alerts_for_workspace": { |
| 7478 | "params": { |
| 7479 | "workspace": "flagon-io" |
| 7480 | }, |
| 7481 | "query": { |
| 7482 | "severity": "critical" |
| 7483 | }, |
| 7484 | "response": [ |
| 7485 | { |
| 7486 | "repo": "hello", |
| 7487 | "vulnerability": { |
| 7488 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 7489 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7490 | "ecosystem": "npm", |
| 7491 | "package": "lodash", |
| 7492 | "version": "4.17.20", |
| 7493 | "manifest": "package-lock.json", |
| 7494 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 7495 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 7496 | "summary": "Command Injection in lodash", |
| 7497 | "severity": "high", |
| 7498 | "fixed_version": "4.17.21", |
| 7499 | "status": "open", |
| 7500 | "issue": null, |
| 7501 | "found_at": "2026-10-06T09:14:02.118Z", |
| 7502 | "fixed_at": null, |
| 7503 | "state": "open", |
| 7504 | "dismissed_by": null, |
| 7505 | "dismissed_reason": null, |
| 7506 | "dismissed_comment": null, |
| 7507 | "dismissed_at": null, |
| 7508 | "update": null |
| 7509 | } |
| 7510 | } |
| 7511 | ] |
| 7512 | }, |
| 7513 | "get_vulnerability_alert": { |
| 7514 | "params": { |
| 7515 | "owner": "flagon-io", |
| 7516 | "name": "hello", |
| 7517 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n" |
| 7518 | }, |
| 7519 | "response": { |
| 7520 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 7521 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7522 | "ecosystem": "npm", |
| 7523 | "package": "lodash", |
| 7524 | "version": "4.17.20", |
| 7525 | "manifest": "package-lock.json", |
| 7526 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 7527 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 7528 | "summary": "Command Injection in lodash", |
| 7529 | "severity": "high", |
| 7530 | "fixed_version": "4.17.21", |
| 7531 | "status": "open", |
| 7532 | "issue": null, |
| 7533 | "found_at": "2026-10-06T09:14:02.118Z", |
| 7534 | "fixed_at": null, |
| 7535 | "state": "open", |
| 7536 | "dismissed_by": null, |
| 7537 | "dismissed_reason": null, |
| 7538 | "dismissed_comment": null, |
| 7539 | "dismissed_at": null, |
| 7540 | "update": null |
| 7541 | } |
| 7542 | }, |
| 7543 | "update_vulnerability_alert": { |
| 7544 | "params": { |
| 7545 | "owner": "flagon-io", |
| 7546 | "name": "hello", |
| 7547 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n" |
| 7548 | }, |
| 7549 | "request": { |
| 7550 | "state": "dismissed", |
| 7551 | "reason": "tolerable_risk", |
| 7552 | "comment": "Only the build uses it." |
| 7553 | }, |
| 7554 | "response": { |
| 7555 | "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n", |
| 7556 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7557 | "ecosystem": "npm", |
| 7558 | "package": "lodash", |
| 7559 | "version": "4.17.20", |
| 7560 | "manifest": "package-lock.json", |
| 7561 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 7562 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 7563 | "summary": "Command Injection in lodash", |
| 7564 | "severity": "high", |
| 7565 | "fixed_version": "4.17.21", |
| 7566 | "status": "dismissed", |
| 7567 | "issue": null, |
| 7568 | "found_at": "2026-10-06T09:14:02.118Z", |
| 7569 | "fixed_at": null, |
| 7570 | "state": "dismissed", |
| 7571 | "dismissed_by": "syntaqx", |
| 7572 | "dismissed_reason": "tolerable_risk", |
| 7573 | "dismissed_comment": "Only the build uses it.", |
| 7574 | "dismissed_at": "2026-10-06T09:20:41.502Z", |
| 7575 | "update": null |
| 7576 | } |
| 7577 | }, |
| 7578 | "fix_security_alert": { |
| 7579 | "params": { |
| 7580 | "owner": "flagon-io", |
| 7581 | "name": "hello", |
| 7582 | "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s" |
| 7583 | }, |
| 7584 | "response": { |
| 7585 | "issue": 57, |
| 7586 | "started": true, |
| 7587 | "message": null |
| 7588 | }, |
| 7589 | "notes": "Opens an issue with what is wrong and what done means, and puts g1t on it as you. Its run is charged as agent usage, and its pull request lands through the repository's required checks. Asking again while the issue is open returns it." |
| 7590 | }, |
| 7591 | "get_dependency_graph": { |
| 7592 | "params": { |
| 7593 | "owner": "flagon-io", |
| 7594 | "name": "hello" |
| 7595 | }, |
| 7596 | "response": { |
| 7597 | "commit": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7598 | "manifests": [ |
| 7599 | { |
| 7600 | "path": "package-lock.json", |
| 7601 | "ecosystem": "npm", |
| 7602 | "dependencies": 2, |
| 7603 | "direct": 1 |
| 7604 | } |
| 7605 | ], |
| 7606 | "dependencies": [ |
| 7607 | { |
| 7608 | "ecosystem": "npm", |
| 7609 | "name": "lodash", |
| 7610 | "version": "4.17.20", |
| 7611 | "manifest": "package-lock.json", |
| 7612 | "relationship": "direct", |
| 7613 | "development": false, |
| 7614 | "license": "MIT", |
| 7615 | "purl": "pkg:npm/lodash@4.17.20", |
| 7616 | "vulnerabilities": 1 |
| 7617 | }, |
| 7618 | { |
| 7619 | "ecosystem": "npm", |
| 7620 | "name": "ms", |
| 7621 | "version": "2.1.3", |
| 7622 | "manifest": "package-lock.json", |
| 7623 | "relationship": "transitive", |
| 7624 | "development": false, |
| 7625 | "license": "MIT", |
| 7626 | "purl": "pkg:npm/ms@2.1.3", |
| 7627 | "vulnerabilities": 0 |
| 7628 | } |
| 7629 | ] |
| 7630 | } |
| 7631 | }, |
| 7632 | "get_sbom": { |
| 7633 | "params": { |
| 7634 | "owner": "flagon-io", |
| 7635 | "name": "hello" |
| 7636 | }, |
| 7637 | "response": { |
| 7638 | "sbom": { |
| 7639 | "spdxVersion": "SPDX-2.3", |
| 7640 | "dataLicense": "CC0-1.0", |
| 7641 | "SPDXID": "SPDXRef-DOCUMENT", |
| 7642 | "name": "flagon-io/hello dependency graph", |
| 7643 | "documentNamespace": "https://g1t.sh/flagon-io/hello/sbom/sbom_01kq2tdk0m1n2p3q4r5s6t7v8w", |
| 7644 | "creationInfo": { |
| 7645 | "created": "2026-10-06T09:14:02Z", |
| 7646 | "creators": [ |
| 7647 | "Tool: g1t", |
| 7648 | "Organization: g1t" |
| 7649 | ], |
| 7650 | "comment": "Read from the repository's lockfiles on its default branch." |
| 7651 | }, |
| 7652 | "documentDescribes": [ |
| 7653 | "SPDXRef-Repository-flagon-io-hello" |
| 7654 | ], |
| 7655 | "packages": [ |
| 7656 | { |
| 7657 | "SPDXID": "SPDXRef-Repository-flagon-io-hello", |
| 7658 | "name": "flagon-io/hello", |
| 7659 | "versionInfo": "4807077b296e6edbf410d55e72749d3e1170c291", |
| 7660 | "downloadLocation": "git+https://g1t.sh/flagon-io/hello.git", |
| 7661 | "filesAnalyzed": false, |
| 7662 | "licenseConcluded": "NOASSERTION", |
| 7663 | "licenseDeclared": "NOASSERTION", |
| 7664 | "copyrightText": "NOASSERTION", |
| 7665 | "primaryPackagePurpose": "SOURCE", |
| 7666 | "externalRefs": [] |
| 7667 | }, |
| 7668 | { |
| 7669 | "SPDXID": "SPDXRef-Package-npm-lodash-4.17.20", |
| 7670 | "name": "lodash", |
| 7671 | "versionInfo": "4.17.20", |
| 7672 | "downloadLocation": "NOASSERTION", |
| 7673 | "filesAnalyzed": false, |
| 7674 | "licenseConcluded": "NOASSERTION", |
| 7675 | "licenseDeclared": "MIT", |
| 7676 | "copyrightText": "NOASSERTION", |
| 7677 | "primaryPackagePurpose": "LIBRARY", |
| 7678 | "comment": "Resolved by package-lock.json (direct dependency).", |
| 7679 | "externalRefs": [ |
| 7680 | { |
| 7681 | "referenceCategory": "PACKAGE-MANAGER", |
| 7682 | "referenceType": "purl", |
| 7683 | "referenceLocator": "pkg:npm/lodash@4.17.20" |
| 7684 | } |
| 7685 | ] |
| 7686 | } |
| 7687 | ], |
| 7688 | "relationships": [ |
| 7689 | { |
| 7690 | "spdxElementId": "SPDXRef-DOCUMENT", |
| 7691 | "relationshipType": "DESCRIBES", |
| 7692 | "relatedSpdxElement": "SPDXRef-Repository-flagon-io-hello" |
| 7693 | }, |
| 7694 | { |
| 7695 | "spdxElementId": "SPDXRef-Repository-flagon-io-hello", |
| 7696 | "relationshipType": "DEPENDS_ON", |
| 7697 | "relatedSpdxElement": "SPDXRef-Package-npm-lodash-4.17.20" |
| 7698 | } |
| 7699 | ] |
| 7700 | } |
| 7701 | }, |
| 7702 | "notes": "`sbom` is an SPDX 2.3 JSON document, sent as SPDX spells it. Save it with `jq .sbom`." |
| 7703 | }, |
| 7704 | "compare_dependencies": { |
| 7705 | "params": { |
| 7706 | "owner": "flagon-io", |
| 7707 | "name": "hello", |
| 7708 | "basehead": "main...upgrade-deps" |
| 7709 | }, |
| 7710 | "response": { |
| 7711 | "base": "main", |
| 7712 | "head": "upgrade-deps", |
| 7713 | "changes": [ |
| 7714 | { |
| 7715 | "change_type": "added", |
| 7716 | "manifest": "package-lock.json", |
| 7717 | "ecosystem": "npm", |
| 7718 | "name": "lodash", |
| 7719 | "version": "4.17.20", |
| 7720 | "relationship": "direct", |
| 7721 | "development": false, |
| 7722 | "license": "MIT", |
| 7723 | "purl": "pkg:npm/lodash@4.17.20", |
| 7724 | "vulnerabilities": [ |
| 7725 | { |
| 7726 | "advisory": "GHSA-35jh-r3h4-6jhm", |
| 7727 | "osv_id": "GHSA-35jh-r3h4-6jhm", |
| 7728 | "summary": "Command Injection in lodash", |
| 7729 | "severity": "high", |
| 7730 | "fixed_version": "4.17.21", |
| 7731 | "url": "https://osv.dev/vulnerability/GHSA-35jh-r3h4-6jhm" |
| 7732 | } |
| 7733 | ], |
| 7734 | "denied_license": false, |
| 7735 | "failing": true |
| 7736 | }, |
| 7737 | { |
| 7738 | "change_type": "removed", |
| 7739 | "manifest": "package-lock.json", |
| 7740 | "ecosystem": "npm", |
| 7741 | "name": "lodash", |
| 7742 | "version": "4.17.21", |
| 7743 | "relationship": "direct", |
| 7744 | "development": false, |
| 7745 | "license": "MIT", |
| 7746 | "purl": "pkg:npm/lodash@4.17.21", |
| 7747 | "vulnerabilities": [], |
| 7748 | "denied_license": false, |
| 7749 | "failing": false |
| 7750 | } |
| 7751 | ], |
| 7752 | "passed": false, |
| 7753 | "headline": "Adds 1 vulnerable package", |
| 7754 | "fail_on": "high", |
| 7755 | "deny_licenses": [] |
| 7756 | } |
| 7757 | }, |
| 7758 | "get_security_settings": { |
| 7759 | "params": { |
| 7760 | "owner": "flagon-io", |
| 7761 | "name": "hello" |
| 7762 | }, |
| 7763 | "response": { |
| 7764 | "settings": { |
| 7765 | "code_scanning_gate": "high", |
| 7766 | "dependency_review": true, |
| 7767 | "review_fail_on": "high", |
| 7768 | "review_deny_licenses": [ |
| 7769 | "AGPL-3.0-only" |
| 7770 | ], |
| 7771 | "review_comment": true |
| 7772 | }, |
| 7773 | "workspace": { |
| 7774 | "delegated_bypass": true, |
| 7775 | "validity_checks": true |
| 7776 | }, |
| 7777 | "private": true, |
| 7778 | "entitled": true, |
| 7779 | "upkeep": true |
| 7780 | } |
| 7781 | }, |
| 7782 | "update_security_settings": { |
| 7783 | "params": { |
| 7784 | "owner": "flagon-io", |
| 7785 | "name": "hello" |
| 7786 | }, |
| 7787 | "request": { |
| 7788 | "code_scanning_gate": "high", |
| 7789 | "review_deny_licenses": [ |
| 7790 | "AGPL-3.0-only" |
| 7791 | ] |
| 7792 | }, |
| 7793 | "response": { |
| 7794 | "settings": { |
| 7795 | "code_scanning_gate": "high", |
| 7796 | "dependency_review": true, |
| 7797 | "review_fail_on": "high", |
| 7798 | "review_deny_licenses": [ |
| 7799 | "AGPL-3.0-only" |
| 7800 | ], |
| 7801 | "review_comment": true |
| 7802 | }, |
| 7803 | "workspace": { |
| 7804 | "delegated_bypass": true, |
| 7805 | "validity_checks": true |
| 7806 | }, |
| 7807 | "private": true, |
| 7808 | "entitled": true, |
| 7809 | "upkeep": true |
| 7810 | }, |
| 7811 | "notes": "Only what you send changes. The `Code scanning` and `Dependency review` checks gate merges once you require them in branch protection." |
| 7812 | }, |
| 7813 | "get_workspace_security_settings": { |
| 7814 | "params": { |
| 7815 | "workspace": "flagon-io" |
| 7816 | }, |
| 7817 | "response": { |
| 7818 | "settings": { |
| 7819 | "delegated_bypass": true, |
| 7820 | "validity_checks": true |
| 7821 | }, |
| 7822 | "activated": true |
| 7823 | } |
| 7824 | }, |
| 7825 | "update_workspace_security_settings": { |
| 7826 | "params": { |
| 7827 | "workspace": "flagon-io" |
| 7828 | }, |
| 7829 | "request": { |
| 7830 | "delegated_bypass": true |
| 7831 | }, |
| 7832 | "response": { |
| 7833 | "settings": { |
| 7834 | "delegated_bypass": true, |
| 7835 | "validity_checks": true |
| 7836 | }, |
| 7837 | "activated": true |
| 7838 | } |
| 7839 | }, |
| 7840 | "get_security_overview": { |
| 7841 | "params": { |
| 7842 | "workspace": "flagon-io" |
| 7843 | }, |
| 7844 | "query": { |
| 7845 | "days": "30" |
| 7846 | }, |
| 7847 | "response": { |
| 7848 | "activated": true, |
| 7849 | "private_hidden": 0, |
| 7850 | "totals": [ |
| 7851 | { |
| 7852 | "alert_type": "secret_scanning", |
| 7853 | "open": { |
| 7854 | "critical": 1, |
| 7855 | "high": 0, |
| 7856 | "medium": 0, |
| 7857 | "low": 0, |
| 7858 | "unknown": 0 |
| 7859 | }, |
| 7860 | "opened": 2, |
| 7861 | "closed": 1 |
| 7862 | }, |
| 7863 | { |
| 7864 | "alert_type": "code_scanning", |
| 7865 | "open": { |
| 7866 | "critical": 0, |
| 7867 | "high": 3, |
| 7868 | "medium": 4, |
| 7869 | "low": 0, |
| 7870 | "unknown": 0 |
| 7871 | }, |
| 7872 | "opened": 7, |
| 7873 | "closed": 2 |
| 7874 | }, |
| 7875 | { |
| 7876 | "alert_type": "vulnerability", |
| 7877 | "open": { |
| 7878 | "critical": 0, |
| 7879 | "high": 1, |
| 7880 | "medium": 2, |
| 7881 | "low": 1, |
| 7882 | "unknown": 0 |
| 7883 | }, |
| 7884 | "opened": 3, |
| 7885 | "closed": 5 |
| 7886 | } |
| 7887 | ], |
| 7888 | "trend": [ |
| 7889 | { |
| 7890 | "day": "2026-10-05", |
| 7891 | "secret_scanning": 1, |
| 7892 | "code_scanning": 8, |
| 7893 | "vulnerability": 6 |
| 7894 | }, |
| 7895 | { |
| 7896 | "day": "2026-10-06", |
| 7897 | "secret_scanning": 1, |
| 7898 | "code_scanning": 7, |
| 7899 | "vulnerability": 4 |
| 7900 | } |
| 7901 | ], |
| 7902 | "repos": [ |
| 7903 | { |
| 7904 | "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m", |
| 7905 | "name": "hello", |
| 7906 | "private": true, |
| 7907 | "custom_patterns": 1, |
| 7908 | "validity_checks": true, |
| 7909 | "code_scanning_at": "2026-10-06T09:14:02.118Z", |
| 7910 | "dependency_review": true, |
| 7911 | "security_updates": true, |
| 7912 | "lockfiles": 1, |
| 7913 | "secrets": { |
| 7914 | "critical": 1, |
| 7915 | "high": 0, |
| 7916 | "medium": 0, |
| 7917 | "low": 0, |
| 7918 | "unknown": 0 |
| 7919 | }, |
| 7920 | "code": { |
| 7921 | "critical": 0, |
| 7922 | "high": 3, |
| 7923 | "medium": 4, |
| 7924 | "low": 0, |
| 7925 | "unknown": 0 |
| 7926 | }, |
| 7927 | "vulnerabilities": { |
| 7928 | "critical": 0, |
| 7929 | "high": 1, |
| 7930 | "medium": 2, |
| 7931 | "low": 1, |
| 7932 | "unknown": 0 |
| 7933 | } |
| 7934 | } |
| 7935 | ] |
| 7936 | } |
| 7937 | }, |
| 7938 | "create_label": { |
| 7939 | "request": { |
| 7940 | "label": "area: cli", |
| 7941 | "color": "1d76db", |
| 7942 | "description": "The command-line tool" |
| 7943 | }, |
| 7944 | "response": { |
| 7945 | "name": "area: cli", |
| 7946 | "color": "1d76db", |
| 7947 | "description": "The command-line tool", |
| 7948 | "issues": 0, |
| 7949 | "pulls": 0 |
| 7950 | } |
| 7951 | }, |
| 7952 | "update_label": { |
| 7953 | "params": { |
| 7954 | "label": "area: cli" |
| 7955 | }, |
| 7956 | "request": { |
| 7957 | "new_name": "cli", |
| 7958 | "color": "0052cc" |
| 7959 | }, |
| 7960 | "response": { |
| 7961 | "name": "cli", |
| 7962 | "color": "0052cc", |
| 7963 | "description": "The command-line tool", |
| 7964 | "issues": 3, |
| 7965 | "pulls": 1 |
| 7966 | }, |
| 7967 | "notes": "Renaming a label renames it on every issue and pull request that carries it." |
| 7968 | }, |
| 7969 | "delete_label": { |
| 7970 | "params": { |
| 7971 | "label": "wontfix" |
| 7972 | }, |
| 7973 | "response": true |
| 7974 | }, |
| 7975 | "add_default_labels": { |
| 7976 | "response": [ |
| 7977 | { |
| 7978 | "name": "bug", |
| 7979 | "color": "d73a4a", |
| 7980 | "description": "Something isn't working", |
| 7981 | "issues": 4, |
| 7982 | "pulls": 1 |
| 7983 | }, |
| 7984 | { |
| 7985 | "name": "documentation", |
| 7986 | "color": "0075ca", |
| 7987 | "description": "Improvements or additions to documentation", |
| 7988 | "issues": 0, |
| 7989 | "pulls": 0 |
| 7990 | } |
| 7991 | ], |
| 7992 | "notes": "Every label the repository has afterwards, shortened here. Labels it already had are left as they were." |
| 7993 | }, |
| 7994 | "list_issue_labels": { |
| 7995 | "response": [ |
| 7996 | { |
| 7997 | "name": "bug", |
| 7998 | "color": "d73a4a", |
| 7999 | "description": "Something isn't working", |
| 8000 | "issues": 4, |
| 8001 | "pulls": 1 |
| 8002 | }, |
| 8003 | { |
| 8004 | "name": "help wanted", |
| 8005 | "color": "008672", |
| 8006 | "description": "Extra attention is needed", |
| 8007 | "issues": 1, |
| 8008 | "pulls": 0 |
| 8009 | } |
| 8010 | ] |
| 8011 | }, |
| 8012 | "add_issue_labels": { |
| 8013 | "request": { |
| 8014 | "labels": [ |
| 8015 | "help wanted" |
| 8016 | ] |
| 8017 | }, |
| 8018 | "response": [ |
| 8019 | "bug", |
| 8020 | "help wanted" |
| 8021 | ], |
| 8022 | "notes": "Returns its labels now, by name." |
| 8023 | }, |
| 8024 | "set_issue_labels": { |
| 8025 | "request": { |
| 8026 | "labels": [ |
| 8027 | "bug" |
| 8028 | ] |
| 8029 | }, |
| 8030 | "response": [ |
| 8031 | "bug" |
| 8032 | ] |
| 8033 | }, |
| 8034 | "remove_issue_labels": { |
| 8035 | "response": [] |
| 8036 | }, |
| 8037 | "remove_issue_label": { |
| 8038 | "params": { |
| 8039 | "label": "help wanted" |
| 8040 | }, |
| 8041 | "response": [ |
| 8042 | "bug" |
| 8043 | ] |
| 8044 | }, |
| 8045 | "list_milestones": { |
| 8046 | "response": [ |
| 8047 | { |
| 8048 | "number": 3, |
| 8049 | "title": "Launch", |
| 8050 | "description": "Everything that has to land before the launch on October 14.", |
| 8051 | "due_on": "2026-10-14", |
| 8052 | "state": "open", |
| 8053 | "open_items": 5, |
| 8054 | "closed_items": 12, |
| 8055 | "created_at": "2026-09-20T09:00:00.000Z", |
| 8056 | "updated_at": "2026-10-06T16:12:40.118Z", |
| 8057 | "closed_at": null |
| 8058 | } |
| 8059 | ], |
| 8060 | "notes": "Open milestones soonest due first, then closed ones. Progress is closed_items out of open_items plus closed_items." |
| 8061 | }, |
| 8062 | "create_milestone": { |
| 8063 | "request": { |
| 8064 | "title": "Launch", |
| 8065 | "description": "Everything that has to land before the launch on October 14.", |
| 8066 | "due_on": "2026-10-14" |
| 8067 | }, |
| 8068 | "response": { |
| 8069 | "number": 3, |
| 8070 | "title": "Launch", |
| 8071 | "description": "Everything that has to land before the launch on October 14.", |
| 8072 | "due_on": "2026-10-14", |
| 8073 | "state": "open", |
| 8074 | "open_items": 0, |
| 8075 | "closed_items": 0, |
| 8076 | "created_at": "2026-09-20T09:00:00.000Z", |
| 8077 | "updated_at": "2026-09-20T09:00:00.000Z", |
| 8078 | "closed_at": null |
| 8079 | } |
| 8080 | }, |
| 8081 | "update_milestone": { |
| 8082 | "params": { |
| 8083 | "milestone": 3 |
| 8084 | }, |
| 8085 | "request": { |
| 8086 | "state": "closed" |
| 8087 | }, |
| 8088 | "response": { |
| 8089 | "number": 3, |
| 8090 | "title": "Launch", |
| 8091 | "description": "Everything that has to land before the launch on October 14.", |
| 8092 | "due_on": "2026-10-14", |
| 8093 | "state": "closed", |
| 8094 | "open_items": 0, |
| 8095 | "closed_items": 17, |
| 8096 | "created_at": "2026-09-20T09:00:00.000Z", |
| 8097 | "updated_at": "2026-10-14T18:00:00.000Z", |
| 8098 | "closed_at": "2026-10-14T18:00:00.000Z" |
| 8099 | } |
| 8100 | }, |
| 8101 | "delete_milestone": { |
| 8102 | "params": { |
| 8103 | "milestone": 3 |
| 8104 | }, |
| 8105 | "response": true |
| 8106 | }, |
| 8107 | "get_milestone": { |
| 8108 | "params": { |
| 8109 | "milestone": 3 |
| 8110 | }, |
| 8111 | "response": { |
| 8112 | "milestone": { |
| 8113 | "number": 3, |
| 8114 | "title": "Launch", |
| 8115 | "description": "Everything that has to land before the launch on October 14.", |
| 8116 | "due_on": "2026-10-14", |
| 8117 | "state": "open", |
| 8118 | "open_items": 5, |
| 8119 | "closed_items": 12, |
| 8120 | "created_at": "2026-09-20T09:00:00.000Z", |
| 8121 | "updated_at": "2026-10-06T16:12:40.118Z", |
| 8122 | "closed_at": null |
| 8123 | }, |
| 8124 | "issues": [ |
| 8125 | { |
| 8126 | "id": "iss_01m43shrzpfe49x74ga7sj1c6v", |
| 8127 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 8128 | "number": 12, |
| 8129 | "title": "Greeting should name the caller", |
| 8130 | "body": "Take a name from the first argument; fall back to world.", |
| 8131 | "labels": [ |
| 8132 | "feature", |
| 8133 | "good first issue" |
| 8134 | ], |
| 8135 | "state": "open", |
| 8136 | "reason": null, |
| 8137 | "resolved_by": null, |
| 8138 | "author": { |
| 8139 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 8140 | "username": "syntaqx", |
| 8141 | "kind": "user", |
| 8142 | "verified": false, |
| 8143 | "workspaces": [] |
| 8144 | }, |
| 8145 | "requested_by": null, |
| 8146 | "created_at": "2026-10-01T18:04:11.482Z", |
| 8147 | "updated_at": "2026-10-01T18:09:47.305Z", |
| 8148 | "closed_at": null, |
| 8149 | "pull_count": 0, |
| 8150 | "comment_count": 0, |
| 8151 | "assignees": [ |
| 8152 | "syntaqx" |
| 8153 | ], |
| 8154 | "blocked_by": [], |
| 8155 | "queued": false, |
| 8156 | "agent": null, |
| 8157 | "milestone": { |
| 8158 | "number": 3, |
| 8159 | "title": "Launch" |
| 8160 | } |
| 8161 | } |
| 8162 | ], |
| 8163 | "pulls": [ |
| 8164 | { |
| 8165 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 8166 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 8167 | "number": 14, |
| 8168 | "issue": 12, |
| 8169 | "title": "Greeting should name the caller", |
| 8170 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 8171 | "agent": "claude-code", |
| 8172 | "runtime": "external", |
| 8173 | "status": "open", |
| 8174 | "fork": { |
| 8175 | "namespace": "pulls", |
| 8176 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 8177 | }, |
| 8178 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 8179 | "branch": null, |
| 8180 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 8181 | "merge_base": null, |
| 8182 | "merged_by": null, |
| 8183 | "merged_at": null, |
| 8184 | "superseded_by": null, |
| 8185 | "check_status": "passed", |
| 8186 | "files": [ |
| 8187 | { |
| 8188 | "path": "src/main.rs", |
| 8189 | "additions": 6, |
| 8190 | "deletions": 2 |
| 8191 | } |
| 8192 | ], |
| 8193 | "assignees": [], |
| 8194 | "reviewers": [ |
| 8195 | "ana" |
| 8196 | ], |
| 8197 | "labels": [], |
| 8198 | "milestone": { |
| 8199 | "number": 3, |
| 8200 | "title": "Launch" |
| 8201 | }, |
| 8202 | "base": "main", |
| 8203 | "author": { |
| 8204 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 8205 | "username": "syntaqx", |
| 8206 | "kind": "user", |
| 8207 | "verified": false, |
| 8208 | "workspaces": [] |
| 8209 | }, |
| 8210 | "requested_by": null, |
| 8211 | "created_at": "2026-10-01T18:20:02.117Z", |
| 8212 | "updated_at": "2026-10-01T18:35:44.902Z", |
| 8213 | "confidence": null |
| 8214 | } |
| 8215 | ] |
| 8216 | } |
| 8217 | }, |
| 8218 | "update_pull_request": { |
| 8219 | "request": { |
| 8220 | "base": "release/1.x", |
| 8221 | "labels": [ |
| 8222 | "bug" |
| 8223 | ] |
| 8224 | }, |
| 8225 | "response": { |
| 8226 | "id": "pr_01m43smh3vexsr5pmp60qwv0vs", |
| 8227 | "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr", |
| 8228 | "number": 14, |
| 8229 | "issue": 12, |
| 8230 | "title": "Greeting should name the caller", |
| 8231 | "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".", |
| 8232 | "agent": "claude-code", |
| 8233 | "runtime": "external", |
| 8234 | "status": "open", |
| 8235 | "fork": { |
| 8236 | "namespace": "pulls", |
| 8237 | "name": "pr_01m43smh3vexsr5pmp60qwv0vs" |
| 8238 | }, |
| 8239 | "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e", |
| 8240 | "branch": null, |
| 8241 | "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13", |
| 8242 | "merge_base": null, |
| 8243 | "merged_by": null, |
| 8244 | "merged_at": null, |
| 8245 | "superseded_by": null, |
| 8246 | "check_status": "passed", |
| 8247 | "files": [ |
| 8248 | { |
| 8249 | "path": "src/main.rs", |
| 8250 | "additions": 6, |
| 8251 | "deletions": 2 |
| 8252 | } |
| 8253 | ], |
| 8254 | "assignees": [], |
| 8255 | "reviewers": [ |
| 8256 | "ana" |
| 8257 | ], |
| 8258 | "labels": [ |
| 8259 | "bug" |
| 8260 | ], |
| 8261 | "milestone": null, |
| 8262 | "base": "release/1.x", |
| 8263 | "author": { |
| 8264 | "id": "usr_01kkntcg1eeb98j62xjm7eh09p", |
| 8265 | "username": "syntaqx", |
| 8266 | "kind": "user", |
| 8267 | "verified": false, |
| 8268 | "workspaces": [] |
| 8269 | }, |
| 8270 | "requested_by": null, |
| 8271 | "created_at": "2026-10-01T18:20:02.117Z", |
| 8272 | "updated_at": "2026-10-01T18:35:44.902Z", |
| 8273 | "confidence": null |
| 8274 | }, |
| 8275 | "notes": "A new base takes it out of the merge queue, and whether it is behind, merges cleanly and has the checks it needs is worked out against the new base." |
| 8276 | }, |
| 8277 | "list_repo_rulesets": { |
| 8278 | "params": { |
| 8279 | "owner": "flagon-io", |
| 8280 | "name": "hello" |
| 8281 | }, |
| 8282 | "query": { |
| 8283 | "include_parents": "true" |
| 8284 | }, |
| 8285 | "response": [ |
| 8286 | { |
| 8287 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8288 | "level": "repository", |
| 8289 | "workspace": "flagon-io", |
| 8290 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 8291 | "repository": "flagon-io/hello", |
| 8292 | "name": "Protect main", |
| 8293 | "enforcement": "active", |
| 8294 | "target": "branch", |
| 8295 | "conditions": { |
| 8296 | "ref_name": { |
| 8297 | "include": [ |
| 8298 | "~DEFAULT_BRANCH" |
| 8299 | ], |
| 8300 | "exclude": [] |
| 8301 | } |
| 8302 | }, |
| 8303 | "bypass_actors": [ |
| 8304 | { |
| 8305 | "kind": "role", |
| 8306 | "value": "admin", |
| 8307 | "mode": "pull_requests" |
| 8308 | } |
| 8309 | ], |
| 8310 | "rules": [ |
| 8311 | { |
| 8312 | "type": "deletion", |
| 8313 | "parameters": {}, |
| 8314 | "applies_to": "everyone" |
| 8315 | }, |
| 8316 | { |
| 8317 | "type": "non_fast_forward", |
| 8318 | "parameters": {}, |
| 8319 | "applies_to": "everyone" |
| 8320 | }, |
| 8321 | { |
| 8322 | "type": "pull_request", |
| 8323 | "parameters": { |
| 8324 | "required_approvals": 1, |
| 8325 | "count_agent_approvals": true, |
| 8326 | "dismiss_stale_reviews_on_push": true, |
| 8327 | "require_code_owner_review": true, |
| 8328 | "require_last_push_approval": false, |
| 8329 | "allowed_merge_methods": [] |
| 8330 | }, |
| 8331 | "applies_to": "everyone" |
| 8332 | }, |
| 8333 | { |
| 8334 | "type": "required_status_checks", |
| 8335 | "parameters": { |
| 8336 | "checks": [ |
| 8337 | { |
| 8338 | "context": "CI", |
| 8339 | "integration": "actions" |
| 8340 | } |
| 8341 | ], |
| 8342 | "strict": true, |
| 8343 | "paths": [], |
| 8344 | "allow_bypass_on_merge": false |
| 8345 | }, |
| 8346 | "applies_to": "everyone" |
| 8347 | }, |
| 8348 | { |
| 8349 | "type": "pull_request", |
| 8350 | "parameters": { |
| 8351 | "required_approvals": 1, |
| 8352 | "count_agent_approvals": false, |
| 8353 | "dismiss_stale_reviews_on_push": false, |
| 8354 | "require_code_owner_review": false, |
| 8355 | "require_last_push_approval": false, |
| 8356 | "allowed_merge_methods": [] |
| 8357 | }, |
| 8358 | "applies_to": "agents" |
| 8359 | }, |
| 8360 | { |
| 8361 | "type": "file_path_restriction", |
| 8362 | "parameters": { |
| 8363 | "restricted_file_paths": [ |
| 8364 | ".g1t/workflows/**", |
| 8365 | "CODEOWNERS" |
| 8366 | ] |
| 8367 | }, |
| 8368 | "applies_to": "agents" |
| 8369 | } |
| 8370 | ], |
| 8371 | "created_by": "syntaqx", |
| 8372 | "created_at": "2026-10-07T14:02:11.318Z", |
| 8373 | "updated_by": "syntaqx", |
| 8374 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 8375 | }, |
| 8376 | { |
| 8377 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 8378 | "level": "workspace", |
| 8379 | "workspace": "flagon-io", |
| 8380 | "name": "Release freeze", |
| 8381 | "enforcement": "evaluate", |
| 8382 | "target": "branch", |
| 8383 | "conditions": { |
| 8384 | "ref_name": { |
| 8385 | "include": [ |
| 8386 | "~DEFAULT_BRANCH", |
| 8387 | "release/**" |
| 8388 | ], |
| 8389 | "exclude": [] |
| 8390 | }, |
| 8391 | "repository": { |
| 8392 | "include": [ |
| 8393 | "~ALL" |
| 8394 | ], |
| 8395 | "exclude": [ |
| 8396 | "sandbox-*" |
| 8397 | ], |
| 8398 | "visibility": "any", |
| 8399 | "topics": [] |
| 8400 | } |
| 8401 | }, |
| 8402 | "bypass_actors": [ |
| 8403 | { |
| 8404 | "kind": "team", |
| 8405 | "value": "flagon-io/release", |
| 8406 | "mode": "always" |
| 8407 | } |
| 8408 | ], |
| 8409 | "rules": [ |
| 8410 | { |
| 8411 | "type": "merge_window", |
| 8412 | "parameters": { |
| 8413 | "time_zone": "-05:00", |
| 8414 | "windows": [ |
| 8415 | { |
| 8416 | "days": [ |
| 8417 | "mon", |
| 8418 | "tue", |
| 8419 | "wed", |
| 8420 | "thu" |
| 8421 | ], |
| 8422 | "start": "09:00", |
| 8423 | "end": "17:00" |
| 8424 | } |
| 8425 | ], |
| 8426 | "freezes": [ |
| 8427 | { |
| 8428 | "start": "2026-12-20T00:00:00Z", |
| 8429 | "end": "2027-01-04T00:00:00Z", |
| 8430 | "reason": "Holidays" |
| 8431 | } |
| 8432 | ], |
| 8433 | "exceptions": [] |
| 8434 | }, |
| 8435 | "applies_to": "everyone" |
| 8436 | }, |
| 8437 | { |
| 8438 | "type": "cost_cap", |
| 8439 | "parameters": { |
| 8440 | "max_usd": 25 |
| 8441 | }, |
| 8442 | "applies_to": "agents" |
| 8443 | } |
| 8444 | ], |
| 8445 | "created_by": "syntaqx", |
| 8446 | "created_at": "2026-10-07T14:02:11.318Z", |
| 8447 | "updated_by": "syntaqx", |
| 8448 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 8449 | } |
| 8450 | ], |
| 8451 | "notes": "With `include_parents`, the workspace's rulesets that hold in the repository come too, with `level` `workspace`. The ruleset made from the repository's branch protection settings has `source` `branch_protection`." |
| 8452 | }, |
| 8453 | "get_repo_ruleset": { |
| 8454 | "params": { |
| 8455 | "owner": "flagon-io", |
| 8456 | "name": "hello", |
| 8457 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m" |
| 8458 | }, |
| 8459 | "response": { |
| 8460 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8461 | "level": "repository", |
| 8462 | "workspace": "flagon-io", |
| 8463 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 8464 | "repository": "flagon-io/hello", |
| 8465 | "name": "Protect main", |
| 8466 | "enforcement": "active", |
| 8467 | "target": "branch", |
| 8468 | "conditions": { |
| 8469 | "ref_name": { |
| 8470 | "include": [ |
| 8471 | "~DEFAULT_BRANCH" |
| 8472 | ], |
| 8473 | "exclude": [] |
| 8474 | } |
| 8475 | }, |
| 8476 | "bypass_actors": [ |
| 8477 | { |
| 8478 | "kind": "role", |
| 8479 | "value": "admin", |
| 8480 | "mode": "pull_requests" |
| 8481 | } |
| 8482 | ], |
| 8483 | "rules": [ |
| 8484 | { |
| 8485 | "type": "deletion", |
| 8486 | "parameters": {}, |
| 8487 | "applies_to": "everyone" |
| 8488 | }, |
| 8489 | { |
| 8490 | "type": "non_fast_forward", |
| 8491 | "parameters": {}, |
| 8492 | "applies_to": "everyone" |
| 8493 | }, |
| 8494 | { |
| 8495 | "type": "pull_request", |
| 8496 | "parameters": { |
| 8497 | "required_approvals": 1, |
| 8498 | "count_agent_approvals": true, |
| 8499 | "dismiss_stale_reviews_on_push": true, |
| 8500 | "require_code_owner_review": true, |
| 8501 | "require_last_push_approval": false, |
| 8502 | "allowed_merge_methods": [] |
| 8503 | }, |
| 8504 | "applies_to": "everyone" |
| 8505 | }, |
| 8506 | { |
| 8507 | "type": "required_status_checks", |
| 8508 | "parameters": { |
| 8509 | "checks": [ |
| 8510 | { |
| 8511 | "context": "CI", |
| 8512 | "integration": "actions" |
| 8513 | } |
| 8514 | ], |
| 8515 | "strict": true, |
| 8516 | "paths": [], |
| 8517 | "allow_bypass_on_merge": false |
| 8518 | }, |
| 8519 | "applies_to": "everyone" |
| 8520 | }, |
| 8521 | { |
| 8522 | "type": "pull_request", |
| 8523 | "parameters": { |
| 8524 | "required_approvals": 1, |
| 8525 | "count_agent_approvals": false, |
| 8526 | "dismiss_stale_reviews_on_push": false, |
| 8527 | "require_code_owner_review": false, |
| 8528 | "require_last_push_approval": false, |
| 8529 | "allowed_merge_methods": [] |
| 8530 | }, |
| 8531 | "applies_to": "agents" |
| 8532 | }, |
| 8533 | { |
| 8534 | "type": "file_path_restriction", |
| 8535 | "parameters": { |
| 8536 | "restricted_file_paths": [ |
| 8537 | ".g1t/workflows/**", |
| 8538 | "CODEOWNERS" |
| 8539 | ] |
| 8540 | }, |
| 8541 | "applies_to": "agents" |
| 8542 | } |
| 8543 | ], |
| 8544 | "created_by": "syntaqx", |
| 8545 | "created_at": "2026-10-07T14:02:11.318Z", |
| 8546 | "updated_by": "syntaqx", |
| 8547 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 8548 | } |
| 8549 | }, |
| 8550 | "create_repo_ruleset": { |
| 8551 | "params": { |
| 8552 | "owner": "flagon-io", |
| 8553 | "name": "hello" |
| 8554 | }, |
| 8555 | "request": { |
| 8556 | "ruleset_name": "Protect main", |
| 8557 | "enforcement": "active", |
| 8558 | "target": "branch", |
| 8559 | "conditions": { |
| 8560 | "ref_name": { |
| 8561 | "include": [ |
| 8562 | "~DEFAULT_BRANCH" |
| 8563 | ], |
| 8564 | "exclude": [] |
| 8565 | } |
| 8566 | }, |
| 8567 | "bypass_actors": [ |
| 8568 | { |
| 8569 | "kind": "role", |
| 8570 | "value": "admin", |
| 8571 | "mode": "pull_requests" |
| 8572 | } |
| 8573 | ], |
| 8574 | "rules": [ |
| 8575 | { |
| 8576 | "type": "deletion", |
| 8577 | "parameters": {}, |
| 8578 | "applies_to": "everyone" |
| 8579 | }, |
| 8580 | { |
| 8581 | "type": "non_fast_forward", |
| 8582 | "parameters": {}, |
| 8583 | "applies_to": "everyone" |
| 8584 | }, |
| 8585 | { |
| 8586 | "type": "pull_request", |
| 8587 | "parameters": { |
| 8588 | "required_approvals": 1, |
| 8589 | "count_agent_approvals": true, |
| 8590 | "dismiss_stale_reviews_on_push": true, |
| 8591 | "require_code_owner_review": true, |
| 8592 | "require_last_push_approval": false, |
| 8593 | "allowed_merge_methods": [] |
| 8594 | }, |
| 8595 | "applies_to": "everyone" |
| 8596 | }, |
| 8597 | { |
| 8598 | "type": "required_status_checks", |
| 8599 | "parameters": { |
| 8600 | "checks": [ |
| 8601 | { |
| 8602 | "context": "CI", |
| 8603 | "integration": "actions" |
| 8604 | } |
| 8605 | ], |
| 8606 | "strict": true, |
| 8607 | "paths": [], |
| 8608 | "allow_bypass_on_merge": false |
| 8609 | }, |
| 8610 | "applies_to": "everyone" |
| 8611 | }, |
| 8612 | { |
| 8613 | "type": "pull_request", |
| 8614 | "parameters": { |
| 8615 | "required_approvals": 1, |
| 8616 | "count_agent_approvals": false, |
| 8617 | "dismiss_stale_reviews_on_push": false, |
| 8618 | "require_code_owner_review": false, |
| 8619 | "require_last_push_approval": false, |
| 8620 | "allowed_merge_methods": [] |
| 8621 | }, |
| 8622 | "applies_to": "agents" |
| 8623 | }, |
| 8624 | { |
| 8625 | "type": "file_path_restriction", |
| 8626 | "parameters": { |
| 8627 | "restricted_file_paths": [ |
| 8628 | ".g1t/workflows/**", |
| 8629 | "CODEOWNERS" |
| 8630 | ] |
| 8631 | }, |
| 8632 | "applies_to": "agents" |
| 8633 | } |
| 8634 | ] |
| 8635 | }, |
| 8636 | "response": { |
| 8637 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8638 | "level": "repository", |
| 8639 | "workspace": "flagon-io", |
| 8640 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 8641 | "repository": "flagon-io/hello", |
| 8642 | "name": "Protect main", |
| 8643 | "enforcement": "active", |
| 8644 | "target": "branch", |
| 8645 | "conditions": { |
| 8646 | "ref_name": { |
| 8647 | "include": [ |
| 8648 | "~DEFAULT_BRANCH" |
| 8649 | ], |
| 8650 | "exclude": [] |
| 8651 | } |
| 8652 | }, |
| 8653 | "bypass_actors": [ |
| 8654 | { |
| 8655 | "kind": "role", |
| 8656 | "value": "admin", |
| 8657 | "mode": "pull_requests" |
| 8658 | } |
| 8659 | ], |
| 8660 | "rules": [ |
| 8661 | { |
| 8662 | "type": "deletion", |
| 8663 | "parameters": {}, |
| 8664 | "applies_to": "everyone" |
| 8665 | }, |
| 8666 | { |
| 8667 | "type": "non_fast_forward", |
| 8668 | "parameters": {}, |
| 8669 | "applies_to": "everyone" |
| 8670 | }, |
| 8671 | { |
| 8672 | "type": "pull_request", |
| 8673 | "parameters": { |
| 8674 | "required_approvals": 1, |
| 8675 | "count_agent_approvals": true, |
| 8676 | "dismiss_stale_reviews_on_push": true, |
| 8677 | "require_code_owner_review": true, |
| 8678 | "require_last_push_approval": false, |
| 8679 | "allowed_merge_methods": [] |
| 8680 | }, |
| 8681 | "applies_to": "everyone" |
| 8682 | }, |
| 8683 | { |
| 8684 | "type": "required_status_checks", |
| 8685 | "parameters": { |
| 8686 | "checks": [ |
| 8687 | { |
| 8688 | "context": "CI", |
| 8689 | "integration": "actions" |
| 8690 | } |
| 8691 | ], |
| 8692 | "strict": true, |
| 8693 | "paths": [], |
| 8694 | "allow_bypass_on_merge": false |
| 8695 | }, |
| 8696 | "applies_to": "everyone" |
| 8697 | }, |
| 8698 | { |
| 8699 | "type": "pull_request", |
| 8700 | "parameters": { |
| 8701 | "required_approvals": 1, |
| 8702 | "count_agent_approvals": false, |
| 8703 | "dismiss_stale_reviews_on_push": false, |
| 8704 | "require_code_owner_review": false, |
| 8705 | "require_last_push_approval": false, |
| 8706 | "allowed_merge_methods": [] |
| 8707 | }, |
| 8708 | "applies_to": "agents" |
| 8709 | }, |
| 8710 | { |
| 8711 | "type": "file_path_restriction", |
| 8712 | "parameters": { |
| 8713 | "restricted_file_paths": [ |
| 8714 | ".g1t/workflows/**", |
| 8715 | "CODEOWNERS" |
| 8716 | ] |
| 8717 | }, |
| 8718 | "applies_to": "agents" |
| 8719 | } |
| 8720 | ], |
| 8721 | "created_by": "syntaqx", |
| 8722 | "created_at": "2026-10-07T14:02:11.318Z", |
| 8723 | "updated_by": "syntaqx", |
| 8724 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 8725 | }, |
| 8726 | "notes": "Parameters left out take their defaults, and the ruleset comes back as saved: patterns trimmed, roles and teams lowercased. A pattern that does not compile, or a rule the target cannot hold (a pull request rule on tags), is refused with `invalid` and says why." |
| 8727 | }, |
| 8728 | "update_repo_ruleset": { |
| 8729 | "params": { |
| 8730 | "owner": "flagon-io", |
| 8731 | "name": "hello", |
| 8732 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m" |
| 8733 | }, |
| 8734 | "request": { |
| 8735 | "enforcement": "evaluate" |
| 8736 | }, |
| 8737 | "response": { |
| 8738 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8739 | "level": "repository", |
| 8740 | "workspace": "flagon-io", |
| 8741 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 8742 | "repository": "flagon-io/hello", |
| 8743 | "name": "Protect main", |
| 8744 | "enforcement": "evaluate", |
| 8745 | "target": "branch", |
| 8746 | "conditions": { |
| 8747 | "ref_name": { |
| 8748 | "include": [ |
| 8749 | "~DEFAULT_BRANCH" |
| 8750 | ], |
| 8751 | "exclude": [] |
| 8752 | } |
| 8753 | }, |
| 8754 | "bypass_actors": [ |
| 8755 | { |
| 8756 | "kind": "role", |
| 8757 | "value": "admin", |
| 8758 | "mode": "pull_requests" |
| 8759 | } |
| 8760 | ], |
| 8761 | "rules": [ |
| 8762 | { |
| 8763 | "type": "deletion", |
| 8764 | "parameters": {}, |
| 8765 | "applies_to": "everyone" |
| 8766 | }, |
| 8767 | { |
| 8768 | "type": "non_fast_forward", |
| 8769 | "parameters": {}, |
| 8770 | "applies_to": "everyone" |
| 8771 | }, |
| 8772 | { |
| 8773 | "type": "pull_request", |
| 8774 | "parameters": { |
| 8775 | "required_approvals": 1, |
| 8776 | "count_agent_approvals": true, |
| 8777 | "dismiss_stale_reviews_on_push": true, |
| 8778 | "require_code_owner_review": true, |
| 8779 | "require_last_push_approval": false, |
| 8780 | "allowed_merge_methods": [] |
| 8781 | }, |
| 8782 | "applies_to": "everyone" |
| 8783 | }, |
| 8784 | { |
| 8785 | "type": "required_status_checks", |
| 8786 | "parameters": { |
| 8787 | "checks": [ |
| 8788 | { |
| 8789 | "context": "CI", |
| 8790 | "integration": "actions" |
| 8791 | } |
| 8792 | ], |
| 8793 | "strict": true, |
| 8794 | "paths": [], |
| 8795 | "allow_bypass_on_merge": false |
| 8796 | }, |
| 8797 | "applies_to": "everyone" |
| 8798 | }, |
| 8799 | { |
| 8800 | "type": "pull_request", |
| 8801 | "parameters": { |
| 8802 | "required_approvals": 1, |
| 8803 | "count_agent_approvals": false, |
| 8804 | "dismiss_stale_reviews_on_push": false, |
| 8805 | "require_code_owner_review": false, |
| 8806 | "require_last_push_approval": false, |
| 8807 | "allowed_merge_methods": [] |
| 8808 | }, |
| 8809 | "applies_to": "agents" |
| 8810 | }, |
| 8811 | { |
| 8812 | "type": "file_path_restriction", |
| 8813 | "parameters": { |
| 8814 | "restricted_file_paths": [ |
| 8815 | ".g1t/workflows/**", |
| 8816 | "CODEOWNERS" |
| 8817 | ] |
| 8818 | }, |
| 8819 | "applies_to": "agents" |
| 8820 | } |
| 8821 | ], |
| 8822 | "created_by": "syntaqx", |
| 8823 | "created_at": "2026-10-07T14:02:11.318Z", |
| 8824 | "updated_by": "syntaqx", |
| 8825 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 8826 | }, |
| 8827 | "notes": "Fields left out stay as they are. `rules` and `bypass_actors`, when given, replace the whole list." |
| 8828 | }, |
| 8829 | "delete_repo_ruleset": { |
| 8830 | "params": { |
| 8831 | "owner": "flagon-io", |
| 8832 | "name": "hello", |
| 8833 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m" |
| 8834 | }, |
| 8835 | "response": { |
| 8836 | "deleted": true |
| 8837 | } |
| 8838 | }, |
| 8839 | "get_branch_rules": { |
| 8840 | "params": { |
| 8841 | "owner": "flagon-io", |
| 8842 | "name": "hello", |
| 8843 | "branch": "main" |
| 8844 | }, |
| 8845 | "response": { |
| 8846 | "name": "main", |
| 8847 | "target": "branch", |
| 8848 | "default_branch": true, |
| 8849 | "rules": [ |
| 8850 | { |
| 8851 | "type": "deletion", |
| 8852 | "parameters": {}, |
| 8853 | "applies_to": "everyone", |
| 8854 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8855 | "ruleset_name": "Protect main", |
| 8856 | "level": "repository", |
| 8857 | "enforcement": "active" |
| 8858 | }, |
| 8859 | { |
| 8860 | "type": "non_fast_forward", |
| 8861 | "parameters": {}, |
| 8862 | "applies_to": "everyone", |
| 8863 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8864 | "ruleset_name": "Protect main", |
| 8865 | "level": "repository", |
| 8866 | "enforcement": "active" |
| 8867 | }, |
| 8868 | { |
| 8869 | "type": "pull_request", |
| 8870 | "parameters": { |
| 8871 | "required_approvals": 1, |
| 8872 | "count_agent_approvals": true, |
| 8873 | "dismiss_stale_reviews_on_push": true, |
| 8874 | "require_code_owner_review": true, |
| 8875 | "require_last_push_approval": false, |
| 8876 | "allowed_merge_methods": [] |
| 8877 | }, |
| 8878 | "applies_to": "everyone", |
| 8879 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8880 | "ruleset_name": "Protect main", |
| 8881 | "level": "repository", |
| 8882 | "enforcement": "active" |
| 8883 | }, |
| 8884 | { |
| 8885 | "type": "required_status_checks", |
| 8886 | "parameters": { |
| 8887 | "checks": [ |
| 8888 | { |
| 8889 | "context": "CI", |
| 8890 | "integration": "actions" |
| 8891 | } |
| 8892 | ], |
| 8893 | "strict": true, |
| 8894 | "paths": [], |
| 8895 | "allow_bypass_on_merge": false |
| 8896 | }, |
| 8897 | "applies_to": "everyone", |
| 8898 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8899 | "ruleset_name": "Protect main", |
| 8900 | "level": "repository", |
| 8901 | "enforcement": "active" |
| 8902 | }, |
| 8903 | { |
| 8904 | "type": "merge_window", |
| 8905 | "parameters": { |
| 8906 | "time_zone": "-05:00", |
| 8907 | "windows": [ |
| 8908 | { |
| 8909 | "days": [ |
| 8910 | "mon", |
| 8911 | "tue", |
| 8912 | "wed", |
| 8913 | "thu" |
| 8914 | ], |
| 8915 | "start": "09:00", |
| 8916 | "end": "17:00" |
| 8917 | } |
| 8918 | ], |
| 8919 | "freezes": [ |
| 8920 | { |
| 8921 | "start": "2026-12-20T00:00:00Z", |
| 8922 | "end": "2027-01-04T00:00:00Z", |
| 8923 | "reason": "Holidays" |
| 8924 | } |
| 8925 | ], |
| 8926 | "exceptions": [] |
| 8927 | }, |
| 8928 | "applies_to": "everyone", |
| 8929 | "ruleset_id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 8930 | "ruleset_name": "Release freeze", |
| 8931 | "level": "workspace", |
| 8932 | "enforcement": "evaluate" |
| 8933 | } |
| 8934 | ], |
| 8935 | "rulesets": [ |
| 8936 | { |
| 8937 | "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8938 | "name": "Protect main", |
| 8939 | "level": "repository", |
| 8940 | "enforcement": "active", |
| 8941 | "bypass_actors": [ |
| 8942 | { |
| 8943 | "kind": "role", |
| 8944 | "value": "admin", |
| 8945 | "mode": "pull_requests" |
| 8946 | } |
| 8947 | ] |
| 8948 | }, |
| 8949 | { |
| 8950 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 8951 | "name": "Release freeze", |
| 8952 | "level": "workspace", |
| 8953 | "enforcement": "evaluate", |
| 8954 | "bypass_actors": [ |
| 8955 | { |
| 8956 | "kind": "team", |
| 8957 | "value": "flagon-io/release", |
| 8958 | "mode": "always" |
| 8959 | } |
| 8960 | ] |
| 8961 | } |
| 8962 | ] |
| 8963 | }, |
| 8964 | "notes": "A branch with slashes in its name is URL-encoded as one segment: `/rules/branches/release%2F1.x`. Add `?target=tag` for a tag." |
| 8965 | }, |
| 8966 | "list_rule_evaluations": { |
| 8967 | "params": { |
| 8968 | "owner": "flagon-io", |
| 8969 | "name": "hello" |
| 8970 | }, |
| 8971 | "query": { |
| 8972 | "problems_only": "true" |
| 8973 | }, |
| 8974 | "response": { |
| 8975 | "evaluations": [ |
| 8976 | { |
| 8977 | "id": "rev_01kq3c4d5e6f7g8h9j0k1m2n3p", |
| 8978 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 8979 | "workspace": "flagon-io", |
| 8980 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8981 | "ruleset_name": "Protect main", |
| 8982 | "enforcement": "active", |
| 8983 | "action": "push", |
| 8984 | "git_ref": "refs/heads/main", |
| 8985 | "actor": "g1t", |
| 8986 | "actor_kind": "agent", |
| 8987 | "verdict": "fail", |
| 8988 | "violations": [ |
| 8989 | { |
| 8990 | "rule": "pull_request", |
| 8991 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 8992 | "ruleset_name": "Protect main", |
| 8993 | "enforcement": "active", |
| 8994 | "message": "Changes to main must be made through a pull request.", |
| 8995 | "remedy": "Push a branch, open a pull request into main, and merge it." |
| 8996 | } |
| 8997 | ], |
| 8998 | "number": null, |
| 8999 | "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e", |
| 9000 | "repository": "flagon-io/hello", |
| 9001 | "created_at": "2026-10-07T14:02:11.318Z" |
| 9002 | } |
| 9003 | ], |
| 9004 | "next": null, |
| 9005 | "insights": { |
| 9006 | "days": 30, |
| 9007 | "total": 214, |
| 9008 | "passed": 198, |
| 9009 | "blocked": 9, |
| 9010 | "would_block": 5, |
| 9011 | "bypassed": 2, |
| 9012 | "by_ruleset": [ |
| 9013 | { |
| 9014 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 9015 | "ruleset_name": "Protect main", |
| 9016 | "enforcement": "active", |
| 9017 | "total": 120, |
| 9018 | "blocked": 9, |
| 9019 | "would_block": 0, |
| 9020 | "bypassed": 2 |
| 9021 | } |
| 9022 | ], |
| 9023 | "by_rule": [ |
| 9024 | { |
| 9025 | "rule": "pull_request", |
| 9026 | "count": 7 |
| 9027 | }, |
| 9028 | { |
| 9029 | "rule": "non_fast_forward", |
| 9030 | "count": 2 |
| 9031 | } |
| 9032 | ] |
| 9033 | } |
| 9034 | }, |
| 9035 | "notes": "A `fail` of a ruleset in `evaluate` is what it would have refused. Pass `next` as `before` for the next page. `insights` counts the last 30 days." |
| 9036 | }, |
| 9037 | "list_workspace_rulesets": { |
| 9038 | "params": { |
| 9039 | "workspace": "flagon-io" |
| 9040 | }, |
| 9041 | "response": [ |
| 9042 | { |
| 9043 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 9044 | "level": "workspace", |
| 9045 | "workspace": "flagon-io", |
| 9046 | "name": "Release freeze", |
| 9047 | "enforcement": "evaluate", |
| 9048 | "target": "branch", |
| 9049 | "conditions": { |
| 9050 | "ref_name": { |
| 9051 | "include": [ |
| 9052 | "~DEFAULT_BRANCH", |
| 9053 | "release/**" |
| 9054 | ], |
| 9055 | "exclude": [] |
| 9056 | }, |
| 9057 | "repository": { |
| 9058 | "include": [ |
| 9059 | "~ALL" |
| 9060 | ], |
| 9061 | "exclude": [ |
| 9062 | "sandbox-*" |
| 9063 | ], |
| 9064 | "visibility": "any", |
| 9065 | "topics": [] |
| 9066 | } |
| 9067 | }, |
| 9068 | "bypass_actors": [ |
| 9069 | { |
| 9070 | "kind": "team", |
| 9071 | "value": "flagon-io/release", |
| 9072 | "mode": "always" |
| 9073 | } |
| 9074 | ], |
| 9075 | "rules": [ |
| 9076 | { |
| 9077 | "type": "merge_window", |
| 9078 | "parameters": { |
| 9079 | "time_zone": "-05:00", |
| 9080 | "windows": [ |
| 9081 | { |
| 9082 | "days": [ |
| 9083 | "mon", |
| 9084 | "tue", |
| 9085 | "wed", |
| 9086 | "thu" |
| 9087 | ], |
| 9088 | "start": "09:00", |
| 9089 | "end": "17:00" |
| 9090 | } |
| 9091 | ], |
| 9092 | "freezes": [ |
| 9093 | { |
| 9094 | "start": "2026-12-20T00:00:00Z", |
| 9095 | "end": "2027-01-04T00:00:00Z", |
| 9096 | "reason": "Holidays" |
| 9097 | } |
| 9098 | ], |
| 9099 | "exceptions": [] |
| 9100 | }, |
| 9101 | "applies_to": "everyone" |
| 9102 | }, |
| 9103 | { |
| 9104 | "type": "cost_cap", |
| 9105 | "parameters": { |
| 9106 | "max_usd": 25 |
| 9107 | }, |
| 9108 | "applies_to": "agents" |
| 9109 | } |
| 9110 | ], |
| 9111 | "created_by": "syntaqx", |
| 9112 | "created_at": "2026-10-07T14:02:11.318Z", |
| 9113 | "updated_by": "syntaqx", |
| 9114 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 9115 | } |
| 9116 | ] |
| 9117 | }, |
| 9118 | "get_workspace_ruleset": { |
| 9119 | "params": { |
| 9120 | "workspace": "flagon-io", |
| 9121 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n" |
| 9122 | }, |
| 9123 | "response": { |
| 9124 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 9125 | "level": "workspace", |
| 9126 | "workspace": "flagon-io", |
| 9127 | "name": "Release freeze", |
| 9128 | "enforcement": "evaluate", |
| 9129 | "target": "branch", |
| 9130 | "conditions": { |
| 9131 | "ref_name": { |
| 9132 | "include": [ |
| 9133 | "~DEFAULT_BRANCH", |
| 9134 | "release/**" |
| 9135 | ], |
| 9136 | "exclude": [] |
| 9137 | }, |
| 9138 | "repository": { |
| 9139 | "include": [ |
| 9140 | "~ALL" |
| 9141 | ], |
| 9142 | "exclude": [ |
| 9143 | "sandbox-*" |
| 9144 | ], |
| 9145 | "visibility": "any", |
| 9146 | "topics": [] |
| 9147 | } |
| 9148 | }, |
| 9149 | "bypass_actors": [ |
| 9150 | { |
| 9151 | "kind": "team", |
| 9152 | "value": "flagon-io/release", |
| 9153 | "mode": "always" |
| 9154 | } |
| 9155 | ], |
| 9156 | "rules": [ |
| 9157 | { |
| 9158 | "type": "merge_window", |
| 9159 | "parameters": { |
| 9160 | "time_zone": "-05:00", |
| 9161 | "windows": [ |
| 9162 | { |
| 9163 | "days": [ |
| 9164 | "mon", |
| 9165 | "tue", |
| 9166 | "wed", |
| 9167 | "thu" |
| 9168 | ], |
| 9169 | "start": "09:00", |
| 9170 | "end": "17:00" |
| 9171 | } |
| 9172 | ], |
| 9173 | "freezes": [ |
| 9174 | { |
| 9175 | "start": "2026-12-20T00:00:00Z", |
| 9176 | "end": "2027-01-04T00:00:00Z", |
| 9177 | "reason": "Holidays" |
| 9178 | } |
| 9179 | ], |
| 9180 | "exceptions": [] |
| 9181 | }, |
| 9182 | "applies_to": "everyone" |
| 9183 | }, |
| 9184 | { |
| 9185 | "type": "cost_cap", |
| 9186 | "parameters": { |
| 9187 | "max_usd": 25 |
| 9188 | }, |
| 9189 | "applies_to": "agents" |
| 9190 | } |
| 9191 | ], |
| 9192 | "created_by": "syntaqx", |
| 9193 | "created_at": "2026-10-07T14:02:11.318Z", |
| 9194 | "updated_by": "syntaqx", |
| 9195 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 9196 | } |
| 9197 | }, |
| 9198 | "create_workspace_ruleset": { |
| 9199 | "params": { |
| 9200 | "workspace": "flagon-io" |
| 9201 | }, |
| 9202 | "request": { |
| 9203 | "ruleset_name": "Release freeze", |
| 9204 | "enforcement": "evaluate", |
| 9205 | "target": "branch", |
| 9206 | "conditions": { |
| 9207 | "ref_name": { |
| 9208 | "include": [ |
| 9209 | "~DEFAULT_BRANCH", |
| 9210 | "release/**" |
| 9211 | ], |
| 9212 | "exclude": [] |
| 9213 | }, |
| 9214 | "repository": { |
| 9215 | "include": [ |
| 9216 | "~ALL" |
| 9217 | ], |
| 9218 | "exclude": [ |
| 9219 | "sandbox-*" |
| 9220 | ], |
| 9221 | "visibility": "any", |
| 9222 | "topics": [] |
| 9223 | } |
| 9224 | }, |
| 9225 | "bypass_actors": [ |
| 9226 | { |
| 9227 | "kind": "team", |
| 9228 | "value": "flagon-io/release", |
| 9229 | "mode": "always" |
| 9230 | } |
| 9231 | ], |
| 9232 | "rules": [ |
| 9233 | { |
| 9234 | "type": "merge_window", |
| 9235 | "parameters": { |
| 9236 | "time_zone": "-05:00", |
| 9237 | "windows": [ |
| 9238 | { |
| 9239 | "days": [ |
| 9240 | "mon", |
| 9241 | "tue", |
| 9242 | "wed", |
| 9243 | "thu" |
| 9244 | ], |
| 9245 | "start": "09:00", |
| 9246 | "end": "17:00" |
| 9247 | } |
| 9248 | ], |
| 9249 | "freezes": [ |
| 9250 | { |
| 9251 | "start": "2026-12-20T00:00:00Z", |
| 9252 | "end": "2027-01-04T00:00:00Z", |
| 9253 | "reason": "Holidays" |
| 9254 | } |
| 9255 | ], |
| 9256 | "exceptions": [] |
| 9257 | }, |
| 9258 | "applies_to": "everyone" |
| 9259 | }, |
| 9260 | { |
| 9261 | "type": "cost_cap", |
| 9262 | "parameters": { |
| 9263 | "max_usd": 25 |
| 9264 | }, |
| 9265 | "applies_to": "agents" |
| 9266 | } |
| 9267 | ] |
| 9268 | }, |
| 9269 | "response": { |
| 9270 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 9271 | "level": "workspace", |
| 9272 | "workspace": "flagon-io", |
| 9273 | "name": "Release freeze", |
| 9274 | "enforcement": "evaluate", |
| 9275 | "target": "branch", |
| 9276 | "conditions": { |
| 9277 | "ref_name": { |
| 9278 | "include": [ |
| 9279 | "~DEFAULT_BRANCH", |
| 9280 | "release/**" |
| 9281 | ], |
| 9282 | "exclude": [] |
| 9283 | }, |
| 9284 | "repository": { |
| 9285 | "include": [ |
| 9286 | "~ALL" |
| 9287 | ], |
| 9288 | "exclude": [ |
| 9289 | "sandbox-*" |
| 9290 | ], |
| 9291 | "visibility": "any", |
| 9292 | "topics": [] |
| 9293 | } |
| 9294 | }, |
| 9295 | "bypass_actors": [ |
| 9296 | { |
| 9297 | "kind": "team", |
| 9298 | "value": "flagon-io/release", |
| 9299 | "mode": "always" |
| 9300 | } |
| 9301 | ], |
| 9302 | "rules": [ |
| 9303 | { |
| 9304 | "type": "merge_window", |
| 9305 | "parameters": { |
| 9306 | "time_zone": "-05:00", |
| 9307 | "windows": [ |
| 9308 | { |
| 9309 | "days": [ |
| 9310 | "mon", |
| 9311 | "tue", |
| 9312 | "wed", |
| 9313 | "thu" |
| 9314 | ], |
| 9315 | "start": "09:00", |
| 9316 | "end": "17:00" |
| 9317 | } |
| 9318 | ], |
| 9319 | "freezes": [ |
| 9320 | { |
| 9321 | "start": "2026-12-20T00:00:00Z", |
| 9322 | "end": "2027-01-04T00:00:00Z", |
| 9323 | "reason": "Holidays" |
| 9324 | } |
| 9325 | ], |
| 9326 | "exceptions": [] |
| 9327 | }, |
| 9328 | "applies_to": "everyone" |
| 9329 | }, |
| 9330 | { |
| 9331 | "type": "cost_cap", |
| 9332 | "parameters": { |
| 9333 | "max_usd": 25 |
| 9334 | }, |
| 9335 | "applies_to": "agents" |
| 9336 | } |
| 9337 | ], |
| 9338 | "created_by": "syntaqx", |
| 9339 | "created_at": "2026-10-07T14:02:11.318Z", |
| 9340 | "updated_by": "syntaqx", |
| 9341 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 9342 | }, |
| 9343 | "notes": "`conditions.repository` chooses the repositories it holds in; left out, every repository of the workspace." |
| 9344 | }, |
| 9345 | "update_workspace_ruleset": { |
| 9346 | "params": { |
| 9347 | "workspace": "flagon-io", |
| 9348 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n" |
| 9349 | }, |
| 9350 | "request": { |
| 9351 | "enforcement": "active" |
| 9352 | }, |
| 9353 | "response": { |
| 9354 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n", |
| 9355 | "level": "workspace", |
| 9356 | "workspace": "flagon-io", |
| 9357 | "name": "Release freeze", |
| 9358 | "enforcement": "active", |
| 9359 | "target": "branch", |
| 9360 | "conditions": { |
| 9361 | "ref_name": { |
| 9362 | "include": [ |
| 9363 | "~DEFAULT_BRANCH", |
| 9364 | "release/**" |
| 9365 | ], |
| 9366 | "exclude": [] |
| 9367 | }, |
| 9368 | "repository": { |
| 9369 | "include": [ |
| 9370 | "~ALL" |
| 9371 | ], |
| 9372 | "exclude": [ |
| 9373 | "sandbox-*" |
| 9374 | ], |
| 9375 | "visibility": "any", |
| 9376 | "topics": [] |
| 9377 | } |
| 9378 | }, |
| 9379 | "bypass_actors": [ |
| 9380 | { |
| 9381 | "kind": "team", |
| 9382 | "value": "flagon-io/release", |
| 9383 | "mode": "always" |
| 9384 | } |
| 9385 | ], |
| 9386 | "rules": [ |
| 9387 | { |
| 9388 | "type": "merge_window", |
| 9389 | "parameters": { |
| 9390 | "time_zone": "-05:00", |
| 9391 | "windows": [ |
| 9392 | { |
| 9393 | "days": [ |
| 9394 | "mon", |
| 9395 | "tue", |
| 9396 | "wed", |
| 9397 | "thu" |
| 9398 | ], |
| 9399 | "start": "09:00", |
| 9400 | "end": "17:00" |
| 9401 | } |
| 9402 | ], |
| 9403 | "freezes": [ |
| 9404 | { |
| 9405 | "start": "2026-12-20T00:00:00Z", |
| 9406 | "end": "2027-01-04T00:00:00Z", |
| 9407 | "reason": "Holidays" |
| 9408 | } |
| 9409 | ], |
| 9410 | "exceptions": [] |
| 9411 | }, |
| 9412 | "applies_to": "everyone" |
| 9413 | }, |
| 9414 | { |
| 9415 | "type": "cost_cap", |
| 9416 | "parameters": { |
| 9417 | "max_usd": 25 |
| 9418 | }, |
| 9419 | "applies_to": "agents" |
| 9420 | } |
| 9421 | ], |
| 9422 | "created_by": "syntaqx", |
| 9423 | "created_at": "2026-10-07T14:02:11.318Z", |
| 9424 | "updated_by": "syntaqx", |
| 9425 | "updated_at": "2026-10-07T14:02:11.318Z" |
| 9426 | } |
| 9427 | }, |
| 9428 | "delete_workspace_ruleset": { |
| 9429 | "params": { |
| 9430 | "workspace": "flagon-io", |
| 9431 | "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n" |
| 9432 | }, |
| 9433 | "response": { |
| 9434 | "deleted": true |
| 9435 | } |
| 9436 | }, |
| 9437 | "list_workspace_rule_evaluations": { |
| 9438 | "params": { |
| 9439 | "workspace": "flagon-io" |
| 9440 | }, |
| 9441 | "response": { |
| 9442 | "evaluations": [ |
| 9443 | { |
| 9444 | "id": "rev_01kq3c4d5e6f7g8h9j0k1m2n3p", |
| 9445 | "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k", |
| 9446 | "workspace": "flagon-io", |
| 9447 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 9448 | "ruleset_name": "Protect main", |
| 9449 | "enforcement": "active", |
| 9450 | "action": "push", |
| 9451 | "git_ref": "refs/heads/main", |
| 9452 | "actor": "g1t", |
| 9453 | "actor_kind": "agent", |
| 9454 | "verdict": "fail", |
| 9455 | "violations": [ |
| 9456 | { |
| 9457 | "rule": "pull_request", |
| 9458 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 9459 | "ruleset_name": "Protect main", |
| 9460 | "enforcement": "active", |
| 9461 | "message": "Changes to main must be made through a pull request.", |
| 9462 | "remedy": "Push a branch, open a pull request into main, and merge it." |
| 9463 | } |
| 9464 | ], |
| 9465 | "number": null, |
| 9466 | "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e", |
| 9467 | "repository": "flagon-io/hello", |
| 9468 | "created_at": "2026-10-07T14:02:11.318Z" |
| 9469 | } |
| 9470 | ], |
| 9471 | "next": null, |
| 9472 | "insights": { |
| 9473 | "days": 30, |
| 9474 | "total": 214, |
| 9475 | "passed": 198, |
| 9476 | "blocked": 9, |
| 9477 | "would_block": 5, |
| 9478 | "bypassed": 2, |
| 9479 | "by_ruleset": [ |
| 9480 | { |
| 9481 | "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m", |
| 9482 | "ruleset_name": "Protect main", |
| 9483 | "enforcement": "active", |
| 9484 | "total": 120, |
| 9485 | "blocked": 9, |
| 9486 | "would_block": 0, |
| 9487 | "bypassed": 2 |
| 9488 | } |
| 9489 | ], |
| 9490 | "by_rule": [ |
| 9491 | { |
| 9492 | "rule": "pull_request", |
| 9493 | "count": 7 |
| 9494 | }, |
| 9495 | { |
| 9496 | "rule": "non_fast_forward", |
| 9497 | "count": 2 |
| 9498 | } |
| 9499 | ] |
| 9500 | } |
| 9501 | } |
| 9502 | } |
| 9503 | } |