Skip to content

Where people and agents ship software together. The open-source git platform for the whole job: issues, agents, checks and deploys to the edge.

g1t.sh
15,152 linesCodeBlameRaw
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 "display_username": "syntaqx",
24 "verified": true
25 }
26 },
27 "whoami": {
28 "response": {
29 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
30 "username": "syntaqx",
31 "display_username": "syntaqx",
32 "kind": "user",
33 "verified": true,
34 "workspaces": [
35 {
36 "slug": "acme",
37 "role": "member",
38 "base_permission": "write"
39 },
40 {
41 "slug": "flagon-io",
42 "role": "owner",
43 "base_permission": "write"
44 }
45 ],
46 "token": {
47 "token_id": "tok_01kkntd3p2v8x6ym5r0c1q7a9e",
48 "scopes": [
49 "repo:read",
50 "issues:read",
51 "issues:write",
52 "pull_requests:read",
53 "pull_requests:write"
54 ]
55 }
56 },
57 "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/)."
58 },
59 "create_workspace": {
60 "request": {
61 "slug": "acme-labs",
62 "name": "Acme Labs"
63 },
64 "response": {
65 "id": "wsp_01m43teqa9em6bje0bhvdj4jkb",
66 "slug": "acme-labs",
67 "name": "Acme Labs",
68 "description": null,
69 "created_at": "2026-10-04T16:02:51.337Z",
70 "member_count": 1,
71 "base_permission": "read",
72 "team_creation": "members",
73 "members_can_create_public_repositories": true,
74 "members_can_create_private_repositories": true,
75 "members_can_change_repo_visibility": true,
76 "members_can_delete_repositories": false,
77 "members_can_invite_outside_collaborators": true,
78 "two_factor_requirement_enabled": false
79 },
80 "notes": "`base_permission` is what every member gets on each of its repositories: `read` for a new workspace 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)."
81 },
82 "get_workspace": {
83 "params": {
84 "workspace": "acme-labs"
85 },
86 "response": {
87 "id": "wsp_01m43teqa9em6bje0bhvdj4jkb",
88 "slug": "acme-labs",
89 "name": "Acme Labs",
90 "description": "Rockets, and the software that flies them.",
91 "created_at": "2026-10-04T16:02:51.337Z",
92 "member_count": 3,
93 "base_permission": "write",
94 "team_creation": "members",
95 "members_can_create_public_repositories": true,
96 "members_can_create_private_repositories": true,
97 "members_can_change_repo_visibility": true,
98 "members_can_delete_repositories": false,
99 "members_can_invite_outside_collaborators": true,
100 "two_factor_requirement_enabled": false
101 },
102 "notes": "`team_creation` is who may create its teams: `members` (any member, the default) or `owners`. The `members_can_…` fields are its [member privileges](/guides/workspaces/#member-privileges), and `two_factor_requirement_enabled` whether it [requires two-factor authentication](/guides/authentication/#require-two-factor-authentication). 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/)."
103 },
104 "update_workspace": {
105 "params": {
106 "workspace": "acme-labs"
107 },
108 "request": {
109 "name": "Acme Labs",
110 "description": "Rockets, and the software that flies them.",
111 "team_creation": "owners",
112 "members_can_delete_repositories": true
113 },
114 "response": {
115 "id": "wsp_01m43teqa9em6bje0bhvdj4jkb",
116 "slug": "acme-labs",
117 "name": "Acme Labs",
118 "description": "Rockets, and the software that flies them.",
119 "created_at": "2026-10-04T16:02:51.337Z",
120 "member_count": 3,
121 "base_permission": "write",
122 "team_creation": "owners",
123 "members_can_create_public_repositories": true,
124 "members_can_create_private_repositories": true,
125 "members_can_change_repo_visibility": true,
126 "members_can_delete_repositories": true,
127 "members_can_invite_outside_collaborators": true,
128 "two_factor_requirement_enabled": false
129 },
130 "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. The `members_can_…` fields are the workspace's member privileges: who may create public and private repositories, and whether members with the Admin role on a repository may change its visibility, delete or transfer it, and invite outside collaborators. `two_factor_requirement_enabled` holds everyone without two-factor authentication out of the workspace until they turn it on, and needs it on your own account first. 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/)."
131 },
132 "list_members": {
133 "params": {
134 "workspace": "acme-labs"
135 },
136 "response": [
137 {
138 "username": "ada",
139 "display_username": "Ada",
140 "role": "owner",
141 "org_roles": [],
142 "two_factor": true,
143 "name": "Ada Lovelace",
144 "avatar": null
145 },
146 {
147 "username": "grace",
148 "display_username": "grace",
149 "role": "member",
150 "org_roles": [
151 "security_manager"
152 ],
153 "two_factor": false,
154 "name": "Grace Hopper",
155 "avatar": null
156 }
157 ],
158 "notes": "Owners first, then by username. `two_factor` is shown to owners only, and is `null` for anyone else. `403` for anyone who is not a member. See [Workspaces](/guides/workspaces/#members-and-owners)."
159 },
160 "update_member": {
161 "params": {
162 "workspace": "acme-labs",
163 "username": "grace"
164 },
165 "request": {
166 "role": "member",
167 "org_roles": [
168 "security_manager"
169 ]
170 },
171 "response": {
172 "username": "grace",
173 "display_username": "grace",
174 "role": "member",
175 "org_roles": [
176 "security_manager"
177 ],
178 "two_factor": null,
179 "name": "Grace Hopper",
180 "avatar": null
181 },
182 "notes": "Only the fields given change; `org_roles` replaces the list. `409` when it would leave the workspace without an owner. Refused with `403` for anyone but an owner signed in as a person. Recorded in the [audit log](/guides/audit-log/) as `member.role_changed`, `member.org_role_added` or `member.org_role_removed`. See [Workspaces](/guides/workspaces/#members-and-owners)."
183 },
184 "remove_member": {
185 "params": {
186 "workspace": "acme-labs",
187 "username": "grace"
188 },
189 "response": true,
190 "notes": "Their roles on the workspace's repositories and their place in its teams go with them. Your own username is leaving, as [`leave_workspace`](/reference/api/members/leave-workspace/). `409` for the last owner. Recorded as `member.removed`."
191 },
192 "transfer_ownership": {
193 "params": {
194 "workspace": "acme-labs"
195 },
196 "request": {
197 "username": "grace"
198 },
199 "response": true,
200 "notes": "`username` becomes an owner and you a member, in one step. Recorded as `workspace.ownership_transferred`."
201 },
202 "leave_workspace": {
203 "params": {
204 "workspace": "acme-labs"
205 },
206 "response": true,
207 "notes": "`409` for the last owner: make another member an owner first, or delete the workspace. Recorded as `member.left`."
208 },
209 "delete_workspace": {
210 "request": {
211 "confirm": "acme-labs"
212 },
213 "response": true,
214 "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)."
215 },
216 "list_emails": {
217 "response": {
218 "emails": [
219 {
220 "email": "ada@example.com",
221 "verified": true,
222 "primary": true,
223 "backup": false,
224 "created_at": "2026-09-01T10:00:00.000Z",
225 "verified_at": "2026-09-01T10:02:11.000Z"
226 },
227 {
228 "email": "ada@acme.com",
229 "verified": true,
230 "primary": false,
231 "backup": true,
232 "created_at": "2026-10-02T09:30:00.000Z",
233 "verified_at": "2026-10-02T09:31:40.000Z"
234 },
235 {
236 "email": "ada.l@example.org",
237 "verified": false,
238 "primary": false,
239 "backup": false,
240 "created_at": "2026-10-05T14:12:03.000Z",
241 "verified_at": null
242 }
243 ],
244 "private_email": true,
245 "block_private_pushes": false,
246 "noreply": "6c1d0efg+ada@users.noreply.g1t.sh",
247 "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh",
248 "limit": 10
249 },
250 "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)."
251 },
252 "add_email": {
253 "request": {
254 "email": "ada.l@example.org",
255 "password": "…"
256 },
257 "response": {
258 "emails": [
259 {
260 "email": "ada@example.com",
261 "verified": true,
262 "primary": true,
263 "backup": false,
264 "created_at": "2026-09-01T10:00:00.000Z",
265 "verified_at": "2026-09-01T10:02:11.000Z"
266 },
267 {
268 "email": "ada@acme.com",
269 "verified": true,
270 "primary": false,
271 "backup": true,
272 "created_at": "2026-10-02T09:30:00.000Z",
273 "verified_at": "2026-10-02T09:31:40.000Z"
274 },
275 {
276 "email": "ada.l@example.org",
277 "verified": false,
278 "primary": false,
279 "backup": false,
280 "created_at": "2026-10-05T14:12:03.000Z",
281 "verified_at": null
282 }
283 ],
284 "private_email": true,
285 "block_private_pushes": false,
286 "noreply": "6c1d0efg+ada@users.noreply.g1t.sh",
287 "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh",
288 "limit": 10
289 },
290 "notes": "Answers `403` with code `reauth_required` when `password` is missing or wrong, and `409` when another account has confirmed the address. g1t emails the address a six-digit code and a link; it stays unconfirmed until the code is sent to [`confirm_email`](/reference/api/accounts/confirm-email/) or the link is followed."
291 },
292 "confirm_email": {
293 "request": {
294 "code": "482913"
295 },
296 "response": {
297 "username": "ada",
298 "display_username": "Ada",
299 "email": "ada@example.com",
300 "verified": true,
301 "joined": null,
302 "invited_to": "acme",
303 "invite_lapsed": null
304 },
305 "notes": "The code confirms the address it was sent to, and ends the link sent with it. A wrong, used or expired code answers `422` with one message for all three; after ten wrong codes in an hour the account answers `409` for a while, and the link in the email still works. `verified` says whether the account is confirmed: whether its primary address is. `invited_to` is set when the invite the account signed up with brings it into a workspace: confirming the address sends the account an invitation to that workspace, which it accepts with `POST /user/invitations/{id}/accept` or declines; nobody joins a workspace without saying yes. `joined` is kept for older clients and is null. When the invite was revoked or expired, or the workspace deleted, while the account waited, the address is confirmed all the same and `invite_lapsed` says so. See [Confirming your email address](/guides/authentication/#confirming-your-email-address)."
306 },
307 "remove_email": {
308 "request": {
309 "password": "…"
310 },
311 "response": {
312 "emails": [
313 {
314 "email": "ada@example.com",
315 "verified": true,
316 "primary": true,
317 "backup": false,
318 "created_at": "2026-09-01T10:00:00.000Z",
319 "verified_at": "2026-09-01T10:02:11.000Z"
320 },
321 {
322 "email": "ada@acme.com",
323 "verified": true,
324 "primary": false,
325 "backup": true,
326 "created_at": "2026-10-02T09:30:00.000Z",
327 "verified_at": "2026-10-02T09:31:40.000Z"
328 },
329 {
330 "email": "ada.l@example.org",
331 "verified": false,
332 "primary": false,
333 "backup": false,
334 "created_at": "2026-10-05T14:12:03.000Z",
335 "verified_at": null
336 }
337 ],
338 "private_email": true,
339 "block_private_pushes": false,
340 "noreply": "6c1d0efg+ada@users.noreply.g1t.sh",
341 "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh",
342 "limit": 10
343 },
344 "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."
345 },
346 "update_email_settings": {
347 "request": {
348 "primary": "ada@acme.com",
349 "password": "…"
350 },
351 "response": {
352 "emails": [
353 {
354 "email": "ada@example.com",
355 "verified": true,
356 "primary": true,
357 "backup": false,
358 "created_at": "2026-09-01T10:00:00.000Z",
359 "verified_at": "2026-09-01T10:02:11.000Z"
360 },
361 {
362 "email": "ada@acme.com",
363 "verified": true,
364 "primary": false,
365 "backup": true,
366 "created_at": "2026-10-02T09:30:00.000Z",
367 "verified_at": "2026-10-02T09:31:40.000Z"
368 },
369 {
370 "email": "ada.l@example.org",
371 "verified": false,
372 "primary": false,
373 "backup": false,
374 "created_at": "2026-10-05T14:12:03.000Z",
375 "verified_at": null
376 }
377 ],
378 "private_email": true,
379 "block_private_pushes": false,
380 "noreply": "6c1d0efg+ada@users.noreply.g1t.sh",
381 "commit_email": "6c1d0efg+ada@users.noreply.g1t.sh",
382 "limit": 10
383 },
384 "notes": "Only the fields given change. `primary` and `backup` need `password`; `private_email` and `block_private_pushes` do not."
385 },
386 "list_invites": {
387 "response": {
388 "allowance": {
389 "limit": 20,
390 "used": 2,
391 "remaining": 18
392 },
393 "invites": [
394 {
395 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
396 "code": "g1t-k7m2-q9xd-4hpw-…",
397 "hint": "g1t-k7m2",
398 "email": "ada@example.com",
399 "kind": "account",
400 "workspace": null,
401 "status": "pending",
402 "charged_to": "user",
403 "invited_by": "syntaqx",
404 "redeemed_by": null,
405 "created_at": "2026-10-05T17:00:00.000Z",
406 "expires_at": "2026-11-04T17:00:00.000Z",
407 "redeemed_at": null,
408 "revoked_at": null,
409 "invitee": null,
410 "role": null
411 },
412 {
413 "id": "inv_01kp1v3c4d5e6f7g8h9j0k1m2n",
414 "code": null,
415 "hint": "g1t-p3rt",
416 "email": "grace@example.com",
417 "kind": "account",
418 "workspace": null,
419 "status": "redeemed",
420 "charged_to": "user",
421 "invited_by": "syntaqx",
422 "redeemed_by": "grace",
423 "created_at": "2026-10-02T09:12:40.000Z",
424 "expires_at": "2026-11-01T09:12:40.000Z",
425 "redeemed_at": "2026-10-02T11:30:05.000Z",
426 "revoked_at": null,
427 "invitee": "grace",
428 "role": null
429 }
430 ]
431 },
432 "notes": "Anyone can sign up for g1t without an invite. A revoked or expired invite that was never used is not counted, so it comes back; a used one stays spent. `status` is `pending`, `awaiting_confirmation`, `awaiting_answer` (the account it made has yet to accept or decline the workspace in `workspace`), `redeemed` (they joined, as `redeemed_by`), `declined`, `expired` or `revoked`. See [Invite a friend](/guides/authentication/#invite-a-friend)."
433 },
434 "create_invite": {
435 "request": {
436 "email": "ada@example.com",
437 "message": "This is where we keep the compiler now. Come and look."
438 },
439 "response": {
440 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
441 "code": "g1t-k7m2-q9xd-4hpw-…",
442 "hint": "g1t-k7m2",
443 "email": "ada@example.com",
444 "kind": "account",
445 "workspace": null,
446 "status": "pending",
447 "charged_to": "user",
448 "invited_by": "syntaqx",
449 "redeemed_by": null,
450 "created_at": "2026-10-05T17:00:00.000Z",
451 "expires_at": "2026-11-04T17:00:00.000Z",
452 "redeemed_at": null,
453 "revoked_at": null,
454 "invitee": null,
455 "role": null
456 },
457 "notes": "The code is returned in full; the email g1t sends carries a link to `https://g1t.sh/invite/<code>` that opens sign-up with the address filled in and confirmed. Add `workspace` (and `role`) to also invite them to a workspace you own on a paid plan: once their account is confirmed they accept or decline it, and no workspace of their own is made. A free workspace is refused with `402` (`payment_required`). Refused with `409` when the address already has a g1t account or you already have a pending invite for it, neither of which uses an invite; with `402` (`limit`) when you have none left; and with `403` for an agent's or a workspace's token, or before your own address is confirmed."
458 },
459 "revoke_invite": {
460 "response": {
461 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
462 "code": null,
463 "hint": "g1t-k7m2",
464 "email": "ada@example.com",
465 "kind": "account",
466 "workspace": null,
467 "status": "revoked",
468 "charged_to": "user",
469 "invited_by": "syntaqx",
470 "redeemed_by": null,
471 "created_at": "2026-10-05T17:00:00.000Z",
472 "expires_at": "2026-11-04T17:00:00.000Z",
473 "redeemed_at": null,
474 "revoked_at": "2026-10-06T08:00:00.000Z",
475 "invitee": null,
476 "role": null
477 },
478 "notes": "The invite comes back to you. One already used to make an account cannot be revoked and stays spent."
479 },
480 "resend_invite": {
481 "response": {
482 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
483 "code": "g1t-k7m2-q9xd-4hpw-…",
484 "hint": "g1t-k7m2",
485 "email": "ada@example.com",
486 "kind": "account",
487 "workspace": null,
488 "status": "pending",
489 "charged_to": "user",
490 "invited_by": "syntaqx",
491 "redeemed_by": null,
492 "created_at": "2026-10-05T17:00:00.000Z",
493 "expires_at": "2026-11-04T17:00:00.000Z",
494 "redeemed_at": null,
495 "revoked_at": null,
496 "invitee": null,
497 "role": null
498 },
499 "notes": "Sends the same email again, with the same link; when it stops working does not change. Refused with `409` unless it is pending."
500 },
501 "list_workspace_invites": {
502 "response": [
503 {
504 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
505 "code": "g1t-k7m2-q9xd-4hpw-…",
506 "hint": "g1t-k7m2",
507 "email": "ada@example.com",
508 "kind": "account",
509 "workspace": "acme-labs",
510 "status": "pending",
511 "charged_to": "none",
512 "invited_by": "syntaqx",
513 "redeemed_by": null,
514 "created_at": "2026-10-05T17:00:00.000Z",
515 "expires_at": "2026-11-04T17:00:00.000Z",
516 "redeemed_at": null,
517 "revoked_at": null,
518 "invitee": null,
519 "role": "member"
520 },
521 {
522 "id": "inv_01kp1z9y8x7w6v5t4s3r2q1p0n",
523 "code": "g1t-k7m2-q9xd-4hpw-…",
524 "hint": "g1t-w2vb",
525 "email": null,
526 "kind": "workspace",
527 "workspace": "acme-labs",
528 "status": "pending",
529 "charged_to": "none",
530 "invited_by": "syntaqx",
531 "redeemed_by": null,
532 "created_at": "2026-10-05T17:00:00.000Z",
533 "expires_at": "2026-11-04T17:00:00.000Z",
534 "redeemed_at": null,
535 "revoked_at": null,
536 "invitee": "linus",
537 "role": "owner"
538 }
539 ]
540 },
541 "invite_member": {
542 "request": {
543 "username": "ada",
544 "role": "member"
545 },
546 "response": {
547 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
548 "code": "g1t-k7m2-q9xd-4hpw-…",
549 "hint": "g1t-k7m2",
550 "email": null,
551 "kind": "workspace",
552 "workspace": "acme-labs",
553 "status": "pending",
554 "charged_to": "none",
555 "invited_by": "syntaqx",
556 "redeemed_by": null,
557 "created_at": "2026-10-05T17:00:00.000Z",
558 "expires_at": "2026-11-04T17:00:00.000Z",
559 "redeemed_at": null,
560 "revoked_at": null,
561 "invitee": "ada",
562 "role": "member"
563 },
564 "notes": "Give `username` or `email`. Nobody is added without saying yes: the person gets an invitation to accept or decline, and joins with `role` when they accept. By username, `invitee` names the account and it costs nothing; `404` when there is no account with that username. By email, `kind` is `workspace` when the address already has a g1t account (`charged_to` is then `none`), and `account` when the link makes one; both answers look alike to the caller on purpose, and `invitee` stays null until an account is known. `409` when the person is already a member or already has a pending invitation to the workspace. A free workspace cannot invite anyone: `402` with `payment_required`, until it starts the g1t plan. See [Workspace invitations](/reference/api/invites/list-invitations/) for the other side."
565 },
566 "revoke_workspace_invite": {
567 "response": {
568 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
569 "code": null,
570 "hint": "g1t-k7m2",
571 "email": "ada@example.com",
572 "kind": "account",
573 "workspace": "acme-labs",
574 "status": "revoked",
575 "charged_to": "none",
576 "invited_by": "syntaqx",
577 "redeemed_by": null,
578 "created_at": "2026-10-05T17:00:00.000Z",
579 "expires_at": "2026-11-04T17:00:00.000Z",
580 "redeemed_at": null,
581 "revoked_at": "2026-10-06T08:00:00.000Z",
582 "invitee": null,
583 "role": "member"
584 }
585 },
586 "list_invitations": {
587 "response": [
588 {
589 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y",
590 "workspace": {
591 "slug": "acme-labs",
592 "name": "Acme Labs",
593 "avatar": null
594 },
595 "role": "member",
596 "invited_by": {
597 "username": "syntaqx",
598 "display_username": "syntaqx",
599 "name": "Chase",
600 "avatar": null
601 },
602 "created_at": "2026-10-05T17:00:00.000Z",
603 "expires_at": "2026-11-04T17:00:00.000Z"
604 }
605 ],
606 "notes": "Accept one with `POST /user/invitations/{id}/accept`, or decline it with `POST /user/invitations/{id}/decline`. An agent's or a workspace's token gets an empty list."
607 },
608 "accept_invitation": {
609 "params": {
610 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y"
611 },
612 "response": {
613 "workspace": "acme-labs"
614 },
615 "notes": "You join at once with the invitation's `role`. `404` when you have no open invitation with that id (it may have been answered, revoked or expired). `403` until you confirm your email address, and when your account does not meet what the workspace asks of its members, such as two-factor authentication, with a message that says what to turn on. `402` with `payment_required` while the workspace is on the free plan; the invitation stays open until it starts the g1t plan. Recorded as `member.added`."
616 },
617 "decline_invitation": {
618 "params": {
619 "id": "inv_01kp2x7m8n9q0r1s2t3v4w5x6y"
620 },
621 "response": true,
622 "notes": "Whoever sent it is told in their inbox. The workspace's owners can invite you again. `404` when you have no open invitation with that id."
623 },
624 "list_repos": {
625 "query": {
626 "q": "hello"
627 },
628 "response": [
629 {
630 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
631 "namespace": "flagon-io",
632 "name": "hello",
633 "is_private": false,
634 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
635 "default_branch": "main",
636 "fork_of": null,
637 "protected": true,
638 "created_at": "2026-09-28T14:11:52.640Z",
639 "website": "https://hello.g1t.page",
640 "archived_at": null
641 }
642 ],
643 "notes": "Returns at most 50 repositories, newest first. Forks made for pull requests are left out."
644 },
645 "create_repo": {
646 "request": {
647 "workspace": "flagon-io",
648 "name": "hello-cli",
649 "description": "Command-line client for hello.",
650 "private": false
651 },
652 "response": {
653 "id": "rep_01m43tk1jhehztx23drs87f5fc",
654 "namespace": "flagon-io",
655 "name": "hello-cli",
656 "is_private": false,
657 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
658 "default_branch": "main",
659 "fork_of": null,
660 "protected": false,
661 "created_at": "2026-10-04T16:05:12.913Z",
662 "website": "https://hello.g1t.page",
663 "archived_at": null
664 },
665 "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. With `deploy: true`, its project's [Deployments](/guides/deployments/) are turned on once it is made, as [`update_deployment_settings`](/reference/api/deployments/update-deployment-settings/) with `enabled: true` does, and the response adds `deployments` (those settings, with `production_url`) and `deploy_error` (null). When they cannot be turned on (the workspace has no g1t plan, or your role there is below Admin) the repository is still made: `deployments` is null and `deploy_error` says why, and they can be turned on later. Turning them on here needs no scope beyond `repo:create`: you are the new repository's admin."
666 },
667 "get_repo": {
668 "response": {
669 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
670 "namespace": "flagon-io",
671 "name": "hello",
672 "is_private": false,
673 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
674 "default_branch": "main",
675 "fork_of": null,
676 "protected": true,
677 "created_at": "2026-09-28T14:11:52.640Z",
678 "website": "https://hello.g1t.page",
679 "archived_at": null
680 }
681 },
682 "update_repo": {
683 "request": {
684 "website": "hello.g1t.page",
685 "default_branch": "trunk",
686 "protected": true
687 },
688 "response": {
689 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
690 "namespace": "flagon-io",
691 "name": "hello",
692 "is_private": false,
693 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
694 "default_branch": "trunk",
695 "fork_of": null,
696 "protected": true,
697 "created_at": "2026-09-28T14:11:52.640Z",
698 "topics": [
699 "http",
700 "example"
701 ],
702 "website": "https://hello.g1t.page",
703 "archived_at": null
704 },
705 "notes": "Only the fields given change. A repository has no description of its own: `description` changes its project's, as [`update_project`](/reference/api/projects/update-project/) does; an empty string clears it. `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`, `allow_forking`, `max_ref_updates` 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. A fork cannot change `private` (`422`): detach it first. See [Managing a repository](/guides/managing-repositories/) and [Access and roles](/guides/access-and-roles/)."
706 },
707 "transfer_repo": {
708 "request": {
709 "to": "flagon-io"
710 },
711 "response": {
712 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
713 "namespace": "flagon-io",
714 "name": "hello",
715 "is_private": false,
716 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
717 "default_branch": "main",
718 "fork_of": null,
719 "protected": true,
720 "created_at": "2026-09-28T14:11:52.640Z",
721 "website": "https://hello.g1t.page",
722 "archived_at": null
723 },
724 "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/)."
725 },
726 "fork_repo": {
727 "request": {
728 "workspace": "ada",
729 "default_branch_only": true
730 },
731 "response": {
732 "id": "rep_01m4b7k2v9c3tq8x5n6d0fr1hz",
733 "namespace": "ada",
734 "name": "hello",
735 "is_private": false,
736 "owner_id": "usr_01kq3r8w2m6vd5e9t0hy7jx4cb",
737 "default_branch": "main",
738 "fork_of": null,
739 "parent_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
740 "parent": {
741 "namespace": "flagon-io",
742 "name": "hello"
743 },
744 "allow_forking": false,
745 "protected": false,
746 "created_at": "2026-10-14T09:30:12.418Z",
747 "website": null,
748 "archived_at": null
749 },
750 "notes": "The new fork, with `parent` naming the repository it came from. Refused with `403` when the repository is private and its admins have not allowed forking, or when you cannot create repositories in the workspace; `409` when the workspace already has a repository of that name (give another `name`); `402` when a free workspace's private storage has no room for a private fork. Its code and description are copied; nothing else is. See [Forking a repository](/guides/forking-repositories/) and [Forks](/concepts/forks/)."
751 },
752 "list_forks": {
753 "query": {
754 "limit": "30"
755 },
756 "response": [
757 {
758 "id": "rep_01m4b7k2v9c3tq8x5n6d0fr1hz",
759 "namespace": "ada",
760 "name": "hello",
761 "is_private": false,
762 "owner_id": "usr_01kq3r8w2m6vd5e9t0hy7jx4cb",
763 "default_branch": "main",
764 "fork_of": null,
765 "parent_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
766 "parent": {
767 "namespace": "flagon-io",
768 "name": "hello"
769 },
770 "allow_forking": false,
771 "protected": false,
772 "created_at": "2026-10-14T09:30:12.418Z",
773 "website": null,
774 "archived_at": null
775 }
776 ],
777 "notes": "Only the forks you can read, newest first: a private repository's forks are listed for people who can read them. Forks of a fork are listed on that fork. See [Forks](/concepts/forks/)."
778 },
779 "sync_fork": {
780 "request": {
781 "branch": "main"
782 },
783 "response": {
784 "status": "fast_forwarded",
785 "branch": "main",
786 "head": "9c4e1f0b7a2d3e5f6a8b9c0d1e2f3a4b5c6d7e8f",
787 "behind": 3,
788 "ahead": 0,
789 "conflicts": []
790 },
791 "notes": "`status` is `up_to_date`, `fast_forwarded`, `merged` (a merge commit joins the fork's own commits and the parent's) or `conflicted`: both sides changed the files in `conflicts`, and nothing was changed. Merge the parent's branch in a clone and push. Refused with `422` when the repository is not a fork, `403` without the Write role on it, and `404` when its parent is gone or you can no longer read it. See [Sync a fork](/guides/forking-repositories/#sync-a-fork)."
792 },
793 "detach_fork": {
794 "response": {
795 "id": "rep_01m4b7k2v9c3tq8x5n6d0fr1hz",
796 "namespace": "ada",
797 "name": "hello",
798 "is_private": false,
799 "owner_id": "usr_01kq3r8w2m6vd5e9t0hy7jx4cb",
800 "default_branch": "main",
801 "fork_of": null,
802 "parent_id": null,
803 "parent": null,
804 "allow_forking": false,
805 "protected": false,
806 "created_at": "2026-10-14T09:30:12.418Z",
807 "website": null,
808 "archived_at": null
809 },
810 "notes": "The repository, now with no parent. Needs the Admin role (`403` otherwise); `422` when it is not a fork. It cannot be attached again. See [Detach a fork](/guides/forking-repositories/#detach-a-fork)."
811 },
812 "rename_repo": {
813 "request": {
814 "name": "greeter"
815 },
816 "response": {
817 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
818 "namespace": "flagon-io",
819 "name": "greeter",
820 "is_private": false,
821 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
822 "default_branch": "main",
823 "fork_of": null,
824 "protected": true,
825 "created_at": "2026-09-28T14:11:52.640Z",
826 "topics": [
827 "http",
828 "example"
829 ],
830 "website": "https://hello.g1t.page",
831 "archived_at": null
832 },
833 "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)."
834 },
835 "rename_branch": {
836 "params": {
837 "owner": "flagon-io",
838 "name": "hello",
839 "branch": "feature/login"
840 },
841 "request": {
842 "new_name": "feature/sign-in"
843 },
844 "response": {
845 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
846 "namespace": "flagon-io",
847 "name": "hello",
848 "is_private": false,
849 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
850 "default_branch": "main",
851 "fork_of": null,
852 "protected": true,
853 "created_at": "2026-09-28T14:11:52.640Z",
854 "topics": [
855 "http",
856 "example"
857 ],
858 "website": "https://hello.g1t.page",
859 "archived_at": null
860 },
861 "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)."
862 },
863 "create_branch": {
864 "request": {
865 "name": "feature/login",
866 "from": "main"
867 },
868 "response": {
869 "name": "feature/login",
870 "hash": "9f2c4e1b7a3d5c6e8f0a1b2c3d4e5f6a7b8c9d0e"
871 },
872 "notes": "The new branch and the commit it points to. `from` is a branch, a tag or a commit, the default branch when left out; to restore a deleted branch, send the `hash` that deleting it answered with. Refused with `404` when `from` names nothing, `409` when the name is taken or is a folder of another branch's name (or holds one), `422` when it is not a valid branch name, and `403` without the Write role or when the repository's rules refuse it. See [Branches](/guides/git/#branches)."
873 },
874 "delete_branch": {
875 "params": {
876 "owner": "flagon-io",
877 "name": "hello",
878 "branch": "feature/login"
879 },
880 "response": {
881 "name": "feature/login",
882 "hash": "9f2c4e1b7a3d5c6e8f0a1b2c3d4e5f6a7b8c9d0e"
883 },
884 "notes": "The branch as it was. Its commits stay in the repository: `POST /repos/{owner}/{name}/branches` with this `hash` as `from` restores it. Add `?head=<sha>` to leave it alone (`409`) if it has moved from the commit you saw. Refused with `403` for the default branch, without the Write role, or when the repository's rules refuse it, and `404` when there is no such branch. Send a branch name with slashes URL-encoded, as one path segment. See [Branches](/guides/git/#branches)."
885 },
886 "set_repo_visibility": {
887 "request": {
888 "private": true,
889 "confirm": "flagon-io/hello"
890 },
891 "response": {
892 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
893 "namespace": "flagon-io",
894 "name": "hello",
895 "is_private": true,
896 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
897 "default_branch": "main",
898 "fork_of": null,
899 "protected": true,
900 "created_at": "2026-09-28T14:11:52.640Z",
901 "topics": [
902 "http",
903 "example"
904 ],
905 "website": "https://hello.g1t.page",
906 "archived_at": null
907 },
908 "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)."
909 },
910 "archive_repo": {
911 "response": {
912 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
913 "namespace": "flagon-io",
914 "name": "hello",
915 "is_private": false,
916 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
917 "default_branch": "main",
918 "fork_of": null,
919 "protected": true,
920 "created_at": "2026-09-28T14:11:52.640Z",
921 "topics": [
922 "http",
923 "example"
924 ],
925 "website": "https://hello.g1t.page",
926 "archived_at": "2026-10-05T09:30:00.000Z"
927 },
928 "notes": "The repository, with `archived_at` set. Needs the Admin role (`403` otherwise). See [Archive a repository](/guides/managing-repositories/#archive-a-repository)."
929 },
930 "unarchive_repo": {
931 "response": {
932 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
933 "namespace": "flagon-io",
934 "name": "hello",
935 "is_private": false,
936 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
937 "default_branch": "main",
938 "fork_of": null,
939 "protected": true,
940 "created_at": "2026-09-28T14:11:52.640Z",
941 "topics": [
942 "http",
943 "example"
944 ],
945 "website": "https://hello.g1t.page",
946 "archived_at": null
947 },
948 "notes": "The repository, with `archived_at` null. Needs the Admin role (`403` otherwise)."
949 },
950 "delete_repo": {
951 "request": {
952 "confirm": "flagon-io/hello"
953 },
954 "response": {
955 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
956 "namespace": "flagon-io",
957 "name": "hello",
958 "is_private": false,
959 "deleted_at": "2026-10-05T09:30:00.000Z",
960 "deleted_by": "syntaqx",
961 "purge_after": "2026-11-04T09:30:00.000Z"
962 },
963 "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)."
964 },
965 "list_deleted_repos": {
966 "params": {
967 "workspace": "flagon-io"
968 },
969 "response": [
970 {
971 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
972 "namespace": "flagon-io",
973 "name": "hello",
974 "is_private": false,
975 "deleted_at": "2026-10-05T09:30:00.000Z",
976 "deleted_by": "syntaqx",
977 "purge_after": "2026-11-04T09:30:00.000Z"
978 }
979 ],
980 "notes": "Newest first. Empty for anyone who is not an owner of the workspace."
981 },
982 "restore_repo": {
983 "response": {
984 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
985 "namespace": "flagon-io",
986 "name": "hello",
987 "is_private": false,
988 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
989 "default_branch": "main",
990 "fork_of": null,
991 "protected": true,
992 "created_at": "2026-09-28T14:11:52.640Z",
993 "topics": [
994 "http",
995 "example"
996 ],
997 "website": "https://hello.g1t.page",
998 "archived_at": null
999 },
1000 "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)."
1001 },
1002 "purge_repo": {
1003 "request": {
1004 "confirm": "flagon-io/hello"
1005 },
1006 "response": true,
1007 "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."
1008 },
1009 "get_repo_settings": {
1010 "response": {
1011 "auto_merge": false,
1012 "required_checks": [
1013 "CI"
1014 ],
1015 "require_up_to_date": false,
1016 "required_approvals": 0,
1017 "count_agent_approvals": true,
1018 "allow_ignoring_checks": true,
1019 "merge_queue": false,
1020 "require_code_owner_review": false,
1021 "has_issues": null,
1022 "issues_enabled": true,
1023 "allow_merge_commit": true,
1024 "allow_squash_merge": true,
1025 "allow_rebase_merge": true,
1026 "allow_fast_forward": false,
1027 "default_merge_method": "merge",
1028 "merge_commit_message": "default",
1029 "squash_commit_message": "default",
1030 "merge_commit_template": null,
1031 "squash_commit_template": null,
1032 "suggest_updating_branches": true,
1033 "allow_auto_merge": true,
1034 "delete_branch_on_merge": false,
1035 "require_web_commit_sign_off": false,
1036 "allow_commit_comments": true,
1037 "auto_close_issues": true,
1038 "updated_by": null,
1039 "updated_at": null
1040 }
1041 },
1042 "update_repo_settings": {
1043 "request": {
1044 "required_checks": [
1045 "CI",
1046 "g1t / deploy"
1047 ],
1048 "required_approvals": 1,
1049 "count_agent_approvals": false,
1050 "merge_queue": true,
1051 "require_code_owner_review": true,
1052 "allow_merge_commit": false,
1053 "default_merge_method": "squash",
1054 "squash_commit_message": "pull_title_and_description",
1055 "delete_branch_on_merge": true
1056 },
1057 "response": {
1058 "auto_merge": false,
1059 "required_checks": [
1060 "CI",
1061 "g1t / deploy"
1062 ],
1063 "require_up_to_date": false,
1064 "required_approvals": 1,
1065 "count_agent_approvals": false,
1066 "allow_ignoring_checks": true,
1067 "merge_queue": true,
1068 "require_code_owner_review": true,
1069 "has_issues": null,
1070 "issues_enabled": true,
1071 "allow_merge_commit": false,
1072 "allow_squash_merge": true,
1073 "allow_rebase_merge": true,
1074 "allow_fast_forward": false,
1075 "default_merge_method": "squash",
1076 "merge_commit_message": "default",
1077 "squash_commit_message": "pull_title_and_description",
1078 "merge_commit_template": null,
1079 "squash_commit_template": null,
1080 "suggest_updating_branches": true,
1081 "allow_auto_merge": true,
1082 "delete_branch_on_merge": true,
1083 "require_web_commit_sign_off": false,
1084 "allow_commit_comments": true,
1085 "auto_close_issues": true,
1086 "updated_by": "syntaqx",
1087 "updated_at": "2026-10-04T16:20:37.508Z"
1088 },
1089 "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. See [Required checks](/guides/checks/#required-checks). 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/). At least one of `allow_merge_commit`, `allow_squash_merge`, `allow_rebase_merge` and `allow_fast_forward` stays on, and `default_merge_method` must be one of them (`422` otherwise). `merge_commit_template` and `squash_commit_template` are used with `custom`: see [Commit messages](/guides/pull-requests/#commit-messages) for their placeholders. `has_issues` `null` goes back to the default: on for a repository, off for a fork. See [Repository settings](/guides/managing-repositories/#settings)."
1090 },
1091 "list_check_names": {
1092 "response": [
1093 {
1094 "name": "CI",
1095 "events": [
1096 "pull_request",
1097 "merge_group",
1098 "push"
1099 ],
1100 "last_seen": "2026-10-06T09:14:02.118Z"
1101 },
1102 {
1103 "name": "g1t / deploy",
1104 "events": [],
1105 "last_seen": "2026-10-06T08:51:40.006Z"
1106 }
1107 ],
1108 "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."
1109 },
1110 "get_codeowners_errors": {
1111 "params": {
1112 "owner": "flagon-io",
1113 "name": "hello"
1114 },
1115 "query": {
1116 "ref": "main"
1117 },
1118 "response": {
1119 "path": ".github/CODEOWNERS",
1120 "ref": "main",
1121 "size": 412,
1122 "rules": 9,
1123 "sections": [
1124 "Docs"
1125 ],
1126 "errors": [
1127 {
1128 "line": 4,
1129 "kind": "unknown_team",
1130 "token": "@flagon-io/platform",
1131 "message": "@flagon-io/platform is not a team of flagon-io."
1132 },
1133 {
1134 "line": 7,
1135 "kind": "negation",
1136 "token": "!docs/internal/",
1137 "message": "!docs/internal/ starts with !, and negation is not supported; this line is skipped. Give the path a later rule with no owners instead."
1138 }
1139 ]
1140 },
1141 "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/)."
1142 },
1143 "list_events": {
1144 "query": {
1145 "before": "evt_01m43t2a6c9e3g7j1m5q9t3x7b"
1146 },
1147 "response": [
1148 {
1149 "id": "evt_01m43smh3ve52vkcna207vqctf",
1150 "type": "pull.opened",
1151 "source": "work",
1152 "time": "2026-10-01T18:20:02.117Z",
1153 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1154 "actor": "usr_01kkntcg1eeb98j62xjm7eh09p",
1155 "data": {
1156 "pull_id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1157 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1158 "number": 14,
1159 "issue": 12,
1160 "agent": "claude-code"
1161 }
1162 },
1163 {
1164 "id": "evt_01m43shrzpf2vt5rxbb02z0xjt",
1165 "type": "issue.opened",
1166 "source": "work",
1167 "time": "2026-10-01T18:04:11.482Z",
1168 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1169 "actor": "usr_01kkntcg1eeb98j62xjm7eh09p",
1170 "data": {
1171 "issue_id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1172 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1173 "number": 12,
1174 "title": "Greeting should name the caller"
1175 }
1176 }
1177 ],
1178 "notes": "Returns 50 events a page, newest first. To page back, send the `id` of the last event you have as `before`. `actor` is a user id, and `data` depends on `type`.\n\nTo follow a repository without a webhook, send `after` instead: the events written after that event come oldest first, and the last one's `id` is your next `after`. Add `wait` (seconds, at most 25) and a call that finds nothing holds on until a matching event is written or the time is up, then returns what it has, which may be an empty list; call again with the same `after`. Events come in the order g1t wrote them, so none is skipped when two arrive close together.\n\n```sh\ncurl -H \"Authorization: Bearer $G1T_TOKEN\" \\\n \"https://api.g1t.sh/repos/acme/rocket/events?after=evt_01m43smh3ve52vkcna207vqctf&types=work.claimed,integration.failed&numbers=12&wait=25\"\n```\n\n`types` and `numbers` are comma-separated lists in a query string, arrays in a body or an MCP call. `numbers` matches events about those issues and pull requests (`data.number`) and comments, reviews and links on them (`data.issue`). `since` is an RFC 3339 time. `after` and `before` cannot be given together."
1179 },
1180 "list_issues": {
1181 "query": {
1182 "state": "open",
1183 "label": "feature"
1184 },
1185 "response": [
1186 {
1187 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1188 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1189 "number": 12,
1190 "title": "Greeting should name the caller",
1191 "body": "Take a name from the first argument; fall back to world.",
1192 "labels": [
1193 "feature"
1194 ],
1195 "state": "open",
1196 "reason": null,
1197 "resolved_by": null,
1198 "author": {
1199 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1200 "username": "syntaqx",
1201 "display_username": "syntaqx",
1202 "kind": "user",
1203 "verified": false,
1204 "workspaces": []
1205 },
1206 "requested_by": null,
1207 "created_at": "2026-10-01T18:04:11.482Z",
1208 "updated_at": "2026-10-01T18:04:11.482Z",
1209 "closed_at": null,
1210 "pull_count": 1,
1211 "comment_count": 0,
1212 "assignees": [],
1213 "blocked_by": [],
1214 "agent": "claude-code",
1215 "milestone": null
1216 }
1217 ],
1218 "notes": "Returns at most 100 issues, newest first. `comment_count` counts comments, not events such as \"opened #14 for this\"."
1219 },
1220 "create_issue": {
1221 "request": {
1222 "title": "Greeting should name the caller",
1223 "body": "Take a name from the first argument; fall back to world.",
1224 "labels": [
1225 "feature"
1226 ]
1227 },
1228 "response": {
1229 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1230 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1231 "number": 12,
1232 "title": "Greeting should name the caller",
1233 "body": "Take a name from the first argument; fall back to world.",
1234 "labels": [
1235 "feature"
1236 ],
1237 "state": "open",
1238 "reason": null,
1239 "resolved_by": null,
1240 "author": {
1241 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1242 "username": "syntaqx",
1243 "display_username": "syntaqx",
1244 "kind": "user",
1245 "verified": false,
1246 "workspaces": []
1247 },
1248 "requested_by": null,
1249 "created_at": "2026-10-01T18:04:11.482Z",
1250 "updated_at": "2026-10-01T18:04:11.482Z",
1251 "closed_at": null,
1252 "pull_count": 0,
1253 "comment_count": 0,
1254 "assignees": [],
1255 "blocked_by": [],
1256 "agent": null,
1257 "milestone": null
1258 },
1259 "notes": "Labels are lowercased. A label not used before is created."
1260 },
1261 "get_issue": {
1262 "response": {
1263 "issue": {
1264 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1265 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1266 "number": 12,
1267 "title": "Greeting should name the caller",
1268 "body": "Take a name from the first argument; fall back to world.",
1269 "labels": [
1270 "feature"
1271 ],
1272 "state": "closed",
1273 "reason": "completed",
1274 "resolved_by": 14,
1275 "resolved_commit": null,
1276 "resolved_pushed_by": null,
1277 "author": {
1278 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1279 "username": "syntaqx",
1280 "display_username": "syntaqx",
1281 "kind": "user",
1282 "verified": false,
1283 "workspaces": []
1284 },
1285 "requested_by": null,
1286 "created_at": "2026-10-01T18:04:11.482Z",
1287 "updated_at": "2026-10-01T18:52:17.093Z",
1288 "closed_at": "2026-10-01T18:52:17.093Z",
1289 "pull_count": 2,
1290 "comment_count": 0,
1291 "assignees": [],
1292 "blocked_by": [],
1293 "agent": null,
1294 "milestone": null
1295 },
1296 "pulls": [
1297 {
1298 "id": "pr_01m43sjq8tcz5rbm2a7k4d9e6w",
1299 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1300 "number": 13,
1301 "issue": 12,
1302 "title": "Greeting should name the caller",
1303 "body": null,
1304 "agent": "claude-code",
1305 "runtime": "external",
1306 "status": "closed",
1307 "fork": {
1308 "namespace": "pulls",
1309 "name": "pr_01m43sjq8tcz5rbm2a7k4d9e6w"
1310 },
1311 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1312 "branch": null,
1313 "head_commit": null,
1314 "merge_base": null,
1315 "merged_by": null,
1316 "merged_at": null,
1317 "superseded_by": 14,
1318 "check_status": null,
1319 "files": [],
1320 "assignees": [],
1321 "reviewers": [],
1322 "labels": [],
1323 "milestone": null,
1324 "base": "main",
1325 "author": {
1326 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1327 "username": "syntaqx",
1328 "display_username": "syntaqx",
1329 "kind": "user",
1330 "verified": false,
1331 "workspaces": []
1332 },
1333 "requested_by": null,
1334 "created_at": "2026-10-01T18:20:02.117Z",
1335 "updated_at": "2026-10-01T18:20:02.117Z"
1336 },
1337 {
1338 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1339 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1340 "number": 14,
1341 "issue": 12,
1342 "title": "Greeting should name the caller",
1343 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
1344 "agent": "claude-code",
1345 "runtime": "external",
1346 "status": "merged",
1347 "fork": {
1348 "namespace": "pulls",
1349 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
1350 },
1351 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1352 "branch": null,
1353 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
1354 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
1355 "merged_by": "syntaqx",
1356 "merged_at": "2026-10-01T18:52:17.093Z",
1357 "superseded_by": null,
1358 "check_status": "passed",
1359 "files": [
1360 {
1361 "path": "src/main.rs",
1362 "additions": 6,
1363 "deletions": 2
1364 }
1365 ],
1366 "assignees": [],
1367 "reviewers": [
1368 "ana"
1369 ],
1370 "labels": [],
1371 "milestone": null,
1372 "base": "main",
1373 "author": {
1374 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1375 "username": "syntaqx",
1376 "display_username": "syntaqx",
1377 "kind": "user",
1378 "verified": false,
1379 "workspaces": []
1380 },
1381 "requested_by": null,
1382 "created_at": "2026-10-01T18:20:02.117Z",
1383 "updated_at": "2026-10-01T18:52:17.093Z"
1384 }
1385 ],
1386 "comments": [
1387 {
1388 "id": "cmt_01m43sr2b7d5f0j6k3n8p1q4v9",
1389 "kind": "event",
1390 "author": {
1391 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1392 "username": "syntaqx",
1393 "display_username": "syntaqx",
1394 "kind": "user",
1395 "verified": false,
1396 "workspaces": []
1397 },
1398 "body": "opened #14 for this",
1399 "path": null,
1400 "line": null,
1401 "verdict": null,
1402 "created_at": "2026-10-01T18:20:02.141Z"
1403 }
1404 ]
1405 },
1406 "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, or `resolved_commit` the commit pushed to the default branch whose message closed it (`Fixes #12`), with `resolved_pushed_by` saying who pushed it. Each pull request made for it is listed; one closed because another was merged has `superseded_by` set."
1407 },
1408 "update_issue": {
1409 "request": {
1410 "labels": [
1411 "feature",
1412 "good first issue"
1413 ],
1414 "assignees": [
1415 "syntaqx"
1416 ],
1417 "milestone": 3,
1418 "blocked_by": [9]
1419 },
1420 "response": {
1421 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1422 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1423 "number": 12,
1424 "title": "Greeting should name the caller",
1425 "body": "Take a name from the first argument; fall back to world.",
1426 "labels": [
1427 "feature",
1428 "good first issue"
1429 ],
1430 "state": "open",
1431 "reason": null,
1432 "resolved_by": null,
1433 "author": {
1434 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1435 "username": "syntaqx",
1436 "display_username": "syntaqx",
1437 "kind": "user",
1438 "verified": false,
1439 "workspaces": []
1440 },
1441 "requested_by": null,
1442 "created_at": "2026-10-01T18:04:11.482Z",
1443 "updated_at": "2026-10-01T18:09:47.305Z",
1444 "closed_at": null,
1445 "pull_count": 0,
1446 "comment_count": 0,
1447 "assignees": [
1448 "syntaqx"
1449 ],
1450 "blocked_by": [9],
1451 "agent": null,
1452 "milestone": {
1453 "number": 3,
1454 "title": "Launch"
1455 }
1456 }
1457 },
1458 "close_issue": {
1459 "request": {
1460 "reason": "not_planned"
1461 },
1462 "response": {
1463 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1464 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1465 "number": 12,
1466 "title": "Greeting should name the caller",
1467 "body": "Take a name from the first argument; fall back to world.",
1468 "labels": [
1469 "feature"
1470 ],
1471 "state": "closed",
1472 "reason": "not_planned",
1473 "resolved_by": null,
1474 "author": {
1475 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1476 "username": "syntaqx",
1477 "display_username": "syntaqx",
1478 "kind": "user",
1479 "verified": false,
1480 "workspaces": []
1481 },
1482 "requested_by": null,
1483 "created_at": "2026-10-01T18:04:11.482Z",
1484 "updated_at": "2026-10-01T19:30:00.214Z",
1485 "closed_at": "2026-10-01T19:30:00.214Z",
1486 "pull_count": 0,
1487 "comment_count": 0,
1488 "assignees": [],
1489 "blocked_by": [],
1490 "agent": null,
1491 "milestone": null
1492 },
1493 "notes": "With `commit`, a commit already on the default branch whose message names the issue after a closing keyword (`Fixes #12`), the issue closes as completed in that commit, as pushing it would have: `resolved_commit` is set, the event is `issue.closed` with `data.commit`, and the timeline says \"closed this in\" the commit, linked. Give `commit` as its full hash. A commit not on the default branch, or one whose message does not name the issue, is refused (`422`); an issue already closed is `409`, saying what closed it. See [Closing issues](/guides/pull-requests/#closing-issues)."
1494 },
1495 "reopen_issue": {
1496 "response": {
1497 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1498 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1499 "number": 12,
1500 "title": "Greeting should name the caller",
1501 "body": "Take a name from the first argument; fall back to world.",
1502 "labels": [
1503 "feature"
1504 ],
1505 "state": "open",
1506 "reason": null,
1507 "resolved_by": null,
1508 "author": {
1509 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1510 "username": "syntaqx",
1511 "display_username": "syntaqx",
1512 "kind": "user",
1513 "verified": false,
1514 "workspaces": []
1515 },
1516 "requested_by": null,
1517 "created_at": "2026-10-01T18:04:11.482Z",
1518 "updated_at": "2026-10-01T19:41:52.830Z",
1519 "closed_at": null,
1520 "pull_count": 0,
1521 "comment_count": 0,
1522 "assignees": [],
1523 "blocked_by": [],
1524 "agent": null,
1525 "milestone": null
1526 }
1527 },
1528 "add_comment": {
1529 "request": {
1530 "body": "Should an empty name fall back to \"world\"?"
1531 },
1532 "response": {
1533 "id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1",
1534 "kind": "comment",
1535 "author": {
1536 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1537 "username": "syntaqx",
1538 "display_username": "syntaqx",
1539 "kind": "user",
1540 "verified": true,
1541 "workspaces": [
1542 {
1543 "slug": "flagon-io",
1544 "role": "owner"
1545 }
1546 ]
1547 },
1548 "body": "Should an empty name fall back to \"world\"?",
1549 "path": null,
1550 "line": null,
1551 "verdict": null,
1552 "created_at": "2026-10-01T18:12:30.551Z"
1553 }
1554 },
1555 "edit_comment": {
1556 "params": {
1557 "comment_id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1"
1558 },
1559 "request": {
1560 "body": "Should an empty name fall back to \"world\", or print the usage?"
1561 },
1562 "response": {
1563 "id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1",
1564 "kind": "comment",
1565 "author": {
1566 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1567 "username": "syntaqx",
1568 "display_username": "syntaqx",
1569 "kind": "user",
1570 "verified": true,
1571 "workspaces": [
1572 {
1573 "slug": "flagon-io",
1574 "role": "owner"
1575 }
1576 ]
1577 },
1578 "body": "Should an empty name fall back to \"world\", or print the usage?",
1579 "path": null,
1580 "line": null,
1581 "verdict": null,
1582 "created_at": "2026-10-01T18:12:30.551Z",
1583 "edited_at": "2026-10-01T18:30:04.210Z"
1584 },
1585 "notes": "Its author, or someone with the Maintain role or higher. A note of something that happened answers `409`."
1586 },
1587 "delete_comment": {
1588 "params": {
1589 "comment_id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1"
1590 },
1591 "notes": "Answers `204` with no body. Its author, or someone with the Maintain role or higher. A review that approved or requested changes answers `409`: edit it instead."
1592 },
1593 "react": {
1594 "params": {
1595 "number": 12,
1596 "comment_id": "cmt_01m43sv4c8e2g6j0m4q8t2x6a1",
1597 "content": "heart"
1598 },
1599 "response": [
1600 { "content": "heart", "count": 1, "users": ["ana"] },
1601 { "content": "eyes", "count": 1, "users": ["g1t"] }
1602 ],
1603 "notes": "Reacting twice the same way is one reaction. Without comment_id it reacts to the issue's or pull request's description."
1604 },
1605 "list_labels": {
1606 "response": [
1607 {
1608 "name": "bug",
1609 "color": "d73a4a",
1610 "description": "Something isn't working",
1611 "issues": 4,
1612 "pulls": 1
1613 },
1614 {
1615 "name": "dependencies",
1616 "color": "0366d6",
1617 "description": "Updates a dependency",
1618 "issues": 0,
1619 "pulls": 6
1620 },
1621 {
1622 "name": "good first issue",
1623 "color": "7057ff",
1624 "description": "Good for newcomers",
1625 "issues": 2,
1626 "pulls": 0
1627 }
1628 ],
1629 "notes": "By name. A new repository starts with the default labels; add_default_labels adds those an older one is missing."
1630 },
1631 "list_pull_requests": {
1632 "query": {
1633 "state": "open"
1634 },
1635 "response": [
1636 {
1637 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1638 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1639 "number": 14,
1640 "issue": 12,
1641 "title": "Greeting should name the caller",
1642 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
1643 "agent": "claude-code",
1644 "runtime": "external",
1645 "status": "open",
1646 "fork": {
1647 "namespace": "pulls",
1648 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
1649 },
1650 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1651 "branch": null,
1652 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
1653 "merge_base": null,
1654 "merged_by": null,
1655 "merged_at": null,
1656 "superseded_by": null,
1657 "check_status": "passed",
1658 "files": [
1659 {
1660 "path": "src/main.rs",
1661 "additions": 6,
1662 "deletions": 2
1663 }
1664 ],
1665 "assignees": [],
1666 "reviewers": [
1667 "ana"
1668 ],
1669 "team_reviewers": [],
1670 "author": {
1671 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1672 "username": "syntaqx",
1673 "display_username": "syntaqx",
1674 "kind": "user",
1675 "verified": false,
1676 "workspaces": []
1677 },
1678 "requested_by": null,
1679 "created_at": "2026-10-01T18:20:02.117Z",
1680 "updated_at": "2026-10-01T18:35:44.902Z",
1681 "labels": [],
1682 "milestone": null,
1683 "base": "main"
1684 }
1685 ],
1686 "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."
1687 },
1688 "create_pull_request": {
1689 "request": {
1690 "issue": 12,
1691 "agent": "claude-code"
1692 },
1693 "response": {
1694 "pull": {
1695 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1696 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1697 "number": 14,
1698 "issue": 12,
1699 "title": "Greeting should name the caller",
1700 "body": null,
1701 "agent": "claude-code",
1702 "runtime": "external",
1703 "status": "draft",
1704 "fork": {
1705 "namespace": "pulls",
1706 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
1707 },
1708 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1709 "branch": null,
1710 "head_commit": null,
1711 "merge_base": null,
1712 "merged_by": null,
1713 "merged_at": null,
1714 "superseded_by": null,
1715 "check_status": null,
1716 "files": [],
1717 "assignees": [],
1718 "reviewers": [],
1719 "labels": [],
1720 "milestone": null,
1721 "base": "main",
1722 "author": {
1723 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1724 "username": "syntaqx",
1725 "display_username": "syntaqx",
1726 "kind": "user",
1727 "verified": false,
1728 "workspaces": []
1729 },
1730 "requested_by": null,
1731 "created_at": "2026-10-01T18:20:02.117Z",
1732 "updated_at": "2026-10-01T18:20:02.117Z"
1733 },
1734 "git": {
1735 "remote": "https://g1t.sh/pulls/pr_01m43smh3vexsr5pmp60qwv0vs.git",
1736 "username": "syntaqx",
1737 "password": "your g1t access token"
1738 }
1739 },
1740 "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."
1741 },
1742 "get_pull_request": {
1743 "response": {
1744 "pull": {
1745 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1746 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1747 "number": 14,
1748 "issue": 12,
1749 "title": "Greeting should name the caller",
1750 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
1751 "agent": "claude-code",
1752 "runtime": "external",
1753 "status": "open",
1754 "fork": {
1755 "namespace": "pulls",
1756 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
1757 },
1758 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1759 "branch": null,
1760 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
1761 "merge_base": null,
1762 "merged_by": null,
1763 "merged_at": null,
1764 "superseded_by": null,
1765 "check_status": "passed",
1766 "files": [
1767 {
1768 "path": "src/main.rs",
1769 "additions": 6,
1770 "deletions": 2
1771 }
1772 ],
1773 "assignees": [],
1774 "reviewers": [
1775 "ana"
1776 ],
1777 "team_reviewers": [
1778 "flagon-io/backend"
1779 ],
1780 "author": {
1781 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1782 "username": "syntaqx",
1783 "display_username": "syntaqx",
1784 "kind": "user",
1785 "verified": false,
1786 "workspaces": []
1787 },
1788 "requested_by": null,
1789 "created_at": "2026-10-01T18:20:02.117Z",
1790 "updated_at": "2026-10-01T18:35:44.902Z",
1791 "labels": [],
1792 "milestone": null,
1793 "base": "main"
1794 },
1795 "issue": {
1796 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
1797 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1798 "number": 12,
1799 "title": "Greeting should name the caller",
1800 "body": "Take a name from the first argument; fall back to world.",
1801 "labels": [
1802 "feature"
1803 ],
1804 "state": "open",
1805 "reason": null,
1806 "resolved_by": null,
1807 "author": {
1808 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1809 "username": "syntaqx",
1810 "display_username": "syntaqx",
1811 "kind": "user",
1812 "verified": false,
1813 "workspaces": []
1814 },
1815 "requested_by": null,
1816 "created_at": "2026-10-01T18:04:11.482Z",
1817 "updated_at": "2026-10-01T18:20:02.117Z",
1818 "closed_at": null,
1819 "pull_count": 1,
1820 "comment_count": 0,
1821 "assignees": [],
1822 "blocked_by": [],
1823 "agent": "claude-code",
1824 "milestone": null
1825 },
1826 "comments": [
1827 {
1828 "id": "cmt_01m43st6d0f4h8k2n6r0v4z8c2",
1829 "kind": "event",
1830 "author": {
1831 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1832 "username": "syntaqx",
1833 "display_username": "syntaqx",
1834 "kind": "user",
1835 "verified": false,
1836 "workspaces": []
1837 },
1838 "body": "marked this ready for review",
1839 "path": null,
1840 "line": null,
1841 "verdict": null,
1842 "created_at": "2026-10-01T18:33:10.420Z"
1843 },
1844 {
1845 "id": "cmt_01m43sw2a6c0e4h8k2n6r0v4z8",
1846 "kind": "comment",
1847 "author": {
1848 "id": "agt_01m43q8d2f6h0k4n8r2v6z0c4g",
1849 "username": "margo",
1850 "kind": "agent",
1851 "verified": false,
1852 "workspaces": []
1853 },
1854 "body": "The empty-name case is handled and tested. One nit: trim the name before using it.",
1855 "path": null,
1856 "line": null,
1857 "verdict": "approve",
1858 "created_at": "2026-10-01T18:36:41.207Z",
1859 "agent": {
1860 "id": "agt_01m43q8d2f6h0k4n8r2v6z0c4g",
1861 "handle": "margo",
1862 "display_name": "Margo",
1863 "avatar_seed": "margo"
1864 },
1865 "acting_for": {
1866 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
1867 "username": "syntaqx",
1868 "kind": "user",
1869 "verified": false,
1870 "workspaces": []
1871 },
1872 "advisory": true
1873 }
1874 ],
1875 "checks": null,
1876 "overlaps": [],
1877 "behind": false,
1878 "lifecycle": null,
1879 "landing": false,
1880 "stalled": null,
1881 "statuses": [
1882 {
1883 "context": "CI / pull_request",
1884 "state": "success",
1885 "description": "CI passed",
1886 "target_url": "https://g1t.sh/syntaqx/hello/actions/runs/run_01m43sw8e2g6j0m4q8t2x6a0c4",
1887 "updated_at": "2026-10-01T18:35:44.902Z"
1888 }
1889 ],
1890 "required_checks": [
1891 {
1892 "name": "CI",
1893 "state": "success",
1894 "description": "CI passed",
1895 "target_url": "https://g1t.sh/syntaqx/hello/actions/runs/run_01m43sw8e2g6j0m4q8t2x6a0c4"
1896 }
1897 ],
1898 "code_owners": {
1899 "path": ".github/CODEOWNERS",
1900 "required": true,
1901 "reviews": [
1902 {
1903 "section": null,
1904 "line": 3,
1905 "pattern": "/src/",
1906 "owners": [
1907 "@flagon-io/backend"
1908 ],
1909 "files": [
1910 "src/main.rs"
1911 ],
1912 "optional": false,
1913 "required": 1,
1914 "approved_by": [],
1915 "changes_requested_by": [],
1916 "satisfied": false
1917 }
1918 ],
1919 "missing": "Code owners have not approved: @flagon-io/backend for /src/.",
1920 "errors": 0
1921 }
1922 },
1923 "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/)."
1924 },
1925 "get_pull_request_changes": {
1926 "response": {
1927 "base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
1928 "head": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
1929 "files": [
1930 {
1931 "path": "src/main.rs",
1932 "status": "modified",
1933 "additions": 1,
1934 "deletions": 1,
1935 "binary": false,
1936 "hunks": [
1937 {
1938 "lines": [
1939 {
1940 "kind": "context",
1941 "old": 3,
1942 "new": 3,
1943 "text": "fn main() {"
1944 },
1945 {
1946 "kind": "delete",
1947 "old": 4,
1948 "new": null,
1949 "text": " println!(\"Hello, world!\");"
1950 },
1951 {
1952 "kind": "add",
1953 "old": null,
1954 "new": 4,
1955 "text": " println!(\"Hello, {}!\", std::env::args().nth(1).unwrap_or(\"world\".into()));"
1956 },
1957 {
1958 "kind": "context",
1959 "old": 5,
1960 "new": 5,
1961 "text": "}"
1962 }
1963 ]
1964 }
1965 ]
1966 }
1967 ],
1968 "truncated": false
1969 },
1970 "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."
1971 },
1972 "mark_pull_request_ready": {
1973 "request": {
1974 "summary": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\"."
1975 },
1976 "response": {
1977 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
1978 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
1979 "number": 14,
1980 "issue": 12,
1981 "title": "Greeting should name the caller",
1982 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
1983 "agent": "claude-code",
1984 "runtime": "external",
1985 "status": "open",
1986 "fork": {
1987 "namespace": "pulls",
1988 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
1989 },
1990 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
1991 "branch": null,
1992 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
1993 "merge_base": null,
1994 "merged_by": null,
1995 "merged_at": null,
1996 "superseded_by": null,
1997 "check_status": null,
1998 "files": [
1999 {
2000 "path": "src/main.rs",
2001 "additions": 6,
2002 "deletions": 2
2003 }
2004 ],
2005 "assignees": [],
2006 "reviewers": [],
2007 "labels": [],
2008 "milestone": null,
2009 "base": "main",
2010 "author": {
2011 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2012 "username": "syntaqx",
2013 "display_username": "syntaqx",
2014 "kind": "user",
2015 "verified": false,
2016 "workspaces": []
2017 },
2018 "requested_by": null,
2019 "created_at": "2026-10-01T18:20:02.117Z",
2020 "updated_at": "2026-10-01T18:33:10.398Z"
2021 }
2022 },
2023 "review_pull_request": {
2024 "request": {
2025 "verdict": "request_changes",
2026 "body": "Trim the name before using it."
2027 },
2028 "response": {
2029 "id": "cmt_01m43sx9f3h7k1n5r9v3z7d1g5",
2030 "kind": "comment",
2031 "author": {
2032 "id": "usr_01kz9d3f7h1k5n9r3v7z1c5g9b",
2033 "username": "ana",
2034 "display_username": "Ana",
2035 "kind": "user",
2036 "verified": true,
2037 "workspaces": [
2038 {
2039 "slug": "flagon-io",
2040 "role": "member"
2041 }
2042 ]
2043 },
2044 "body": "Trim the name before using it.",
2045 "path": null,
2046 "line": null,
2047 "verdict": "request_changes",
2048 "created_at": "2026-10-01T18:40:05.019Z"
2049 }
2050 },
2051 "request_reviewers": {
2052 "params": {
2053 "owner": "flagon-io",
2054 "name": "hello",
2055 "number": 14
2056 },
2057 "request": {
2058 "reviewers": [
2059 "bo"
2060 ],
2061 "team_reviewers": [
2062 "backend"
2063 ]
2064 },
2065 "response": {
2066 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2067 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2068 "number": 14,
2069 "issue": 12,
2070 "title": "Greeting should name the caller",
2071 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2072 "agent": "claude-code",
2073 "runtime": "external",
2074 "status": "open",
2075 "fork": {
2076 "namespace": "pulls",
2077 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2078 },
2079 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2080 "branch": null,
2081 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2082 "merge_base": null,
2083 "merged_by": null,
2084 "merged_at": null,
2085 "superseded_by": null,
2086 "check_status": "passed",
2087 "files": [
2088 {
2089 "path": "src/main.rs",
2090 "additions": 6,
2091 "deletions": 2
2092 }
2093 ],
2094 "assignees": [],
2095 "reviewers": [
2096 "ana",
2097 "bo"
2098 ],
2099 "team_reviewers": [
2100 "flagon-io/backend"
2101 ],
2102 "author": {
2103 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2104 "username": "syntaqx",
2105 "display_username": "syntaqx",
2106 "kind": "user",
2107 "verified": false,
2108 "workspaces": []
2109 },
2110 "requested_by": null,
2111 "created_at": "2026-10-01T18:20:02.117Z",
2112 "updated_at": "2026-10-01T18:40:12.331Z"
2113 },
2114 "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/)."
2115 },
2116 "remove_requested_reviewers": {
2117 "params": {
2118 "owner": "flagon-io",
2119 "name": "hello",
2120 "number": 14
2121 },
2122 "request": {
2123 "reviewers": [
2124 "bo"
2125 ],
2126 "team_reviewers": [
2127 "flagon-io/backend"
2128 ]
2129 },
2130 "response": {
2131 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2132 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2133 "number": 14,
2134 "issue": 12,
2135 "title": "Greeting should name the caller",
2136 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2137 "agent": "claude-code",
2138 "runtime": "external",
2139 "status": "open",
2140 "fork": {
2141 "namespace": "pulls",
2142 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2143 },
2144 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2145 "branch": null,
2146 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2147 "merge_base": null,
2148 "merged_by": null,
2149 "merged_at": null,
2150 "superseded_by": null,
2151 "check_status": "passed",
2152 "files": [
2153 {
2154 "path": "src/main.rs",
2155 "additions": 6,
2156 "deletions": 2
2157 }
2158 ],
2159 "assignees": [],
2160 "reviewers": [
2161 "ana"
2162 ],
2163 "team_reviewers": [],
2164 "author": {
2165 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2166 "username": "syntaqx",
2167 "display_username": "syntaqx",
2168 "kind": "user",
2169 "verified": false,
2170 "workspaces": []
2171 },
2172 "requested_by": null,
2173 "created_at": "2026-10-01T18:20:02.117Z",
2174 "updated_at": "2026-10-01T18:41:30.904Z"
2175 },
2176 "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."
2177 },
2178 "get_pull_request_merge_options": {
2179 "response": {
2180 "methods": [
2181 "merge",
2182 "squash",
2183 "rebase"
2184 ],
2185 "default_method": "squash",
2186 "options": [
2187 {
2188 "method": "merge",
2189 "commit_title": "Merge pull request #14 from flagon-io/greet-caller",
2190 "commit_message": "Greeting should name the caller",
2191 "unavailable": null
2192 },
2193 {
2194 "method": "squash",
2195 "commit_title": "Greeting should name the caller (#14)",
2196 "commit_message": "* Read the name from the first argument\n* Fall back to \"world\"",
2197 "unavailable": null
2198 },
2199 {
2200 "method": "rebase",
2201 "commit_title": null,
2202 "commit_message": null,
2203 "unavailable": null
2204 }
2205 ],
2206 "behind": false,
2207 "can_fast_forward": false,
2208 "suggest_update": false,
2209 "require_up_to_date": false,
2210 "merge_queue": false,
2211 "auto_merge_allowed": true,
2212 "delete_branch_default": true,
2213 "can_delete_branch": true,
2214 "sign_off": false
2215 },
2216 "notes": "`methods` are the repository's allowed methods, narrowed by the rules for the branch it merges into: required linear history leaves out `merge`. `fast_forward` lists `unavailable` until the branch contains its base's head. `merge` and `squash` carry the commit message a merge would use if you wrote none. See [Merging a pull request](/guides/pull-requests/#merging-a-pull-request)."
2217 },
2218 "merge_pull_request": {
2219 "request": {
2220 "merge_method": "squash",
2221 "commit_title": "Greeting names the caller (#14)",
2222 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2223 "delete_branch": true
2224 },
2225 "response": {
2226 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2227 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2228 "number": 14,
2229 "issue": 12,
2230 "title": "Greeting should name the caller",
2231 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2232 "agent": "claude-code",
2233 "runtime": "external",
2234 "status": "merged",
2235 "fork": {
2236 "namespace": "pulls",
2237 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2238 },
2239 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2240 "branch": null,
2241 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2242 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2243 "merged_by": "syntaqx",
2244 "merged_at": "2026-10-01T18:52:17.093Z",
2245 "merge_method": "squash",
2246 "merge_commit": "c41d7e2a9b0f3e5d7c9a1b3d5f7e9c0a2b4d6f81",
2247 "closes": [
2248 12
2249 ],
2250 "superseded_by": null,
2251 "check_status": "passed",
2252 "files": [
2253 {
2254 "path": "src/main.rs",
2255 "additions": 6,
2256 "deletions": 2
2257 }
2258 ],
2259 "assignees": [],
2260 "reviewers": [
2261 "ana"
2262 ],
2263 "labels": [],
2264 "milestone": null,
2265 "base": "main",
2266 "author": {
2267 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2268 "username": "syntaqx",
2269 "display_username": "syntaqx",
2270 "kind": "user",
2271 "verified": false,
2272 "workspaces": []
2273 },
2274 "requested_by": null,
2275 "created_at": "2026-10-01T18:20:02.117Z",
2276 "updated_at": "2026-10-01T18:52:17.093Z"
2277 },
2278 "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`, closes the issues in `closes` (into the default branch, where `auto_close_issues` is on) and sets `superseded_by` on the pull requests it closes. A `merge_method` the repository or a rule for the base does not allow answers `422`, and a head that moved since `sha`, `409`. `merge_commit` is the commit the base is at afterwards: the merge or squash commit, the last rebased one, or the head for a fast-forward. See [Merging a pull request](/guides/pull-requests/#merging-a-pull-request)."
2279 },
2280 "update_pull_request_branch": {
2281 "request": {
2282 "expected_head_sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2283 "update_method": "merge"
2284 },
2285 "response": {
2286 "outcome": "updated",
2287 "commit": "5b8d0f2a4c6e8a0c2e4a6c8e0a2c4e6a8c0e2a4c",
2288 "previous": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13"
2289 },
2290 "notes": "`outcome` is `updated` (its branch moved from `previous` to `commit`), `up_to_date` (it already holds its base's head; `commit` only) or `needs_agent` (nothing was pushed: `reason` is `overlap`, `conflicting` or `unsupported`, with `detail` and the `paths` concerned). `update_method` `rebase` rewrites its branch, so pull it again before pushing more. A head that moved since `expected_head_sha` answers `409`. See [Keeping a pull request up to date](/guides/pull-requests/#keeping-it-up-to-date)."
2291 },
2292 "enable_pull_request_auto_merge": {
2293 "request": {
2294 "merge_method": "squash",
2295 "commit_title": "Greeting names the caller (#14)"
2296 },
2297 "response": {
2298 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2299 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2300 "number": 14,
2301 "issue": 12,
2302 "title": "Greeting should name the caller",
2303 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2304 "agent": "claude-code",
2305 "runtime": "external",
2306 "status": "open",
2307 "fork": {
2308 "namespace": "pulls",
2309 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2310 },
2311 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2312 "branch": null,
2313 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2314 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2315 "merged_by": null,
2316 "merged_at": null,
2317 "superseded_by": null,
2318 "check_status": "running",
2319 "files": [
2320 {
2321 "path": "src/main.rs",
2322 "additions": 6,
2323 "deletions": 2
2324 }
2325 ],
2326 "assignees": [],
2327 "reviewers": [
2328 "ana"
2329 ],
2330 "labels": [],
2331 "milestone": null,
2332 "base": "main",
2333 "author": {
2334 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2335 "username": "syntaqx",
2336 "display_username": "syntaqx",
2337 "kind": "user",
2338 "verified": false,
2339 "workspaces": []
2340 },
2341 "requested_by": null,
2342 "created_at": "2026-10-01T18:20:02.117Z",
2343 "updated_at": "2026-10-01T18:44:09.310Z",
2344 "auto_merge": {
2345 "method": "squash",
2346 "commit_title": "Greeting names the caller (#14)",
2347 "commit_message": null,
2348 "enabled_by": "syntaqx",
2349 "enabled_at": "2026-10-01T18:44:09.310Z"
2350 },
2351 "closes": [
2352 12
2353 ]
2354 },
2355 "notes": "A repository with `allow_auto_merge` off answers `422`, as does a method it or a rule for the base does not allow. A pull request that may already merge merges at once: check `status`. `auto_merge` is cleared when it merges or closes, when it is turned off, and when someone other than `enabled_by` pushes to it. See [Auto-merge](/guides/pull-requests/#auto-merge)."
2356 },
2357 "disable_pull_request_auto_merge": {
2358 "response": {
2359 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2360 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2361 "number": 14,
2362 "issue": 12,
2363 "title": "Greeting should name the caller",
2364 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2365 "agent": "claude-code",
2366 "runtime": "external",
2367 "status": "open",
2368 "fork": {
2369 "namespace": "pulls",
2370 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2371 },
2372 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2373 "branch": null,
2374 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2375 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2376 "merged_by": null,
2377 "merged_at": null,
2378 "superseded_by": null,
2379 "check_status": "running",
2380 "files": [
2381 {
2382 "path": "src/main.rs",
2383 "additions": 6,
2384 "deletions": 2
2385 }
2386 ],
2387 "assignees": [],
2388 "reviewers": [
2389 "ana"
2390 ],
2391 "labels": [],
2392 "milestone": null,
2393 "base": "main",
2394 "author": {
2395 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2396 "username": "syntaqx",
2397 "display_username": "syntaqx",
2398 "kind": "user",
2399 "verified": false,
2400 "workspaces": []
2401 },
2402 "requested_by": null,
2403 "created_at": "2026-10-01T18:20:02.117Z",
2404 "updated_at": "2026-10-01T18:44:09.310Z",
2405 "auto_merge": null,
2406 "closes": [
2407 12
2408 ]
2409 }
2410 },
2411 "delete_pull_request_head_branch": {
2412 "response": {
2413 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2414 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2415 "number": 14,
2416 "issue": 12,
2417 "title": "Greeting should name the caller",
2418 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2419 "agent": "claude-code",
2420 "runtime": "external",
2421 "status": "merged",
2422 "fork": null,
2423 "fork_repo_id": null,
2424 "branch": "greet-caller",
2425 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2426 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2427 "merged_by": "syntaqx",
2428 "merged_at": "2026-10-01T18:52:17.093Z",
2429 "superseded_by": null,
2430 "check_status": "passed",
2431 "files": [
2432 {
2433 "path": "src/main.rs",
2434 "additions": 6,
2435 "deletions": 2
2436 }
2437 ],
2438 "assignees": [],
2439 "reviewers": [
2440 "ana"
2441 ],
2442 "labels": [],
2443 "milestone": null,
2444 "base": "main",
2445 "author": {
2446 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2447 "username": "syntaqx",
2448 "display_username": "syntaqx",
2449 "kind": "user",
2450 "verified": false,
2451 "workspaces": []
2452 },
2453 "requested_by": null,
2454 "created_at": "2026-10-01T18:20:02.117Z",
2455 "updated_at": "2026-10-01T18:53:02.415Z",
2456 "merge_method": "squash",
2457 "merge_commit": "c41d7e2a9b0f3e5d7c9a1b3d5f7e9c0a2b4d6f81",
2458 "closes": [
2459 12
2460 ],
2461 "head_branch_deleted": true
2462 },
2463 "notes": "An open pull request answers `409`: close or merge it first. `head_branch_deleted` is then `true`; [restore it](/reference/api/pull-requests/restore-pull-request-head-branch/) at `head_commit`."
2464 },
2465 "restore_pull_request_head_branch": {
2466 "response": {
2467 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2468 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2469 "number": 14,
2470 "issue": 12,
2471 "title": "Greeting should name the caller",
2472 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2473 "agent": "claude-code",
2474 "runtime": "external",
2475 "status": "merged",
2476 "fork": null,
2477 "fork_repo_id": null,
2478 "branch": "greet-caller",
2479 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2480 "merge_base": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2481 "merged_by": "syntaqx",
2482 "merged_at": "2026-10-01T18:52:17.093Z",
2483 "superseded_by": null,
2484 "check_status": "passed",
2485 "files": [
2486 {
2487 "path": "src/main.rs",
2488 "additions": 6,
2489 "deletions": 2
2490 }
2491 ],
2492 "assignees": [],
2493 "reviewers": [
2494 "ana"
2495 ],
2496 "labels": [],
2497 "milestone": null,
2498 "base": "main",
2499 "author": {
2500 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2501 "username": "syntaqx",
2502 "display_username": "syntaqx",
2503 "kind": "user",
2504 "verified": false,
2505 "workspaces": []
2506 },
2507 "requested_by": null,
2508 "created_at": "2026-10-01T18:20:02.117Z",
2509 "updated_at": "2026-10-02T09:10:44.902Z",
2510 "merge_method": "squash",
2511 "merge_commit": "c41d7e2a9b0f3e5d7c9a1b3d5f7e9c0a2b4d6f81",
2512 "closes": [
2513 12
2514 ],
2515 "head_branch_deleted": false
2516 },
2517 "notes": "The branch is made again at `head_commit`. A branch of that name that exists again answers `409`."
2518 },
2519 "list_repo_commit_comments": {
2520 "query": {
2521 "page": 1
2522 },
2523 "response": [
2524 {
2525 "id": "ccm_01m4a2s1b5c7e9g3k6m0p4s8v2",
2526 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2527 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2528 "path": null,
2529 "line": null,
2530 "author": "syntaqx",
2531 "body": "Released as v0.4.0.",
2532 "created_at": "2026-10-02T08:30:57.664Z",
2533 "updated_at": null
2534 },
2535 {
2536 "id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4",
2537 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2538 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2539 "path": "src/main.rs",
2540 "line": 12,
2541 "author": "ana",
2542 "body": "Should an empty name fall back to \"world\"?",
2543 "created_at": "2026-10-01T19:02:11.208Z",
2544 "updated_at": null
2545 }
2546 ],
2547 "notes": "Newest first, 30 a page. A comment with `path` and `line` is on that line of the file as its `commit` left it; one without is on the whole commit."
2548 },
2549 "list_commit_comments": {
2550 "params": {
2551 "owner": "flagon-io",
2552 "name": "hello",
2553 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13"
2554 },
2555 "response": [
2556 {
2557 "id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4",
2558 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2559 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2560 "path": "src/main.rs",
2561 "line": 12,
2562 "author": "ana",
2563 "body": "Should an empty name fall back to \"world\"?",
2564 "created_at": "2026-10-01T19:02:11.208Z",
2565 "updated_at": null
2566 }
2567 ],
2568 "notes": "Oldest first."
2569 },
2570 "create_commit_comment": {
2571 "params": {
2572 "owner": "flagon-io",
2573 "name": "hello",
2574 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13"
2575 },
2576 "request": {
2577 "body": "Should an empty name fall back to \"world\"?",
2578 "path": "src/main.rs",
2579 "line": 12
2580 },
2581 "response": {
2582 "id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4",
2583 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2584 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2585 "path": "src/main.rs",
2586 "line": 12,
2587 "author": "ana",
2588 "body": "Should an empty name fall back to \"world\"?",
2589 "created_at": "2026-10-01T19:02:11.208Z",
2590 "updated_at": null
2591 },
2592 "notes": "`line` needs `path`, a file the commit changed, and counts lines of that file as the commit left it. A repository with `allow_commit_comments` off answers `403`; a commit it does not have, `404`. See [Commit comments](/guides/pull-requests/#commit-comments)."
2593 },
2594 "update_commit_comment": {
2595 "params": {
2596 "owner": "flagon-io",
2597 "name": "hello",
2598 "comment_id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4"
2599 },
2600 "request": {
2601 "body": "Should an empty name fall back to \"world\"? The README says it does."
2602 },
2603 "response": {
2604 "id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4",
2605 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2606 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2607 "path": "src/main.rs",
2608 "line": 12,
2609 "author": "ana",
2610 "body": "Should an empty name fall back to \"world\"? The README says it does.",
2611 "created_at": "2026-10-01T19:02:11.208Z",
2612 "updated_at": "2026-10-01T19:05:40.117Z"
2613 },
2614 "notes": "Its author only."
2615 },
2616 "delete_commit_comment": {
2617 "params": {
2618 "owner": "flagon-io",
2619 "name": "hello",
2620 "comment_id": "ccm_01m4a2r7k3d9f1h5j8n2q6t0w4"
2621 },
2622 "notes": "Answers `204` with no body. Its author, or someone with the Maintain role or higher."
2623 },
2624 "close_pull_request": {
2625 "response": {
2626 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2627 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2628 "number": 14,
2629 "issue": 12,
2630 "title": "Greeting should name the caller",
2631 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2632 "agent": "claude-code",
2633 "runtime": "external",
2634 "status": "closed",
2635 "fork": {
2636 "namespace": "pulls",
2637 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2638 },
2639 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2640 "branch": null,
2641 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2642 "merge_base": null,
2643 "merged_by": null,
2644 "merged_at": null,
2645 "superseded_by": null,
2646 "check_status": null,
2647 "files": [
2648 {
2649 "path": "src/main.rs",
2650 "additions": 6,
2651 "deletions": 2
2652 }
2653 ],
2654 "assignees": [],
2655 "reviewers": [],
2656 "labels": [],
2657 "milestone": null,
2658 "base": "main",
2659 "author": {
2660 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2661 "username": "syntaqx",
2662 "display_username": "syntaqx",
2663 "kind": "user",
2664 "verified": false,
2665 "workspaces": []
2666 },
2667 "requested_by": null,
2668 "created_at": "2026-10-01T18:20:02.117Z",
2669 "updated_at": "2026-10-01T19:02:48.760Z"
2670 }
2671 },
2672 "reopen_pull_request": {
2673 "response": {
2674 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2675 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2676 "number": 14,
2677 "issue": 12,
2678 "title": "Greeting should name the caller",
2679 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2680 "agent": "claude-code",
2681 "runtime": "external",
2682 "status": "open",
2683 "fork": {
2684 "namespace": "pulls",
2685 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2686 },
2687 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2688 "branch": null,
2689 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2690 "merge_base": null,
2691 "merged_by": null,
2692 "merged_at": null,
2693 "superseded_by": null,
2694 "check_status": null,
2695 "files": [
2696 {
2697 "path": "src/main.rs",
2698 "additions": 6,
2699 "deletions": 2
2700 }
2701 ],
2702 "assignees": [],
2703 "reviewers": [],
2704 "labels": [],
2705 "milestone": null,
2706 "base": "main",
2707 "author": {
2708 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2709 "username": "syntaqx",
2710 "display_username": "syntaqx",
2711 "kind": "user",
2712 "verified": false,
2713 "workspaces": []
2714 },
2715 "requested_by": null,
2716 "created_at": "2026-10-01T18:20:02.117Z",
2717 "updated_at": "2026-10-01T19:14:05.322Z"
2718 },
2719 "notes": "A merged pull request, or one that is not closed, answers `409`. A pull request closed as a draft comes back as a draft; any other comes back ready for review. A pull request from a branch of the repository whose branch was deleted answers `409` until the branch is pushed again. The same as `PATCH /repos/{owner}/{repo}/pulls/{number}` with `state` `open`."
2720 },
2721 "convert_pull_request_to_draft": {
2722 "response": {
2723 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
2724 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2725 "number": 14,
2726 "issue": 12,
2727 "title": "Greeting should name the caller",
2728 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
2729 "agent": "claude-code",
2730 "runtime": "external",
2731 "status": "draft",
2732 "fork": {
2733 "namespace": "pulls",
2734 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
2735 },
2736 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
2737 "branch": null,
2738 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2739 "merge_base": null,
2740 "merged_by": null,
2741 "merged_at": null,
2742 "superseded_by": null,
2743 "check_status": null,
2744 "files": [
2745 {
2746 "path": "src/main.rs",
2747 "additions": 6,
2748 "deletions": 2
2749 }
2750 ],
2751 "assignees": [],
2752 "reviewers": [],
2753 "labels": [],
2754 "milestone": null,
2755 "base": "main",
2756 "author": {
2757 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2758 "username": "syntaqx",
2759 "display_username": "syntaqx",
2760 "kind": "user",
2761 "verified": false,
2762 "workspaces": []
2763 },
2764 "requested_by": null,
2765 "created_at": "2026-10-01T18:20:02.117Z",
2766 "updated_at": "2026-10-01T19:20:41.908Z"
2767 },
2768 "notes": "Only a pull request that is open and ready for review can be made a draft; any other answers `409`. It leaves the [merge queue](/guides/merge-queue/)."
2769 },
2770 "get_merge_queue": {
2771 "response": {
2772 "enabled": true,
2773 "active": [
2774 {
2775 "id": "qen_01m43rn0qsft1tpap1awkewzbb",
2776 "number": 14,
2777 "title": "Greeting should name the caller",
2778 "agent": "claude-code",
2779 "state": "testing",
2780 "ahead": [],
2781 "base_commit": "3a7e9c1b5d2f4a6c8e0b2d4f6a8c0e2b4d6f8a1c",
2782 "combined_commit": null,
2783 "error": null,
2784 "results": [],
2785 "enqueued_by": "syntaqx",
2786 "created_at": "2026-10-04T15:31:20.441Z",
2787 "finished_at": null
2788 }
2789 ],
2790 "recent": [
2791 {
2792 "id": "qen_01m43khqjmeb5a1magayrnk63z",
2793 "number": 11,
2794 "title": "Fix trailing newline in greeting",
2795 "agent": "g1t",
2796 "state": "landed",
2797 "ahead": [],
2798 "base_commit": "4b1d7e9c2a5f8e3d6c0b9a7e5d3c1b8a6f4e2d0c",
2799 "combined_commit": "c3e8a1f6d4b2097e5c3a1f8d6b4e2c0a9f7d5b3e",
2800 "error": null,
2801 "results": [
2802 {
2803 "command": "cargo test",
2804 "passed": true,
2805 "exit_code": 0,
2806 "output": "test result: ok. 12 passed; 0 failed\n",
2807 "duration_ms": 48211
2808 }
2809 ],
2810 "enqueued_by": "g1t",
2811 "created_at": "2026-10-04T14:02:09.876Z",
2812 "finished_at": "2026-10-04T14:09:55.102Z"
2813 }
2814 ]
2815 },
2816 "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."
2817 },
2818 "read_session": {
2819 "query": {
2820 "after": 0
2821 },
2822 "response": [
2823 {
2824 "seq": 1,
2825 "kind": "prompt",
2826 "text": "Make the greeting name the caller (issue #12).",
2827 "tool": null,
2828 "commit": null,
2829 "at": "2026-10-01T18:21:00.004Z"
2830 },
2831 {
2832 "seq": 2,
2833 "kind": "tool_call",
2834 "text": "cargo test",
2835 "tool": "bash",
2836 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2837 "at": "2026-10-01T18:30:12.660Z"
2838 }
2839 ]
2840 },
2841 "record_session": {
2842 "request": {
2843 "entries": [
2844 {
2845 "kind": "message",
2846 "text": "Reading src/main.rs."
2847 },
2848 {
2849 "kind": "tool_call",
2850 "text": "cargo test",
2851 "tool": "bash"
2852 }
2853 ]
2854 },
2855 "response": {
2856 "count": 2
2857 },
2858 "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/)."
2859 },
2860 "start_session": {
2861 "request": {
2862 "harness": "claude_code",
2863 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
2864 "issue": 12,
2865 "branch": "greet-caller",
2866 "title": "Make the greeting name the caller"
2867 },
2868 "response": {
2869 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
2870 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2871 "issue": 12,
2872 "pull": null,
2873 "branch": "greet-caller",
2874 "actor": {
2875 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2876 "username": "syntaqx"
2877 },
2878 "harness": "claude_code",
2879 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
2880 "title": "Make the greeting name the caller",
2881 "state": "active",
2882 "head_commit": null,
2883 "started_at": "2026-10-12T14:02:11.204Z",
2884 "last_seen_at": "2026-10-12T14:02:11.204Z",
2885 "ended_at": null,
2886 "end_reason": null
2887 },
2888 "notes": "Idempotent on `harness_session_id`: a second start with it returns this session, so call it from a hook without checking first. `state` is `active`, `idle` (no heartbeat for 15 minutes) or `ended` (ended, or no heartbeat for 2 hours: `end_reason` `timed_out`). A subagent gives `parent_id`, `agent_type`, `task` and `prompt`. See [Sessions](/guides/sessions/)."
2889 },
2890 "start_agent_session": {
2891 "request": {
2892 "issue": 12,
2893 "mode": "implement",
2894 "instruction": "Keep the old greeting behind a flag."
2895 },
2896 "response": {
2897 "issue": 12,
2898 "session": {
2899 "id": "ses_01m4c9a8b7c6d5e4f3g2h1j0k9",
2900 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2901 "issue": 12,
2902 "pull": null,
2903 "branch": null,
2904 "actor": {
2905 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2906 "username": "syntaqx"
2907 },
2908 "harness": "claude_managed_agents",
2909 "harness_session_id": "sesn_011CZkZAtmR3yMPDzynEDxu7",
2910 "title": "#12 Make the greeting name the caller",
2911 "state": "active",
2912 "head_commit": null,
2913 "started_at": "2026-10-12T15:10:02.117Z",
2914 "last_seen_at": "2026-10-12T15:10:02.117Z",
2915 "ended_at": null,
2916 "end_reason": null,
2917 "parent_id": null,
2918 "agent_type": null,
2919 "task": null,
2920 "prompt": null,
2921 "result": null,
2922 "model": "claude-opus-5-5",
2923 "subagents": 0
2924 },
2925 "session_url": "https://g1t.sh/syntaqx/hello/work/sessions/ses_01m4c9a8b7c6d5e4f3g2h1j0k9",
2926 "provider": "anthropic",
2927 "provider_session_id": "sesn_011CZkZAtmR3yMPDzynEDxu7",
2928 "provider_session_url": "https://platform.claude.com/workspaces/default/sessions/sesn_011CZkZAtmR3yMPDzynEDxu7",
2929 "handoff": false,
2930 "command": null,
2931 "prompt": "Work on issue #12 in syntaqx/hello: Make the greeting name the caller.\n\n…"
2932 },
2933 "notes": "Runs on the workspace's own Anthropic key: g1t runs no model and bills nothing for it. Without an Anthropic AI provider (or with `handoff: true`) nothing is started and `command` is a Claude Code command line to run with g1t's plugin. See [Sessions](/guides/sessions/#start-a-session-on-your-anthropic-account)."
2934 },
2935 "update_session": {
2936 "request": {
2937 "pull": 14,
2938 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13"
2939 },
2940 "response": {
2941 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
2942 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2943 "issue": 12,
2944 "pull": 14,
2945 "branch": "greet-caller",
2946 "actor": {
2947 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2948 "username": "syntaqx"
2949 },
2950 "harness": "claude_code",
2951 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
2952 "title": "Make the greeting name the caller",
2953 "state": "active",
2954 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2955 "started_at": "2026-10-12T14:02:11.204Z",
2956 "last_seen_at": "2026-10-12T14:31:40.518Z",
2957 "ended_at": null,
2958 "end_reason": null
2959 },
2960 "notes": "Send `{}` as a heartbeat. Each call renews the session's claims and brings back one that timed out. Refused with `404` for a session that is not yours, and `409` for one you ended."
2961 },
2962 "end_session": {
2963 "request": {
2964 "reason": "done"
2965 },
2966 "response": {
2967 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
2968 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2969 "issue": 12,
2970 "pull": 14,
2971 "branch": "greet-caller",
2972 "actor": {
2973 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
2974 "username": "syntaqx"
2975 },
2976 "harness": "claude_code",
2977 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
2978 "title": "Make the greeting name the caller",
2979 "state": "ended",
2980 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
2981 "started_at": "2026-10-12T14:02:11.204Z",
2982 "last_seen_at": "2026-10-12T14:40:03.115Z",
2983 "ended_at": "2026-10-12T14:40:03.115Z",
2984 "end_reason": "done"
2985 }
2986 },
2987 "get_session": {
2988 "query": {
2989 "after": 0
2990 },
2991 "response": {
2992 "session": {
2993 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
2994 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
2995 "issue": 12,
2996 "pull": 14,
2997 "branch": "greet-caller",
2998 "actor": {
2999 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3000 "username": "syntaqx"
3001 },
3002 "harness": "claude_code",
3003 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
3004 "title": "Make the greeting name the caller",
3005 "state": "active",
3006 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3007 "started_at": "2026-10-12T14:02:11.204Z",
3008 "last_seen_at": "2026-10-12T14:31:40.518Z",
3009 "ended_at": null,
3010 "end_reason": null
3011 },
3012 "entries": [
3013 {
3014 "seq": 1,
3015 "kind": "prompt",
3016 "text": "Make the greeting name the caller (issue #12).",
3017 "tool": null,
3018 "commit": null,
3019 "at": "2026-10-12T14:02:12.008Z"
3020 },
3021 {
3022 "seq": 2,
3023 "kind": "tool_call",
3024 "text": "cargo test",
3025 "tool": "Bash",
3026 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3027 "at": "2026-10-12T14:30:12.660Z"
3028 }
3029 ],
3030 "children": [
3031 {
3032 "id": "ses_01m4b2d8x1y2z3a4b5c6d7e8f9",
3033 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3034 "issue": 12,
3035 "pull": null,
3036 "branch": "greet-caller",
3037 "actor": {
3038 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3039 "username": "syntaqx"
3040 },
3041 "harness": "claude_code",
3042 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13/agent/a4d2c8f1e0b3a297",
3043 "title": null,
3044 "state": "ended",
3045 "head_commit": null,
3046 "started_at": "2026-10-12T14:05:40.112Z",
3047 "last_seen_at": "2026-10-12T14:07:02.930Z",
3048 "ended_at": "2026-10-12T14:07:02.930Z",
3049 "end_reason": "done",
3050 "parent_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3051 "agent_type": "Explore",
3052 "task": "Find where the greeting is built",
3053 "prompt": "Find every place the greeting text is built and say which file to change.",
3054 "result": "The greeting is built in src/greet.rs (greet) and nowhere else.",
3055 "model": "claude-sonnet-5-5",
3056 "subagents": 0
3057 }
3058 ],
3059 "touched": [
3060 {
3061 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3062 "kind": "file",
3063 "value": "src/greet.rs",
3064 "at": "2026-10-12T14:12:30.004Z"
3065 },
3066 {
3067 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3068 "kind": "branch",
3069 "value": "greet-caller",
3070 "at": "2026-10-12T14:30:40.871Z"
3071 }
3072 ],
3073 "links": [
3074 {
3075 "kind": "pull",
3076 "number": 14,
3077 "title": "Name the caller in the greeting",
3078 "state": "open",
3079 "via": ["attached", "branch"],
3080 "session_ids": ["ses_01m4b2c3d4e5f6g7h8j9k0m1n2"]
3081 },
3082 {
3083 "kind": "issue",
3084 "number": 12,
3085 "title": "Make the greeting name the caller",
3086 "state": "open",
3087 "via": ["attached", "claim"],
3088 "session_ids": ["ses_01m4b2c3d4e5f6g7h8j9k0m1n2", "ses_01m4b2d8x1y2z3a4b5c6d7e8f9"]
3089 }
3090 ],
3091 "skills": [
3092 {
3093 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3094 "name": "work-on-issue",
3095 "uses": 1
3096 }
3097 ],
3098 "root": null
3099 },
3100 "notes": "Entries are numbered within the session and come 500 at a time; send the last `seq` you have as `after` for the next page. `children` are the session's subagents and theirs; `touched`, `links` and `skills` cover the whole tree."
3101 },
3102 "list_sessions": {
3103 "query": {
3104 "state": "active",
3105 "issue": 12
3106 },
3107 "response": [
3108 {
3109 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3110 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3111 "issue": 12,
3112 "pull": 14,
3113 "branch": "greet-caller",
3114 "actor": {
3115 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3116 "username": "syntaqx"
3117 },
3118 "harness": "claude_code",
3119 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
3120 "title": "Make the greeting name the caller",
3121 "state": "active",
3122 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3123 "started_at": "2026-10-12T14:02:11.204Z",
3124 "last_seen_at": "2026-10-12T14:31:40.518Z",
3125 "ended_at": null,
3126 "end_reason": null
3127 }
3128 ]
3129 },
3130 "record_session_entries": {
3131 "request": {
3132 "entries": [
3133 {
3134 "kind": "prompt",
3135 "text": "Make the greeting name the caller (issue #12).",
3136 "key": "prompt-1"
3137 },
3138 {
3139 "kind": "tool_call",
3140 "text": "cargo test",
3141 "tool": "Bash",
3142 "key": "tool-7"
3143 },
3144 {
3145 "kind": "skill",
3146 "text": "work-on-issue",
3147 "key": "skill-3"
3148 }
3149 ],
3150 "touched": [
3151 { "kind": "file", "value": "src/greet.rs" },
3152 { "kind": "branch", "value": "greet-caller" }
3153 ]
3154 },
3155 "response": {
3156 "recorded": 3,
3157 "duplicates": 0,
3158 "acknowledged": 0
3159 },
3160 "notes": "Up to 200 entries a request. An entry whose `key` the session recorded before is counted in `duplicates` and not recorded again. Entries of a session on a pull request show in that pull request's session too (read_session). `acknowledge` (up to 100 update IDs from get_session's `updates`) clears those updates for this session only; `acknowledged` counts the IDs that were this session's."
3161 },
3162 "claim_issue": {
3163 "request": {
3164 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3165 "note": "Taking the argument parsing first.",
3166 "ttl_minutes": 30
3167 },
3168 "response": {
3169 "claim": {
3170 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3171 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3172 "issue": 12,
3173 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3174 "actor": {
3175 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3176 "username": "syntaqx"
3177 },
3178 "harness": "claude_code",
3179 "note": "Taking the argument parsing first.",
3180 "state": "active",
3181 "created_at": "2026-10-12T14:03:02.771Z",
3182 "expires_at": "2026-10-12T15:01:40.518Z",
3183 "ended_at": null,
3184 "end_reason": null,
3185 "handoff_to": null
3186 },
3187 "others": [
3188 {
3189 "id": "clm_01m4b2a4c6e8g0j2l4n6q8s0u2",
3190 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3191 "issue": 12,
3192 "session_id": null,
3193 "actor": {
3194 "id": "usr_01kkp2v7d4fh8m3q6t9w2z5c8e",
3195 "username": "ana"
3196 },
3197 "harness": null,
3198 "note": "Looking at the tests.",
3199 "state": "active",
3200 "created_at": "2026-10-12T13:50:12.000Z",
3201 "expires_at": "2026-10-12T14:20:12.000Z",
3202 "ended_at": null,
3203 "end_reason": null,
3204 "handoff_to": null
3205 }
3206 ],
3207 "blocked_by": [
3208 {
3209 "number": 9,
3210 "title": "Read arguments with a parser",
3211 "state": "open",
3212 "claims": [
3213 {
3214 "id": "clm_01m4b2a4c6e8g0j2l4n6q8s0u2",
3215 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3216 "issue": 9,
3217 "session_id": null,
3218 "actor": {
3219 "id": "usr_01kkp2v7d4fh8m3q6t9w2z5c8e",
3220 "username": "ana"
3221 },
3222 "harness": null,
3223 "note": null,
3224 "state": "active",
3225 "created_at": "2026-10-12T13:50:12.000Z",
3226 "expires_at": "2026-10-12T14:20:12.000Z",
3227 "ended_at": null,
3228 "end_reason": null,
3229 "handoff_to": null
3230 }
3231 ],
3232 "pulls": [
3233 {
3234 "number": 11,
3235 "title": "Parse arguments with clap",
3236 "status": "open"
3237 }
3238 ]
3239 }
3240 ]
3241 },
3242 "notes": "A claim is advisory: it is made even when `others` lists someone already on the issue. Claiming an issue you hold renews your claim. Refused with `409` for a closed issue. See [Claims](/guides/sessions/#claims)."
3243 },
3244 "release_claim": {
3245 "request": {
3246 "reason": "Ana has it covered."
3247 },
3248 "response": {
3249 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3250 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3251 "issue": 12,
3252 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3253 "actor": {
3254 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3255 "username": "syntaqx"
3256 },
3257 "harness": "claude_code",
3258 "note": "Taking the argument parsing first.",
3259 "state": "released",
3260 "created_at": "2026-10-12T14:03:02.771Z",
3261 "expires_at": "2026-10-12T15:01:40.518Z",
3262 "ended_at": "2026-10-12T14:12:30.000Z",
3263 "end_reason": "Ana has it covered.",
3264 "handoff_to": null
3265 }
3266 },
3267 "hand_off_issue": {
3268 "request": {
3269 "to": "ana",
3270 "note": "Parsing is done and tested; the README still needs the new usage."
3271 },
3272 "response": {
3273 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3274 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3275 "issue": 12,
3276 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3277 "actor": {
3278 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3279 "username": "syntaqx"
3280 },
3281 "harness": "claude_code",
3282 "note": "Parsing is done and tested; the README still needs the new usage.",
3283 "state": "handed_off",
3284 "created_at": "2026-10-12T14:03:02.771Z",
3285 "expires_at": "2026-10-12T15:01:40.518Z",
3286 "ended_at": "2026-10-12T14:38:00.000Z",
3287 "end_reason": "handed_off",
3288 "handoff_to": "ana"
3289 }
3290 },
3291 "list_claims": {
3292 "query": {
3293 "state": "active"
3294 },
3295 "response": [
3296 {
3297 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3298 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3299 "issue": 12,
3300 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3301 "actor": {
3302 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3303 "username": "syntaqx"
3304 },
3305 "harness": "claude_code",
3306 "note": "Taking the argument parsing first.",
3307 "state": "active",
3308 "created_at": "2026-10-12T14:03:02.771Z",
3309 "expires_at": "2026-10-12T15:01:40.518Z",
3310 "ended_at": null,
3311 "end_reason": null,
3312 "handoff_to": null
3313 },
3314 {
3315 "id": "clm_01m4b2a4c6e8g0j2l4n6q8s0u2",
3316 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3317 "issue": 12,
3318 "session_id": null,
3319 "actor": {
3320 "id": "usr_01kkp2v7d4fh8m3q6t9w2z5c8e",
3321 "username": "ana"
3322 },
3323 "harness": null,
3324 "note": "Looking at the tests.",
3325 "state": "active",
3326 "created_at": "2026-10-12T13:50:12.000Z",
3327 "expires_at": "2026-10-12T14:20:12.000Z",
3328 "ended_at": null,
3329 "end_reason": null,
3330 "handoff_to": null
3331 }
3332 ]
3333 },
3334 "get_work": {
3335 "response": {
3336 "issue": {
3337 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
3338 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3339 "number": 12,
3340 "title": "Greeting should name the caller",
3341 "body": "Take a name from the first argument; fall back to world.\n\n## Definition of done\n\n- `cargo test` passes.\n- The README shows the new usage.",
3342 "labels": [
3343 "feature",
3344 "good first issue"
3345 ],
3346 "state": "open",
3347 "reason": null,
3348 "resolved_by": null,
3349 "author": {
3350 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3351 "username": "syntaqx",
3352 "display_username": "syntaqx",
3353 "kind": "user",
3354 "verified": false,
3355 "workspaces": []
3356 },
3357 "requested_by": null,
3358 "created_at": "2026-10-01T18:04:11.482Z",
3359 "updated_at": "2026-10-01T18:09:47.305Z",
3360 "closed_at": null,
3361 "pull_count": 0,
3362 "comment_count": 0,
3363 "assignees": [
3364 "syntaqx"
3365 ],
3366 "blocked_by": [
3367 9
3368 ],
3369 "agent": null,
3370 "milestone": {
3371 "number": 3,
3372 "title": "Launch"
3373 }
3374 },
3375 "definition_of_done": [
3376 "`cargo test` passes.",
3377 "The README shows the new usage."
3378 ],
3379 "required_checks": [
3380 "CI"
3381 ],
3382 "claims": [
3383 {
3384 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3385 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3386 "issue": 12,
3387 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3388 "actor": {
3389 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3390 "username": "syntaqx"
3391 },
3392 "harness": "claude_code",
3393 "note": "Taking the argument parsing first.",
3394 "state": "active",
3395 "created_at": "2026-10-12T14:03:02.771Z",
3396 "expires_at": "2026-10-12T15:01:40.518Z",
3397 "ended_at": null,
3398 "end_reason": null,
3399 "handoff_to": null
3400 }
3401 ],
3402 "sessions": [
3403 {
3404 "id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3405 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3406 "issue": 12,
3407 "pull": 14,
3408 "branch": "greet-caller",
3409 "actor": {
3410 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3411 "username": "syntaqx"
3412 },
3413 "harness": "claude_code",
3414 "harness_session_id": "5b0c1f9e-3d2a-4e8b-9f61-0c7d2a9e4b13",
3415 "title": "Make the greeting name the caller",
3416 "state": "active",
3417 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3418 "started_at": "2026-10-12T14:02:11.204Z",
3419 "last_seen_at": "2026-10-12T14:31:40.518Z",
3420 "ended_at": null,
3421 "end_reason": null
3422 }
3423 ],
3424 "pulls": [
3425 {
3426 "number": 14,
3427 "title": "Greeting should name the caller",
3428 "status": "draft",
3429 "branch": "greet-caller",
3430 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3431 "author": {
3432 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3433 "username": "syntaqx"
3434 },
3435 "check_status": null,
3436 "required_checks": [
3437 {
3438 "name": "CI",
3439 "state": "success",
3440 "description": "CI passed",
3441 "target_url": "https://g1t.sh/syntaqx/hello/actions/runs/run_01m43sw8e2g6j0m4q8t2x6a0c4"
3442 }
3443 ],
3444 "mergeable": "clean",
3445 "overlaps": [
3446 {
3447 "number": 11,
3448 "title": "Parse arguments with clap",
3449 "issue": 9,
3450 "paths": [
3451 "src/main.rs"
3452 ]
3453 }
3454 ],
3455 "queue": null
3456 }
3457 ],
3458 "blocked_by": [
3459 {
3460 "number": 9,
3461 "title": "Read arguments with a parser",
3462 "state": "open",
3463 "claims": [
3464 {
3465 "id": "clm_01m4b2a4c6e8g0j2l4n6q8s0u2",
3466 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3467 "issue": 9,
3468 "session_id": null,
3469 "actor": {
3470 "id": "usr_01kkp2v7d4fh8m3q6t9w2z5c8e",
3471 "username": "ana"
3472 },
3473 "harness": null,
3474 "note": null,
3475 "state": "active",
3476 "created_at": "2026-10-12T13:50:12.000Z",
3477 "expires_at": "2026-10-12T14:20:12.000Z",
3478 "ended_at": null,
3479 "end_reason": null,
3480 "handoff_to": null
3481 }
3482 ],
3483 "pulls": [
3484 {
3485 "number": 11,
3486 "title": "Parse arguments with clap",
3487 "status": "open"
3488 }
3489 ]
3490 }
3491 ],
3492 "blocks": [
3493 {
3494 "number": 15,
3495 "title": "Greet in the caller's language",
3496 "state": "open"
3497 }
3498 ],
3499 "decisions": [
3500 {
3501 "id": "dec_01m4b3e7g9j1l3n5q7s9u1w3y5",
3502 "issue": 12,
3503 "pull": 14,
3504 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3505 "actor": "syntaqx",
3506 "kind": "proposal",
3507 "confidence": "claimed",
3508 "summary": "Read the name with the argument parser #9 brings, rather than by hand.",
3509 "evidence": {
3510 "commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13"
3511 },
3512 "created_at": "2026-10-12T14:20:00.000Z"
3513 }
3514 ],
3515 "last_integration_failure": null,
3516 "recent": [
3517 {
3518 "id": "evt_01m4b3d5f7h9k1m3p5r7t9w1y4",
3519 "type": "work.claimed",
3520 "source": "work",
3521 "time": "2026-10-12T14:03:02.771Z",
3522 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3523 "actor": "usr_01kkntcg1eeb98j62xjm7eh09p",
3524 "data": {
3525 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3526 "number": 12,
3527 "issue": 12,
3528 "claim": {
3529 "id": "clm_01m4b3d5f7h9k1m3p5r7t9w1y3",
3530 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3531 "issue": 12,
3532 "session_id": "ses_01m4b2c3d4e5f6g7h8j9k0m1n2",
3533 "actor": {
3534 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
3535 "username": "syntaqx"
3536 },
3537 "harness": "claude_code",
3538 "note": "Taking the argument parsing first.",
3539 "state": "active",
3540 "created_at": "2026-10-12T14:03:02.771Z",
3541 "expires_at": "2026-10-12T15:01:40.518Z",
3542 "ended_at": null,
3543 "end_reason": null,
3544 "handoff_to": null
3545 },
3546 "others": [
3547 {
3548 "id": "clm_01m4b2a4c6e8g0j2l4n6q8s0u2",
3549 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
3550 "issue": 12,
3551 "session_id": null,
3552 "actor": {
3553 "id": "usr_01kkp2v7d4fh8m3q6t9w2z5c8e",
3554 "username": "ana"
3555 },
3556 "harness": null,
3557 "note": "Looking at the tests.",
3558 "state": "active",
3559 "created_at": "2026-10-12T13:50:12.000Z",
3560 "expires_at": "2026-10-12T14:20:12.000Z",
3561 "ended_at": null,
3562 "end_reason": null,
3563 "handoff_to": null
3564 }
3565 ]
3566 }
3567 }
3568 ]
3569 },
3570 "notes": "`pulls` are the issue's pull requests, oldest first; `required_checks`, `mergeable`, `overlaps` and `queue` (its `state` and `position` in the merge queue, 1 at the front) are filled in for those still open or draft. `recent` holds up to 20 coordination events about the issue or its pull requests, newest first. See [Picking up an issue](/guides/sessions/#picking-up-an-issue)."
3571 },
3572 "record_decision": {
3573 "request": {
3574 "kind": "fix",
3575 "summary": "Renamed the config key #12 also introduced, so both read retry_limit.",
3576 "evidence": {
3577 "commit": "7d3e9a1c5b2f4e6a8c0d2e4f6a8b0c2d4e6f8a0b"
3578 },
3579 "session_id": "ses_01kpz7x9y1z3a5b7c9d1e3f5gh"
3580 },
3581 "response": {
3582 "id": "dec_01kpz9a1b3c5d7e9f1g3h5j7kb",
3583 "issue": 9,
3584 "pull": 14,
3585 "session_id": "ses_01kpz7x9y1z3a5b7c9d1e3f5gh",
3586 "actor": "ana",
3587 "kind": "fix",
3588 "confidence": "claimed",
3589 "summary": "Renamed the config key #12 also introduced, so both read retry_limit.",
3590 "evidence": {
3591 "commit": "7d3e9a1c5b2f4e6a8c0d2e4f6a8b0c2d4e6f8a0b"
3592 },
3593 "created_at": "2026-10-12T15:31:40.019Z"
3594 },
3595 "notes": "Kept as `claimed`. g1t records `integration_failure`, `integration_passed`, `approval` and `merge` itself. Publishes `decision.recorded`. See [decision records](/guides/why-blame/#decision-records)."
3596 },
3597 "list_decisions": {
3598 "response": [
3599 {
3600 "id": "dec_01kpz8m2q4r6s8t0v2w4x6y8za",
3601 "issue": 9,
3602 "pull": 14,
3603 "session_id": null,
3604 "actor": null,
3605 "kind": "integration_failure",
3606 "confidence": "tested",
3607 "summary": "#14 failed in the merge queue together with #12: `CI / merge_group` failed when they were combined.",
3608 "evidence": {
3609 "commit": "4be1c0d9a2f3e4b5c6d7e8f90a1b2c3d4e5f6a7b",
3610 "check": {
3611 "name": "CI / merge_group",
3612 "conclusion": "failure",
3613 "url": "https://g1t.sh/acme/web/actions/runs/run_01kpz8k0"
3614 },
3615 "combination": [
3616 11,
3617 12,
3618 14
3619 ],
3620 "other_pulls": [
3621 11,
3622 12
3623 ],
3624 "suspects": [
3625 12
3626 ],
3627 "bisected": true,
3628 "landed": []
3629 },
3630 "created_at": "2026-10-12T15:04:11.204Z"
3631 },
3632 {
3633 "id": "dec_01kpz9a1b3c5d7e9f1g3h5j7kb",
3634 "issue": 9,
3635 "pull": 14,
3636 "session_id": "ses_01kpz7x9y1z3a5b7c9d1e3f5gh",
3637 "actor": "ana",
3638 "kind": "fix",
3639 "confidence": "claimed",
3640 "summary": "Renamed the config key #12 also introduced, so both read retry_limit.",
3641 "evidence": {
3642 "commit": "7d3e9a1c5b2f4e6a8c0d2e4f6a8b0c2d4e6f8a0b"
3643 },
3644 "created_at": "2026-10-12T15:31:40.019Z"
3645 }
3646 ],
3647 "notes": "`GET /repos/{owner}/{name}/issues/{number}/decisions` lists an issue's, with those on its pull requests."
3648 },
3649 "why": {
3650 "query": {
3651 "path": "src/config.rs",
3652 "line": 42
3653 },
3654 "response": {
3655 "path": "src/config.rs",
3656 "line": 42,
3657 "commit": {
3658 "hash": "7d3e9a1c5b2f4e6a8c0d2e4f6a8b0c2d4e6f8a0b",
3659 "tree_hash": "c1d2e3f4a5b6c7d8e9f0a1b2c3d4e5f6a7b8c9d0",
3660 "message": "Read retry_limit, as #12 names it",
3661 "author": {
3662 "name": "Ana Lima",
3663 "username": "ana"
3664 },
3665 "parents": [
3666 "4be1c0d9a2f3e4b5c6d7e8f90a1b2c3d4e5f6a7b"
3667 ],
3668 "authored_at": "2026-10-12T15:29:02Z"
3669 },
3670 "pull": {
3671 "number": 14,
3672 "title": "Retry failed webhook deliveries",
3673 "author": "ana",
3674 "agent": "claude-code",
3675 "merged_by": "g1t",
3676 "merged_at": "2026-10-12T15:52:18.330Z"
3677 },
3678 "issue": {
3679 "number": 9,
3680 "title": "Webhook deliveries are not retried",
3681 "state": "closed",
3682 "body": "A delivery that times out is never sent again."
3683 },
3684 "decisions": [
3685 {
3686 "id": "dec_01kpz8m2q4r6s8t0v2w4x6y8za",
3687 "issue": 9,
3688 "pull": 14,
3689 "session_id": null,
3690 "actor": null,
3691 "kind": "integration_failure",
3692 "confidence": "tested",
3693 "summary": "#14 failed in the merge queue together with #12: `CI / merge_group` failed when they were combined.",
3694 "evidence": {
3695 "commit": "4be1c0d9a2f3e4b5c6d7e8f90a1b2c3d4e5f6a7b",
3696 "check": {
3697 "name": "CI / merge_group",
3698 "conclusion": "failure",
3699 "url": "https://g1t.sh/acme/web/actions/runs/run_01kpz8k0"
3700 },
3701 "combination": [
3702 11,
3703 12,
3704 14
3705 ],
3706 "other_pulls": [
3707 11,
3708 12
3709 ],
3710 "suspects": [
3711 12
3712 ],
3713 "bisected": true,
3714 "landed": []
3715 },
3716 "created_at": "2026-10-12T15:04:11.204Z"
3717 },
3718 {
3719 "id": "dec_01kpz9a1b3c5d7e9f1g3h5j7kb",
3720 "issue": 9,
3721 "pull": 14,
3722 "session_id": "ses_01kpz7x9y1z3a5b7c9d1e3f5gh",
3723 "actor": "ana",
3724 "kind": "fix",
3725 "confidence": "claimed",
3726 "summary": "Renamed the config key #12 also introduced, so both read retry_limit.",
3727 "evidence": {
3728 "commit": "7d3e9a1c5b2f4e6a8c0d2e4f6a8b0c2d4e6f8a0b"
3729 },
3730 "created_at": "2026-10-12T15:31:40.019Z"
3731 }
3732 ],
3733 "sessions": [
3734 {
3735 "seq": 31,
3736 "kind": "message",
3737 "text": "#12 renamed retries to retry_limit; reading the new name here.",
3738 "tool": null,
3739 "commit": null,
3740 "at": "2026-10-12T15:27:40.118Z"
3741 }
3742 ]
3743 },
3744 "notes": "`ref` reads the file at a branch, tag or commit. See [sessions and why-blame](/guides/why-blame/#why-over-the-api)."
3745 },
3746 "list_workflows": {
3747 "response": [
3748 {
3749 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
3750 "path": ".g1t/workflows/ci.yml",
3751 "name": "CI",
3752 "events": [
3753 "push",
3754 "pull_request",
3755 "workflow_dispatch"
3756 ],
3757 "state": "active",
3758 "error": null,
3759 "notes": [
3760 {
3761 "severity": "unsupported",
3762 "job": "test",
3763 "message": "`services` containers (such as a database) are not started on g1t yet."
3764 }
3765 ],
3766 "dispatch": {
3767 "debug": {
3768 "description": "Verbose logs",
3769 "type": "boolean",
3770 "default": false
3771 }
3772 },
3773 "last_run": {
3774 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3775 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
3776 "path": ".g1t/workflows/ci.yml",
3777 "name": "CI",
3778 "title": "Greeting should name the caller",
3779 "number": 12,
3780 "attempt": 1,
3781 "event": "push",
3782 "ref": "refs/heads/main",
3783 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3784 "pull": null,
3785 "status": "completed",
3786 "conclusion": "success",
3787 "error": null,
3788 "actor": "syntaqx",
3789 "created_at": "2026-10-04T15:42:07.318Z",
3790 "started_at": "2026-10-04T15:42:09.020Z",
3791 "finished_at": "2026-10-04T15:44:31.877Z"
3792 }
3793 },
3794 {
3795 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq",
3796 "path": ".g1t/workflows/nightly.yml",
3797 "name": "Nightly",
3798 "events": [
3799 "schedule"
3800 ],
3801 "state": "disabled",
3802 "error": null,
3803 "notes": [],
3804 "dispatch": null,
3805 "last_run": null
3806 }
3807 ],
3808 "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/)."
3809 },
3810 "get_workflow": {
3811 "params": {
3812 "workflow": "release.yml"
3813 },
3814 "query": {
3815 "ref": "main"
3816 },
3817 "response": {
3818 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nr",
3819 "path": ".g1t/workflows/release.yml",
3820 "name": "Release",
3821 "events": [
3822 "workflow_dispatch"
3823 ],
3824 "state": "active",
3825 "error": null,
3826 "notes": [],
3827 "dispatch": {
3828 "channel": {
3829 "type": "choice",
3830 "options": [
3831 "beta",
3832 "stable"
3833 ],
3834 "default": "beta"
3835 }
3836 },
3837 "last_run": null,
3838 "ref": "main",
3839 "source": "name: Release\non:\n workflow_dispatch:\n inputs:\n channel:\n type: choice\n options: [beta, stable]\n default: beta\njobs:\n release:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n - run: ./scripts/release.sh ${{ inputs.channel }}\n"
3840 },
3841 "notes": "`workflow` is the workflow's id, file name, path or name. `source` is its file as written on `ref`; `404` when the file is not on that branch or tag."
3842 },
3843 "list_workflow_runs": {
3844 "query": {
3845 "workflow": "ci.yml",
3846 "branch": "main",
3847 "per_page": 20
3848 },
3849 "response": [
3850 {
3851 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3852 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
3853 "path": ".g1t/workflows/ci.yml",
3854 "name": "CI",
3855 "title": "Greeting should name the caller",
3856 "number": 12,
3857 "attempt": 1,
3858 "event": "push",
3859 "ref": "refs/heads/main",
3860 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3861 "pull": null,
3862 "status": "completed",
3863 "conclusion": "success",
3864 "error": null,
3865 "actor": "syntaqx",
3866 "created_at": "2026-10-04T15:42:07.318Z",
3867 "started_at": "2026-10-04T15:42:09.020Z",
3868 "finished_at": "2026-10-04T15:44:31.877Z"
3869 }
3870 ],
3871 "notes": "A run's `status` is `queued`, `pending` (waiting for its concurrency group), `in_progress` or `completed`; `conclusion` is set once it completes."
3872 },
3873 "list_runs_of_workflow": {
3874 "params": {
3875 "workflow": "ci.yml"
3876 },
3877 "query": {
3878 "branch": "main",
3879 "per_page": 20
3880 },
3881 "response": [
3882 {
3883 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3884 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
3885 "path": ".g1t/workflows/ci.yml",
3886 "name": "CI",
3887 "title": "Greeting should name the caller",
3888 "number": 12,
3889 "attempt": 1,
3890 "event": "push",
3891 "ref": "refs/heads/main",
3892 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3893 "pull": null,
3894 "status": "completed",
3895 "conclusion": "success",
3896 "error": null,
3897 "actor": "syntaqx",
3898 "created_at": "2026-10-04T15:42:07.318Z",
3899 "started_at": "2026-10-04T15:42:09.020Z",
3900 "finished_at": "2026-10-04T15:44:31.877Z"
3901 }
3902 ]
3903 },
3904 "get_workflow_run": {
3905 "params": {
3906 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr"
3907 },
3908 "response": {
3909 "run": {
3910 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3911 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
3912 "path": ".g1t/workflows/ci.yml",
3913 "name": "CI",
3914 "title": "Greeting should name the caller",
3915 "number": 12,
3916 "attempt": 1,
3917 "event": "push",
3918 "ref": "refs/heads/main",
3919 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
3920 "pull": null,
3921 "status": "completed",
3922 "conclusion": "failure",
3923 "error": null,
3924 "actor": "syntaqx",
3925 "created_at": "2026-10-04T15:42:07.318Z",
3926 "started_at": "2026-10-04T15:42:09.020Z",
3927 "finished_at": "2026-10-04T15:44:31.877Z"
3928 },
3929 "jobs": [
3930 {
3931 "id": "job_01kpx7b3d0e4f8g2h6j0k4m8ns",
3932 "run_id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3933 "key": "test",
3934 "name": "test",
3935 "needs": [],
3936 "status": "completed",
3937 "conclusion": "failure",
3938 "steps": [
3939 {
3940 "number": 1,
3941 "name": "Run actions/checkout@v4",
3942 "status": "completed",
3943 "conclusion": "success",
3944 "started_at": "2026-10-04T15:42:10.101Z",
3945 "finished_at": "2026-10-04T15:42:12.433Z"
3946 },
3947 {
3948 "number": 2,
3949 "name": "Run cargo test",
3950 "status": "completed",
3951 "conclusion": "failure",
3952 "started_at": "2026-10-04T15:42:12.440Z",
3953 "finished_at": "2026-10-04T15:44:30.902Z"
3954 }
3955 ],
3956 "annotations": [
3957 {
3958 "level": "error",
3959 "message": "assertion failed: greeting names the caller",
3960 "title": "greet",
3961 "file": "src/main.rs",
3962 "line": 41
3963 }
3964 ],
3965 "reason": null,
3966 "started_at": "2026-10-04T15:42:09.020Z",
3967 "finished_at": "2026-10-04T15:44:31.002Z"
3968 },
3969 {
3970 "id": "job_01kpx7b3d0e4f8g2h6j0k4m8nt",
3971 "run_id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
3972 "key": "deploy",
3973 "name": "deploy",
3974 "needs": [
3975 "test"
3976 ],
3977 "status": "completed",
3978 "conclusion": "skipped",
3979 "steps": [],
3980 "annotations": [],
3981 "reason": "A job it needs did not succeed.",
3982 "started_at": null,
3983 "finished_at": "2026-10-04T15:44:31.877Z"
3984 }
3985 ],
3986 "notes": [
3987 {
3988 "severity": "unsupported",
3989 "job": "test",
3990 "message": "`services` containers (such as a database) are not started on g1t yet."
3991 }
3992 ],
3993 "attempts": [
3994 {
3995 "attempt": 1,
3996 "status": "completed",
3997 "conclusion": "failure",
3998 "actor": "syntaqx",
3999 "debug": false,
4000 "started_at": "2026-10-04T15:42:09.020Z",
4001 "finished_at": "2026-10-04T15:44:31.877Z"
4002 }
4003 ]
4004 },
4005 "notes": "Each re-run is a new attempt. Read an earlier one with `attempt`, or at `GET /repos/{owner}/{repo}/actions/runs/{id}/attempts/{attempt}`; its jobs have ids of their own, so `get_job_logs` reads the log each had then. A job that is `cancelling` was cancelled and is running its cleanup steps."
4006 },
4007 "get_job_logs": {
4008 "params": {
4009 "job": "job_01kpx7b3d0e4f8g2h6j0k4m8ns"
4010 },
4011 "query": {
4012 "after": 0
4013 },
4014 "response": {
4015 "chunks": [
4016 {
4017 "seq": 1,
4018 "step": 0,
4019 "text": "Preparing the sandbox\n"
4020 },
4021 {
4022 "seq": 2,
4023 "step": 2,
4024 "text": "> cargo test\ntest greet ... FAILED\n"
4025 }
4026 ],
4027 "done": true
4028 },
4029 "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`."
4030 },
4031 "dispatch_workflow": {
4032 "params": {
4033 "workflow": "ci.yml"
4034 },
4035 "request": {
4036 "ref": "main",
4037 "inputs": {
4038 "debug": true
4039 }
4040 },
4041 "response": {
4042 "id": "run_01kpx8d4e7f0g3h6j9k2m5n8pq",
4043 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4044 "path": ".g1t/workflows/ci.yml",
4045 "name": "CI",
4046 "title": "CI run by syntaqx",
4047 "number": 13,
4048 "attempt": 1,
4049 "event": "workflow_dispatch",
4050 "ref": "refs/heads/main",
4051 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4052 "pull": null,
4053 "status": "queued",
4054 "conclusion": null,
4055 "error": null,
4056 "actor": "syntaqx",
4057 "created_at": "2026-10-04T16:30:00.512Z",
4058 "started_at": null,
4059 "finished_at": null
4060 }
4061 },
4062 "cancel_workflow_run": {
4063 "params": {
4064 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr"
4065 },
4066 "response": {
4067 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
4068 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4069 "path": ".g1t/workflows/ci.yml",
4070 "name": "CI",
4071 "title": "Greeting should name the caller",
4072 "number": 12,
4073 "attempt": 1,
4074 "event": "push",
4075 "ref": "refs/heads/main",
4076 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4077 "pull": null,
4078 "status": "completed",
4079 "conclusion": "cancelled",
4080 "error": null,
4081 "actor": "syntaqx",
4082 "created_at": "2026-10-04T15:42:07.318Z",
4083 "started_at": "2026-10-04T15:42:09.020Z",
4084 "finished_at": "2026-10-04T15:44:31.877Z"
4085 }
4086 },
4087 "rerun_workflow_run": {
4088 "params": {
4089 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr"
4090 },
4091 "request": {
4092 "failed_only": true
4093 },
4094 "response": {
4095 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
4096 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4097 "path": ".g1t/workflows/ci.yml",
4098 "name": "CI",
4099 "title": "Greeting should name the caller",
4100 "number": 12,
4101 "attempt": 2,
4102 "event": "push",
4103 "ref": "refs/heads/main",
4104 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4105 "pull": null,
4106 "status": "queued",
4107 "conclusion": null,
4108 "error": null,
4109 "actor": "syntaqx",
4110 "created_at": "2026-10-04T15:42:07.318Z",
4111 "started_at": null,
4112 "finished_at": null
4113 },
4114 "notes": "The run keeps its id; `attempt` goes up by one."
4115 },
4116 "rerun_failed_jobs": {
4117 "params": {
4118 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr"
4119 },
4120 "response": {
4121 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
4122 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4123 "path": ".g1t/workflows/ci.yml",
4124 "name": "CI",
4125 "title": "Greeting should name the caller",
4126 "number": 12,
4127 "attempt": 2,
4128 "event": "push",
4129 "ref": "refs/heads/main",
4130 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4131 "pull": null,
4132 "status": "queued",
4133 "conclusion": null,
4134 "error": null,
4135 "actor": "syntaqx",
4136 "created_at": "2026-10-04T15:42:07.318Z",
4137 "started_at": null,
4138 "finished_at": null
4139 }
4140 },
4141 "rerun_job": {
4142 "params": {
4143 "job": "job_01kpx7b3d0e4f8g2h6j0k4m8ns"
4144 },
4145 "request": {
4146 "enable_debug_logging": true
4147 },
4148 "response": {
4149 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
4150 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4151 "path": ".g1t/workflows/ci.yml",
4152 "name": "CI",
4153 "title": "Greeting should name the caller",
4154 "number": 12,
4155 "attempt": 2,
4156 "event": "push",
4157 "ref": "refs/heads/main",
4158 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4159 "pull": null,
4160 "status": "queued",
4161 "conclusion": null,
4162 "error": null,
4163 "actor": "syntaqx",
4164 "created_at": "2026-10-04T15:42:07.318Z",
4165 "started_at": null,
4166 "finished_at": null
4167 },
4168 "notes": "Runs the job again with every job that needs it, as a new attempt; the rest keep how they ended. A job of a matrix runs again with the rest of its matrix, and a job of a called workflow with the job that calls it. The run must have finished."
4169 },
4170 "force_cancel_workflow_run": {
4171 "params": {
4172 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr"
4173 },
4174 "response": {
4175 "id": "run_01kpx7b3c6d9e2f5g8h1j4k7mr",
4176 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
4177 "path": ".g1t/workflows/ci.yml",
4178 "name": "CI",
4179 "title": "Greeting should name the caller",
4180 "number": 12,
4181 "attempt": 1,
4182 "event": "push",
4183 "ref": "refs/heads/main",
4184 "sha": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
4185 "pull": null,
4186 "status": "completed",
4187 "conclusion": "cancelled",
4188 "error": null,
4189 "actor": "syntaqx",
4190 "created_at": "2026-10-04T15:42:07.318Z",
4191 "started_at": "2026-10-04T15:42:09.020Z",
4192 "finished_at": "2026-10-04T15:43:02.411Z"
4193 },
4194 "notes": "Stops running jobs at once, without their `if: always()`, `cancelled()` or post steps. Use it when a job's cleanup hangs."
4195 },
4196 "update_workflow": {
4197 "params": {
4198 "workflow": "nightly.yml"
4199 },
4200 "request": {
4201 "enabled": false
4202 },
4203 "response": {
4204 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq",
4205 "path": ".g1t/workflows/nightly.yml",
4206 "name": "Nightly",
4207 "events": [
4208 "schedule"
4209 ],
4210 "state": "disabled",
4211 "error": null,
4212 "notes": [],
4213 "dispatch": null,
4214 "last_run": null
4215 }
4216 },
4217 "enable_workflow": {
4218 "params": {
4219 "workflow": "nightly.yml"
4220 },
4221 "response": {
4222 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq",
4223 "path": ".g1t/workflows/nightly.yml",
4224 "name": "Nightly",
4225 "events": [
4226 "schedule"
4227 ],
4228 "state": "active",
4229 "error": null,
4230 "notes": [],
4231 "dispatch": null,
4232 "last_run": null
4233 }
4234 },
4235 "disable_workflow": {
4236 "params": {
4237 "workflow": "nightly.yml"
4238 },
4239 "response": {
4240 "id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9nq",
4241 "path": ".g1t/workflows/nightly.yml",
4242 "name": "Nightly",
4243 "events": [
4244 "schedule"
4245 ],
4246 "state": "disabled",
4247 "error": null,
4248 "notes": [],
4249 "dispatch": null,
4250 "last_run": null
4251 }
4252 },
4253 "list_actions_secrets": {
4254 "response": [
4255 {
4256 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ab",
4257 "name": "NPM_TOKEN",
4258 "kind": "secret",
4259 "value": null,
4260 "scope": "workspace",
4261 "updated_at": "2026-10-01T09:12:44.020Z",
4262 "available_to": [
4263 "workflows"
4264 ],
4265 "environments": [],
4266 "projects": [],
4267 "note": null,
4268 "updated_by": "syntaqx",
4269 "brokered_hosts": [
4270 "registry.npmjs.org"
4271 ]
4272 },
4273 {
4274 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac",
4275 "name": "STRIPE_KEY",
4276 "kind": "secret",
4277 "value": null,
4278 "scope": "project",
4279 "updated_at": "2026-10-04T15:42:07.318Z",
4280 "available_to": [
4281 "workflows",
4282 "deployments"
4283 ],
4284 "environments": [
4285 "production"
4286 ],
4287 "projects": [],
4288 "note": "Rotate in the Stripe dashboard.",
4289 "updated_by": "syntaqx",
4290 "brokered_hosts": []
4291 }
4292 ],
4293 "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; empty `brokered_hosts`, a secret that is not brokered."
4294 },
4295 "list_actions_secrets_for_workspace": {
4296 "params": {
4297 "workspace": "flagon-io"
4298 },
4299 "response": [
4300 {
4301 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ab",
4302 "name": "NPM_TOKEN",
4303 "kind": "secret",
4304 "value": null,
4305 "scope": "workspace",
4306 "updated_at": "2026-10-04T15:42:07.318Z",
4307 "available_to": [
4308 "workflows"
4309 ],
4310 "environments": [],
4311 "projects": [],
4312 "note": null,
4313 "updated_by": "syntaqx",
4314 "brokered_hosts": [
4315 "registry.npmjs.org"
4316 ]
4317 }
4318 ],
4319 "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; empty `brokered_hosts`, a secret that is not brokered."
4320 },
4321 "set_actions_secret": {
4322 "params": {
4323 "setting": "STRIPE_KEY"
4324 },
4325 "request": {
4326 "value": "sk_live_…",
4327 "available_to": [
4328 "workflows",
4329 "deployments"
4330 ],
4331 "environments": [
4332 "production"
4333 ]
4334 },
4335 "response": {
4336 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac",
4337 "name": "STRIPE_KEY",
4338 "kind": "secret",
4339 "value": null,
4340 "scope": "project",
4341 "updated_at": "2026-10-04T15:42:07.318Z",
4342 "available_to": [
4343 "workflows",
4344 "deployments"
4345 ],
4346 "environments": [
4347 "production"
4348 ],
4349 "projects": [],
4350 "note": null,
4351 "updated_by": "syntaqx",
4352 "brokered_hosts": []
4353 },
4354 "notes": "Keys are uppercased. See [secrets and variables](/guides/secrets-and-variables/)."
4355 },
4356 "set_actions_secret_for_workspace": {
4357 "params": {
4358 "workspace": "flagon-io",
4359 "setting": "NPM_TOKEN"
4360 },
4361 "request": {
4362 "value": "npm_…",
4363 "projects": [
4364 "hello"
4365 ],
4366 "brokered_hosts": [
4367 "registry.npmjs.org"
4368 ]
4369 },
4370 "response": {
4371 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ac",
4372 "name": "NPM_TOKEN",
4373 "kind": "secret",
4374 "value": null,
4375 "scope": "workspace",
4376 "updated_at": "2026-10-04T15:42:07.318Z",
4377 "available_to": [
4378 "workflows"
4379 ],
4380 "environments": [],
4381 "projects": [
4382 "hello"
4383 ],
4384 "note": null,
4385 "updated_by": "syntaqx",
4386 "brokered_hosts": [
4387 "registry.npmjs.org"
4388 ]
4389 }
4390 },
4391 "delete_actions_secret": {
4392 "params": {
4393 "setting": "STRIPE_KEY"
4394 },
4395 "response": true
4396 },
4397 "delete_actions_secret_for_workspace": {
4398 "params": {
4399 "workspace": "flagon-io",
4400 "setting": "NPM_TOKEN"
4401 },
4402 "response": true
4403 },
4404 "list_actions_variables": {
4405 "response": [
4406 {
4407 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4408 "name": "NODE_VERSION",
4409 "kind": "variable",
4410 "value": "20",
4411 "scope": "project",
4412 "updated_at": "2026-10-04T15:42:07.318Z",
4413 "available_to": [
4414 "workflows",
4415 "deployments"
4416 ],
4417 "environments": [],
4418 "projects": [],
4419 "note": null,
4420 "updated_by": "syntaqx"
4421 }
4422 ],
4423 "notes": "A repository's list includes the workspace's rows that reach it, with `scope` set to `workspace`. Empty `environments` means every environment."
4424 },
4425 "list_actions_variables_for_workspace": {
4426 "params": {
4427 "workspace": "flagon-io"
4428 },
4429 "response": [
4430 {
4431 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4432 "name": "NODE_VERSION",
4433 "kind": "variable",
4434 "value": "20",
4435 "scope": "workspace",
4436 "updated_at": "2026-10-04T15:42:07.318Z",
4437 "available_to": [
4438 "workflows",
4439 "deployments"
4440 ],
4441 "environments": [],
4442 "projects": [],
4443 "note": null,
4444 "updated_by": "syntaqx"
4445 }
4446 ]
4447 },
4448 "set_actions_variable": {
4449 "request": {
4450 "setting": "NODE_VERSION",
4451 "value": "20"
4452 },
4453 "response": {
4454 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4455 "name": "NODE_VERSION",
4456 "kind": "variable",
4457 "value": "20",
4458 "scope": "project",
4459 "updated_at": "2026-10-04T15:42:07.318Z",
4460 "available_to": [
4461 "workflows",
4462 "deployments"
4463 ],
4464 "environments": [],
4465 "projects": [],
4466 "note": null,
4467 "updated_by": "syntaqx"
4468 },
4469 "notes": "GitHub's clients send the key as `name`; that is accepted too."
4470 },
4471 "set_actions_variable_for_workspace": {
4472 "params": {
4473 "workspace": "flagon-io"
4474 },
4475 "request": {
4476 "setting": "NODE_VERSION",
4477 "value": "20"
4478 },
4479 "response": {
4480 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4481 "name": "NODE_VERSION",
4482 "kind": "variable",
4483 "value": "20",
4484 "scope": "workspace",
4485 "updated_at": "2026-10-04T15:42:07.318Z",
4486 "available_to": [
4487 "workflows",
4488 "deployments"
4489 ],
4490 "environments": [],
4491 "projects": [],
4492 "note": null,
4493 "updated_by": "syntaqx"
4494 }
4495 },
4496 "update_actions_variable": {
4497 "params": {
4498 "setting": "NODE_VERSION"
4499 },
4500 "request": {
4501 "value": "22"
4502 },
4503 "response": {
4504 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4505 "name": "NODE_VERSION",
4506 "kind": "variable",
4507 "value": "22",
4508 "scope": "project",
4509 "updated_at": "2026-10-04T15:42:07.318Z",
4510 "available_to": [
4511 "workflows",
4512 "deployments"
4513 ],
4514 "environments": [],
4515 "projects": [],
4516 "note": null,
4517 "updated_by": "syntaqx"
4518 }
4519 },
4520 "update_actions_variable_for_workspace": {
4521 "params": {
4522 "workspace": "flagon-io",
4523 "setting": "NODE_VERSION"
4524 },
4525 "request": {
4526 "value": "22"
4527 },
4528 "response": {
4529 "id": "set_01kpv9q4r7s0t3v6w9x2y5z8ad",
4530 "name": "NODE_VERSION",
4531 "kind": "variable",
4532 "value": "22",
4533 "scope": "workspace",
4534 "updated_at": "2026-10-04T15:42:07.318Z",
4535 "available_to": [
4536 "workflows",
4537 "deployments"
4538 ],
4539 "environments": [],
4540 "projects": [],
4541 "note": null,
4542 "updated_by": "syntaqx"
4543 }
4544 },
4545 "delete_actions_variable": {
4546 "params": {
4547 "setting": "NODE_VERSION"
4548 },
4549 "response": true
4550 },
4551 "delete_actions_variable_for_workspace": {
4552 "params": {
4553 "workspace": "flagon-io",
4554 "setting": "NODE_VERSION"
4555 },
4556 "response": true
4557 },
4558 "list_runners": {
4559 "response": [
4560 {
4561 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z",
4562 "name": "build-01",
4563 "workspace": "flagon-io",
4564 "repo": null,
4565 "group": "Default",
4566 "labels": [
4567 "self-hosted",
4568 "linux",
4569 "x64",
4570 "gpu"
4571 ],
4572 "os": "linux",
4573 "arch": "x64",
4574 "version": "0.2.0",
4575 "ephemeral": false,
4576 "status": "busy",
4577 "work": {
4578 "kind": "workflow",
4579 "id": "job_01kq2m9b1d4g7j0m3p6s9v2y5b",
4580 "name": "test (linux, 24)",
4581 "repo": "flagon-io/hello",
4582 "run_id": "run_01kq2m9a8c1f4h7k0n3q6t9w2z",
4583 "started_at": "2026-10-06T14:02:11.000Z"
4584 },
4585 "last_seen_at": "2026-10-06T14:05:40.512Z",
4586 "created_at": "2026-10-02T09:30:00.000Z",
4587 "created_by": null,
4588 "isolation": "nested-container"
4589 },
4590 {
4591 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w9a",
4592 "name": "mac-mini",
4593 "workspace": "flagon-io",
4594 "repo": null,
4595 "group": "Default",
4596 "labels": [
4597 "self-hosted",
4598 "macos",
4599 "arm64"
4600 ],
4601 "os": "macos",
4602 "arch": "arm64",
4603 "version": "0.2.0",
4604 "ephemeral": false,
4605 "status": "online",
4606 "work": null,
4607 "last_seen_at": "2026-10-06T14:05:40.512Z",
4608 "created_at": "2026-10-02T09:30:00.000Z",
4609 "created_by": null,
4610 "isolation": "host"
4611 }
4612 ],
4613 "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."
4614 },
4615 "list_runners_for_workspace": {
4616 "params": {
4617 "workspace": "flagon-io"
4618 },
4619 "response": [
4620 {
4621 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z",
4622 "name": "build-01",
4623 "workspace": "flagon-io",
4624 "repo": null,
4625 "group": "Default",
4626 "labels": [
4627 "self-hosted",
4628 "linux",
4629 "x64",
4630 "gpu"
4631 ],
4632 "os": "linux",
4633 "arch": "x64",
4634 "version": "0.2.0",
4635 "ephemeral": false,
4636 "status": "busy",
4637 "work": {
4638 "kind": "workflow",
4639 "id": "job_01kq2m9b1d4g7j0m3p6s9v2y5b",
4640 "name": "test (linux, 24)",
4641 "repo": "flagon-io/hello",
4642 "run_id": "run_01kq2m9a8c1f4h7k0n3q6t9w2z",
4643 "started_at": "2026-10-06T14:02:11.000Z"
4644 },
4645 "last_seen_at": "2026-10-06T14:05:40.512Z",
4646 "created_at": "2026-10-02T09:30:00.000Z",
4647 "created_by": null,
4648 "isolation": "nested-container"
4649 },
4650 {
4651 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w9a",
4652 "name": "mac-mini",
4653 "workspace": "flagon-io",
4654 "repo": null,
4655 "group": "Default",
4656 "labels": [
4657 "self-hosted",
4658 "macos",
4659 "arm64"
4660 ],
4661 "os": "macos",
4662 "arch": "arm64",
4663 "version": "0.2.0",
4664 "ephemeral": false,
4665 "status": "online",
4666 "work": null,
4667 "last_seen_at": "2026-10-06T14:05:40.512Z",
4668 "created_at": "2026-10-02T09:30:00.000Z",
4669 "created_by": null,
4670 "isolation": "host"
4671 }
4672 ]
4673 },
4674 "create_runner_registration_token": {
4675 "response": {
4676 "token": "g1trt_…",
4677 "expires_at": "2026-10-06T15:04:00.000Z",
4678 "workspace": "flagon-io",
4679 "repo": "flagon-io/hello",
4680 "group": null,
4681 "url": "https://g1t.sh"
4682 },
4683 "notes": "Pass it to `g1t-runner register --url https://g1t.sh --token …` within the hour. See [self-hosted runners](/guides/self-hosted-runners/)."
4684 },
4685 "create_runner_registration_token_for_workspace": {
4686 "params": {
4687 "workspace": "flagon-io"
4688 },
4689 "request": {
4690 "group": "Default"
4691 },
4692 "response": {
4693 "token": "g1trt_…",
4694 "expires_at": "2026-10-06T15:04:00.000Z",
4695 "workspace": "flagon-io",
4696 "repo": null,
4697 "group": "Default",
4698 "url": "https://g1t.sh"
4699 }
4700 },
4701 "remove_runner": {
4702 "params": {
4703 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z"
4704 },
4705 "response": true
4706 },
4707 "remove_runner_for_workspace": {
4708 "params": {
4709 "workspace": "flagon-io",
4710 "id": "rnr_01kq2m8v4c7f0h3k6n9q2t5w8z"
4711 },
4712 "response": true
4713 },
4714 "get_runner_settings": {
4715 "response": {
4716 "agents_on_self_hosted": false,
4717 "agent_labels": [
4718 "self-hosted",
4719 "linux"
4720 ],
4721 "fork_pull_requests": false,
4722 "inherited": true
4723 }
4724 },
4725 "get_runner_settings_for_workspace": {
4726 "params": {
4727 "workspace": "flagon-io"
4728 },
4729 "response": {
4730 "agents_on_self_hosted": true,
4731 "agent_labels": [
4732 "self-hosted",
4733 "linux"
4734 ],
4735 "fork_pull_requests": false,
4736 "inherited": false
4737 }
4738 },
4739 "update_runner_settings": {
4740 "request": {
4741 "inherit": true
4742 },
4743 "response": {
4744 "agents_on_self_hosted": false,
4745 "agent_labels": [
4746 "self-hosted",
4747 "linux"
4748 ],
4749 "fork_pull_requests": false,
4750 "inherited": true
4751 }
4752 },
4753 "update_runner_settings_for_workspace": {
4754 "params": {
4755 "workspace": "flagon-io"
4756 },
4757 "request": {
4758 "agents_on_self_hosted": true,
4759 "agent_labels": [
4760 "linux"
4761 ]
4762 },
4763 "response": {
4764 "agents_on_self_hosted": true,
4765 "agent_labels": [
4766 "self-hosted",
4767 "linux"
4768 ],
4769 "fork_pull_requests": false,
4770 "inherited": false
4771 },
4772 "notes": "`agents_on_self_hosted` and `agent_labels` keep their names from before g1t ran agents of its own: they now send g1t's own work (pull request checks and merge checks) to your runners with those labels."
4773 },
4774 "list_runner_groups": {
4775 "params": {
4776 "workspace": "flagon-io"
4777 },
4778 "response": [
4779 {
4780 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6y",
4781 "name": "Default",
4782 "default": true,
4783 "repositories": [],
4784 "runners": 2,
4785 "updated_at": "2026-10-02T09:30:00.000Z"
4786 },
4787 {
4788 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z",
4789 "name": "GPU",
4790 "default": false,
4791 "repositories": [
4792 "hello",
4793 "models"
4794 ],
4795 "runners": 1,
4796 "updated_at": "2026-10-05T11:20:00.000Z"
4797 }
4798 ]
4799 },
4800 "create_runner_group": {
4801 "params": {
4802 "workspace": "flagon-io"
4803 },
4804 "request": {
4805 "name": "GPU",
4806 "repositories": [
4807 "hello",
4808 "models"
4809 ]
4810 },
4811 "response": {
4812 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z",
4813 "name": "GPU",
4814 "default": false,
4815 "repositories": [
4816 "hello",
4817 "models"
4818 ],
4819 "runners": 1,
4820 "updated_at": "2026-10-05T11:20:00.000Z"
4821 }
4822 },
4823 "update_runner_group": {
4824 "params": {
4825 "workspace": "flagon-io",
4826 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z"
4827 },
4828 "request": {
4829 "repositories": []
4830 },
4831 "response": {
4832 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z",
4833 "name": "GPU",
4834 "default": false,
4835 "repositories": [],
4836 "runners": 1,
4837 "updated_at": "2026-10-05T11:20:00.000Z"
4838 }
4839 },
4840 "delete_runner_group": {
4841 "params": {
4842 "workspace": "flagon-io",
4843 "id": "rng_01kq2m7r2a5d8g1j4m7p0s3v6z"
4844 },
4845 "response": true
4846 },
4847 "list_webhooks": {
4848 "response": [
4849 {
4850 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4851 "scope": "repo",
4852 "workspace": "flagon-io",
4853 "repo": "flagon-io/hello",
4854 "url": "https://hooks.example.com/g1t",
4855 "events": [
4856 "git.push",
4857 "pull.merged"
4858 ],
4859 "active": true,
4860 "secret_hint": "…9c2e",
4861 "created_by": "syntaqx",
4862 "created_at": "2026-10-04T15:42:07.318Z",
4863 "last_status": "delivered",
4864 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4865 }
4866 ]
4867 },
4868 "list_webhooks_for_workspace": {
4869 "params": {
4870 "workspace": "flagon-io"
4871 },
4872 "response": [
4873 {
4874 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4875 "scope": "workspace",
4876 "workspace": "flagon-io",
4877 "repo": null,
4878 "url": "https://hooks.example.com/g1t",
4879 "events": [
4880 "git.push",
4881 "pull.merged"
4882 ],
4883 "active": true,
4884 "secret_hint": "…9c2e",
4885 "created_by": "syntaqx",
4886 "created_at": "2026-10-04T15:42:07.318Z",
4887 "last_status": "delivered",
4888 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4889 }
4890 ]
4891 },
4892 "create_webhook": {
4893 "request": {
4894 "url": "https://hooks.example.com/g1t",
4895 "events": [
4896 "git.push",
4897 "pull.merged"
4898 ]
4899 },
4900 "response": {
4901 "hook": {
4902 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4903 "scope": "repo",
4904 "workspace": "flagon-io",
4905 "repo": "flagon-io/hello",
4906 "url": "https://hooks.example.com/g1t",
4907 "events": [
4908 "git.push",
4909 "pull.merged"
4910 ],
4911 "active": true,
4912 "secret_hint": "…9c2e",
4913 "created_by": "syntaqx",
4914 "created_at": "2026-10-04T15:42:07.318Z",
4915 "last_status": "delivered",
4916 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4917 },
4918 "secret": "whsec_…"
4919 },
4920 "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/)."
4921 },
4922 "create_webhook_for_workspace": {
4923 "params": {
4924 "workspace": "flagon-io"
4925 },
4926 "request": {
4927 "url": "https://hooks.example.com/g1t"
4928 },
4929 "response": {
4930 "hook": {
4931 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4932 "scope": "workspace",
4933 "workspace": "flagon-io",
4934 "repo": null,
4935 "url": "https://hooks.example.com/g1t",
4936 "events": [
4937 "*"
4938 ],
4939 "active": true,
4940 "secret_hint": "…9c2e",
4941 "created_by": "syntaqx",
4942 "created_at": "2026-10-04T15:42:07.318Z",
4943 "last_status": "delivered",
4944 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4945 },
4946 "secret": "whsec_…"
4947 },
4948 "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/)."
4949 },
4950 "update_webhook": {
4951 "params": {
4952 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
4953 },
4954 "request": {
4955 "active": false
4956 },
4957 "response": {
4958 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4959 "scope": "repo",
4960 "workspace": "flagon-io",
4961 "repo": "flagon-io/hello",
4962 "url": "https://hooks.example.com/g1t",
4963 "events": [
4964 "git.push",
4965 "pull.merged"
4966 ],
4967 "active": false,
4968 "secret_hint": "…9c2e",
4969 "created_by": "syntaqx",
4970 "created_at": "2026-10-04T15:42:07.318Z",
4971 "last_status": "delivered",
4972 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4973 }
4974 },
4975 "update_webhook_for_workspace": {
4976 "params": {
4977 "workspace": "flagon-io",
4978 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
4979 },
4980 "request": {
4981 "active": false
4982 },
4983 "response": {
4984 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
4985 "scope": "workspace",
4986 "workspace": "flagon-io",
4987 "repo": null,
4988 "url": "https://hooks.example.com/g1t",
4989 "events": [
4990 "git.push",
4991 "pull.merged"
4992 ],
4993 "active": false,
4994 "secret_hint": "…9c2e",
4995 "created_by": "syntaqx",
4996 "created_at": "2026-10-04T15:42:07.318Z",
4997 "last_status": "delivered",
4998 "last_delivered_at": "2026-10-04T15:42:07.611Z"
4999 }
5000 },
5001 "delete_webhook": {
5002 "params": {
5003 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5004 },
5005 "response": true
5006 },
5007 "delete_webhook_for_workspace": {
5008 "params": {
5009 "workspace": "flagon-io",
5010 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5011 },
5012 "response": true
5013 },
5014 "ping_webhook": {
5015 "params": {
5016 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5017 },
5018 "response": {
5019 "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st",
5020 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5021 "event_id": "",
5022 "event": "ping",
5023 "status": "delivered",
5024 "attempts": 1,
5025 "response_status": 200,
5026 "response_body": "ok",
5027 "error": null,
5028 "duration_ms": 184,
5029 "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\"}",
5030 "created_at": "2026-10-04T16:01:12.440Z",
5031 "delivered_at": "2026-10-04T16:01:12.631Z",
5032 "next_attempt_at": null
5033 },
5034 "notes": "`payload` is the JSON that was sent, as a string."
5035 },
5036 "ping_webhook_for_workspace": {
5037 "params": {
5038 "workspace": "flagon-io",
5039 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5040 },
5041 "response": {
5042 "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st",
5043 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5044 "event_id": "",
5045 "event": "ping",
5046 "status": "delivered",
5047 "attempts": 1,
5048 "response_status": 200,
5049 "response_body": "ok",
5050 "error": null,
5051 "duration_ms": 184,
5052 "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\"}",
5053 "created_at": "2026-10-04T16:01:12.440Z",
5054 "delivered_at": "2026-10-04T16:01:12.631Z",
5055 "next_attempt_at": null
5056 }
5057 },
5058 "list_webhook_deliveries": {
5059 "params": {
5060 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5061 },
5062 "response": [
5063 {
5064 "id": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz",
5065 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5066 "event_id": "",
5067 "event": "ping",
5068 "status": "pending",
5069 "attempts": 1,
5070 "response_status": 503,
5071 "response_body": "Service Unavailable",
5072 "error": null,
5073 "duration_ms": 212,
5074 "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\"}",
5075 "created_at": "2026-10-04T16:20:03.100Z",
5076 "delivered_at": null,
5077 "next_attempt_at": "2026-10-04T16:21:03.312Z"
5078 },
5079 {
5080 "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st",
5081 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5082 "event_id": "",
5083 "event": "ping",
5084 "status": "delivered",
5085 "attempts": 1,
5086 "response_status": 200,
5087 "response_body": "ok",
5088 "error": null,
5089 "duration_ms": 184,
5090 "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\"}",
5091 "created_at": "2026-10-04T16:01:12.440Z",
5092 "delivered_at": "2026-10-04T16:01:12.631Z",
5093 "next_attempt_at": null
5094 }
5095 ],
5096 "notes": "Returns at most 50, newest first. `status` is `pending`, `delivered` or `failed`; `next_attempt_at` is set while it is pending."
5097 },
5098 "list_webhook_deliveries_for_workspace": {
5099 "params": {
5100 "workspace": "flagon-io",
5101 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd"
5102 },
5103 "response": [
5104 {
5105 "id": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz",
5106 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5107 "event_id": "",
5108 "event": "ping",
5109 "status": "pending",
5110 "attempts": 1,
5111 "response_status": 503,
5112 "response_body": "Service Unavailable",
5113 "error": null,
5114 "duration_ms": 212,
5115 "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\"}",
5116 "created_at": "2026-10-04T16:20:03.100Z",
5117 "delivered_at": null,
5118 "next_attempt_at": "2026-10-04T16:21:03.312Z"
5119 },
5120 {
5121 "id": "dlv_01kpx5p9v2j7k3m8n4p5q6r7st",
5122 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5123 "event_id": "",
5124 "event": "ping",
5125 "status": "delivered",
5126 "attempts": 1,
5127 "response_status": 200,
5128 "response_body": "ok",
5129 "error": null,
5130 "duration_ms": 184,
5131 "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\"}",
5132 "created_at": "2026-10-04T16:01:12.440Z",
5133 "delivered_at": "2026-10-04T16:01:12.631Z",
5134 "next_attempt_at": null
5135 }
5136 ]
5137 },
5138 "redeliver_webhook": {
5139 "params": {
5140 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5141 "delivery": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz"
5142 },
5143 "response": {
5144 "id": "dlv_01kpx6c8d1e2f3g4h5j6k7m8np",
5145 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5146 "event_id": "",
5147 "event": "ping",
5148 "status": "delivered",
5149 "attempts": 1,
5150 "response_status": 200,
5151 "response_body": "ok",
5152 "error": null,
5153 "duration_ms": 171,
5154 "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\"}",
5155 "created_at": "2026-10-04T16:25:40.007Z",
5156 "delivered_at": "2026-10-04T16:25:40.178Z",
5157 "next_attempt_at": null
5158 },
5159 "notes": "The response is the new delivery."
5160 },
5161 "redeliver_webhook_for_workspace": {
5162 "params": {
5163 "workspace": "flagon-io",
5164 "id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5165 "delivery": "dlv_01kpx6a2b3c4d5e6f7g8h9j0kz"
5166 },
5167 "response": {
5168 "id": "dlv_01kpx6c8d1e2f3g4h5j6k7m8np",
5169 "hook_id": "hk_01kpx5p9s4h0t1w6x8y2a3b4cd",
5170 "event_id": "",
5171 "event": "ping",
5172 "status": "delivered",
5173 "attempts": 1,
5174 "response_status": 200,
5175 "response_body": "ok",
5176 "error": null,
5177 "duration_ms": 171,
5178 "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\"}",
5179 "created_at": "2026-10-04T16:25:40.007Z",
5180 "delivered_at": "2026-10-04T16:25:40.178Z",
5181 "next_attempt_at": null
5182 }
5183 },
5184 "list_integrations": {
5185 "params": {
5186 "workspace": "flagon-io"
5187 },
5188 "response": [
5189 {
5190 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bc",
5191 "workspace": "flagon-io",
5192 "provider": "jira",
5193 "kind": "tracker",
5194 "name": "Jira",
5195 "config": {
5196 "write_back": true,
5197 "site": "https://acme.atlassian.net",
5198 "email": "syntaqx@example.com",
5199 "keys": [
5200 "TECH"
5201 ]
5202 },
5203 "secret_hint": "…x7Qe",
5204 "webhook_url": null,
5205 "created_by": "syntaqx",
5206 "created_at": "2026-10-04T15:42:07.318Z",
5207 "last_used_at": null,
5208 "last_error": null
5209 }
5210 ],
5211 "notes": "`kind` is `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."
5212 },
5213 "connect_integration": {
5214 "params": {
5215 "workspace": "flagon-io"
5216 },
5217 "request": {
5218 "provider": "webhook",
5219 "config": {
5220 "repo": "flagon-io/hello",
5221 "label": "bug"
5222 }
5223 },
5224 "response": {
5225 "connection": {
5226 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bd",
5227 "workspace": "flagon-io",
5228 "provider": "webhook",
5229 "kind": "alerts",
5230 "name": "Webhook",
5231 "config": {
5232 "repo": "flagon-io/hello",
5233 "label": "bug",
5234 "write_back": true
5235 },
5236 "secret_hint": null,
5237 "webhook_url": "https://api.g1t.sh/hooks/con_01kpx4n8r3g9s0v5w7x1z2a3bd",
5238 "created_by": "syntaqx",
5239 "created_at": "2026-10-04T15:42:07.318Z",
5240 "last_used_at": null,
5241 "last_error": null
5242 },
5243 "signing_secret": "g1ts_9f2c4a7e1b0d3c6f8a2e5b7d9c1f4a6e8b0d2c4f6a8e1b3d"
5244 },
5245 "notes": "`signing_secret` is set only when g1t made it, for `datadog` and `webhook`, and is shown only this once. See [integrations](/guides/integrations/)."
5246 },
5247 "update_integration": {
5248 "params": {
5249 "workspace": "flagon-io",
5250 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bc"
5251 },
5252 "request": {
5253 "config": {
5254 "site": "https://acme.atlassian.net",
5255 "email": "syntaqx@example.com",
5256 "keys": [
5257 "TECH",
5258 "OPS"
5259 ]
5260 },
5261 "secret": "atlassian-api-token"
5262 },
5263 "response": {
5264 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bc",
5265 "workspace": "flagon-io",
5266 "provider": "jira",
5267 "kind": "tracker",
5268 "name": "Jira",
5269 "config": {
5270 "write_back": true,
5271 "site": "https://acme.atlassian.net",
5272 "email": "syntaqx@example.com",
5273 "keys": [
5274 "TECH",
5275 "OPS"
5276 ]
5277 },
5278 "secret_hint": "…oken",
5279 "webhook_url": null,
5280 "created_by": "syntaqx",
5281 "created_at": "2026-10-04T15:42:07.318Z",
5282 "last_used_at": "2026-10-07T14:00:02.000Z",
5283 "last_error": null
5284 },
5285 "notes": "The secret is write-only: it is kept encrypted and only its last four characters come back, as `secret_hint`. Use it to rotate a key."
5286 },
5287 "disconnect_integration": {
5288 "params": {
5289 "workspace": "flagon-io",
5290 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bd"
5291 },
5292 "response": true
5293 },
5294 "test_integration": {
5295 "params": {
5296 "workspace": "flagon-io",
5297 "id": "con_01kpx4n8r3g9s0v5w7x1z2a3bc"
5298 },
5299 "response": {
5300 "ok": true,
5301 "message": "Connected to https://acme.atlassian.net as Chase Pierce."
5302 },
5303 "notes": "Credentials that do not work still answer `200`, with `ok` false and `message` saying what went wrong."
5304 },
5305 "list_ai_providers": {
5306 "params": {
5307 "workspace": "flagon-io"
5308 },
5309 "response": [
5310 {
5311 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be",
5312 "workspace": "flagon-io",
5313 "provider": "anthropic",
5314 "group": "labs",
5315 "name": "Anthropic",
5316 "config": {},
5317 "secret_hint": "…Q2fA",
5318 "created_by": "syntaqx",
5319 "created_at": "2026-10-04T15:42:07.318Z",
5320 "last_used_at": "2026-10-14T09:12:44.051Z",
5321 "last_error": null,
5322 "models": [
5323 "claude-haiku-4-5",
5324 "claude-sonnet-4-5",
5325 "claude-opus-4-1"
5326 ]
5327 },
5328 {
5329 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3bf",
5330 "workspace": "flagon-io",
5331 "provider": "openai_endpoint",
5332 "group": "self_hosted",
5333 "name": "vLLM",
5334 "config": {
5335 "base_url": "https://llm.example.com/v1",
5336 "auth_header": "authorization",
5337 "model": "qwen3-coder"
5338 },
5339 "secret_hint": "…k9Lm",
5340 "created_by": "syntaqx",
5341 "created_at": "2026-10-14T10:03:51.902Z",
5342 "last_used_at": null,
5343 "last_error": null,
5344 "models": [
5345 "qwen3-coder"
5346 ]
5347 }
5348 ],
5349 "notes": "`group` is `labs`, `platforms` or `self_hosted`. `secret_hint` shows the end of the key; the key itself is never returned. `models` are those the provider offered when last checked. See [AI](/guides/ai/)."
5350 },
5351 "add_ai_provider": {
5352 "params": {
5353 "workspace": "flagon-io"
5354 },
5355 "request": {
5356 "provider": "openai_endpoint",
5357 "name": "vLLM",
5358 "config": {
5359 "base_url": "https://llm.example.com/v1",
5360 "auth_header": "authorization",
5361 "model": "qwen3-coder"
5362 },
5363 "secret": "sk-…"
5364 },
5365 "response": {
5366 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3bf",
5367 "workspace": "flagon-io",
5368 "provider": "openai_endpoint",
5369 "group": "self_hosted",
5370 "name": "vLLM",
5371 "config": {
5372 "base_url": "https://llm.example.com/v1",
5373 "auth_header": "authorization",
5374 "model": "qwen3-coder"
5375 },
5376 "secret_hint": "…k9Lm",
5377 "created_by": "syntaqx",
5378 "created_at": "2026-10-14T10:03:51.902Z",
5379 "last_used_at": null,
5380 "last_error": null,
5381 "models": [
5382 "qwen3-coder"
5383 ]
5384 },
5385 "notes": "The key is checked as it is saved: one the provider refuses is refused with `422`, saying why. It is sealed and never returned; only its last four characters come back, as `secret_hint`."
5386 },
5387 "update_ai_provider": {
5388 "params": {
5389 "workspace": "flagon-io",
5390 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be"
5391 },
5392 "request": {
5393 "name": "Anthropic (team)",
5394 "secret": "sk-ant-…"
5395 },
5396 "response": {
5397 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be",
5398 "workspace": "flagon-io",
5399 "provider": "anthropic",
5400 "group": "labs",
5401 "name": "Anthropic (team)",
5402 "config": {},
5403 "secret_hint": "…w8Rt",
5404 "created_by": "syntaqx",
5405 "created_at": "2026-10-04T15:42:07.318Z",
5406 "last_used_at": "2026-10-14T09:12:44.051Z",
5407 "last_error": null,
5408 "models": [
5409 "claude-haiku-4-5",
5410 "claude-sonnet-4-5",
5411 "claude-opus-4-1"
5412 ]
5413 },
5414 "notes": "The key is write-only. Use it to rotate a key: the new one replaces the old at once."
5415 },
5416 "remove_ai_provider": {
5417 "params": {
5418 "workspace": "flagon-io",
5419 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3bf"
5420 },
5421 "response": true
5422 },
5423 "test_ai_provider": {
5424 "params": {
5425 "workspace": "flagon-io",
5426 "id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be"
5427 },
5428 "response": {
5429 "ok": true,
5430 "message": "Anthropic answered with 3 models."
5431 },
5432 "notes": "A key that does not work still answers `200`, with `ok` false and `message` saying what went wrong."
5433 },
5434 "get_ask_settings": {
5435 "params": {
5436 "workspace": "flagon-io"
5437 },
5438 "response": {
5439 "provider_id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be",
5440 "provider_name": "Anthropic",
5441 "provider": "anthropic",
5442 "model": null,
5443 "auto": true,
5444 "problem": null
5445 },
5446 "notes": "`auto` is true when Ask picks one of the provider's models for each question. `problem` says why Ask cannot answer, such as no provider chosen, and is null when it can. See [Ask g1t](/guides/ask/)."
5447 },
5448 "set_ask_settings": {
5449 "params": {
5450 "workspace": "flagon-io"
5451 },
5452 "request": {
5453 "provider_id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be",
5454 "model": "claude-sonnet-4-5"
5455 },
5456 "response": {
5457 "provider_id": "ai_01kpx4n8r3g9s0v5w7x1z2a3be",
5458 "provider_name": "Anthropic",
5459 "provider": "anthropic",
5460 "model": "claude-sonnet-4-5",
5461 "auto": false,
5462 "problem": null
5463 },
5464 "notes": "`model` is one of the models the provider offers, or `auto`. Send `provider_id` null to turn Ask off."
5465 },
5466 "get_context": {
5467 "query": {
5468 "reference": "TECH-1234"
5469 },
5470 "response": {
5471 "provider": "jira",
5472 "key": "TECH-1234",
5473 "title": "Checkout fails for EU cards",
5474 "url": "https://acme.atlassian.net/browse/TECH-1234",
5475 "status": "In Progress",
5476 "body": "Customers with 3DS cards see a 500 at /pay.",
5477 "fetched_at": "2026-10-04T15:42:07.318Z"
5478 }
5479 },
5480 "import_issue": {
5481 "request": {
5482 "reference": "TECH-1234"
5483 },
5484 "response": {
5485 "number": 42,
5486 "item": {
5487 "provider": "jira",
5488 "key": "TECH-1234",
5489 "title": "Checkout fails for EU cards",
5490 "url": "https://acme.atlassian.net/browse/TECH-1234",
5491 "status": "In Progress",
5492 "body": "Customers with 3DS cards see a 500 at /pay.",
5493 "fetched_at": "2026-10-04T15:42:07.318Z"
5494 },
5495 "created": true
5496 },
5497 "notes": "`created` is false when the ticket was imported before; `number` is then that issue."
5498 },
5499 "search": {
5500 "query": {
5501 "q": "parse_query language:rust repo:acme/web",
5502 "type": "code"
5503 },
5504 "response": {
5505 "query": "parse_query repo:acme/web language:rust",
5506 "type": "code",
5507 "counts": {
5508 "repositories": 0,
5509 "code": 2,
5510 "issues": 0,
5511 "pulls": 0,
5512 "people": 0
5513 },
5514 "page": 1,
5515 "per_page": 20,
5516 "more": false,
5517 "hits": [
5518 {
5519 "kind": "code",
5520 "title": "src/search/query.rs",
5521 "url": "/acme/web/blob/main/src/search/query.rs#L42",
5522 "repo": "acme/web",
5523 "private": false,
5524 "description": null,
5525 "snippet": [],
5526 "lines": [
5527 {
5528 "number": 41,
5529 "parts": [
5530 {
5531 "text": "/// Reads a query typed into the search box.",
5532 "highlight": false
5533 }
5534 ]
5535 },
5536 {
5537 "number": 42,
5538 "parts": [
5539 {
5540 "text": "pub fn ",
5541 "highlight": false
5542 },
5543 {
5544 "text": "parse_query",
5545 "highlight": true
5546 },
5547 {
5548 "text": "(text: &str) -> Query {",
5549 "highlight": false
5550 }
5551 ]
5552 },
5553 {
5554 "number": 43,
5555 "parts": [
5556 {
5557 "text": " let mut query = Query::default();",
5558 "highlight": false
5559 }
5560 ]
5561 }
5562 ],
5563 "path": "src/search/query.rs",
5564 "language": "rust",
5565 "ref": "main",
5566 "number": null,
5567 "state": null,
5568 "author": null,
5569 "requested_by": null,
5570 "labels": [],
5571 "topics": [],
5572 "slug": null,
5573 "avatar": null,
5574 "updated_at": null
5575 }
5576 ],
5577 "notes": []
5578 },
5579 "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."
5580 },
5581 "list_collaborators": {
5582 "response": {
5583 "repo": "flagon-io/hello",
5584 "base_permission": "write",
5585 "people": [
5586 {
5587 "username": "syntaqx",
5588 "display_username": "syntaqx",
5589 "name": "Chase Pierce",
5590 "avatar": null,
5591 "role": "admin",
5592 "source": "owner",
5593 "direct": null,
5594 "workspace_role": "owner"
5595 },
5596 {
5597 "username": "linus",
5598 "display_username": "linus",
5599 "name": null,
5600 "avatar": null,
5601 "role": "maintain",
5602 "source": "direct",
5603 "direct": "maintain",
5604 "workspace_role": "member"
5605 },
5606 {
5607 "username": "grace",
5608 "display_username": "grace",
5609 "name": "Grace Hopper",
5610 "avatar": null,
5611 "role": "write",
5612 "source": "base",
5613 "direct": null,
5614 "workspace_role": "member"
5615 },
5616 {
5617 "username": "ada",
5618 "display_username": "Ada",
5619 "name": "Ada Lovelace",
5620 "avatar": null,
5621 "role": "triage",
5622 "source": "direct",
5623 "direct": "triage",
5624 "workspace_role": null
5625 }
5626 ],
5627 "invitations": [
5628 {
5629 "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p",
5630 "repo": "flagon-io/hello",
5631 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5632 "invitee": "alan",
5633 "email": null,
5634 "role": "write",
5635 "invited_by": "syntaqx",
5636 "inviter_avatar": null,
5637 "status": "pending",
5638 "created_at": "2026-10-05T17:00:00.000Z",
5639 "expires_at": "2026-10-12T17:00:00.000Z"
5640 },
5641 {
5642 "id": "rin_01kp3d7e8f9g0h1j2k3m4n5p6q",
5643 "repo": "flagon-io/hello",
5644 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5645 "invitee": null,
5646 "email": "joan@example.com",
5647 "role": "read",
5648 "invited_by": "syntaqx",
5649 "inviter_avatar": null,
5650 "status": "pending",
5651 "created_at": "2026-10-05T17:00:00.000Z",
5652 "expires_at": "2026-10-12T17:00:00.000Z"
5653 }
5654 ],
5655 "viewer_role": "admin",
5656 "can_manage": true
5657 },
5658 "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/)."
5659 },
5660 "add_collaborator": {
5661 "request": {
5662 "invitee": "ada",
5663 "role": "triage"
5664 },
5665 "response": {
5666 "result": "invited",
5667 "invitation": {
5668 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r",
5669 "repo": "flagon-io/hello",
5670 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5671 "invitee": "ada",
5672 "email": null,
5673 "role": "triage",
5674 "invited_by": "syntaqx",
5675 "inviter_avatar": null,
5676 "status": "pending",
5677 "created_at": "2026-10-05T17:00:00.000Z",
5678 "expires_at": "2026-10-12T17:00:00.000Z"
5679 }
5680 },
5681 "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. A `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."
5682 },
5683 "update_collaborator": {
5684 "params": {
5685 "owner": "flagon-io",
5686 "name": "hello",
5687 "username": "ada"
5688 },
5689 "request": {
5690 "role": "write"
5691 },
5692 "response": {
5693 "username": "ada",
5694 "display_username": "Ada",
5695 "name": "Ada Lovelace",
5696 "avatar": null,
5697 "role": "write",
5698 "source": "direct",
5699 "direct": "write",
5700 "workspace_role": null
5701 },
5702 "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/)."
5703 },
5704 "remove_collaborator": {
5705 "params": {
5706 "owner": "flagon-io",
5707 "name": "hello",
5708 "username": "ada"
5709 },
5710 "response": true,
5711 "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/)."
5712 },
5713 "get_collaborator_permission": {
5714 "params": {
5715 "owner": "flagon-io",
5716 "name": "hello",
5717 "username": "ada"
5718 },
5719 "response": {
5720 "username": "ada",
5721 "display_username": "Ada",
5722 "role": "triage",
5723 "source": "direct",
5724 "capabilities": [
5725 "read",
5726 "participate",
5727 "triage"
5728 ]
5729 },
5730 "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/)."
5731 },
5732 "list_repo_invitations": {
5733 "response": [
5734 {
5735 "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p",
5736 "repo": "flagon-io/hello",
5737 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5738 "invitee": "alan",
5739 "email": null,
5740 "role": "write",
5741 "invited_by": "syntaqx",
5742 "inviter_avatar": null,
5743 "status": "pending",
5744 "created_at": "2026-10-05T17:00:00.000Z",
5745 "expires_at": "2026-10-12T17:00:00.000Z"
5746 },
5747 {
5748 "id": "rin_01kp3d7e8f9g0h1j2k3m4n5p6q",
5749 "repo": "flagon-io/hello",
5750 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5751 "invitee": null,
5752 "email": "joan@example.com",
5753 "role": "read",
5754 "invited_by": "syntaqx",
5755 "inviter_avatar": null,
5756 "status": "pending",
5757 "created_at": "2026-10-05T17:00:00.000Z",
5758 "expires_at": "2026-10-12T17:00:00.000Z"
5759 }
5760 ],
5761 "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/)."
5762 },
5763 "revoke_repo_invitation": {
5764 "params": {
5765 "owner": "flagon-io",
5766 "name": "hello",
5767 "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p"
5768 },
5769 "response": {
5770 "id": "rin_01kp3c4d5e6f7g8h9j0k1m2n3p",
5771 "repo": "flagon-io/hello",
5772 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5773 "invitee": "alan",
5774 "email": null,
5775 "role": "write",
5776 "invited_by": "syntaqx",
5777 "inviter_avatar": null,
5778 "status": "revoked",
5779 "created_at": "2026-10-05T17:00:00.000Z",
5780 "expires_at": "2026-10-12T17:00:00.000Z"
5781 },
5782 "notes": "`404` when there is no pending invitation with that id on this repository."
5783 },
5784 "list_my_repo_invitations": {
5785 "response": [
5786 {
5787 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r",
5788 "repo": "flagon-io/hello",
5789 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5790 "invitee": "ada",
5791 "email": null,
5792 "role": "triage",
5793 "invited_by": "syntaqx",
5794 "inviter_avatar": null,
5795 "status": "pending",
5796 "created_at": "2026-10-05T17:00:00.000Z",
5797 "expires_at": "2026-10-12T17:00:00.000Z"
5798 }
5799 ],
5800 "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."
5801 },
5802 "accept_repo_invitation": {
5803 "params": {
5804 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r"
5805 },
5806 "response": {
5807 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r",
5808 "repo": "flagon-io/hello",
5809 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5810 "invitee": "ada",
5811 "email": null,
5812 "role": "triage",
5813 "invited_by": "syntaqx",
5814 "inviter_avatar": null,
5815 "status": "accepted",
5816 "created_at": "2026-10-05T17:00:00.000Z",
5817 "expires_at": "2026-10-12T17:00:00.000Z"
5818 },
5819 "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/)."
5820 },
5821 "decline_repo_invitation": {
5822 "params": {
5823 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r"
5824 },
5825 "response": {
5826 "id": "rin_01kp3e9f0g1h2j3k4m5n6p7q8r",
5827 "repo": "flagon-io/hello",
5828 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
5829 "invitee": "ada",
5830 "email": null,
5831 "role": "triage",
5832 "invited_by": "syntaqx",
5833 "inviter_avatar": null,
5834 "status": "declined",
5835 "created_at": "2026-10-05T17:00:00.000Z",
5836 "expires_at": "2026-10-12T17:00:00.000Z"
5837 },
5838 "notes": "`404` when you have no pending invitation with that id."
5839 },
5840 "set_base_permission": {
5841 "params": {
5842 "workspace": "flagon-io"
5843 },
5844 "request": {
5845 "base_permission": "read"
5846 },
5847 "response": {
5848 "workspace": "flagon-io",
5849 "base_permission": "read"
5850 },
5851 "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/)."
5852 },
5853 "list_outside_collaborators": {
5854 "params": {
5855 "workspace": "flagon-io"
5856 },
5857 "response": [
5858 {
5859 "username": "ada",
5860 "display_username": "Ada",
5861 "name": "Ada Lovelace",
5862 "avatar": null,
5863 "repos": [
5864 {
5865 "repo": "flagon-io/docs",
5866 "role": "write"
5867 },
5868 {
5869 "repo": "flagon-io/hello",
5870 "role": "triage"
5871 }
5872 ]
5873 }
5874 ],
5875 "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/)."
5876 },
5877 "list_deploy_keys": {
5878 "params": {
5879 "owner": "flagon-io",
5880 "name": "hello"
5881 },
5882 "response": [
5883 {
5884 "id": "dk_01kp3f2g3h4j5k6m7n8p9q0r1s",
5885 "title": "Docs build",
5886 "key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGb9ECWmEzf6FQbrBZ9w7lshQhqowtrbLDFw4rXAxZuE",
5887 "fingerprint": "SHA256:ubxEl41fJDnUoEPKSZE0y6R0ZjjAQf/wV5vZgeBV8qk",
5888 "read_only": true,
5889 "created_at": "2026-10-06T09:12:00.000Z",
5890 "created_by": "syntaqx",
5891 "last_used_at": "2026-10-08T07:40:00.000Z"
5892 },
5893 {
5894 "id": "dk_01kp3g4h5j6k7m8n9p0q1r2s3t",
5895 "title": "Release bot",
5896 "key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ8Vq2nLr5Xw0sT3yK7mP1cH4dF6gB9aE2uZ5oN8iR0j",
5897 "fingerprint": "SHA256:2h7VyLkcqBHwKVtfFUchGsE5pDwpgBPV/VvJgYiS27M",
5898 "read_only": false,
5899 "created_at": "2026-10-07T15:30:00.000Z",
5900 "created_by": "syntaqx",
5901 "last_used_at": null
5902 }
5903 ],
5904 "notes": "Oldest first. `read_only` false means the key may push, workflow files included. `last_used_at` is when it last signed in over SSH, to within 5 minutes, and null when it never has. Refused with `403` without the Admin role, and for an agent's token or a workspace token without Admin; `404` for a private repository you cannot see. See [Deploy keys](/guides/git/#deploy-keys)."
5905 },
5906 "get_deploy_key": {
5907 "params": {
5908 "owner": "flagon-io",
5909 "name": "hello",
5910 "id": "dk_01kp3f2g3h4j5k6m7n8p9q0r1s"
5911 },
5912 "response": {
5913 "id": "dk_01kp3f2g3h4j5k6m7n8p9q0r1s",
5914 "title": "Docs build",
5915 "key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGb9ECWmEzf6FQbrBZ9w7lshQhqowtrbLDFw4rXAxZuE",
5916 "fingerprint": "SHA256:ubxEl41fJDnUoEPKSZE0y6R0ZjjAQf/wV5vZgeBV8qk",
5917 "read_only": true,
5918 "created_at": "2026-10-06T09:12:00.000Z",
5919 "created_by": "syntaqx",
5920 "last_used_at": "2026-10-08T07:40:00.000Z"
5921 },
5922 "notes": "`404` when the repository has no deploy key with that id."
5923 },
5924 "create_deploy_key": {
5925 "params": {
5926 "owner": "flagon-io",
5927 "name": "hello"
5928 },
5929 "request": {
5930 "title": "Release bot",
5931 "key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ8Vq2nLr5Xw0sT3yK7mP1cH4dF6gB9aE2uZ5oN8iR0j release@ci",
5932 "read_only": false
5933 },
5934 "response": {
5935 "id": "dk_01kp3g4h5j6k7m8n9p0q1r2s3t",
5936 "title": "Release bot",
5937 "key": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ8Vq2nLr5Xw0sT3yK7mP1cH4dF6gB9aE2uZ5oN8iR0j",
5938 "fingerprint": "SHA256:2h7VyLkcqBHwKVtfFUchGsE5pDwpgBPV/VvJgYiS27M",
5939 "read_only": false,
5940 "created_at": "2026-10-07T15:30:00.000Z",
5941 "created_by": "syntaqx",
5942 "last_used_at": null
5943 },
5944 "notes": "`read_only` is true unless you send false. The key's comment is not kept; it becomes the title when you send none. Refused with `400` for a line that is not an OpenSSH public key, `409` with `Key is already in use.` when the key is registered already (as anyone's SSH key or as a deploy key anywhere), `409` past 100 keys, and `403` without the Admin role, from an agent's token, from a workspace token without Admin, or before your email address is confirmed. Recorded in the workspace's audit log as `repo.deploy_key_added`."
5945 },
5946 "delete_deploy_key": {
5947 "params": {
5948 "owner": "flagon-io",
5949 "name": "hello",
5950 "id": "dk_01kp3g4h5j6k7m8n9p0q1r2s3t"
5951 },
5952 "response": true,
5953 "notes": "The key stops working at once. `404` when the repository has no deploy key with that id. Recorded in the workspace's audit log as `repo.deploy_key_removed`."
5954 },
5955 "list_teams": {
5956 "params": {
5957 "workspace": "flagon-io"
5958 },
5959 "query": {
5960 "q": "back"
5961 },
5962 "response": [
5963 {
5964 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
5965 "workspace": "flagon-io",
5966 "slug": "backend",
5967 "name": "Backend",
5968 "description": "The API and the services behind it.",
5969 "visibility": "visible",
5970 "parent": {
5971 "slug": "engineering",
5972 "name": "Engineering"
5973 },
5974 "notify": true,
5975 "review_assignment": {
5976 "enabled": false,
5977 "algorithm": "round_robin",
5978 "count": 1,
5979 "skip_busy": false,
5980 "busy_at": 5,
5981 "include_child_teams": false,
5982 "excluded": [],
5983 "notify_team": false
5984 },
5985 "members_count": 4,
5986 "repos_count": 2,
5987 "child_teams_count": 1,
5988 "viewer_role": "maintainer",
5989 "can_manage": true,
5990 "created_at": "2026-10-06T15:02:11.480Z",
5991 "updated_at": "2026-10-06T15:02:11.480Z"
5992 }
5993 ],
5994 "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/)."
5995 },
5996 "create_team": {
5997 "params": {
5998 "workspace": "flagon-io"
5999 },
6000 "request": {
6001 "name": "Backend",
6002 "description": "The API and the services behind it.",
6003 "visibility": "visible",
6004 "parent": "engineering",
6005 "members": [
6006 "ana"
6007 ]
6008 },
6009 "response": {
6010 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6011 "workspace": "flagon-io",
6012 "slug": "backend",
6013 "name": "Backend",
6014 "description": "The API and the services behind it.",
6015 "visibility": "visible",
6016 "parent": {
6017 "slug": "engineering",
6018 "name": "Engineering"
6019 },
6020 "notify": true,
6021 "review_assignment": {
6022 "enabled": false,
6023 "algorithm": "round_robin",
6024 "count": 1,
6025 "skip_busy": false,
6026 "busy_at": 5,
6027 "include_child_teams": false,
6028 "excluded": [],
6029 "notify_team": false
6030 },
6031 "members_count": 2,
6032 "repos_count": 0,
6033 "child_teams_count": 0,
6034 "viewer_role": "maintainer",
6035 "can_manage": true,
6036 "created_at": "2026-10-06T15:02:11.480Z",
6037 "updated_at": "2026-10-06T15:02:11.480Z"
6038 },
6039 "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/)."
6040 },
6041 "get_team": {
6042 "params": {
6043 "workspace": "flagon-io",
6044 "team": "backend"
6045 },
6046 "response": {
6047 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6048 "workspace": "flagon-io",
6049 "slug": "backend",
6050 "name": "Backend",
6051 "description": "The API and the services behind it.",
6052 "visibility": "visible",
6053 "parent": {
6054 "slug": "engineering",
6055 "name": "Engineering"
6056 },
6057 "notify": true,
6058 "review_assignment": {
6059 "enabled": false,
6060 "algorithm": "round_robin",
6061 "count": 1,
6062 "skip_busy": false,
6063 "busy_at": 5,
6064 "include_child_teams": false,
6065 "excluded": [],
6066 "notify_team": false
6067 },
6068 "members_count": 4,
6069 "repos_count": 2,
6070 "child_teams_count": 1,
6071 "viewer_role": "maintainer",
6072 "can_manage": true,
6073 "created_at": "2026-10-06T15:02:11.480Z",
6074 "updated_at": "2026-10-06T15:02:11.480Z"
6075 },
6076 "notes": "`404` for a team that does not exist, or a secret one you are not in, unless you are an owner."
6077 },
6078 "update_team": {
6079 "params": {
6080 "workspace": "flagon-io",
6081 "team": "backend"
6082 },
6083 "request": {
6084 "description": "The API, the services behind it, and their on-call.",
6085 "visibility": "secret",
6086 "parent": ""
6087 },
6088 "response": {
6089 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6090 "workspace": "flagon-io",
6091 "slug": "backend",
6092 "name": "Backend",
6093 "description": "The API, the services behind it, and their on-call.",
6094 "visibility": "secret",
6095 "parent": null,
6096 "notify": true,
6097 "review_assignment": {
6098 "enabled": false,
6099 "algorithm": "round_robin",
6100 "count": 1,
6101 "skip_busy": false,
6102 "busy_at": 5,
6103 "include_child_teams": false,
6104 "excluded": [],
6105 "notify_team": false
6106 },
6107 "members_count": 4,
6108 "repos_count": 2,
6109 "child_teams_count": 1,
6110 "viewer_role": "maintainer",
6111 "can_manage": true,
6112 "created_at": "2026-10-06T15:02:11.480Z",
6113 "updated_at": "2026-10-07T09:41:52.006Z"
6114 },
6115 "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)."
6116 },
6117 "delete_team": {
6118 "params": {
6119 "workspace": "flagon-io",
6120 "team": "backend"
6121 },
6122 "response": true,
6123 "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)."
6124 },
6125 "list_team_members": {
6126 "params": {
6127 "workspace": "flagon-io",
6128 "team": "backend"
6129 },
6130 "query": {
6131 "include_child_teams": "true"
6132 },
6133 "response": [
6134 {
6135 "username": "syntaqx",
6136 "display_username": "syntaqx",
6137 "name": "Chase Pierce",
6138 "avatar": null,
6139 "role": "maintainer",
6140 "via": null
6141 },
6142 {
6143 "username": "ana",
6144 "display_username": "Ana",
6145 "name": "Ana Lima",
6146 "avatar": null,
6147 "role": "member",
6148 "via": null
6149 },
6150 {
6151 "username": "bo",
6152 "display_username": "bo",
6153 "name": null,
6154 "avatar": null,
6155 "role": "member",
6156 "via": "payments"
6157 }
6158 ],
6159 "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."
6160 },
6161 "set_team_member": {
6162 "params": {
6163 "workspace": "flagon-io",
6164 "team": "backend",
6165 "username": "ana"
6166 },
6167 "request": {
6168 "role": "maintainer"
6169 },
6170 "response": {
6171 "username": "ana",
6172 "display_username": "Ana",
6173 "name": "Ana Lima",
6174 "avatar": null,
6175 "role": "maintainer",
6176 "via": null
6177 },
6178 "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)."
6179 },
6180 "remove_team_member": {
6181 "params": {
6182 "workspace": "flagon-io",
6183 "team": "backend",
6184 "username": "ana"
6185 },
6186 "response": true,
6187 "notes": "Anyone may take themselves out of a team. Leaving the workspace takes a person out of all its teams."
6188 },
6189 "list_child_teams": {
6190 "params": {
6191 "workspace": "flagon-io",
6192 "team": "engineering"
6193 },
6194 "response": [
6195 {
6196 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6197 "workspace": "flagon-io",
6198 "slug": "backend",
6199 "name": "Backend",
6200 "description": "The API and the services behind it.",
6201 "visibility": "visible",
6202 "parent": {
6203 "slug": "engineering",
6204 "name": "Engineering"
6205 },
6206 "notify": true,
6207 "review_assignment": {
6208 "enabled": false,
6209 "algorithm": "round_robin",
6210 "count": 1,
6211 "skip_busy": false,
6212 "busy_at": 5,
6213 "include_child_teams": false,
6214 "excluded": [],
6215 "notify_team": false
6216 },
6217 "members_count": 4,
6218 "repos_count": 2,
6219 "child_teams_count": 0,
6220 "viewer_role": "maintainer",
6221 "can_manage": true,
6222 "created_at": "2026-10-06T15:02:11.480Z",
6223 "updated_at": "2026-10-06T15:02:11.480Z"
6224 }
6225 ],
6226 "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."
6227 },
6228 "list_team_repos": {
6229 "params": {
6230 "workspace": "flagon-io",
6231 "team": "backend"
6232 },
6233 "response": [
6234 {
6235 "repo": "flagon-io/hello",
6236 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
6237 "role": "write",
6238 "inherited_from": null
6239 },
6240 {
6241 "repo": "flagon-io/docs",
6242 "repo_id": "rep_01m3m5r2a8c4e6g8j0m2p4r6t8",
6243 "role": "read",
6244 "inherited_from": "engineering"
6245 }
6246 ],
6247 "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."
6248 },
6249 "set_team_repo": {
6250 "params": {
6251 "workspace": "flagon-io",
6252 "team": "backend",
6253 "repo": "hello"
6254 },
6255 "request": {
6256 "role": "maintain"
6257 },
6258 "response": {
6259 "repo": "flagon-io/hello",
6260 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
6261 "role": "maintain",
6262 "inherited_from": null
6263 },
6264 "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/)."
6265 },
6266 "remove_team_repo": {
6267 "params": {
6268 "workspace": "flagon-io",
6269 "team": "backend",
6270 "repo": "hello"
6271 },
6272 "response": true,
6273 "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."
6274 },
6275 "set_team_review_assignment": {
6276 "params": {
6277 "workspace": "flagon-io",
6278 "team": "backend"
6279 },
6280 "request": {
6281 "enabled": true,
6282 "algorithm": "load_balance",
6283 "count": 2,
6284 "skip_busy": true,
6285 "busy_at": 5,
6286 "excluded": [
6287 "syntaqx"
6288 ]
6289 },
6290 "response": {
6291 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6292 "workspace": "flagon-io",
6293 "slug": "backend",
6294 "name": "Backend",
6295 "description": "The API and the services behind it.",
6296 "visibility": "visible",
6297 "parent": {
6298 "slug": "engineering",
6299 "name": "Engineering"
6300 },
6301 "notify": true,
6302 "review_assignment": {
6303 "enabled": true,
6304 "algorithm": "load_balance",
6305 "count": 2,
6306 "skip_busy": true,
6307 "busy_at": 5,
6308 "include_child_teams": false,
6309 "excluded": [
6310 "syntaqx"
6311 ],
6312 "notify_team": false
6313 },
6314 "members_count": 4,
6315 "repos_count": 2,
6316 "child_teams_count": 1,
6317 "viewer_role": "maintainer",
6318 "can_manage": true,
6319 "created_at": "2026-10-06T15:02:11.480Z",
6320 "updated_at": "2026-10-07T09:44:03.512Z"
6321 },
6322 "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/)."
6323 },
6324 "list_user_teams": {
6325 "params": {
6326 "workspace": "flagon-io",
6327 "username": "ana"
6328 },
6329 "response": [
6330 {
6331 "id": "team_01m52k8d3f7h1k5n9r3v7z1c5g",
6332 "workspace": "flagon-io",
6333 "slug": "backend",
6334 "name": "Backend",
6335 "description": "The API and the services behind it.",
6336 "visibility": "visible",
6337 "parent": {
6338 "slug": "engineering",
6339 "name": "Engineering"
6340 },
6341 "notify": true,
6342 "review_assignment": {
6343 "enabled": false,
6344 "algorithm": "round_robin",
6345 "count": 1,
6346 "skip_busy": false,
6347 "busy_at": 5,
6348 "include_child_teams": false,
6349 "excluded": [],
6350 "notify_team": false
6351 },
6352 "members_count": 4,
6353 "repos_count": 2,
6354 "child_teams_count": 1,
6355 "viewer_role": null,
6356 "can_manage": false,
6357 "created_at": "2026-10-06T15:02:11.480Z",
6358 "updated_at": "2026-10-06T15:02:11.480Z"
6359 }
6360 ],
6361 "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."
6362 },
6363 "list_security_alerts": {
6364 "params": {
6365 "owner": "flagon-io",
6366 "name": "hello"
6367 },
6368 "query": {
6369 "state": "open"
6370 },
6371 "response": [
6372 {
6373 "kind": "secret",
6374 "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m",
6375 "state": "dismissed",
6376 "secret_type": "aws_access_key",
6377 "label": "an AWS access key",
6378 "path": "test/fixtures/aws.env",
6379 "line": 3,
6380 "commit": "9f2c1e04b7d3a8e6f5c2b1a0d9e8f7c6b5a4d3e2",
6381 "preview": "AKIA…MPLE",
6382 "status": "allowed",
6383 "source": "history",
6384 "test_value": "the documented example key",
6385 "found_by": null,
6386 "found_at": "2026-10-01T12:00:00.000Z",
6387 "dismissed_reason": "used_in_tests",
6388 "dismissed_comment": "Only in the test fixtures.",
6389 "dismissed_by": "syntaqx",
6390 "dismissed_at": "2026-10-02T09:15:00.000Z"
6391 },
6392 {
6393 "kind": "dependency",
6394 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
6395 "state": "open",
6396 "ecosystem": "npm",
6397 "package": "lodash",
6398 "version": "4.17.20",
6399 "manifest": "package-lock.json",
6400 "advisory": "GHSA-35jh-r3h4-6jhm",
6401 "osv_id": "GHSA-35jh-r3h4-6jhm",
6402 "summary": "Command Injection in lodash",
6403 "severity": "high",
6404 "fixed_version": "4.17.21",
6405 "fixed_at": null,
6406 "update": {
6407 "state": "open",
6408 "target": "4.17.21",
6409 "branch": "g1t/security/lodash-4.17.21",
6410 "pull": 42,
6411 "issue": null,
6412 "error": null,
6413 "updated_at": "2026-10-01T12:20:00.000Z"
6414 },
6415 "found_at": "2026-10-01T12:00:00.000Z",
6416 "dismissed_reason": null,
6417 "dismissed_comment": null,
6418 "dismissed_by": null,
6419 "dismissed_at": null
6420 }
6421 ],
6422 "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/)."
6423 },
6424 "dismiss_security_alert": {
6425 "params": {
6426 "owner": "flagon-io",
6427 "name": "hello",
6428 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n"
6429 },
6430 "request": {
6431 "reason": "tolerable_risk",
6432 "comment": "Only the build uses it, on trusted input."
6433 },
6434 "response": {
6435 "kind": "dependency",
6436 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
6437 "state": "dismissed",
6438 "ecosystem": "npm",
6439 "package": "lodash",
6440 "version": "4.17.20",
6441 "manifest": "package-lock.json",
6442 "advisory": "GHSA-35jh-r3h4-6jhm",
6443 "osv_id": "GHSA-35jh-r3h4-6jhm",
6444 "summary": "Command Injection in lodash",
6445 "severity": "high",
6446 "fixed_version": "4.17.21",
6447 "fixed_at": null,
6448 "update": {
6449 "state": "open",
6450 "target": "4.17.21",
6451 "branch": "g1t/security/lodash-4.17.21",
6452 "pull": 42,
6453 "issue": null,
6454 "error": null,
6455 "updated_at": "2026-10-01T12:20:00.000Z"
6456 },
6457 "found_at": "2026-10-01T12:00:00.000Z",
6458 "dismissed_reason": "tolerable_risk",
6459 "dismissed_comment": "Only the build uses it, on trusted input.",
6460 "dismissed_by": "syntaqx",
6461 "dismissed_at": "2026-10-06T10:00:00.000Z"
6462 },
6463 "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."
6464 },
6465 "reopen_security_alert": {
6466 "params": {
6467 "owner": "flagon-io",
6468 "name": "hello",
6469 "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m"
6470 },
6471 "response": {
6472 "kind": "secret",
6473 "id": "sec_01kp4a7b2c3d4e5f6g7h8j9k0m",
6474 "state": "open",
6475 "secret_type": "aws_access_key",
6476 "label": "an AWS access key",
6477 "path": "test/fixtures/aws.env",
6478 "line": 3,
6479 "commit": "9f2c1e04b7d3a8e6f5c2b1a0d9e8f7c6b5a4d3e2",
6480 "preview": "AKIA…MPLE",
6481 "status": "open",
6482 "source": "history",
6483 "test_value": "the documented example key",
6484 "found_by": null,
6485 "found_at": "2026-10-01T12:00:00.000Z",
6486 "dismissed_reason": null,
6487 "dismissed_comment": null,
6488 "dismissed_by": null,
6489 "dismissed_at": null
6490 },
6491 "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."
6492 },
6493 "list_notifications": {
6494 "query": {
6495 "participating": "true"
6496 },
6497 "response": {
6498 "items": [
6499 {
6500 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6501 "reason": "review_requested",
6502 "severity": "warning",
6503 "title": "ada asked you to review flagon-io/hello#14",
6504 "body": "Add a greeting to the README",
6505 "event": "pull.review_requested",
6506 "repo": "flagon-io/hello",
6507 "workspace": "flagon-io",
6508 "subject": "pull",
6509 "number": 14,
6510 "url": "/flagon-io/hello/pull/14",
6511 "actor": "ada",
6512 "count": 3,
6513 "created_at": "2026-10-06T15:02:11.000Z",
6514 "updated_at": "2026-10-07T09:41:30.000Z",
6515 "read_at": null,
6516 "done_at": null,
6517 "saved": false,
6518 "snoozed_until": null
6519 },
6520 {
6521 "id": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k",
6522 "reason": "ci_activity",
6523 "severity": "error",
6524 "title": "Production of hello failed to deploy",
6525 "body": "The build failed: npm run build exited with 1.",
6526 "event": "deployment.failed",
6527 "repo": "flagon-io/hello",
6528 "workspace": "flagon-io",
6529 "subject": "deploy",
6530 "number": null,
6531 "url": "/flagon-io/hello/deployments/dpl_01kp7k8z7y6x5w4v3t2s1r0q9p",
6532 "actor": "syntaqx",
6533 "count": 1,
6534 "created_at": "2026-10-07T08:12:40.000Z",
6535 "updated_at": "2026-10-07T08:12:40.000Z",
6536 "read_at": null,
6537 "done_at": null,
6538 "saved": false,
6539 "snoozed_until": null
6540 }
6541 ],
6542 "next": null
6543 },
6544 "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."
6545 },
6546 "list_repo_notifications": {
6547 "params": {
6548 "owner": "flagon-io",
6549 "name": "hello"
6550 },
6551 "query": {
6552 "all": "true"
6553 },
6554 "response": {
6555 "items": [
6556 {
6557 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6558 "reason": "review_requested",
6559 "severity": "warning",
6560 "title": "ada asked you to review flagon-io/hello#14",
6561 "body": "Add a greeting to the README",
6562 "event": "pull.review_requested",
6563 "repo": "flagon-io/hello",
6564 "workspace": "flagon-io",
6565 "subject": "pull",
6566 "number": 14,
6567 "url": "/flagon-io/hello/pull/14",
6568 "actor": "ada",
6569 "count": 3,
6570 "created_at": "2026-10-06T15:02:11.000Z",
6571 "updated_at": "2026-10-07T09:41:30.000Z",
6572 "read_at": "2026-10-07T09:50:00.000Z",
6573 "done_at": null,
6574 "saved": false,
6575 "snoozed_until": null
6576 },
6577 {
6578 "id": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k",
6579 "reason": "ci_activity",
6580 "severity": "error",
6581 "title": "Production of hello failed to deploy",
6582 "body": "The build failed: npm run build exited with 1.",
6583 "event": "deployment.failed",
6584 "repo": "flagon-io/hello",
6585 "workspace": "flagon-io",
6586 "subject": "deploy",
6587 "number": null,
6588 "url": "/flagon-io/hello/deployments/dpl_01kp7k8z7y6x5w4v3t2s1r0q9p",
6589 "actor": "syntaqx",
6590 "count": 1,
6591 "created_at": "2026-10-07T08:12:40.000Z",
6592 "updated_at": "2026-10-07T08:12:40.000Z",
6593 "read_at": null,
6594 "done_at": null,
6595 "saved": false,
6596 "snoozed_until": null
6597 }
6598 ],
6599 "next": "ntf_01kp7k9a8b7c6d5e4f3g2h1j0k"
6600 },
6601 "notes": "The same as `GET /notifications`, for one repository you can read."
6602 },
6603 "mark_notifications_read": {
6604 "request": {
6605 "last_read_at": "2026-10-07T10:00:00Z"
6606 },
6607 "response": {
6608 "marked": 12,
6609 "last_read_at": "2026-10-07T10:00:00.000Z"
6610 },
6611 "notes": "Threads with activity after `last_read_at` stay unread, so send the time you last listed them."
6612 },
6613 "mark_repo_notifications_read": {
6614 "params": {
6615 "owner": "flagon-io",
6616 "name": "hello"
6617 },
6618 "request": {},
6619 "response": {
6620 "marked": 3,
6621 "last_read_at": "2026-10-07T10:02:41.512Z"
6622 }
6623 },
6624 "get_notification_thread": {
6625 "params": {
6626 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6627 },
6628 "response": {
6629 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6630 "reason": "review_requested",
6631 "severity": "warning",
6632 "title": "ada asked you to review flagon-io/hello#14",
6633 "body": "Add a greeting to the README",
6634 "event": "pull.review_requested",
6635 "repo": "flagon-io/hello",
6636 "workspace": "flagon-io",
6637 "subject": "pull",
6638 "number": 14,
6639 "url": "/flagon-io/hello/pull/14",
6640 "actor": "ada",
6641 "count": 3,
6642 "created_at": "2026-10-06T15:02:11.000Z",
6643 "updated_at": "2026-10-07T09:41:30.000Z",
6644 "read_at": null,
6645 "done_at": null,
6646 "saved": false,
6647 "snoozed_until": null,
6648 "activity": [
6649 {
6650 "reason": "review_requested",
6651 "severity": "warning",
6652 "title": "ada asked you to review flagon-io/hello#14",
6653 "body": "Add a greeting to the README",
6654 "event": "pull.review_requested",
6655 "actor": "ada",
6656 "created_at": "2026-10-07T09:41:30.000Z"
6657 },
6658 {
6659 "reason": "comment",
6660 "severity": "info",
6661 "title": "ada commented on flagon-io/hello#14",
6662 "body": "Pushed the fix for the heading.",
6663 "event": "comment.created",
6664 "actor": "ada",
6665 "created_at": "2026-10-06T18:20:02.000Z"
6666 },
6667 {
6668 "reason": "comment",
6669 "severity": "info",
6670 "title": "g1t commented on flagon-io/hello#14",
6671 "body": "The heading level is off by one.",
6672 "event": "comment.created",
6673 "actor": "g1t",
6674 "created_at": "2026-10-06T15:02:11.000Z"
6675 }
6676 ],
6677 "subscription": {
6678 "subscribed": true,
6679 "ignored": false,
6680 "reason": "review_requested",
6681 "repo": "flagon-io/hello",
6682 "number": 14,
6683 "updated_at": null
6684 }
6685 },
6686 "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."
6687 },
6688 "mark_thread_read": {
6689 "params": {
6690 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6691 },
6692 "request": {},
6693 "response": {
6694 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6695 "reason": "review_requested",
6696 "severity": "warning",
6697 "title": "ada asked you to review flagon-io/hello#14",
6698 "body": "Add a greeting to the README",
6699 "event": "pull.review_requested",
6700 "repo": "flagon-io/hello",
6701 "workspace": "flagon-io",
6702 "subject": "pull",
6703 "number": 14,
6704 "url": "/flagon-io/hello/pull/14",
6705 "actor": "ada",
6706 "count": 3,
6707 "created_at": "2026-10-06T15:02:11.000Z",
6708 "updated_at": "2026-10-07T09:41:30.000Z",
6709 "read_at": "2026-10-07T10:03:00.000Z",
6710 "done_at": null,
6711 "saved": false,
6712 "snoozed_until": null,
6713 "activity": [
6714 {
6715 "reason": "review_requested",
6716 "severity": "warning",
6717 "title": "ada asked you to review flagon-io/hello#14",
6718 "body": "Add a greeting to the README",
6719 "event": "pull.review_requested",
6720 "actor": "ada",
6721 "created_at": "2026-10-07T09:41:30.000Z"
6722 },
6723 {
6724 "reason": "comment",
6725 "severity": "info",
6726 "title": "ada commented on flagon-io/hello#14",
6727 "body": "Pushed the fix for the heading.",
6728 "event": "comment.created",
6729 "actor": "ada",
6730 "created_at": "2026-10-06T18:20:02.000Z"
6731 },
6732 {
6733 "reason": "comment",
6734 "severity": "info",
6735 "title": "g1t commented on flagon-io/hello#14",
6736 "body": "The heading level is off by one.",
6737 "event": "comment.created",
6738 "actor": "g1t",
6739 "created_at": "2026-10-06T15:02:11.000Z"
6740 }
6741 ],
6742 "subscription": {
6743 "subscribed": true,
6744 "ignored": false,
6745 "reason": "review_requested",
6746 "repo": "flagon-io/hello",
6747 "number": 14,
6748 "updated_at": null
6749 }
6750 }
6751 },
6752 "mark_thread_done": {
6753 "params": {
6754 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6755 },
6756 "response": {
6757 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6758 "reason": "review_requested",
6759 "severity": "warning",
6760 "title": "ada asked you to review flagon-io/hello#14",
6761 "body": "Add a greeting to the README",
6762 "event": "pull.review_requested",
6763 "repo": "flagon-io/hello",
6764 "workspace": "flagon-io",
6765 "subject": "pull",
6766 "number": 14,
6767 "url": "/flagon-io/hello/pull/14",
6768 "actor": "ada",
6769 "count": 3,
6770 "created_at": "2026-10-06T15:02:11.000Z",
6771 "updated_at": "2026-10-07T09:41:30.000Z",
6772 "read_at": "2026-10-07T10:03:00.000Z",
6773 "done_at": "2026-10-07T10:03:00.000Z",
6774 "saved": false,
6775 "snoozed_until": null,
6776 "activity": [
6777 {
6778 "reason": "review_requested",
6779 "severity": "warning",
6780 "title": "ada asked you to review flagon-io/hello#14",
6781 "body": "Add a greeting to the README",
6782 "event": "pull.review_requested",
6783 "actor": "ada",
6784 "created_at": "2026-10-07T09:41:30.000Z"
6785 },
6786 {
6787 "reason": "comment",
6788 "severity": "info",
6789 "title": "ada commented on flagon-io/hello#14",
6790 "body": "Pushed the fix for the heading.",
6791 "event": "comment.created",
6792 "actor": "ada",
6793 "created_at": "2026-10-06T18:20:02.000Z"
6794 },
6795 {
6796 "reason": "comment",
6797 "severity": "info",
6798 "title": "g1t commented on flagon-io/hello#14",
6799 "body": "The heading level is off by one.",
6800 "event": "comment.created",
6801 "actor": "g1t",
6802 "created_at": "2026-10-06T15:02:11.000Z"
6803 }
6804 ],
6805 "subscription": {
6806 "subscribed": true,
6807 "ignored": false,
6808 "reason": "review_requested",
6809 "repo": "flagon-io/hello",
6810 "number": 14,
6811 "updated_at": null
6812 }
6813 },
6814 "notes": "New activity on a done thread brings it back to the inbox, unread."
6815 },
6816 "save_thread": {
6817 "params": {
6818 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6819 },
6820 "request": {},
6821 "response": {
6822 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6823 "reason": "review_requested",
6824 "severity": "warning",
6825 "title": "ada asked you to review flagon-io/hello#14",
6826 "body": "Add a greeting to the README",
6827 "event": "pull.review_requested",
6828 "repo": "flagon-io/hello",
6829 "workspace": "flagon-io",
6830 "subject": "pull",
6831 "number": 14,
6832 "url": "/flagon-io/hello/pull/14",
6833 "actor": "ada",
6834 "count": 3,
6835 "created_at": "2026-10-06T15:02:11.000Z",
6836 "updated_at": "2026-10-07T09:41:30.000Z",
6837 "read_at": null,
6838 "done_at": null,
6839 "saved": true,
6840 "snoozed_until": null,
6841 "activity": [
6842 {
6843 "reason": "review_requested",
6844 "severity": "warning",
6845 "title": "ada asked you to review flagon-io/hello#14",
6846 "body": "Add a greeting to the README",
6847 "event": "pull.review_requested",
6848 "actor": "ada",
6849 "created_at": "2026-10-07T09:41:30.000Z"
6850 },
6851 {
6852 "reason": "comment",
6853 "severity": "info",
6854 "title": "ada commented on flagon-io/hello#14",
6855 "body": "Pushed the fix for the heading.",
6856 "event": "comment.created",
6857 "actor": "ada",
6858 "created_at": "2026-10-06T18:20:02.000Z"
6859 },
6860 {
6861 "reason": "comment",
6862 "severity": "info",
6863 "title": "g1t commented on flagon-io/hello#14",
6864 "body": "The heading level is off by one.",
6865 "event": "comment.created",
6866 "actor": "g1t",
6867 "created_at": "2026-10-06T15:02:11.000Z"
6868 }
6869 ],
6870 "subscription": {
6871 "subscribed": true,
6872 "ignored": false,
6873 "reason": "review_requested",
6874 "repo": "flagon-io/hello",
6875 "number": 14,
6876 "updated_at": null
6877 }
6878 }
6879 },
6880 "unsave_thread": {
6881 "params": {
6882 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6883 },
6884 "response": {
6885 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6886 "reason": "review_requested",
6887 "severity": "warning",
6888 "title": "ada asked you to review flagon-io/hello#14",
6889 "body": "Add a greeting to the README",
6890 "event": "pull.review_requested",
6891 "repo": "flagon-io/hello",
6892 "workspace": "flagon-io",
6893 "subject": "pull",
6894 "number": 14,
6895 "url": "/flagon-io/hello/pull/14",
6896 "actor": "ada",
6897 "count": 3,
6898 "created_at": "2026-10-06T15:02:11.000Z",
6899 "updated_at": "2026-10-07T09:41:30.000Z",
6900 "read_at": null,
6901 "done_at": null,
6902 "saved": false,
6903 "snoozed_until": null,
6904 "activity": [
6905 {
6906 "reason": "review_requested",
6907 "severity": "warning",
6908 "title": "ada asked you to review flagon-io/hello#14",
6909 "body": "Add a greeting to the README",
6910 "event": "pull.review_requested",
6911 "actor": "ada",
6912 "created_at": "2026-10-07T09:41:30.000Z"
6913 },
6914 {
6915 "reason": "comment",
6916 "severity": "info",
6917 "title": "ada commented on flagon-io/hello#14",
6918 "body": "Pushed the fix for the heading.",
6919 "event": "comment.created",
6920 "actor": "ada",
6921 "created_at": "2026-10-06T18:20:02.000Z"
6922 },
6923 {
6924 "reason": "comment",
6925 "severity": "info",
6926 "title": "g1t commented on flagon-io/hello#14",
6927 "body": "The heading level is off by one.",
6928 "event": "comment.created",
6929 "actor": "g1t",
6930 "created_at": "2026-10-06T15:02:11.000Z"
6931 }
6932 ],
6933 "subscription": {
6934 "subscribed": true,
6935 "ignored": false,
6936 "reason": "review_requested",
6937 "repo": "flagon-io/hello",
6938 "number": 14,
6939 "updated_at": null
6940 }
6941 }
6942 },
6943 "snooze_thread": {
6944 "params": {
6945 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
6946 },
6947 "request": {
6948 "until": "2026-10-08T09:00:00Z"
6949 },
6950 "response": {
6951 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
6952 "reason": "review_requested",
6953 "severity": "warning",
6954 "title": "ada asked you to review flagon-io/hello#14",
6955 "body": "Add a greeting to the README",
6956 "event": "pull.review_requested",
6957 "repo": "flagon-io/hello",
6958 "workspace": "flagon-io",
6959 "subject": "pull",
6960 "number": 14,
6961 "url": "/flagon-io/hello/pull/14",
6962 "actor": "ada",
6963 "count": 3,
6964 "created_at": "2026-10-06T15:02:11.000Z",
6965 "updated_at": "2026-10-07T09:41:30.000Z",
6966 "read_at": "2026-10-07T10:03:00.000Z",
6967 "done_at": null,
6968 "saved": false,
6969 "snoozed_until": "2026-10-08T09:00:00.000Z",
6970 "activity": [
6971 {
6972 "reason": "review_requested",
6973 "severity": "warning",
6974 "title": "ada asked you to review flagon-io/hello#14",
6975 "body": "Add a greeting to the README",
6976 "event": "pull.review_requested",
6977 "actor": "ada",
6978 "created_at": "2026-10-07T09:41:30.000Z"
6979 },
6980 {
6981 "reason": "comment",
6982 "severity": "info",
6983 "title": "ada commented on flagon-io/hello#14",
6984 "body": "Pushed the fix for the heading.",
6985 "event": "comment.created",
6986 "actor": "ada",
6987 "created_at": "2026-10-06T18:20:02.000Z"
6988 },
6989 {
6990 "reason": "comment",
6991 "severity": "info",
6992 "title": "g1t commented on flagon-io/hello#14",
6993 "body": "The heading level is off by one.",
6994 "event": "comment.created",
6995 "actor": "g1t",
6996 "created_at": "2026-10-06T15:02:11.000Z"
6997 }
6998 ],
6999 "subscription": {
7000 "subscribed": true,
7001 "ignored": false,
7002 "reason": "review_requested",
7003 "repo": "flagon-io/hello",
7004 "number": 14,
7005 "updated_at": null
7006 }
7007 }
7008 },
7009 "unsnooze_thread": {
7010 "params": {
7011 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
7012 },
7013 "response": {
7014 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a",
7015 "reason": "review_requested",
7016 "severity": "warning",
7017 "title": "ada asked you to review flagon-io/hello#14",
7018 "body": "Add a greeting to the README",
7019 "event": "pull.review_requested",
7020 "repo": "flagon-io/hello",
7021 "workspace": "flagon-io",
7022 "subject": "pull",
7023 "number": 14,
7024 "url": "/flagon-io/hello/pull/14",
7025 "actor": "ada",
7026 "count": 3,
7027 "created_at": "2026-10-06T15:02:11.000Z",
7028 "updated_at": "2026-10-07T09:41:30.000Z",
7029 "read_at": "2026-10-07T10:03:00.000Z",
7030 "done_at": null,
7031 "saved": false,
7032 "snoozed_until": null,
7033 "activity": [
7034 {
7035 "reason": "review_requested",
7036 "severity": "warning",
7037 "title": "ada asked you to review flagon-io/hello#14",
7038 "body": "Add a greeting to the README",
7039 "event": "pull.review_requested",
7040 "actor": "ada",
7041 "created_at": "2026-10-07T09:41:30.000Z"
7042 },
7043 {
7044 "reason": "comment",
7045 "severity": "info",
7046 "title": "ada commented on flagon-io/hello#14",
7047 "body": "Pushed the fix for the heading.",
7048 "event": "comment.created",
7049 "actor": "ada",
7050 "created_at": "2026-10-06T18:20:02.000Z"
7051 },
7052 {
7053 "reason": "comment",
7054 "severity": "info",
7055 "title": "g1t commented on flagon-io/hello#14",
7056 "body": "The heading level is off by one.",
7057 "event": "comment.created",
7058 "actor": "g1t",
7059 "created_at": "2026-10-06T15:02:11.000Z"
7060 }
7061 ],
7062 "subscription": {
7063 "subscribed": true,
7064 "ignored": false,
7065 "reason": "review_requested",
7066 "repo": "flagon-io/hello",
7067 "number": 14,
7068 "updated_at": null
7069 }
7070 }
7071 },
7072 "get_thread_subscription": {
7073 "params": {
7074 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
7075 },
7076 "response": {
7077 "subscribed": true,
7078 "ignored": false,
7079 "reason": "review_requested",
7080 "repo": "flagon-io/hello",
7081 "number": 14,
7082 "updated_at": null
7083 }
7084 },
7085 "set_thread_subscription": {
7086 "params": {
7087 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
7088 },
7089 "request": {
7090 "ignored": true
7091 },
7092 "response": {
7093 "subscribed": false,
7094 "ignored": true,
7095 "reason": null,
7096 "repo": "flagon-io/hello",
7097 "number": 14,
7098 "updated_at": "2026-10-07T10:04:00.000Z"
7099 },
7100 "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 |"
7101 },
7102 "delete_thread_subscription": {
7103 "params": {
7104 "id": "ntf_01kp7m2q3r4s5t6v7w8x9y0z1a"
7105 },
7106 "response": {
7107 "subscribed": false,
7108 "ignored": false,
7109 "reason": null,
7110 "repo": "flagon-io/hello",
7111 "number": 14,
7112 "updated_at": "2026-10-07T10:04:00.000Z"
7113 }
7114 },
7115 "get_issue_subscription": {
7116 "params": {
7117 "owner": "flagon-io",
7118 "name": "hello",
7119 "number": 14
7120 },
7121 "response": {
7122 "subscribed": true,
7123 "ignored": false,
7124 "reason": "author",
7125 "repo": null,
7126 "number": 14,
7127 "updated_at": null
7128 }
7129 },
7130 "set_issue_subscription": {
7131 "params": {
7132 "owner": "flagon-io",
7133 "name": "hello",
7134 "number": 14
7135 },
7136 "request": {
7137 "subscribed": true
7138 },
7139 "response": {
7140 "subscribed": true,
7141 "ignored": false,
7142 "reason": "manual",
7143 "repo": null,
7144 "number": 14,
7145 "updated_at": "2026-10-07T10:05:00.000Z"
7146 }
7147 },
7148 "delete_issue_subscription": {
7149 "params": {
7150 "owner": "flagon-io",
7151 "name": "hello",
7152 "number": 14
7153 },
7154 "response": {
7155 "subscribed": false,
7156 "ignored": false,
7157 "reason": null,
7158 "repo": null,
7159 "number": 14,
7160 "updated_at": "2026-10-07T10:05:30.000Z"
7161 }
7162 },
7163 "get_repo_subscription": {
7164 "params": {
7165 "owner": "flagon-io",
7166 "name": "hello"
7167 },
7168 "response": {
7169 "repo": "flagon-io/hello",
7170 "level": "participating",
7171 "events": [],
7172 "subscribed": false,
7173 "ignored": false,
7174 "updated_at": null
7175 }
7176 },
7177 "set_repo_subscription": {
7178 "params": {
7179 "owner": "flagon-io",
7180 "name": "hello"
7181 },
7182 "request": {
7183 "level": "custom",
7184 "events": [
7185 "pulls",
7186 "deployments"
7187 ]
7188 },
7189 "response": {
7190 "repo": "flagon-io/hello",
7191 "level": "custom",
7192 "events": [
7193 "pulls",
7194 "deployments"
7195 ],
7196 "subscribed": true,
7197 "ignored": false,
7198 "updated_at": "2026-10-07T10:06:00.000Z"
7199 },
7200 "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`."
7201 },
7202 "delete_repo_subscription": {
7203 "params": {
7204 "owner": "flagon-io",
7205 "name": "hello"
7206 },
7207 "response": {
7208 "repo": "flagon-io/hello",
7209 "level": "participating",
7210 "events": [],
7211 "subscribed": false,
7212 "ignored": false,
7213 "updated_at": null
7214 }
7215 },
7216 "list_watched_repos": {
7217 "response": [
7218 {
7219 "repo": "flagon-io/hello",
7220 "level": "all",
7221 "events": [],
7222 "subscribed": true,
7223 "ignored": false,
7224 "updated_at": "2026-10-07T10:00:00.000Z"
7225 },
7226 {
7227 "repo": "flagon-io/docs",
7228 "level": "ignore",
7229 "events": [],
7230 "subscribed": false,
7231 "ignored": true,
7232 "updated_at": "2026-10-05T14:30:00.000Z"
7233 }
7234 ]
7235 },
7236 "get_usage": {
7237 "params": {
7238 "workspace": "flagon-io"
7239 },
7240 "query": {
7241 "from": "2026-10-01",
7242 "until": "2026-10-07",
7243 "group_by": "project"
7244 },
7245 "response": {
7246 "from": "2026-10-01",
7247 "until": "2026-10-07",
7248 "totals": {
7249 "price_micros": 48212000,
7250 "discount_micros": 0,
7251 "included_micros": 20000000,
7252 "credits_micros": 18000000,
7253 "charged_micros": 10212000,
7254 "pending_micros": 1340000,
7255 "pending_charged_micros": 1340000,
7256 "cost_micros": 40100000
7257 },
7258 "days": [
7259 {
7260 "day": "2026-10-06",
7261 "product": "other",
7262 "micros": 12400000
7263 },
7264 {
7265 "day": "2026-10-06",
7266 "product": "sandboxes",
7267 "micros": 2100000
7268 },
7269 {
7270 "day": "2026-10-07",
7271 "product": "other",
7272 "micros": 9800000
7273 }
7274 ],
7275 "products": [
7276 {
7277 "key": "sandboxes",
7278 "label": "Sandboxes",
7279 "micros": 7212000,
7280 "meters": [
7281 {
7282 "key": "runner_2-core",
7283 "label": "Runner minutes, 2-core (2 vCPU, 8 GiB, 16 GB)",
7284 "product": "sandboxes",
7285 "unit": "minutes",
7286 "quantity": 1803,
7287 "micros": 7212000,
7288 "pending_micros": 0,
7289 "daily": [
7290 900000,
7291 1200000,
7292 800000,
7293 1100000,
7294 0,
7295 2100000,
7296 1112000
7297 ],
7298 "allowance": null,
7299 "by_project": [
7300 {
7301 "project": "flagon-io/g1t",
7302 "micros": 7212000,
7303 "quantity": 1803
7304 }
7305 ]
7306 }
7307 ]
7308 },
7309 {
7310 "key": "other",
7311 "label": "Other",
7312 "micros": 41000000,
7313 "meters": [
7314 {
7315 "key": "other",
7316 "label": "Other",
7317 "product": "other",
7318 "unit": "entries",
7319 "quantity": 23,
7320 "micros": 41000000,
7321 "pending_micros": 0,
7322 "daily": [
7323 3100000,
7324 5200000,
7325 4400000,
7326 6000000,
7327 0,
7328 12400000,
7329 9800000
7330 ],
7331 "allowance": null,
7332 "by_project": [
7333 {
7334 "project": "flagon-io/g1t",
7335 "micros": 36000000,
7336 "quantity": 14
7337 },
7338 {
7339 "project": "flagon-io/hello",
7340 "micros": 5000000,
7341 "quantity": 9
7342 }
7343 ]
7344 }
7345 ]
7346 }
7347 ],
7348 "projects": [
7349 "flagon-io/g1t",
7350 "flagon-io/hello"
7351 ],
7352 "included": {
7353 "used": 20,
7354 "of": 20,
7355 "unit": "dollars"
7356 },
7357 "discount_percent": null,
7358 "ai_credit_micros": 62000000,
7359 "credit_micros": 0,
7360 "trial_micros": null,
7361 "plan": "pro",
7362 "free": false,
7363 "group_by": "project",
7364 "groups": [
7365 {
7366 "key": "flagon-io/g1t",
7367 "micros": 43210000
7368 },
7369 {
7370 "key": "flagon-io/hello",
7371 "micros": 5000000
7372 }
7373 ]
7374 },
7375 "notes": "Every product family with meters is listed, in order, even with nothing used; this example shows two. `other` comes last, and only when it has something: usage on meters g1t no longer has, such as agent runs from before they were retired. `daily` has one amount for each day of the range, oldest first. `projects` and `products` take several values separated by commas: `?products=sandboxes,deployments`. A range of more than 400 days, or one that ends before it starts, is refused with `invalid`."
7376 },
7377 "get_budget": {
7378 "params": {
7379 "workspace": "flagon-io"
7380 },
7381 "response": {
7382 "workspace": "flagon-io",
7383 "amount_micros": 500000000,
7384 "automatic": false,
7385 "spent_micros": 132450000,
7386 "max_amount_micros": 2000000000,
7387 "alerts": [
7388 50,
7389 75,
7390 90,
7391 100
7392 ],
7393 "pause_at_limit": true,
7394 "webhook": "https://ops.example.com/g1t/budget",
7395 "state": "ok",
7396 "message": null
7397 },
7398 "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."
7399 },
7400 "set_budget": {
7401 "params": {
7402 "workspace": "flagon-io"
7403 },
7404 "request": {
7405 "amount_micros": 500000000,
7406 "alerts": [
7407 50,
7408 75,
7409 90,
7410 100
7411 ],
7412 "webhook": "https://ops.example.com/g1t/budget"
7413 },
7414 "response": {
7415 "workspace": "flagon-io",
7416 "amount_micros": 500000000,
7417 "automatic": false,
7418 "spent_micros": 132450000,
7419 "max_amount_micros": 2000000000,
7420 "alerts": [
7421 50,
7422 75,
7423 90,
7424 100
7425 ],
7426 "pause_at_limit": true,
7427 "webhook": "https://ops.example.com/g1t/budget",
7428 "state": "ok",
7429 "message": null
7430 },
7431 "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 a run's token, it is refused with `forbidden`. Each alert is sent once a month, to the owners by email and, with `webhook`, as a JSON POST."
7432 },
7433 "list_invoices": {
7434 "params": {
7435 "workspace": "flagon-io"
7436 },
7437 "response": {
7438 "invoices": [
7439 {
7440 "id": "in_1Q2w3E4r5T6y7U8i",
7441 "number": "FLAGON-0004",
7442 "status": "paid",
7443 "total_cents": 4210,
7444 "currency": "usd",
7445 "created_at": "2026-10-01T00:05:00.000Z",
7446 "description": "Usage for 2026-09",
7447 "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i",
7448 "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf"
7449 }
7450 ],
7451 "usage_invoices": [
7452 {
7453 "id": "inv_01kkqz8d3c6f9t2wq5n8h1m4r7",
7454 "workspace": "flagon-io",
7455 "reason": "month",
7456 "period": "2026-09",
7457 "amount_micros": 42100000,
7458 "status": "paid",
7459 "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i",
7460 "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf",
7461 "lines": [
7462 {
7463 "description": "Agent: models",
7464 "amount_micros": 35900000
7465 },
7466 {
7467 "description": "Sandbox time",
7468 "amount_micros": 6200000
7469 }
7470 ],
7471 "created_at": "2026-10-01T00:05:00.000Z"
7472 },
7473 {
7474 "id": "inv_01kkqz8d3c6f9t2wq5n8h1m4r7",
7475 "workspace": "flagon-io",
7476 "reason": "month",
7477 "period": "2026-09",
7478 "amount_micros": 42100000,
7479 "status": "paid",
7480 "hosted_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i",
7481 "pdf_url": "https://invoice.example.com/i/acct_1/in_1Q2w3E4r5T6y7U8i/pdf",
7482 "lines": [
7483 {
7484 "description": "Agent: models",
7485 "amount_micros": 35900000
7486 },
7487 {
7488 "description": "Sandbox time",
7489 "amount_micros": 6200000
7490 }
7491 ],
7492 "created_at": "2026-10-01T00:05:00.000Z",
7493 "fee_micros": 0,
7494 "tax_micros": 3510000
7495 }
7496 ],
7497 "upcoming": {
7498 "closes_at": "2026-11-01T00:00:00.000Z",
7499 "subscriptions_micros": 21000000,
7500 "usage_micros": 10210000,
7501 "total_micros": 30210000
7502 },
7503 "unavailable": null
7504 },
7505 "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`."
7506 },
7507 "get_billing_details": {
7508 "params": {
7509 "workspace": "flagon-io"
7510 },
7511 "response": {
7512 "customer": true,
7513 "email": "billing@flagon.example.com",
7514 "name": "Flagon, Inc.",
7515 "address": {
7516 "line1": "100 Market Street",
7517 "line2": "",
7518 "city": "San Francisco",
7519 "state": "CA",
7520 "postal_code": "94105",
7521 "country": "US"
7522 },
7523 "tax_id_type": "us_ein",
7524 "tax_id": "12-3456789",
7525 "po_number": null,
7526 "language": "en",
7527 "payment_method": {
7528 "kind": "card",
7529 "brand": "visa",
7530 "last4": "4242",
7531 "exp_month": 12,
7532 "exp_year": 2028
7533 },
7534 "tax_location": true,
7535 "tax_address_needed_at": null,
7536 "tax_id_status": "unavailable",
7537 "tax_exempt": "none"
7538 },
7539 "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."
7540 },
7541 "list_pinned_projects": {
7542 "params": {
7543 "workspace": "flagon-io"
7544 },
7545 "response": [
7546 {
7547 "position": 0,
7548 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7549 "workspace": "flagon-io",
7550 "slug": "g1t",
7551 "name": "g1t",
7552 "description": null,
7553 "private": false,
7554 "archived": false,
7555 "kind": "app",
7556 "url": "https://g1t.sh/flagon-io/g1t",
7557 "pushed_at": "2026-10-07T10:00:00.000Z",
7558 "updated_at": "2026-10-01T09:12:00.000Z"
7559 },
7560 {
7561 "position": 1,
7562 "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z",
7563 "workspace": "flagon-io",
7564 "slug": "lab-api",
7565 "name": "lab-api",
7566 "description": null,
7567 "private": true,
7568 "archived": false,
7569 "kind": "app",
7570 "url": "https://g1t.sh/flagon-io/lab-api",
7571 "pushed_at": "2026-10-06T18:40:00.000Z",
7572 "updated_at": "2026-10-01T09:12:00.000Z"
7573 },
7574 {
7575 "position": 2,
7576 "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y",
7577 "workspace": "flagon-io",
7578 "slug": "hello",
7579 "name": "hello",
7580 "description": "Greets people from the command line.",
7581 "private": false,
7582 "archived": false,
7583 "kind": "library",
7584 "url": "https://g1t.sh/flagon-io/hello",
7585 "pushed_at": null,
7586 "updated_at": "2026-10-01T09:12:00.000Z"
7587 }
7588 ],
7589 "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."
7590 },
7591 "pin_project": {
7592 "params": {
7593 "workspace": "flagon-io",
7594 "project": "hello"
7595 },
7596 "request": {
7597 "position": 0
7598 },
7599 "response": [
7600 {
7601 "position": 0,
7602 "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y",
7603 "workspace": "flagon-io",
7604 "slug": "hello",
7605 "name": "hello",
7606 "description": "Greets people from the command line.",
7607 "private": false,
7608 "archived": false,
7609 "kind": "library",
7610 "url": "https://g1t.sh/flagon-io/hello",
7611 "pushed_at": null,
7612 "updated_at": "2026-10-01T09:12:00.000Z"
7613 },
7614 {
7615 "position": 1,
7616 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7617 "workspace": "flagon-io",
7618 "slug": "g1t",
7619 "name": "g1t",
7620 "description": null,
7621 "private": false,
7622 "archived": false,
7623 "kind": "app",
7624 "url": "https://g1t.sh/flagon-io/g1t",
7625 "pushed_at": "2026-10-07T10:00:00.000Z",
7626 "updated_at": "2026-10-01T09:12:00.000Z"
7627 },
7628 {
7629 "position": 2,
7630 "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z",
7631 "workspace": "flagon-io",
7632 "slug": "lab-api",
7633 "name": "lab-api",
7634 "description": null,
7635 "private": true,
7636 "archived": false,
7637 "kind": "app",
7638 "url": "https://g1t.sh/flagon-io/lab-api",
7639 "pushed_at": "2026-10-06T18:40:00.000Z",
7640 "updated_at": "2026-10-01T09:12:00.000Z"
7641 }
7642 ],
7643 "notes": "A ninth pin in a workspace is refused with `409 conflict`: unpin one first."
7644 },
7645 "unpin_project": {
7646 "params": {
7647 "workspace": "flagon-io",
7648 "project": "lab-api"
7649 },
7650 "response": [
7651 {
7652 "position": 0,
7653 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7654 "workspace": "flagon-io",
7655 "slug": "g1t",
7656 "name": "g1t",
7657 "description": null,
7658 "private": false,
7659 "archived": false,
7660 "kind": "app",
7661 "url": "https://g1t.sh/flagon-io/g1t",
7662 "pushed_at": "2026-10-07T10:00:00.000Z",
7663 "updated_at": "2026-10-01T09:12:00.000Z"
7664 },
7665 {
7666 "position": 1,
7667 "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y",
7668 "workspace": "flagon-io",
7669 "slug": "hello",
7670 "name": "hello",
7671 "description": "Greets people from the command line.",
7672 "private": false,
7673 "archived": false,
7674 "kind": "library",
7675 "url": "https://g1t.sh/flagon-io/hello",
7676 "pushed_at": null,
7677 "updated_at": "2026-10-01T09:12:00.000Z"
7678 }
7679 ]
7680 },
7681 "reorder_pinned_projects": {
7682 "params": {
7683 "workspace": "flagon-io"
7684 },
7685 "request": {
7686 "projects": [
7687 "lab-api",
7688 "g1t",
7689 "hello"
7690 ]
7691 },
7692 "response": [
7693 {
7694 "position": 0,
7695 "id": "prj_01kkq0c4d9h2w7rn5f8t3k6p2z",
7696 "workspace": "flagon-io",
7697 "slug": "lab-api",
7698 "name": "lab-api",
7699 "description": null,
7700 "private": true,
7701 "archived": false,
7702 "kind": "app",
7703 "url": "https://g1t.sh/flagon-io/lab-api",
7704 "pushed_at": "2026-10-06T18:40:00.000Z",
7705 "updated_at": "2026-10-01T09:12:00.000Z"
7706 },
7707 {
7708 "position": 1,
7709 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7710 "workspace": "flagon-io",
7711 "slug": "g1t",
7712 "name": "g1t",
7713 "description": null,
7714 "private": false,
7715 "archived": false,
7716 "kind": "app",
7717 "url": "https://g1t.sh/flagon-io/g1t",
7718 "pushed_at": "2026-10-07T10:00:00.000Z",
7719 "updated_at": "2026-10-01T09:12:00.000Z"
7720 },
7721 {
7722 "position": 2,
7723 "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y",
7724 "workspace": "flagon-io",
7725 "slug": "hello",
7726 "name": "hello",
7727 "description": "Greets people from the command line.",
7728 "private": false,
7729 "archived": false,
7730 "kind": "library",
7731 "url": "https://g1t.sh/flagon-io/hello",
7732 "pushed_at": null,
7733 "updated_at": "2026-10-01T09:12:00.000Z"
7734 }
7735 ],
7736 "notes": "Name every pinned project once; anything else is refused with `422 invalid`."
7737 },
7738 "list_commits": {
7739 "notes": "With `path`, `last_changed` is the commit that last changed that file or directory. `author.username` is the g1t account the author's address belongs to, when one does; the address is never returned.",
7740 "params": {
7741 "owner": "flagon-io",
7742 "name": "g1t"
7743 },
7744 "query": {
7745 "path": "scripts/deploy/npm-ci.mjs",
7746 "limit": "1"
7747 },
7748 "response": {
7749 "repo": "flagon-io/g1t",
7750 "commits": [
7751 {
7752 "sha": "85c083a0e4b1d2c3f4a5b6c7d8e9f0a1b2c3d4e5",
7753 "message": "The runner's broker test reads the relayed answer's body as chunks.",
7754 "author": { "name": "Chase Pierce", "username": "syntaqx" },
7755 "authored_at": "2026-10-12T22:04:11Z",
7756 "parents": ["75c6704f2b1a3c4d5e6f708192a3b4c5d6e7f809"],
7757 "html_url": "https://g1t.sh/flagon-io/g1t/commit/85c083a0e4b1d2c3f4a5b6c7d8e9f0a1b2c3d4e5"
7758 }
7759 ],
7760 "path": "scripts/deploy/npm-ci.mjs",
7761 "last_changed": {
7762 "sha": "5d1e2f3a4b5c6d7e8f9a0b1c2d3e4f5a6b7c8d9e",
7763 "message": "Installs in cloud jobs retry when npm's download breaks off.",
7764 "author": { "name": "Chase Pierce", "username": "syntaqx" },
7765 "authored_at": "2026-10-13T01:12:40Z",
7766 "parents": ["0a1b2c3d4e5f60718293a4b5c6d7e8f9a0b1c2d3"],
7767 "html_url": "https://g1t.sh/flagon-io/g1t/commit/5d1e2f3a4b5c6d7e8f9a0b1c2d3e4f5a6b7c8d9e"
7768 }
7769 }
7770 },
7771 "get_contents": {
7772 "notes": "A file's text, or with no `path` (or a directory's) the entries and README. `ref` is a branch, tag or commit; the default branch when left out.",
7773 "params": {
7774 "owner": "flagon-io",
7775 "name": "g1t"
7776 },
7777 "query": {
7778 "path": "CONTRIBUTING.md"
7779 },
7780 "response": {
7781 "type": "file",
7782 "repo": "flagon-io/g1t",
7783 "ref": "main",
7784 "path": "CONTRIBUTING.md",
7785 "size": 412,
7786 "binary": false,
7787 "text": "# Contributing\n\nRun the tests before you push:\n\n```sh\ncargo test --workspace\nnpm test --workspaces --if-present\n```\n",
7788 "html_url": "https://g1t.sh/flagon-io/g1t/blob/main/CONTRIBUTING.md"
7789 }
7790 },
7791 "get_workspace_activity": {
7792 "notes": "What shipped today across a workspace: `since` at the start of the day and `kinds=merged,releases,deployments,pushes,runs`. Each event links to its page on g1t (`url`). `landed` is what reached default branches, each commit with `production` where its repository deploys. Ask g1t reads this to answer questions about a workspace.",
7793 "params": {
7794 "workspace": "flagon-io"
7795 },
7796 "query": {
7797 "since": "2026-10-12T00:00:00Z",
7798 "kinds": "merged,releases,deployments"
7799 },
7800 "response": {
7801 "workspace": "flagon-io",
7802 "since": "2026-10-12T00:00:00Z",
7803 "until": "2026-10-12T21:40:00Z",
7804 "repositories": 4,
7805 "summary": {
7806 "merged_pull_requests": 1,
7807 "releases": 1,
7808 "production_deployments": 1,
7809 "failed_deployments": 0,
7810 "default_branch_pushes": 0,
7811 "failed_runs": 0,
7812 "shipped": { "live": 1, "deploying": 0, "failed": 0, "not_deployed": 0 }
7813 },
7814 "landed": [
7815 {
7816 "repo": "flagon-io/g1t",
7817 "commit": "75c6704f2b1a",
7818 "subject": "Ask g1t answers with the workspace's own AI provider",
7819 "author": "Chase Pierce",
7820 "time": "2026-10-12T17:58:40Z",
7821 "url": "https://g1t.sh/flagon-io/g1t/commit/75c6704f2b1a3c4d5e6f708192a3b4c5d6e7f809",
7822 "username": "syntaqx",
7823 "production": "live",
7824 "deploy": { "name": "g1t's production deployment", "url": "https://g1t.sh/flagon-io/g1t/deployments/dpl_01kkp3m8w2f6t9qh4c7d1r5n0x" }
7825 }
7826 ],
7827 "events": [
7828 {
7829 "kind": "deployment_succeeded",
7830 "time": "2026-10-12T21:12:04Z",
7831 "repo": "flagon-io/g1t",
7832 "actor": "syntaqx",
7833 "environment": "production",
7834 "project": "g1t",
7835 "branch": "main",
7836 "commit": "75c6704f2b1a",
7837 "url": "https://g1t.sh/flagon-io/g1t/deployments/dpl_01kkp3m8w2f6t9qh4c7d1r5n0x"
7838 },
7839 {
7840 "kind": "release_published",
7841 "time": "2026-10-12T19:30:51Z",
7842 "repo": "flagon-io/runner",
7843 "actor": "syntaqx",
7844 "tag": "v0.3.3",
7845 "title": "Runner 0.3.3",
7846 "url": "https://g1t.sh/flagon-io/runner/releases/tag/v0.3.3"
7847 },
7848 {
7849 "kind": "pull_merged",
7850 "time": "2026-10-12T18:02:17Z",
7851 "repo": "flagon-io/g1t",
7852 "actor": "syntaqx",
7853 "number": 412,
7854 "title": "Ask g1t answers with the workspace's own AI provider",
7855 "url": "https://g1t.sh/flagon-io/g1t/pull/412",
7856 "issue": 398
7857 }
7858 ],
7859 "complete": true
7860 }
7861 },
7862 "list_projects": {
7863 "params": {
7864 "workspace": "flagon-io"
7865 },
7866 "response": [
7867 {
7868 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7869 "workspace": "flagon-io",
7870 "slug": "g1t",
7871 "name": "g1t",
7872 "description": "Git hosting where people and agents work together.",
7873 "url": "https://g1t.sh/flagon-io/g1t",
7874 "repository": "flagon-io/g1t",
7875 "root_dir": "",
7876 "default_branch": "main",
7877 "private": false,
7878 "archived": false,
7879 "primary": true,
7880 "kind": "app",
7881 "kind_reason": {
7882 "by": "set",
7883 "detail": "Set in its settings: it deploys itself."
7884 },
7885 "runs": "elsewhere",
7886 "production_url": "https://g1t.sh",
7887 "setting": {
7888 "kind": "app",
7889 "runs": "elsewhere"
7890 },
7891 "detected": {
7892 "kind": "app",
7893 "reason": {
7894 "by": "files",
7895 "detail": "wrangler.jsonc at its root makes it an app."
7896 }
7897 },
7898 "ecosystem": null,
7899 "links": {
7900 "homepage": "https://g1t.sh",
7901 "homepage_inherited": true,
7902 "docs": "https://docs.g1t.sh",
7903 "custom": [
7904 {
7905 "label": "Status",
7906 "url": "https://status.g1t.sh"
7907 }
7908 ]
7909 },
7910 "created_at": "2026-09-01T10:00:00.000Z",
7911 "updated_at": "2026-10-07T11:20:00.000Z",
7912 "pushed_at": "2026-10-07T10:00:00.000Z"
7913 },
7914 {
7915 "id": "prj_01kkp3n2a7e5v8sk3b6g9j4m1y",
7916 "workspace": "flagon-io",
7917 "slug": "hello",
7918 "name": "hello",
7919 "description": "Greets people from the command line.",
7920 "url": "https://g1t.sh/flagon-io/hello",
7921 "repository": "flagon-io/hello",
7922 "root_dir": "",
7923 "default_branch": "main",
7924 "private": false,
7925 "archived": false,
7926 "primary": true,
7927 "kind": "library",
7928 "kind_reason": {
7929 "by": "files",
7930 "detail": "composer.json says it is a library."
7931 },
7932 "runs": null,
7933 "production_url": null,
7934 "setting": {
7935 "kind": null,
7936 "runs": null
7937 },
7938 "detected": {
7939 "kind": "library",
7940 "reason": {
7941 "by": "files",
7942 "detail": "composer.json says it is a library."
7943 }
7944 },
7945 "ecosystem": "composer",
7946 "links": {
7947 "homepage": null,
7948 "homepage_inherited": false,
7949 "docs": null,
7950 "custom": []
7951 },
7952 "created_at": "2026-09-12T14:30:00.000Z",
7953 "updated_at": "2026-10-01T09:12:00.000Z",
7954 "pushed_at": null
7955 }
7956 ],
7957 "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/)."
7958 },
7959 "get_project": {
7960 "params": {
7961 "workspace": "flagon-io",
7962 "project": "g1t"
7963 },
7964 "response": {
7965 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
7966 "workspace": "flagon-io",
7967 "slug": "g1t",
7968 "name": "g1t",
7969 "description": "Git hosting where people and agents work together.",
7970 "url": "https://g1t.sh/flagon-io/g1t",
7971 "repository": "flagon-io/g1t",
7972 "root_dir": "",
7973 "default_branch": "main",
7974 "private": false,
7975 "archived": false,
7976 "primary": true,
7977 "kind": "app",
7978 "kind_reason": {
7979 "by": "set",
7980 "detail": "Set in its settings: it deploys itself."
7981 },
7982 "runs": "elsewhere",
7983 "production_url": "https://g1t.sh",
7984 "setting": {
7985 "kind": "app",
7986 "runs": "elsewhere"
7987 },
7988 "detected": {
7989 "kind": "app",
7990 "reason": {
7991 "by": "files",
7992 "detail": "wrangler.jsonc at its root makes it an app."
7993 }
7994 },
7995 "ecosystem": null,
7996 "links": {
7997 "homepage": "https://g1t.sh",
7998 "homepage_inherited": true,
7999 "docs": "https://docs.g1t.sh",
8000 "custom": [
8001 {
8002 "label": "Status",
8003 "url": "https://status.g1t.sh"
8004 }
8005 ]
8006 },
8007 "created_at": "2026-09-01T10:00:00.000Z",
8008 "updated_at": "2026-10-07T11:20:00.000Z",
8009 "pushed_at": "2026-10-07T10:00:00.000Z"
8010 },
8011 "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)."
8012 },
8013 "update_project": {
8014 "params": {
8015 "workspace": "flagon-io",
8016 "project": "g1t"
8017 },
8018 "request": {
8019 "kind": "app",
8020 "runs": "elsewhere",
8021 "production_url": "https://g1t.sh",
8022 "docs_url": "https://docs.g1t.sh",
8023 "links": [
8024 {
8025 "label": "Status",
8026 "url": "https://status.g1t.sh"
8027 }
8028 ]
8029 },
8030 "response": {
8031 "id": "prj_01kkp3m8w2f6t9qh4c7d1r5n0x",
8032 "workspace": "flagon-io",
8033 "slug": "g1t",
8034 "name": "g1t",
8035 "description": "Git hosting where people and agents work together.",
8036 "url": "https://g1t.sh/flagon-io/g1t",
8037 "repository": "flagon-io/g1t",
8038 "root_dir": "",
8039 "default_branch": "main",
8040 "private": false,
8041 "archived": false,
8042 "primary": true,
8043 "kind": "app",
8044 "kind_reason": {
8045 "by": "set",
8046 "detail": "Set in its settings: it deploys itself."
8047 },
8048 "runs": "elsewhere",
8049 "production_url": "https://g1t.sh",
8050 "setting": {
8051 "kind": "app",
8052 "runs": "elsewhere"
8053 },
8054 "detected": {
8055 "kind": "app",
8056 "reason": {
8057 "by": "files",
8058 "detail": "wrangler.jsonc at its root makes it an app."
8059 }
8060 },
8061 "ecosystem": null,
8062 "links": {
8063 "homepage": "https://g1t.sh",
8064 "homepage_inherited": true,
8065 "docs": "https://docs.g1t.sh",
8066 "custom": [
8067 {
8068 "label": "Status",
8069 "url": "https://status.g1t.sh"
8070 }
8071 ]
8072 },
8073 "created_at": "2026-09-01T10:00:00.000Z",
8074 "updated_at": "2026-10-07T11:20:00.000Z",
8075 "pushed_at": "2026-10-07T10:00:00.000Z"
8076 },
8077 "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)."
8078 },
8079 "get_deployment_settings": {
8080 "params": {
8081 "workspace": "flagon-io",
8082 "project": "session-lab"
8083 },
8084 "response": {
8085 "workspace": "flagon-io",
8086 "project": "session-lab",
8087 "enabled": false,
8088 "production": true,
8089 "previews": true,
8090 "production_url": "https://session-lab-flagonio.g1t.page",
8091 "primary_domain": null,
8092 "build_as": "auto",
8093 "build_command": null,
8094 "output_dir": null,
8095 "dockerfile": null,
8096 "instance_type": "lite",
8097 "idle_days": 7,
8098 "via_workflow": false,
8099 "detected": null,
8100 "framework": null
8101 },
8102 "notes": "A repository's own project has the repository's name, so `flagon-io/session-lab`'s settings are at `/workspaces/flagon-io/projects/session-lab/deployments/settings`. `production_url` is where production is served once Deployments are on; `primary_domain` is the first active custom domain that serves it. `detected` and `framework` are what the last finished build found, and null before one has. Needs the Read role on the project's repository (`404` to anyone who cannot see it). See [Deployments](/guides/deployments/#settings)."
8103 },
8104 "update_deployment_settings": {
8105 "params": {
8106 "workspace": "flagon-io",
8107 "project": "session-lab"
8108 },
8109 "request": {
8110 "enabled": true
8111 },
8112 "response": {
8113 "workspace": "flagon-io",
8114 "project": "session-lab",
8115 "enabled": true,
8116 "production": true,
8117 "previews": true,
8118 "production_url": "https://session-lab-flagonio.g1t.page",
8119 "primary_domain": null,
8120 "build_as": "auto",
8121 "build_command": null,
8122 "output_dir": null,
8123 "dockerfile": null,
8124 "instance_type": "lite",
8125 "idle_days": 7,
8126 "via_workflow": false,
8127 "detected": null,
8128 "framework": null
8129 },
8130 "notes": "Only the fields given change. `enabled: true` turns Deployments on: production starts building from the default branch at once (an empty repository's first push to it deploys), and every pull request gets a preview. It is refused with `402 payment_required` when the workspace does not have the [g1t plan](/guides/usage-and-billing/#the-g1t-plan), saying where an owner starts it, and with `409 conflict` for a project set to be a library, a tool or other (change `kind` with [`update_project`](/reference/api/projects/update-project/) first). `enabled: false` takes production and every preview down at once. `build_command`, `output_dir` and `dockerfile` given as null or `\"\"` go back to what is found by itself; `idle_days` is 1 to 90; anything else is refused with `422 invalid`. Needs the Admin role on the project's repository (`403` otherwise, saying so) and a token with `repo:admin`. To turn them on as a repository is made, give `deploy: true` to [`create_repo`](/reference/api/repositories/create-repo/). See [Turn on deployments](/guides/deployments/#turn-on-deployments)."
8131 },
8132 "list_secret_scanning_alerts": {
8133 "params": {
8134 "owner": "flagon-io",
8135 "name": "hello"
8136 },
8137 "query": {
8138 "state": "open"
8139 },
8140 "response": [
8141 {
8142 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8143 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8144 "kind": "github_token",
8145 "label": "a GitHub token",
8146 "path": "scripts/release.sh",
8147 "line": 12,
8148 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8149 "preview": "ghp_X7…",
8150 "status": "open",
8151 "source": "push",
8152 "found_by": "syntaqx",
8153 "found_at": "2026-10-06T09:14:02.118Z",
8154 "decided_by": null,
8155 "reason": null,
8156 "decided_at": null,
8157 "dismissed_reason": null,
8158 "test_value": null,
8159 "state": "open",
8160 "validity": "active",
8161 "validity_checked_at": "2026-10-06T09:20:41.502Z",
8162 "bypass": {
8163 "reason": "will_fix_later",
8164 "comment": "Rotating it this afternoon.",
8165 "by": "syntaqx",
8166 "at": "2026-10-06T09:14:02.118Z",
8167 "approved_by": null
8168 },
8169 "pattern_id": null,
8170 "pattern_name": null,
8171 "locations": 1
8172 }
8173 ],
8174 "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`."
8175 },
8176 "list_secret_scanning_alerts_for_workspace": {
8177 "params": {
8178 "workspace": "flagon-io"
8179 },
8180 "query": {
8181 "state": "open"
8182 },
8183 "response": [
8184 {
8185 "repo": "hello",
8186 "secret": {
8187 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8188 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8189 "kind": "github_token",
8190 "label": "a GitHub token",
8191 "path": "scripts/release.sh",
8192 "line": 12,
8193 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8194 "preview": "ghp_X7…",
8195 "status": "open",
8196 "source": "push",
8197 "found_by": "syntaqx",
8198 "found_at": "2026-10-06T09:14:02.118Z",
8199 "decided_by": null,
8200 "reason": null,
8201 "decided_at": null,
8202 "dismissed_reason": null,
8203 "test_value": null,
8204 "state": "open",
8205 "validity": "active",
8206 "validity_checked_at": "2026-10-06T09:20:41.502Z",
8207 "bypass": {
8208 "reason": "will_fix_later",
8209 "comment": "Rotating it this afternoon.",
8210 "by": "syntaqx",
8211 "at": "2026-10-06T09:14:02.118Z",
8212 "approved_by": null
8213 },
8214 "pattern_id": null,
8215 "pattern_name": null,
8216 "locations": 1
8217 }
8218 }
8219 ],
8220 "notes": "Every repository whose findings you may see, each alert with its repository's name."
8221 },
8222 "get_secret_scanning_alert": {
8223 "params": {
8224 "owner": "flagon-io",
8225 "name": "hello",
8226 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p"
8227 },
8228 "response": {
8229 "secret": {
8230 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8231 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8232 "kind": "github_token",
8233 "label": "a GitHub token",
8234 "path": "scripts/release.sh",
8235 "line": 12,
8236 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8237 "preview": "ghp_X7…",
8238 "status": "blocked",
8239 "source": "push",
8240 "found_by": "syntaqx",
8241 "found_at": "2026-10-06T09:14:02.118Z",
8242 "decided_by": null,
8243 "reason": null,
8244 "decided_at": null,
8245 "dismissed_reason": null,
8246 "test_value": null,
8247 "state": "open",
8248 "validity": null,
8249 "validity_checked_at": null,
8250 "bypass": null,
8251 "pattern_id": null,
8252 "pattern_name": null,
8253 "locations": 1
8254 },
8255 "locations": [
8256 {
8257 "path": "scripts/release.sh",
8258 "line": 12,
8259 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8260 "source": "push",
8261 "found_at": "2026-10-06T09:14:02.118Z"
8262 }
8263 ],
8264 "activity": [],
8265 "requests": [],
8266 "checkable": true,
8267 "can_bypass": true,
8268 "can_request_bypass": false
8269 }
8270 },
8271 "update_secret_scanning_alert": {
8272 "params": {
8273 "owner": "flagon-io",
8274 "name": "hello",
8275 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p"
8276 },
8277 "request": {
8278 "state": "dismissed",
8279 "reason": "revoked",
8280 "comment": "Rotated in the issuer's settings."
8281 },
8282 "response": {
8283 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8284 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8285 "kind": "github_token",
8286 "label": "a GitHub token",
8287 "path": "scripts/release.sh",
8288 "line": 12,
8289 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8290 "preview": "ghp_X7…",
8291 "status": "resolved",
8292 "source": "push",
8293 "found_by": "syntaqx",
8294 "found_at": "2026-10-06T09:14:02.118Z",
8295 "decided_by": "syntaqx",
8296 "reason": "Rotated in the issuer's settings.",
8297 "decided_at": "2026-10-06T09:20:41.502Z",
8298 "dismissed_reason": "revoked",
8299 "test_value": null,
8300 "state": "fixed",
8301 "validity": "active",
8302 "validity_checked_at": "2026-10-06T09:20:41.502Z",
8303 "bypass": {
8304 "reason": "will_fix_later",
8305 "comment": "Rotating it this afternoon.",
8306 "by": "syntaqx",
8307 "at": "2026-10-06T09:14:02.118Z",
8308 "approved_by": null
8309 },
8310 "pattern_id": null,
8311 "pattern_name": null,
8312 "locations": 1
8313 },
8314 "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."
8315 },
8316 "list_secret_scanning_locations": {
8317 "params": {
8318 "owner": "flagon-io",
8319 "name": "hello",
8320 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p"
8321 },
8322 "response": [
8323 {
8324 "path": "scripts/release.sh",
8325 "line": 12,
8326 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8327 "source": "push",
8328 "found_at": "2026-10-06T09:14:02.118Z"
8329 }
8330 ]
8331 },
8332 "bypass_push_protection": {
8333 "params": {
8334 "owner": "flagon-io",
8335 "name": "hello",
8336 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p"
8337 },
8338 "request": {
8339 "reason": "will_fix_later",
8340 "comment": "Rotating it this afternoon."
8341 },
8342 "response": {
8343 "secret": {
8344 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8345 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8346 "kind": "github_token",
8347 "label": "a GitHub token",
8348 "path": "scripts/release.sh",
8349 "line": 12,
8350 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8351 "preview": "ghp_X7…",
8352 "status": "open",
8353 "source": "push",
8354 "found_by": "syntaqx",
8355 "found_at": "2026-10-06T09:14:02.118Z",
8356 "decided_by": null,
8357 "reason": null,
8358 "decided_at": null,
8359 "dismissed_reason": null,
8360 "test_value": null,
8361 "state": "open",
8362 "validity": null,
8363 "validity_checked_at": null,
8364 "bypass": {
8365 "reason": "will_fix_later",
8366 "comment": "Rotating it this afternoon.",
8367 "by": "syntaqx",
8368 "at": "2026-10-06T09:14:02.118Z",
8369 "approved_by": null
8370 },
8371 "pattern_id": null,
8372 "pattern_name": null,
8373 "locations": 1
8374 },
8375 "request": null
8376 },
8377 "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."
8378 },
8379 "check_secret_validity": {
8380 "params": {
8381 "owner": "flagon-io",
8382 "name": "hello",
8383 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p"
8384 },
8385 "response": {
8386 "id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8387 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8388 "kind": "github_token",
8389 "label": "a GitHub token",
8390 "path": "scripts/release.sh",
8391 "line": 12,
8392 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8393 "preview": "ghp_X7…",
8394 "status": "open",
8395 "source": "push",
8396 "found_by": "syntaqx",
8397 "found_at": "2026-10-06T09:14:02.118Z",
8398 "decided_by": null,
8399 "reason": null,
8400 "decided_at": null,
8401 "dismissed_reason": null,
8402 "test_value": null,
8403 "state": "open",
8404 "validity": "active",
8405 "validity_checked_at": "2026-10-06T09:20:41.502Z",
8406 "bypass": {
8407 "reason": "will_fix_later",
8408 "comment": "Rotating it this afternoon.",
8409 "by": "syntaqx",
8410 "at": "2026-10-06T09:14:02.118Z",
8411 "approved_by": null
8412 },
8413 "pattern_id": null,
8414 "pattern_name": null,
8415 "locations": 1
8416 },
8417 "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`."
8418 },
8419 "list_bypass_requests": {
8420 "params": {
8421 "workspace": "flagon-io"
8422 },
8423 "query": {
8424 "state": "pending"
8425 },
8426 "response": [
8427 {
8428 "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q",
8429 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8430 "workspace": "flagon-io",
8431 "repo": "hello",
8432 "secret_id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8433 "label": "a GitHub token",
8434 "path": "scripts/release.sh",
8435 "line": 12,
8436 "preview": "ghp_X7…",
8437 "requester": "ana",
8438 "reason": "used_in_tests",
8439 "comment": "A token from the test fixtures, never issued.",
8440 "state": "pending",
8441 "reviewer": null,
8442 "review_comment": null,
8443 "created_at": "2026-10-06T09:14:02.118Z",
8444 "reviewed_at": null
8445 }
8446 ]
8447 },
8448 "review_bypass_request": {
8449 "params": {
8450 "workspace": "flagon-io",
8451 "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q"
8452 },
8453 "request": {
8454 "decision": "approve",
8455 "comment": "A fixture."
8456 },
8457 "response": {
8458 "id": "byp_01kq2n8e5f6g7h8j9k0m1n2p3q",
8459 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8460 "workspace": "flagon-io",
8461 "repo": "hello",
8462 "secret_id": "sec_01kq2m7d4e5f6g7h8j9k0m1n2p",
8463 "label": "a GitHub token",
8464 "path": "scripts/release.sh",
8465 "line": 12,
8466 "preview": "ghp_X7…",
8467 "requester": "ana",
8468 "reason": "used_in_tests",
8469 "comment": "A token from the test fixtures, never issued.",
8470 "state": "approved",
8471 "reviewer": "syntaqx",
8472 "review_comment": "A fixture.",
8473 "created_at": "2026-10-06T09:14:02.118Z",
8474 "reviewed_at": "2026-10-06T09:20:41.502Z"
8475 }
8476 },
8477 "list_custom_patterns": {
8478 "params": {
8479 "owner": "flagon-io",
8480 "name": "hello"
8481 },
8482 "response": {
8483 "patterns": [
8484 {
8485 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8486 "scope": "repository",
8487 "workspace": "flagon-io",
8488 "repo": "hello",
8489 "name": "Acme API key",
8490 "pattern": "acme_[a-z0-9]{32}",
8491 "before": null,
8492 "after": null,
8493 "test_strings": [
8494 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8495 ],
8496 "state": "published",
8497 "created_by": "syntaqx",
8498 "created_at": "2026-10-06T09:14:02.118Z",
8499 "updated_by": "syntaqx",
8500 "updated_at": "2026-10-06T09:14:02.118Z",
8501 "open_alerts": 0
8502 }
8503 ],
8504 "entitled": true
8505 },
8506 "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 when the workspace is on the g1t plan."
8507 },
8508 "list_custom_patterns_for_workspace": {
8509 "params": {
8510 "workspace": "flagon-io"
8511 },
8512 "response": {
8513 "patterns": [
8514 {
8515 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8516 "scope": "workspace",
8517 "workspace": "flagon-io",
8518 "repo": null,
8519 "name": "Acme API key",
8520 "pattern": "acme_[a-z0-9]{32}",
8521 "before": null,
8522 "after": null,
8523 "test_strings": [
8524 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8525 ],
8526 "state": "published",
8527 "created_by": "syntaqx",
8528 "created_at": "2026-10-06T09:14:02.118Z",
8529 "updated_by": "syntaqx",
8530 "updated_at": "2026-10-06T09:14:02.118Z",
8531 "open_alerts": 0
8532 }
8533 ],
8534 "entitled": true
8535 }
8536 },
8537 "create_custom_pattern": {
8538 "params": {
8539 "owner": "flagon-io",
8540 "name": "hello"
8541 },
8542 "request": {
8543 "pattern_name": "Acme API key",
8544 "pattern": "acme_[a-z0-9]{32}",
8545 "test_strings": [
8546 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8547 ],
8548 "publish": true
8549 },
8550 "response": {
8551 "pattern": {
8552 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8553 "scope": "repository",
8554 "workspace": "flagon-io",
8555 "repo": "hello",
8556 "name": "Acme API key",
8557 "pattern": "acme_[a-z0-9]{32}",
8558 "before": null,
8559 "after": null,
8560 "test_strings": [
8561 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8562 ],
8563 "state": "published",
8564 "created_by": "syntaqx",
8565 "created_at": "2026-10-06T09:14:02.118Z",
8566 "updated_by": "syntaqx",
8567 "updated_at": "2026-10-06T09:14:02.118Z",
8568 "open_alerts": 0
8569 },
8570 "tests": [
8571 [
8572 9,
8573 46
8574 ]
8575 ]
8576 },
8577 "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."
8578 },
8579 "create_custom_pattern_for_workspace": {
8580 "params": {
8581 "workspace": "flagon-io"
8582 },
8583 "request": {
8584 "pattern_name": "Acme API key",
8585 "pattern": "acme_[a-z0-9]{32}",
8586 "publish": false
8587 },
8588 "response": {
8589 "pattern": {
8590 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8591 "scope": "workspace",
8592 "workspace": "flagon-io",
8593 "repo": null,
8594 "name": "Acme API key",
8595 "pattern": "acme_[a-z0-9]{32}",
8596 "before": null,
8597 "after": null,
8598 "test_strings": [],
8599 "state": "draft",
8600 "created_by": "syntaqx",
8601 "created_at": "2026-10-06T09:14:02.118Z",
8602 "updated_by": "syntaqx",
8603 "updated_at": "2026-10-06T09:14:02.118Z",
8604 "open_alerts": 0
8605 },
8606 "tests": []
8607 }
8608 },
8609 "update_custom_pattern": {
8610 "params": {
8611 "owner": "flagon-io",
8612 "name": "hello",
8613 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r"
8614 },
8615 "request": {
8616 "pattern_name": "Acme API key",
8617 "pattern": "acme_[a-z0-9]{32,40}",
8618 "publish": true
8619 },
8620 "response": {
8621 "pattern": {
8622 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8623 "scope": "repository",
8624 "workspace": "flagon-io",
8625 "repo": "hello",
8626 "name": "Acme API key",
8627 "pattern": "acme_[a-z0-9]{32,40}",
8628 "before": null,
8629 "after": null,
8630 "test_strings": [
8631 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8632 ],
8633 "state": "published",
8634 "created_by": "syntaqx",
8635 "created_at": "2026-10-06T09:14:02.118Z",
8636 "updated_by": "syntaqx",
8637 "updated_at": "2026-10-06T09:14:02.118Z",
8638 "open_alerts": 0
8639 },
8640 "tests": [
8641 [
8642 9,
8643 46
8644 ]
8645 ]
8646 }
8647 },
8648 "update_custom_pattern_for_workspace": {
8649 "params": {
8650 "workspace": "flagon-io",
8651 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r"
8652 },
8653 "request": {
8654 "pattern_name": "Acme API key",
8655 "pattern": "acme_[a-z0-9]{32}",
8656 "publish": true
8657 },
8658 "response": {
8659 "pattern": {
8660 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r",
8661 "scope": "workspace",
8662 "workspace": "flagon-io",
8663 "repo": null,
8664 "name": "Acme API key",
8665 "pattern": "acme_[a-z0-9]{32}",
8666 "before": null,
8667 "after": null,
8668 "test_strings": [
8669 "ACME_KEY=acme_0123456789abcdef0123456789abcdef"
8670 ],
8671 "state": "published",
8672 "created_by": "syntaqx",
8673 "created_at": "2026-10-06T09:14:02.118Z",
8674 "updated_by": "syntaqx",
8675 "updated_at": "2026-10-06T09:14:02.118Z",
8676 "open_alerts": 0
8677 },
8678 "tests": [
8679 [
8680 9,
8681 46
8682 ]
8683 ]
8684 }
8685 },
8686 "delete_custom_pattern": {
8687 "params": {
8688 "owner": "flagon-io",
8689 "name": "hello",
8690 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r"
8691 },
8692 "response": {
8693 "deleted": true
8694 }
8695 },
8696 "delete_custom_pattern_for_workspace": {
8697 "params": {
8698 "workspace": "flagon-io",
8699 "id": "pat_01kq2p9f6g7h8j9k0m1n2p3q4r"
8700 },
8701 "response": {
8702 "deleted": true
8703 }
8704 },
8705 "dry_run_custom_pattern": {
8706 "params": {
8707 "owner": "flagon-io",
8708 "name": "hello"
8709 },
8710 "request": {
8711 "pattern": "acme_[a-z0-9]{32}"
8712 },
8713 "response": {
8714 "repos": [
8715 {
8716 "name": "hello",
8717 "files_scanned": 214,
8718 "matches": [
8719 {
8720 "path": "config/dev.env",
8721 "line": 3,
8722 "preview": "ACME_KEY=acme_01••••••••••••••••••••••••"
8723 }
8724 ],
8725 "truncated": false,
8726 "commit": "4807077b296e6edbf410d55e72749d3e1170c291"
8727 }
8728 ]
8729 },
8730 "notes": "Reads up to 2,000 files and 20 MB of the default branch, skipping what secret scanning skips. Nothing is recorded."
8731 },
8732 "dry_run_custom_pattern_for_workspace": {
8733 "params": {
8734 "workspace": "flagon-io"
8735 },
8736 "request": {
8737 "pattern": "acme_[a-z0-9]{32}",
8738 "repos": [
8739 "hello"
8740 ]
8741 },
8742 "response": {
8743 "repos": [
8744 {
8745 "name": "hello",
8746 "files_scanned": 214,
8747 "matches": [],
8748 "truncated": false,
8749 "commit": "4807077b296e6edbf410d55e72749d3e1170c291"
8750 }
8751 ]
8752 }
8753 },
8754 "list_code_scanning_alerts": {
8755 "params": {
8756 "owner": "flagon-io",
8757 "name": "hello"
8758 },
8759 "query": {
8760 "state": "open",
8761 "severity": "high"
8762 },
8763 "response": [
8764 {
8765 "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s",
8766 "number": 4,
8767 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8768 "tool": "Semgrep OSS",
8769 "category": "Semgrep OSS",
8770 "rule_id": "javascript.lang.security.detect-child-process.detect-child-process",
8771 "rule_name": "javascript.lang.security.detect-child-process.detect-child-process",
8772 "rule_description": "Detected calls to child_process from a function argument.",
8773 "help": null,
8774 "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process",
8775 "tags": [
8776 "security",
8777 "CWE-78"
8778 ],
8779 "level": "error",
8780 "security_severity": null,
8781 "severity": "high",
8782 "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.",
8783 "path": "src/server.js",
8784 "start_line": 6,
8785 "end_line": 6,
8786 "start_column": 3,
8787 "end_column": 60,
8788 "state": "open",
8789 "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6",
8790 "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8791 "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8792 "created_at": "2026-10-06T09:14:02.118Z",
8793 "updated_at": "2026-10-06T09:14:02.118Z",
8794 "fixed_at": null,
8795 "dismissed_by": null,
8796 "dismissed_reason": null,
8797 "dismissed_comment": null,
8798 "dismissed_at": null,
8799 "issue": null
8800 }
8801 ],
8802 "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."
8803 },
8804 "list_code_scanning_alerts_for_workspace": {
8805 "params": {
8806 "workspace": "flagon-io"
8807 },
8808 "query": {
8809 "state": "open"
8810 },
8811 "response": [
8812 {
8813 "repo": "hello",
8814 "code": {
8815 "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s",
8816 "number": 4,
8817 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8818 "tool": "Semgrep OSS",
8819 "category": "Semgrep OSS",
8820 "rule_id": "javascript.lang.security.detect-child-process.detect-child-process",
8821 "rule_name": "javascript.lang.security.detect-child-process.detect-child-process",
8822 "rule_description": "Detected calls to child_process from a function argument.",
8823 "help": null,
8824 "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process",
8825 "tags": [
8826 "security",
8827 "CWE-78"
8828 ],
8829 "level": "error",
8830 "security_severity": null,
8831 "severity": "high",
8832 "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.",
8833 "path": "src/server.js",
8834 "start_line": 6,
8835 "end_line": 6,
8836 "start_column": 3,
8837 "end_column": 60,
8838 "state": "open",
8839 "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6",
8840 "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8841 "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8842 "created_at": "2026-10-06T09:14:02.118Z",
8843 "updated_at": "2026-10-06T09:14:02.118Z",
8844 "fixed_at": null,
8845 "dismissed_by": null,
8846 "dismissed_reason": null,
8847 "dismissed_comment": null,
8848 "dismissed_at": null,
8849 "issue": null
8850 }
8851 }
8852 ]
8853 },
8854 "get_code_scanning_alert": {
8855 "params": {
8856 "owner": "flagon-io",
8857 "name": "hello",
8858 "number": 4
8859 },
8860 "response": {
8861 "alert": {
8862 "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s",
8863 "number": 4,
8864 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8865 "tool": "Semgrep OSS",
8866 "category": "Semgrep OSS",
8867 "rule_id": "javascript.lang.security.detect-child-process.detect-child-process",
8868 "rule_name": "javascript.lang.security.detect-child-process.detect-child-process",
8869 "rule_description": "Detected calls to child_process from a function argument.",
8870 "help": null,
8871 "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process",
8872 "tags": [
8873 "security",
8874 "CWE-78"
8875 ],
8876 "level": "error",
8877 "security_severity": null,
8878 "severity": "high",
8879 "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.",
8880 "path": "src/server.js",
8881 "start_line": 6,
8882 "end_line": 6,
8883 "start_column": 3,
8884 "end_column": 60,
8885 "state": "open",
8886 "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6",
8887 "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8888 "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8889 "created_at": "2026-10-06T09:14:02.118Z",
8890 "updated_at": "2026-10-06T09:14:02.118Z",
8891 "fixed_at": null,
8892 "dismissed_by": null,
8893 "dismissed_reason": null,
8894 "dismissed_comment": null,
8895 "dismissed_at": null,
8896 "issue": null
8897 },
8898 "activity": [],
8899 "analyses": [
8900 {
8901 "id": "ana_01kq2rbh8j9k0m1n2p3q4r5s6t",
8902 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8903 "sarif_id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v",
8904 "tool": "Semgrep OSS",
8905 "tool_version": "1.140.0",
8906 "category": "Semgrep OSS",
8907 "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291",
8908 "git_ref": "refs/heads/main",
8909 "pull": null,
8910 "results": 7,
8911 "new_alerts": 2,
8912 "fixed_alerts": 1,
8913 "dropped": 0,
8914 "created_at": "2026-10-06T09:14:02.118Z"
8915 }
8916 ]
8917 }
8918 },
8919 "update_code_scanning_alert": {
8920 "params": {
8921 "owner": "flagon-io",
8922 "name": "hello",
8923 "number": 4
8924 },
8925 "request": {
8926 "state": "dismissed",
8927 "dismissed_reason": "false_positive",
8928 "dismissed_comment": "The argument is a constant."
8929 },
8930 "response": {
8931 "id": "cod_01kq2qag7h8j9k0m1n2p3q4r5s",
8932 "number": 4,
8933 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8934 "tool": "Semgrep OSS",
8935 "category": "Semgrep OSS",
8936 "rule_id": "javascript.lang.security.detect-child-process.detect-child-process",
8937 "rule_name": "javascript.lang.security.detect-child-process.detect-child-process",
8938 "rule_description": "Detected calls to child_process from a function argument.",
8939 "help": null,
8940 "help_uri": "https://semgrep.dev/r/javascript.lang.security.detect-child-process.detect-child-process",
8941 "tags": [
8942 "security",
8943 "CWE-78"
8944 ],
8945 "level": "error",
8946 "security_severity": null,
8947 "severity": "high",
8948 "message": "Detected calls to child_process from a function argument `req`. This could lead to a command injection.",
8949 "path": "src/server.js",
8950 "start_line": 6,
8951 "end_line": 6,
8952 "start_column": 3,
8953 "end_column": 60,
8954 "state": "dismissed",
8955 "fingerprint": "3f1c9a0e7b2d4c5e6f708192a3b4c5d6",
8956 "first_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8957 "last_commit": "4807077b296e6edbf410d55e72749d3e1170c291",
8958 "created_at": "2026-10-06T09:14:02.118Z",
8959 "updated_at": "2026-10-06T09:14:02.118Z",
8960 "fixed_at": null,
8961 "dismissed_by": "syntaqx",
8962 "dismissed_reason": "false_positive",
8963 "dismissed_comment": "The argument is a constant.",
8964 "dismissed_at": "2026-10-06T09:20:41.502Z",
8965 "issue": null
8966 }
8967 },
8968 "list_code_scanning_analyses": {
8969 "params": {
8970 "owner": "flagon-io",
8971 "name": "hello"
8972 },
8973 "response": [
8974 {
8975 "id": "ana_01kq2rbh8j9k0m1n2p3q4r5s6t",
8976 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
8977 "sarif_id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v",
8978 "tool": "Semgrep OSS",
8979 "tool_version": "1.140.0",
8980 "category": "Semgrep OSS",
8981 "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291",
8982 "git_ref": "refs/heads/main",
8983 "pull": null,
8984 "results": 7,
8985 "new_alerts": 2,
8986 "fixed_alerts": 1,
8987 "dropped": 0,
8988 "created_at": "2026-10-06T09:14:02.118Z"
8989 }
8990 ]
8991 },
8992 "upload_sarif": {
8993 "params": {
8994 "owner": "flagon-io",
8995 "name": "hello"
8996 },
8997 "request": {
8998 "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291",
8999 "ref": "refs/heads/main",
9000 "sarif": "H4sIAAAAAAAA…",
9001 "checkout_uri": "file:///home/runner/work/repo"
9002 },
9003 "response": {
9004 "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v",
9005 "processing_status": "complete",
9006 "analyses": [
9007 "ana_01kq2rbh8j9k0m1n2p3q4r5s6t"
9008 ],
9009 "errors": [],
9010 "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291",
9011 "git_ref": "refs/heads/main",
9012 "created_at": "2026-10-06T09:14:02.118Z"
9013 },
9014 "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."
9015 },
9016 "get_sarif_upload": {
9017 "params": {
9018 "owner": "flagon-io",
9019 "name": "hello",
9020 "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v"
9021 },
9022 "response": {
9023 "id": "sar_01kq2scj9k0m1n2p3q4r5s6t7v",
9024 "processing_status": "complete",
9025 "analyses": [
9026 "ana_01kq2rbh8j9k0m1n2p3q4r5s6t"
9027 ],
9028 "errors": [],
9029 "commit_sha": "4807077b296e6edbf410d55e72749d3e1170c291",
9030 "git_ref": "refs/heads/main",
9031 "created_at": "2026-10-06T09:14:02.118Z"
9032 }
9033 },
9034 "list_vulnerability_alerts": {
9035 "params": {
9036 "owner": "flagon-io",
9037 "name": "hello"
9038 },
9039 "query": {
9040 "state": "open"
9041 },
9042 "response": [
9043 {
9044 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
9045 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
9046 "ecosystem": "npm",
9047 "package": "lodash",
9048 "version": "4.17.20",
9049 "manifest": "package-lock.json",
9050 "advisory": "GHSA-35jh-r3h4-6jhm",
9051 "osv_id": "GHSA-35jh-r3h4-6jhm",
9052 "summary": "Command Injection in lodash",
9053 "severity": "high",
9054 "fixed_version": "4.17.21",
9055 "status": "open",
9056 "issue": null,
9057 "found_at": "2026-10-06T09:14:02.118Z",
9058 "fixed_at": null,
9059 "state": "open",
9060 "dismissed_by": null,
9061 "dismissed_reason": null,
9062 "dismissed_comment": null,
9063 "dismissed_at": null,
9064 "update": null
9065 }
9066 ]
9067 },
9068 "list_vulnerability_alerts_for_workspace": {
9069 "params": {
9070 "workspace": "flagon-io"
9071 },
9072 "query": {
9073 "severity": "critical"
9074 },
9075 "response": [
9076 {
9077 "repo": "hello",
9078 "vulnerability": {
9079 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
9080 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
9081 "ecosystem": "npm",
9082 "package": "lodash",
9083 "version": "4.17.20",
9084 "manifest": "package-lock.json",
9085 "advisory": "GHSA-35jh-r3h4-6jhm",
9086 "osv_id": "GHSA-35jh-r3h4-6jhm",
9087 "summary": "Command Injection in lodash",
9088 "severity": "high",
9089 "fixed_version": "4.17.21",
9090 "status": "open",
9091 "issue": null,
9092 "found_at": "2026-10-06T09:14:02.118Z",
9093 "fixed_at": null,
9094 "state": "open",
9095 "dismissed_by": null,
9096 "dismissed_reason": null,
9097 "dismissed_comment": null,
9098 "dismissed_at": null,
9099 "update": null
9100 }
9101 }
9102 ]
9103 },
9104 "get_vulnerability_alert": {
9105 "params": {
9106 "owner": "flagon-io",
9107 "name": "hello",
9108 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n"
9109 },
9110 "response": {
9111 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
9112 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
9113 "ecosystem": "npm",
9114 "package": "lodash",
9115 "version": "4.17.20",
9116 "manifest": "package-lock.json",
9117 "advisory": "GHSA-35jh-r3h4-6jhm",
9118 "osv_id": "GHSA-35jh-r3h4-6jhm",
9119 "summary": "Command Injection in lodash",
9120 "severity": "high",
9121 "fixed_version": "4.17.21",
9122 "status": "open",
9123 "issue": null,
9124 "found_at": "2026-10-06T09:14:02.118Z",
9125 "fixed_at": null,
9126 "state": "open",
9127 "dismissed_by": null,
9128 "dismissed_reason": null,
9129 "dismissed_comment": null,
9130 "dismissed_at": null,
9131 "update": null
9132 }
9133 },
9134 "update_vulnerability_alert": {
9135 "params": {
9136 "owner": "flagon-io",
9137 "name": "hello",
9138 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n"
9139 },
9140 "request": {
9141 "state": "dismissed",
9142 "reason": "tolerable_risk",
9143 "comment": "Only the build uses it."
9144 },
9145 "response": {
9146 "id": "vul_01kp4b8c3d4e5f6g7h8j9k0m1n",
9147 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
9148 "ecosystem": "npm",
9149 "package": "lodash",
9150 "version": "4.17.20",
9151 "manifest": "package-lock.json",
9152 "advisory": "GHSA-35jh-r3h4-6jhm",
9153 "osv_id": "GHSA-35jh-r3h4-6jhm",
9154 "summary": "Command Injection in lodash",
9155 "severity": "high",
9156 "fixed_version": "4.17.21",
9157 "status": "dismissed",
9158 "issue": null,
9159 "found_at": "2026-10-06T09:14:02.118Z",
9160 "fixed_at": null,
9161 "state": "dismissed",
9162 "dismissed_by": "syntaqx",
9163 "dismissed_reason": "tolerable_risk",
9164 "dismissed_comment": "Only the build uses it.",
9165 "dismissed_at": "2026-10-06T09:20:41.502Z",
9166 "update": null
9167 }
9168 },
9169 "get_dependency_graph": {
9170 "params": {
9171 "owner": "flagon-io",
9172 "name": "hello"
9173 },
9174 "response": {
9175 "commit": "4807077b296e6edbf410d55e72749d3e1170c291",
9176 "manifests": [
9177 {
9178 "path": "package-lock.json",
9179 "ecosystem": "npm",
9180 "dependencies": 2,
9181 "direct": 1
9182 }
9183 ],
9184 "dependencies": [
9185 {
9186 "ecosystem": "npm",
9187 "name": "lodash",
9188 "version": "4.17.20",
9189 "manifest": "package-lock.json",
9190 "relationship": "direct",
9191 "development": false,
9192 "license": "MIT",
9193 "purl": "pkg:npm/lodash@4.17.20",
9194 "vulnerabilities": 1
9195 },
9196 {
9197 "ecosystem": "npm",
9198 "name": "ms",
9199 "version": "2.1.3",
9200 "manifest": "package-lock.json",
9201 "relationship": "transitive",
9202 "development": false,
9203 "license": "MIT",
9204 "purl": "pkg:npm/ms@2.1.3",
9205 "vulnerabilities": 0
9206 }
9207 ]
9208 }
9209 },
9210 "get_sbom": {
9211 "params": {
9212 "owner": "flagon-io",
9213 "name": "hello"
9214 },
9215 "response": {
9216 "sbom": {
9217 "spdxVersion": "SPDX-2.3",
9218 "dataLicense": "CC0-1.0",
9219 "SPDXID": "SPDXRef-DOCUMENT",
9220 "name": "flagon-io/hello dependency graph",
9221 "documentNamespace": "https://g1t.sh/flagon-io/hello/sbom/sbom_01kq2tdk0m1n2p3q4r5s6t7v8w",
9222 "creationInfo": {
9223 "created": "2026-10-06T09:14:02Z",
9224 "creators": [
9225 "Tool: g1t",
9226 "Organization: g1t"
9227 ],
9228 "comment": "Read from the repository's lockfiles on its default branch."
9229 },
9230 "documentDescribes": [
9231 "SPDXRef-Repository-flagon-io-hello"
9232 ],
9233 "packages": [
9234 {
9235 "SPDXID": "SPDXRef-Repository-flagon-io-hello",
9236 "name": "flagon-io/hello",
9237 "versionInfo": "4807077b296e6edbf410d55e72749d3e1170c291",
9238 "downloadLocation": "git+https://g1t.sh/flagon-io/hello.git",
9239 "filesAnalyzed": false,
9240 "licenseConcluded": "NOASSERTION",
9241 "licenseDeclared": "NOASSERTION",
9242 "copyrightText": "NOASSERTION",
9243 "primaryPackagePurpose": "SOURCE",
9244 "externalRefs": []
9245 },
9246 {
9247 "SPDXID": "SPDXRef-Package-npm-lodash-4.17.20",
9248 "name": "lodash",
9249 "versionInfo": "4.17.20",
9250 "downloadLocation": "NOASSERTION",
9251 "filesAnalyzed": false,
9252 "licenseConcluded": "NOASSERTION",
9253 "licenseDeclared": "MIT",
9254 "copyrightText": "NOASSERTION",
9255 "primaryPackagePurpose": "LIBRARY",
9256 "comment": "Resolved by package-lock.json (direct dependency).",
9257 "externalRefs": [
9258 {
9259 "referenceCategory": "PACKAGE-MANAGER",
9260 "referenceType": "purl",
9261 "referenceLocator": "pkg:npm/lodash@4.17.20"
9262 }
9263 ]
9264 }
9265 ],
9266 "relationships": [
9267 {
9268 "spdxElementId": "SPDXRef-DOCUMENT",
9269 "relationshipType": "DESCRIBES",
9270 "relatedSpdxElement": "SPDXRef-Repository-flagon-io-hello"
9271 },
9272 {
9273 "spdxElementId": "SPDXRef-Repository-flagon-io-hello",
9274 "relationshipType": "DEPENDS_ON",
9275 "relatedSpdxElement": "SPDXRef-Package-npm-lodash-4.17.20"
9276 }
9277 ]
9278 }
9279 },
9280 "notes": "`sbom` is an SPDX 2.3 JSON document, sent as SPDX spells it. Save it with `jq .sbom`."
9281 },
9282 "compare_dependencies": {
9283 "params": {
9284 "owner": "flagon-io",
9285 "name": "hello",
9286 "basehead": "main...upgrade-deps"
9287 },
9288 "response": {
9289 "base": "main",
9290 "head": "upgrade-deps",
9291 "changes": [
9292 {
9293 "change_type": "added",
9294 "manifest": "package-lock.json",
9295 "ecosystem": "npm",
9296 "name": "lodash",
9297 "version": "4.17.20",
9298 "relationship": "direct",
9299 "development": false,
9300 "license": "MIT",
9301 "purl": "pkg:npm/lodash@4.17.20",
9302 "vulnerabilities": [
9303 {
9304 "advisory": "GHSA-35jh-r3h4-6jhm",
9305 "osv_id": "GHSA-35jh-r3h4-6jhm",
9306 "summary": "Command Injection in lodash",
9307 "severity": "high",
9308 "fixed_version": "4.17.21",
9309 "url": "https://osv.dev/vulnerability/GHSA-35jh-r3h4-6jhm"
9310 }
9311 ],
9312 "denied_license": false,
9313 "failing": true
9314 },
9315 {
9316 "change_type": "removed",
9317 "manifest": "package-lock.json",
9318 "ecosystem": "npm",
9319 "name": "lodash",
9320 "version": "4.17.21",
9321 "relationship": "direct",
9322 "development": false,
9323 "license": "MIT",
9324 "purl": "pkg:npm/lodash@4.17.21",
9325 "vulnerabilities": [],
9326 "denied_license": false,
9327 "failing": false
9328 }
9329 ],
9330 "passed": false,
9331 "headline": "Adds 1 vulnerable package",
9332 "fail_on": "high",
9333 "deny_licenses": []
9334 }
9335 },
9336 "rerun_dependency_review": {
9337 "params": {
9338 "owner": "flagon-io",
9339 "name": "hello",
9340 "number": 12
9341 },
9342 "response": {
9343 "base": "4b1d7c0e9a2f6e3d8c5b0a7f4e1d2c3b4a5f6e7d",
9344 "head": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
9345 "changes": [
9346 {
9347 "change_type": "added",
9348 "manifest": "package-lock.json",
9349 "ecosystem": "npm",
9350 "name": "lodash",
9351 "version": "4.17.21",
9352 "relationship": "direct",
9353 "development": false,
9354 "license": "MIT",
9355 "purl": "pkg:npm/lodash@4.17.21",
9356 "vulnerabilities": [],
9357 "denied_license": false,
9358 "failing": false
9359 },
9360 {
9361 "change_type": "removed",
9362 "manifest": "package-lock.json",
9363 "ecosystem": "npm",
9364 "name": "lodash",
9365 "version": "4.17.20",
9366 "relationship": "direct",
9367 "development": false,
9368 "license": "MIT",
9369 "purl": "pkg:npm/lodash@4.17.20",
9370 "vulnerabilities": [],
9371 "denied_license": false,
9372 "failing": false
9373 }
9374 ],
9375 "passed": true,
9376 "headline": "2 dependency changes, none vulnerable",
9377 "fail_on": "high",
9378 "deny_licenses": []
9379 },
9380 "notes": "The pull request's one dependency review comment is changed in place; nothing new is posted when the review says the same."
9381 },
9382 "get_security_settings": {
9383 "params": {
9384 "owner": "flagon-io",
9385 "name": "hello"
9386 },
9387 "response": {
9388 "settings": {
9389 "code_scanning_gate": "high",
9390 "dependency_review": true,
9391 "review_fail_on": "high",
9392 "review_deny_licenses": [
9393 "AGPL-3.0-only"
9394 ],
9395 "review_comment": true,
9396 "history_alerts": true,
9397 "private_vulnerability_reporting": false
9398 },
9399 "workspace": {
9400 "delegated_bypass": true,
9401 "validity_checks": true
9402 },
9403 "private": true,
9404 "entitled": true,
9405 "upkeep": true
9406 }
9407 },
9408 "update_security_settings": {
9409 "params": {
9410 "owner": "flagon-io",
9411 "name": "hello"
9412 },
9413 "request": {
9414 "code_scanning_gate": "high",
9415 "review_deny_licenses": [
9416 "AGPL-3.0-only"
9417 ]
9418 },
9419 "response": {
9420 "settings": {
9421 "code_scanning_gate": "high",
9422 "dependency_review": true,
9423 "review_fail_on": "high",
9424 "review_deny_licenses": [
9425 "AGPL-3.0-only"
9426 ],
9427 "review_comment": true,
9428 "history_alerts": true,
9429 "private_vulnerability_reporting": true
9430 },
9431 "workspace": {
9432 "delegated_bypass": true,
9433 "validity_checks": true
9434 },
9435 "private": true,
9436 "entitled": true,
9437 "upkeep": true
9438 },
9439 "notes": "Only what you send changes. The `Code scanning` and `Dependency review` checks gate merges once you require them in branch protection."
9440 },
9441 "get_workspace_security_settings": {
9442 "params": {
9443 "workspace": "flagon-io"
9444 },
9445 "response": {
9446 "settings": {
9447 "delegated_bypass": true,
9448 "validity_checks": true
9449 },
9450 "activated": true
9451 }
9452 },
9453 "update_workspace_security_settings": {
9454 "params": {
9455 "workspace": "flagon-io"
9456 },
9457 "request": {
9458 "delegated_bypass": true
9459 },
9460 "response": {
9461 "settings": {
9462 "delegated_bypass": true,
9463 "validity_checks": true
9464 },
9465 "activated": true
9466 }
9467 },
9468 "list_security_advisories": {
9469 "params": {
9470 "owner": "flagon-io",
9471 "name": "hello"
9472 },
9473 "query": {
9474 "state": "published"
9475 },
9476 "response": [
9477 {
9478 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9479 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9480 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9481 "repo": "flagon-io/hello",
9482 "title": "Path traversal in the archive reader",
9483 "description": "A crafted archive could write outside the directory it is extracted to.\n\nUpgrade to 1.4.1.",
9484 "severity": "high",
9485 "cvss_vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N",
9486 "cvss_score": 8.1,
9487 "cve_id": "CVE-2026-12345",
9488 "ecosystem": "npm",
9489 "package": "@flagon/hello",
9490 "affected_versions": ">= 1.2.0, < 1.4.1",
9491 "patched_versions": ">= 1.4.1",
9492 "state": "published",
9493 "credits": [
9494 "ana"
9495 ],
9496 "report_id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9497 "created_by": "syntaqx",
9498 "created_at": "2026-10-06T09:14:02.118Z",
9499 "updated_at": "2026-10-07T15:02:40.000Z",
9500 "published_at": "2026-10-07T15:02:40.000Z",
9501 "withdrawn_at": null
9502 }
9503 ],
9504 "notes": "Without a token, or with one that has no Write on the repository, only published advisories are listed. `state` filters to `draft`, `published` or `withdrawn`; drafts and withdrawn advisories are shown only to those who see the repository's findings."
9505 },
9506 "get_security_advisory": {
9507 "params": {
9508 "owner": "flagon-io",
9509 "name": "hello",
9510 "id": "G1TSA-2026-h7kd-3mqw"
9511 },
9512 "response": {
9513 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9514 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9515 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9516 "repo": "flagon-io/hello",
9517 "title": "Path traversal in the archive reader",
9518 "description": "A crafted archive could write outside the directory it is extracted to.\n\nUpgrade to 1.4.1.",
9519 "severity": "high",
9520 "cvss_vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N",
9521 "cvss_score": 8.1,
9522 "cve_id": "CVE-2026-12345",
9523 "ecosystem": "npm",
9524 "package": "@flagon/hello",
9525 "affected_versions": ">= 1.2.0, < 1.4.1",
9526 "patched_versions": ">= 1.4.1",
9527 "state": "published",
9528 "credits": [
9529 "ana"
9530 ],
9531 "report_id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9532 "created_by": "syntaqx",
9533 "created_at": "2026-10-06T09:14:02.118Z",
9534 "updated_at": "2026-10-07T15:02:40.000Z",
9535 "published_at": "2026-10-07T15:02:40.000Z",
9536 "withdrawn_at": null
9537 },
9538 "notes": "`id` is the advisory's `adv_…` id or its `G1TSA-…` id. A draft or withdrawn advisory is `404` to anyone who does not see the repository's findings."
9539 },
9540 "create_security_advisory": {
9541 "params": {
9542 "owner": "flagon-io",
9543 "name": "hello"
9544 },
9545 "request": {
9546 "title": "Path traversal in the archive reader",
9547 "description": "A crafted archive could write outside the directory it is extracted to.",
9548 "severity": "high",
9549 "ecosystem": "npm",
9550 "package": "@flagon/hello",
9551 "affected_versions": ">= 1.2.0, < 1.4.1",
9552 "patched_versions": ">= 1.4.1",
9553 "credits": [
9554 "ana"
9555 ]
9556 },
9557 "response": {
9558 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9559 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9560 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9561 "repo": "flagon-io/hello",
9562 "title": "Path traversal in the archive reader",
9563 "description": "A crafted archive could write outside the directory it is extracted to.",
9564 "severity": "high",
9565 "cvss_vector": null,
9566 "cvss_score": null,
9567 "cve_id": null,
9568 "ecosystem": "npm",
9569 "package": "@flagon/hello",
9570 "affected_versions": ">= 1.2.0, < 1.4.1",
9571 "patched_versions": ">= 1.4.1",
9572 "state": "draft",
9573 "credits": [
9574 "ana"
9575 ],
9576 "report_id": null,
9577 "created_by": "syntaqx",
9578 "created_at": "2026-10-06T09:14:02.118Z",
9579 "updated_at": "2026-10-06T09:14:02.118Z",
9580 "published_at": null,
9581 "withdrawn_at": null
9582 },
9583 "notes": "The advisory starts as a draft nobody but the maintainers sees; publish it with `POST …/advisories/{id}/state`. Takes the Admin role, or a security manager of the workspace. A title or severity that is missing, or a `cve_id` that is not of the form `CVE-2026-12345`, is `422`."
9584 },
9585 "update_security_advisory": {
9586 "params": {
9587 "owner": "flagon-io",
9588 "name": "hello",
9589 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r"
9590 },
9591 "request": {
9592 "cve_id": "CVE-2026-12345",
9593 "cvss_vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N",
9594 "cvss_score": 8.1
9595 },
9596 "response": {
9597 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9598 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9599 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9600 "repo": "flagon-io/hello",
9601 "title": "Path traversal in the archive reader",
9602 "description": "A crafted archive could write outside the directory it is extracted to.",
9603 "severity": "high",
9604 "cvss_vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N",
9605 "cvss_score": 8.1,
9606 "cve_id": "CVE-2026-12345",
9607 "ecosystem": "npm",
9608 "package": "@flagon/hello",
9609 "affected_versions": ">= 1.2.0, < 1.4.1",
9610 "patched_versions": ">= 1.4.1",
9611 "state": "draft",
9612 "credits": [
9613 "ana"
9614 ],
9615 "report_id": null,
9616 "created_by": "syntaqx",
9617 "created_at": "2026-10-06T09:14:02.118Z",
9618 "updated_at": "2026-10-06T10:30:00.000Z",
9619 "published_at": null,
9620 "withdrawn_at": null
9621 },
9622 "notes": "What the request leaves out stays as it is. A published advisory may be changed; its page shows the change at once."
9623 },
9624 "set_security_advisory_state": {
9625 "params": {
9626 "owner": "flagon-io",
9627 "name": "hello",
9628 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r"
9629 },
9630 "request": {
9631 "state": "published"
9632 },
9633 "response": {
9634 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9635 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9636 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9637 "repo": "flagon-io/hello",
9638 "title": "Path traversal in the archive reader",
9639 "description": "A crafted archive could write outside the directory it is extracted to.",
9640 "severity": "high",
9641 "cvss_vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N",
9642 "cvss_score": 8.1,
9643 "cve_id": "CVE-2026-12345",
9644 "ecosystem": "npm",
9645 "package": "@flagon/hello",
9646 "affected_versions": ">= 1.2.0, < 1.4.1",
9647 "patched_versions": ">= 1.4.1",
9648 "state": "published",
9649 "credits": [
9650 "ana"
9651 ],
9652 "report_id": null,
9653 "created_by": "syntaqx",
9654 "created_at": "2026-10-06T09:14:02.118Z",
9655 "updated_at": "2026-10-07T15:02:40.000Z",
9656 "published_at": "2026-10-07T15:02:40.000Z",
9657 "withdrawn_at": null
9658 },
9659 "notes": "Publishing a draft with no description is `422`. Publishing sends `security_advisory.published` to webhooks and tells the repository's watchers who chose security alerts; withdrawing (`state` `withdrawn`) sends `security_advisory.withdrawn`. A withdrawn advisory can be published again. Asking for the state it already has is `409`."
9660 },
9661 "list_vulnerability_reports": {
9662 "params": {
9663 "owner": "flagon-io",
9664 "name": "hello"
9665 },
9666 "query": {
9667 "state": "new"
9668 },
9669 "response": [
9670 {
9671 "id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9672 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9673 "repo": "flagon-io/hello",
9674 "reporter": null,
9675 "reporter_email": "finder@example.com",
9676 "title": "Path traversal in the archive reader",
9677 "description": "Extracting an archive with an entry named ../../etc/passwd writes outside the target directory. Steps: …",
9678 "severity": "high",
9679 "state": "new",
9680 "advisory_id": null,
9681 "created_at": "2026-10-06T08:40:11.000Z",
9682 "reviewed_by": null,
9683 "reviewed_at": null,
9684 "review_note": null
9685 }
9686 ],
9687 "notes": "New reports first. Those who see the repository's findings (Write, or a security manager) read them; a reporter never sees another's. `state` is `new`, `accepted` or `declined`."
9688 },
9689 "report_vulnerability": {
9690 "params": {
9691 "owner": "flagon-io",
9692 "name": "hello"
9693 },
9694 "request": {
9695 "title": "Path traversal in the archive reader",
9696 "description": "Extracting an archive with an entry named ../../etc/passwd writes outside the target directory. Steps: …",
9697 "severity": "high",
9698 "email": "finder@example.com"
9699 },
9700 "response": {
9701 "id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9702 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9703 "repo": "flagon-io/hello",
9704 "reporter": null,
9705 "reporter_email": "finder@example.com",
9706 "title": "Path traversal in the archive reader",
9707 "description": "Extracting an archive with an entry named ../../etc/passwd writes outside the target directory. Steps: …",
9708 "severity": "high",
9709 "state": "new",
9710 "advisory_id": null,
9711 "created_at": "2026-10-06T08:40:11.000Z",
9712 "reviewed_by": null,
9713 "reviewed_at": null,
9714 "review_note": null
9715 },
9716 "notes": "Needs private vulnerability reporting on for the repository (`409` otherwise). With a token, the report is yours by username; without one, on a public repository, give `email`, or the request is `422`. The workspace's owners and security managers are told at once. More than 5 reports a day from one reporter to one repository, or a repository with 50 new reports waiting, is refused."
9717 },
9718 "review_vulnerability_report": {
9719 "params": {
9720 "owner": "flagon-io",
9721 "name": "hello",
9722 "id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r"
9723 },
9724 "request": {
9725 "decision": "accept",
9726 "note": "Confirmed on 1.4.0."
9727 },
9728 "response": {
9729 "report": {
9730 "id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9731 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9732 "repo": "flagon-io/hello",
9733 "reporter": null,
9734 "reporter_email": "finder@example.com",
9735 "title": "Path traversal in the archive reader",
9736 "description": "Extracting an archive with an entry named ../../etc/passwd writes outside the target directory. Steps: …",
9737 "severity": "high",
9738 "state": "accepted",
9739 "advisory_id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9740 "created_at": "2026-10-06T08:40:11.000Z",
9741 "reviewed_by": "syntaqx",
9742 "reviewed_at": "2026-10-06T09:14:02.118Z",
9743 "review_note": "Confirmed on 1.4.0."
9744 },
9745 "advisory": {
9746 "id": "adv_01kq2p9f6g7h8j9k0m1n2p3q4r",
9747 "g1tsa_id": "G1TSA-2026-h7kd-3mqw",
9748 "repo_id": "rep_01kq2p9f6g7h8j9k0m1n2p3q4r",
9749 "repo": "flagon-io/hello",
9750 "title": "Path traversal in the archive reader",
9751 "description": "Extracting an archive with an entry named ../../etc/passwd writes outside the target directory. Steps: …",
9752 "severity": "high",
9753 "cvss_vector": null,
9754 "cvss_score": null,
9755 "cve_id": null,
9756 "ecosystem": null,
9757 "package": null,
9758 "affected_versions": null,
9759 "patched_versions": null,
9760 "state": "draft",
9761 "credits": [
9762 "finder@example.com"
9763 ],
9764 "report_id": "vrp_01kq2p9f6g7h8j9k0m1n2p3q4r",
9765 "created_by": "syntaqx",
9766 "created_at": "2026-10-06T09:14:02.118Z",
9767 "updated_at": "2026-10-06T09:14:02.118Z",
9768 "published_at": null,
9769 "withdrawn_at": null
9770 }
9771 },
9772 "notes": "`accept` makes a draft advisory from the report, in the report's words and crediting the reporter, for the maintainers to finish and publish; `advisory` is that draft. `decline` closes the report; `advisory` is null. A report that was reviewed already is `409`. Takes the Admin role, or a security manager of the workspace."
9773 },
9774 "get_security_overview": {
9775 "params": {
9776 "workspace": "flagon-io"
9777 },
9778 "query": {
9779 "days": "30"
9780 },
9781 "response": {
9782 "activated": true,
9783 "private_hidden": 0,
9784 "totals": [
9785 {
9786 "alert_type": "secret_scanning",
9787 "open": {
9788 "critical": 1,
9789 "high": 0,
9790 "medium": 0,
9791 "low": 0,
9792 "unknown": 0
9793 },
9794 "opened": 2,
9795 "closed": 1
9796 },
9797 {
9798 "alert_type": "code_scanning",
9799 "open": {
9800 "critical": 0,
9801 "high": 3,
9802 "medium": 4,
9803 "low": 0,
9804 "unknown": 0
9805 },
9806 "opened": 7,
9807 "closed": 2
9808 },
9809 {
9810 "alert_type": "vulnerability",
9811 "open": {
9812 "critical": 0,
9813 "high": 1,
9814 "medium": 2,
9815 "low": 1,
9816 "unknown": 0
9817 },
9818 "opened": 3,
9819 "closed": 5
9820 }
9821 ],
9822 "trend": [
9823 {
9824 "day": "2026-10-05",
9825 "secret_scanning": 1,
9826 "code_scanning": 8,
9827 "vulnerability": 6
9828 },
9829 {
9830 "day": "2026-10-06",
9831 "secret_scanning": 1,
9832 "code_scanning": 7,
9833 "vulnerability": 4
9834 }
9835 ],
9836 "repos": [
9837 {
9838 "repo_id": "rep_01kp0a1b2c3d4e5f6g7h8j9k0m",
9839 "name": "hello",
9840 "private": true,
9841 "custom_patterns": 1,
9842 "validity_checks": true,
9843 "code_scanning_at": "2026-10-06T09:14:02.118Z",
9844 "dependency_review": true,
9845 "security_updates": true,
9846 "lockfiles": 1,
9847 "secrets": {
9848 "critical": 1,
9849 "high": 0,
9850 "medium": 0,
9851 "low": 0,
9852 "unknown": 0
9853 },
9854 "code": {
9855 "critical": 0,
9856 "high": 3,
9857 "medium": 4,
9858 "low": 0,
9859 "unknown": 0
9860 },
9861 "vulnerabilities": {
9862 "critical": 0,
9863 "high": 1,
9864 "medium": 2,
9865 "low": 1,
9866 "unknown": 0
9867 }
9868 }
9869 ]
9870 }
9871 },
9872 "create_label": {
9873 "request": {
9874 "label": "area: cli",
9875 "color": "1d76db",
9876 "description": "The command-line tool"
9877 },
9878 "response": {
9879 "name": "area: cli",
9880 "color": "1d76db",
9881 "description": "The command-line tool",
9882 "issues": 0,
9883 "pulls": 0
9884 }
9885 },
9886 "update_label": {
9887 "params": {
9888 "label": "area: cli"
9889 },
9890 "request": {
9891 "new_name": "cli",
9892 "color": "0052cc"
9893 },
9894 "response": {
9895 "name": "cli",
9896 "color": "0052cc",
9897 "description": "The command-line tool",
9898 "issues": 3,
9899 "pulls": 1
9900 },
9901 "notes": "Renaming a label renames it on every issue and pull request that carries it."
9902 },
9903 "delete_label": {
9904 "params": {
9905 "label": "wontfix"
9906 },
9907 "response": true
9908 },
9909 "add_default_labels": {
9910 "response": [
9911 {
9912 "name": "bug",
9913 "color": "d73a4a",
9914 "description": "Something isn't working",
9915 "issues": 4,
9916 "pulls": 1
9917 },
9918 {
9919 "name": "documentation",
9920 "color": "0075ca",
9921 "description": "Improvements or additions to documentation",
9922 "issues": 0,
9923 "pulls": 0
9924 }
9925 ],
9926 "notes": "Every label the repository has afterwards, shortened here. Labels it already had are left as they were."
9927 },
9928 "list_issue_labels": {
9929 "response": [
9930 {
9931 "name": "bug",
9932 "color": "d73a4a",
9933 "description": "Something isn't working",
9934 "issues": 4,
9935 "pulls": 1
9936 },
9937 {
9938 "name": "help wanted",
9939 "color": "008672",
9940 "description": "Extra attention is needed",
9941 "issues": 1,
9942 "pulls": 0
9943 }
9944 ]
9945 },
9946 "add_issue_labels": {
9947 "request": {
9948 "labels": [
9949 "help wanted"
9950 ]
9951 },
9952 "response": [
9953 "bug",
9954 "help wanted"
9955 ],
9956 "notes": "Returns its labels now, by name."
9957 },
9958 "set_issue_labels": {
9959 "request": {
9960 "labels": [
9961 "bug"
9962 ]
9963 },
9964 "response": [
9965 "bug"
9966 ]
9967 },
9968 "remove_issue_labels": {
9969 "response": []
9970 },
9971 "remove_issue_label": {
9972 "params": {
9973 "label": "help wanted"
9974 },
9975 "response": [
9976 "bug"
9977 ]
9978 },
9979 "list_milestones": {
9980 "response": [
9981 {
9982 "number": 3,
9983 "title": "Launch",
9984 "description": "Everything that has to land before the launch on October 14.",
9985 "due_on": "2026-10-14",
9986 "state": "open",
9987 "open_items": 5,
9988 "closed_items": 12,
9989 "created_at": "2026-09-20T09:00:00.000Z",
9990 "updated_at": "2026-10-06T16:12:40.118Z",
9991 "closed_at": null
9992 }
9993 ],
9994 "notes": "Open milestones soonest due first, then closed ones. Progress is closed_items out of open_items plus closed_items."
9995 },
9996 "create_milestone": {
9997 "request": {
9998 "title": "Launch",
9999 "description": "Everything that has to land before the launch on October 14.",
10000 "due_on": "2026-10-14"
10001 },
10002 "response": {
10003 "number": 3,
10004 "title": "Launch",
10005 "description": "Everything that has to land before the launch on October 14.",
10006 "due_on": "2026-10-14",
10007 "state": "open",
10008 "open_items": 0,
10009 "closed_items": 0,
10010 "created_at": "2026-09-20T09:00:00.000Z",
10011 "updated_at": "2026-09-20T09:00:00.000Z",
10012 "closed_at": null
10013 }
10014 },
10015 "update_milestone": {
10016 "params": {
10017 "milestone": 3
10018 },
10019 "request": {
10020 "state": "closed"
10021 },
10022 "response": {
10023 "number": 3,
10024 "title": "Launch",
10025 "description": "Everything that has to land before the launch on October 14.",
10026 "due_on": "2026-10-14",
10027 "state": "closed",
10028 "open_items": 0,
10029 "closed_items": 17,
10030 "created_at": "2026-09-20T09:00:00.000Z",
10031 "updated_at": "2026-10-14T18:00:00.000Z",
10032 "closed_at": "2026-10-14T18:00:00.000Z"
10033 }
10034 },
10035 "delete_milestone": {
10036 "params": {
10037 "milestone": 3
10038 },
10039 "response": true
10040 },
10041 "get_milestone": {
10042 "params": {
10043 "milestone": 3
10044 },
10045 "response": {
10046 "milestone": {
10047 "number": 3,
10048 "title": "Launch",
10049 "description": "Everything that has to land before the launch on October 14.",
10050 "due_on": "2026-10-14",
10051 "state": "open",
10052 "open_items": 5,
10053 "closed_items": 12,
10054 "created_at": "2026-09-20T09:00:00.000Z",
10055 "updated_at": "2026-10-06T16:12:40.118Z",
10056 "closed_at": null
10057 },
10058 "issues": [
10059 {
10060 "id": "iss_01m43shrzpfe49x74ga7sj1c6v",
10061 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
10062 "number": 12,
10063 "title": "Greeting should name the caller",
10064 "body": "Take a name from the first argument; fall back to world.",
10065 "labels": [
10066 "feature",
10067 "good first issue"
10068 ],
10069 "state": "open",
10070 "reason": null,
10071 "resolved_by": null,
10072 "author": {
10073 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
10074 "username": "syntaqx",
10075 "display_username": "syntaqx",
10076 "kind": "user",
10077 "verified": false,
10078 "workspaces": []
10079 },
10080 "requested_by": null,
10081 "created_at": "2026-10-01T18:04:11.482Z",
10082 "updated_at": "2026-10-01T18:09:47.305Z",
10083 "closed_at": null,
10084 "pull_count": 0,
10085 "comment_count": 0,
10086 "assignees": [
10087 "syntaqx"
10088 ],
10089 "blocked_by": [],
10090 "agent": null,
10091 "milestone": {
10092 "number": 3,
10093 "title": "Launch"
10094 }
10095 }
10096 ],
10097 "pulls": [
10098 {
10099 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
10100 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
10101 "number": 14,
10102 "issue": 12,
10103 "title": "Greeting should name the caller",
10104 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
10105 "agent": "claude-code",
10106 "runtime": "external",
10107 "status": "open",
10108 "fork": {
10109 "namespace": "pulls",
10110 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
10111 },
10112 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
10113 "branch": null,
10114 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
10115 "merge_base": null,
10116 "merged_by": null,
10117 "merged_at": null,
10118 "superseded_by": null,
10119 "check_status": "passed",
10120 "files": [
10121 {
10122 "path": "src/main.rs",
10123 "additions": 6,
10124 "deletions": 2
10125 }
10126 ],
10127 "assignees": [],
10128 "reviewers": [
10129 "ana"
10130 ],
10131 "labels": [],
10132 "milestone": {
10133 "number": 3,
10134 "title": "Launch"
10135 },
10136 "base": "main",
10137 "author": {
10138 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
10139 "username": "syntaqx",
10140 "display_username": "syntaqx",
10141 "kind": "user",
10142 "verified": false,
10143 "workspaces": []
10144 },
10145 "requested_by": null,
10146 "created_at": "2026-10-01T18:20:02.117Z",
10147 "updated_at": "2026-10-01T18:35:44.902Z"
10148 }
10149 ]
10150 }
10151 },
10152 "update_pull_request": {
10153 "request": {
10154 "base": "release/1.x",
10155 "labels": [
10156 "bug"
10157 ]
10158 },
10159 "response": {
10160 "id": "pr_01m43smh3vexsr5pmp60qwv0vs",
10161 "repo_id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
10162 "number": 14,
10163 "issue": 12,
10164 "title": "Greeting should name the caller",
10165 "body": "Reads a name from the first argument. `hello ana` prints \"Hello, ana!\".",
10166 "agent": "claude-code",
10167 "runtime": "external",
10168 "status": "open",
10169 "fork": {
10170 "namespace": "pulls",
10171 "name": "pr_01m43smh3vexsr5pmp60qwv0vs"
10172 },
10173 "fork_repo_id": "rep_01m43smh5xd7aw2kq9tv0b4c8e",
10174 "branch": null,
10175 "head_commit": "9f2c4e1a7b3d5f60812a4c6e8b0d2f4a6c8e0b13",
10176 "merge_base": null,
10177 "merged_by": null,
10178 "merged_at": null,
10179 "superseded_by": null,
10180 "check_status": "passed",
10181 "files": [
10182 {
10183 "path": "src/main.rs",
10184 "additions": 6,
10185 "deletions": 2
10186 }
10187 ],
10188 "assignees": [],
10189 "reviewers": [
10190 "ana"
10191 ],
10192 "labels": [
10193 "bug"
10194 ],
10195 "milestone": null,
10196 "base": "release/1.x",
10197 "author": {
10198 "id": "usr_01kkntcg1eeb98j62xjm7eh09p",
10199 "username": "syntaqx",
10200 "display_username": "syntaqx",
10201 "kind": "user",
10202 "verified": false,
10203 "workspaces": []
10204 },
10205 "requested_by": null,
10206 "created_at": "2026-10-01T18:20:02.117Z",
10207 "updated_at": "2026-10-01T18:35:44.902Z"
10208 },
10209 "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."
10210 },
10211 "list_repo_rulesets": {
10212 "params": {
10213 "owner": "flagon-io",
10214 "name": "hello"
10215 },
10216 "query": {
10217 "include_parents": "true"
10218 },
10219 "response": [
10220 {
10221 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10222 "level": "repository",
10223 "workspace": "flagon-io",
10224 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
10225 "repository": "flagon-io/hello",
10226 "name": "Protect main",
10227 "enforcement": "active",
10228 "target": "branch",
10229 "conditions": {
10230 "ref_name": {
10231 "include": [
10232 "~DEFAULT_BRANCH"
10233 ],
10234 "exclude": []
10235 }
10236 },
10237 "bypass_actors": [
10238 {
10239 "kind": "role",
10240 "value": "admin",
10241 "mode": "pull_requests"
10242 }
10243 ],
10244 "rules": [
10245 {
10246 "type": "deletion",
10247 "parameters": {},
10248 "applies_to": "everyone"
10249 },
10250 {
10251 "type": "non_fast_forward",
10252 "parameters": {},
10253 "applies_to": "everyone"
10254 },
10255 {
10256 "type": "pull_request",
10257 "parameters": {
10258 "required_approvals": 1,
10259 "count_agent_approvals": true,
10260 "dismiss_stale_reviews_on_push": true,
10261 "require_code_owner_review": true,
10262 "require_last_push_approval": false,
10263 "allowed_merge_methods": []
10264 },
10265 "applies_to": "everyone"
10266 },
10267 {
10268 "type": "required_status_checks",
10269 "parameters": {
10270 "checks": [
10271 {
10272 "context": "CI",
10273 "integration": "actions"
10274 }
10275 ],
10276 "strict": true,
10277 "paths": [],
10278 "allow_bypass_on_merge": false
10279 },
10280 "applies_to": "everyone"
10281 },
10282 {
10283 "type": "pull_request",
10284 "parameters": {
10285 "required_approvals": 1,
10286 "count_agent_approvals": false,
10287 "dismiss_stale_reviews_on_push": false,
10288 "require_code_owner_review": false,
10289 "require_last_push_approval": false,
10290 "allowed_merge_methods": []
10291 },
10292 "applies_to": "agents"
10293 },
10294 {
10295 "type": "file_path_restriction",
10296 "parameters": {
10297 "restricted_file_paths": [
10298 ".g1t/workflows/**",
10299 "CODEOWNERS"
10300 ]
10301 },
10302 "applies_to": "agents"
10303 }
10304 ],
10305 "created_by": "syntaqx",
10306 "created_at": "2026-10-07T14:02:11.318Z",
10307 "updated_by": "syntaqx",
10308 "updated_at": "2026-10-07T14:02:11.318Z"
10309 },
10310 {
10311 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
10312 "level": "workspace",
10313 "workspace": "flagon-io",
10314 "name": "Release freeze",
10315 "enforcement": "evaluate",
10316 "target": "branch",
10317 "conditions": {
10318 "ref_name": {
10319 "include": [
10320 "~DEFAULT_BRANCH",
10321 "release/**"
10322 ],
10323 "exclude": []
10324 },
10325 "repository": {
10326 "include": [
10327 "~ALL"
10328 ],
10329 "exclude": [
10330 "sandbox-*"
10331 ],
10332 "visibility": "any",
10333 "topics": []
10334 }
10335 },
10336 "bypass_actors": [
10337 {
10338 "kind": "team",
10339 "value": "flagon-io/release",
10340 "mode": "always"
10341 }
10342 ],
10343 "rules": [
10344 {
10345 "type": "merge_window",
10346 "parameters": {
10347 "time_zone": "-05:00",
10348 "windows": [
10349 {
10350 "days": [
10351 "mon",
10352 "tue",
10353 "wed",
10354 "thu"
10355 ],
10356 "start": "09:00",
10357 "end": "17:00"
10358 }
10359 ],
10360 "freezes": [
10361 {
10362 "start": "2026-12-20T00:00:00Z",
10363 "end": "2027-01-04T00:00:00Z",
10364 "reason": "Holidays"
10365 }
10366 ],
10367 "exceptions": []
10368 },
10369 "applies_to": "everyone"
10370 }
10371 ],
10372 "created_by": "syntaqx",
10373 "created_at": "2026-10-07T14:02:11.318Z",
10374 "updated_by": "syntaqx",
10375 "updated_at": "2026-10-07T14:02:11.318Z"
10376 }
10377 ],
10378 "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`."
10379 },
10380 "get_repo_ruleset": {
10381 "params": {
10382 "owner": "flagon-io",
10383 "name": "hello",
10384 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m"
10385 },
10386 "response": {
10387 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10388 "level": "repository",
10389 "workspace": "flagon-io",
10390 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
10391 "repository": "flagon-io/hello",
10392 "name": "Protect main",
10393 "enforcement": "active",
10394 "target": "branch",
10395 "conditions": {
10396 "ref_name": {
10397 "include": [
10398 "~DEFAULT_BRANCH"
10399 ],
10400 "exclude": []
10401 }
10402 },
10403 "bypass_actors": [
10404 {
10405 "kind": "role",
10406 "value": "admin",
10407 "mode": "pull_requests"
10408 }
10409 ],
10410 "rules": [
10411 {
10412 "type": "deletion",
10413 "parameters": {},
10414 "applies_to": "everyone"
10415 },
10416 {
10417 "type": "non_fast_forward",
10418 "parameters": {},
10419 "applies_to": "everyone"
10420 },
10421 {
10422 "type": "pull_request",
10423 "parameters": {
10424 "required_approvals": 1,
10425 "count_agent_approvals": true,
10426 "dismiss_stale_reviews_on_push": true,
10427 "require_code_owner_review": true,
10428 "require_last_push_approval": false,
10429 "allowed_merge_methods": []
10430 },
10431 "applies_to": "everyone"
10432 },
10433 {
10434 "type": "required_status_checks",
10435 "parameters": {
10436 "checks": [
10437 {
10438 "context": "CI",
10439 "integration": "actions"
10440 }
10441 ],
10442 "strict": true,
10443 "paths": [],
10444 "allow_bypass_on_merge": false
10445 },
10446 "applies_to": "everyone"
10447 },
10448 {
10449 "type": "pull_request",
10450 "parameters": {
10451 "required_approvals": 1,
10452 "count_agent_approvals": false,
10453 "dismiss_stale_reviews_on_push": false,
10454 "require_code_owner_review": false,
10455 "require_last_push_approval": false,
10456 "allowed_merge_methods": []
10457 },
10458 "applies_to": "agents"
10459 },
10460 {
10461 "type": "file_path_restriction",
10462 "parameters": {
10463 "restricted_file_paths": [
10464 ".g1t/workflows/**",
10465 "CODEOWNERS"
10466 ]
10467 },
10468 "applies_to": "agents"
10469 }
10470 ],
10471 "created_by": "syntaqx",
10472 "created_at": "2026-10-07T14:02:11.318Z",
10473 "updated_by": "syntaqx",
10474 "updated_at": "2026-10-07T14:02:11.318Z"
10475 }
10476 },
10477 "create_repo_ruleset": {
10478 "params": {
10479 "owner": "flagon-io",
10480 "name": "hello"
10481 },
10482 "request": {
10483 "ruleset_name": "Protect main",
10484 "enforcement": "active",
10485 "target": "branch",
10486 "conditions": {
10487 "ref_name": {
10488 "include": [
10489 "~DEFAULT_BRANCH"
10490 ],
10491 "exclude": []
10492 }
10493 },
10494 "bypass_actors": [
10495 {
10496 "kind": "role",
10497 "value": "admin",
10498 "mode": "pull_requests"
10499 }
10500 ],
10501 "rules": [
10502 {
10503 "type": "deletion",
10504 "parameters": {},
10505 "applies_to": "everyone"
10506 },
10507 {
10508 "type": "non_fast_forward",
10509 "parameters": {},
10510 "applies_to": "everyone"
10511 },
10512 {
10513 "type": "pull_request",
10514 "parameters": {
10515 "required_approvals": 1,
10516 "count_agent_approvals": true,
10517 "dismiss_stale_reviews_on_push": true,
10518 "require_code_owner_review": true,
10519 "require_last_push_approval": false,
10520 "allowed_merge_methods": []
10521 },
10522 "applies_to": "everyone"
10523 },
10524 {
10525 "type": "required_status_checks",
10526 "parameters": {
10527 "checks": [
10528 {
10529 "context": "CI",
10530 "integration": "actions"
10531 }
10532 ],
10533 "strict": true,
10534 "paths": [],
10535 "allow_bypass_on_merge": false
10536 },
10537 "applies_to": "everyone"
10538 },
10539 {
10540 "type": "pull_request",
10541 "parameters": {
10542 "required_approvals": 1,
10543 "count_agent_approvals": false,
10544 "dismiss_stale_reviews_on_push": false,
10545 "require_code_owner_review": false,
10546 "require_last_push_approval": false,
10547 "allowed_merge_methods": []
10548 },
10549 "applies_to": "agents"
10550 },
10551 {
10552 "type": "file_path_restriction",
10553 "parameters": {
10554 "restricted_file_paths": [
10555 ".g1t/workflows/**",
10556 "CODEOWNERS"
10557 ]
10558 },
10559 "applies_to": "agents"
10560 }
10561 ]
10562 },
10563 "response": {
10564 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10565 "level": "repository",
10566 "workspace": "flagon-io",
10567 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
10568 "repository": "flagon-io/hello",
10569 "name": "Protect main",
10570 "enforcement": "active",
10571 "target": "branch",
10572 "conditions": {
10573 "ref_name": {
10574 "include": [
10575 "~DEFAULT_BRANCH"
10576 ],
10577 "exclude": []
10578 }
10579 },
10580 "bypass_actors": [
10581 {
10582 "kind": "role",
10583 "value": "admin",
10584 "mode": "pull_requests"
10585 }
10586 ],
10587 "rules": [
10588 {
10589 "type": "deletion",
10590 "parameters": {},
10591 "applies_to": "everyone"
10592 },
10593 {
10594 "type": "non_fast_forward",
10595 "parameters": {},
10596 "applies_to": "everyone"
10597 },
10598 {
10599 "type": "pull_request",
10600 "parameters": {
10601 "required_approvals": 1,
10602 "count_agent_approvals": true,
10603 "dismiss_stale_reviews_on_push": true,
10604 "require_code_owner_review": true,
10605 "require_last_push_approval": false,
10606 "allowed_merge_methods": []
10607 },
10608 "applies_to": "everyone"
10609 },
10610 {
10611 "type": "required_status_checks",
10612 "parameters": {
10613 "checks": [
10614 {
10615 "context": "CI",
10616 "integration": "actions"
10617 }
10618 ],
10619 "strict": true,
10620 "paths": [],
10621 "allow_bypass_on_merge": false
10622 },
10623 "applies_to": "everyone"
10624 },
10625 {
10626 "type": "pull_request",
10627 "parameters": {
10628 "required_approvals": 1,
10629 "count_agent_approvals": false,
10630 "dismiss_stale_reviews_on_push": false,
10631 "require_code_owner_review": false,
10632 "require_last_push_approval": false,
10633 "allowed_merge_methods": []
10634 },
10635 "applies_to": "agents"
10636 },
10637 {
10638 "type": "file_path_restriction",
10639 "parameters": {
10640 "restricted_file_paths": [
10641 ".g1t/workflows/**",
10642 "CODEOWNERS"
10643 ]
10644 },
10645 "applies_to": "agents"
10646 }
10647 ],
10648 "created_by": "syntaqx",
10649 "created_at": "2026-10-07T14:02:11.318Z",
10650 "updated_by": "syntaqx",
10651 "updated_at": "2026-10-07T14:02:11.318Z"
10652 },
10653 "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."
10654 },
10655 "update_repo_ruleset": {
10656 "params": {
10657 "owner": "flagon-io",
10658 "name": "hello",
10659 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m"
10660 },
10661 "request": {
10662 "enforcement": "evaluate"
10663 },
10664 "response": {
10665 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10666 "level": "repository",
10667 "workspace": "flagon-io",
10668 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
10669 "repository": "flagon-io/hello",
10670 "name": "Protect main",
10671 "enforcement": "evaluate",
10672 "target": "branch",
10673 "conditions": {
10674 "ref_name": {
10675 "include": [
10676 "~DEFAULT_BRANCH"
10677 ],
10678 "exclude": []
10679 }
10680 },
10681 "bypass_actors": [
10682 {
10683 "kind": "role",
10684 "value": "admin",
10685 "mode": "pull_requests"
10686 }
10687 ],
10688 "rules": [
10689 {
10690 "type": "deletion",
10691 "parameters": {},
10692 "applies_to": "everyone"
10693 },
10694 {
10695 "type": "non_fast_forward",
10696 "parameters": {},
10697 "applies_to": "everyone"
10698 },
10699 {
10700 "type": "pull_request",
10701 "parameters": {
10702 "required_approvals": 1,
10703 "count_agent_approvals": true,
10704 "dismiss_stale_reviews_on_push": true,
10705 "require_code_owner_review": true,
10706 "require_last_push_approval": false,
10707 "allowed_merge_methods": []
10708 },
10709 "applies_to": "everyone"
10710 },
10711 {
10712 "type": "required_status_checks",
10713 "parameters": {
10714 "checks": [
10715 {
10716 "context": "CI",
10717 "integration": "actions"
10718 }
10719 ],
10720 "strict": true,
10721 "paths": [],
10722 "allow_bypass_on_merge": false
10723 },
10724 "applies_to": "everyone"
10725 },
10726 {
10727 "type": "pull_request",
10728 "parameters": {
10729 "required_approvals": 1,
10730 "count_agent_approvals": false,
10731 "dismiss_stale_reviews_on_push": false,
10732 "require_code_owner_review": false,
10733 "require_last_push_approval": false,
10734 "allowed_merge_methods": []
10735 },
10736 "applies_to": "agents"
10737 },
10738 {
10739 "type": "file_path_restriction",
10740 "parameters": {
10741 "restricted_file_paths": [
10742 ".g1t/workflows/**",
10743 "CODEOWNERS"
10744 ]
10745 },
10746 "applies_to": "agents"
10747 }
10748 ],
10749 "created_by": "syntaqx",
10750 "created_at": "2026-10-07T14:02:11.318Z",
10751 "updated_by": "syntaqx",
10752 "updated_at": "2026-10-07T14:02:11.318Z"
10753 },
10754 "notes": "Fields left out stay as they are. `rules` and `bypass_actors`, when given, replace the whole list."
10755 },
10756 "delete_repo_ruleset": {
10757 "params": {
10758 "owner": "flagon-io",
10759 "name": "hello",
10760 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m"
10761 },
10762 "response": {
10763 "deleted": true
10764 }
10765 },
10766 "get_branch_rules": {
10767 "params": {
10768 "owner": "flagon-io",
10769 "name": "hello",
10770 "branch": "main"
10771 },
10772 "response": {
10773 "name": "main",
10774 "target": "branch",
10775 "default_branch": true,
10776 "rules": [
10777 {
10778 "type": "deletion",
10779 "parameters": {},
10780 "applies_to": "everyone",
10781 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10782 "ruleset_name": "Protect main",
10783 "level": "repository",
10784 "enforcement": "active"
10785 },
10786 {
10787 "type": "non_fast_forward",
10788 "parameters": {},
10789 "applies_to": "everyone",
10790 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10791 "ruleset_name": "Protect main",
10792 "level": "repository",
10793 "enforcement": "active"
10794 },
10795 {
10796 "type": "pull_request",
10797 "parameters": {
10798 "required_approvals": 1,
10799 "count_agent_approvals": true,
10800 "dismiss_stale_reviews_on_push": true,
10801 "require_code_owner_review": true,
10802 "require_last_push_approval": false,
10803 "allowed_merge_methods": []
10804 },
10805 "applies_to": "everyone",
10806 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10807 "ruleset_name": "Protect main",
10808 "level": "repository",
10809 "enforcement": "active"
10810 },
10811 {
10812 "type": "required_status_checks",
10813 "parameters": {
10814 "checks": [
10815 {
10816 "context": "CI",
10817 "integration": "actions"
10818 }
10819 ],
10820 "strict": true,
10821 "paths": [],
10822 "allow_bypass_on_merge": false
10823 },
10824 "applies_to": "everyone",
10825 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10826 "ruleset_name": "Protect main",
10827 "level": "repository",
10828 "enforcement": "active"
10829 },
10830 {
10831 "type": "merge_window",
10832 "parameters": {
10833 "time_zone": "-05:00",
10834 "windows": [
10835 {
10836 "days": [
10837 "mon",
10838 "tue",
10839 "wed",
10840 "thu"
10841 ],
10842 "start": "09:00",
10843 "end": "17:00"
10844 }
10845 ],
10846 "freezes": [
10847 {
10848 "start": "2026-12-20T00:00:00Z",
10849 "end": "2027-01-04T00:00:00Z",
10850 "reason": "Holidays"
10851 }
10852 ],
10853 "exceptions": []
10854 },
10855 "applies_to": "everyone",
10856 "ruleset_id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
10857 "ruleset_name": "Release freeze",
10858 "level": "workspace",
10859 "enforcement": "evaluate"
10860 }
10861 ],
10862 "rulesets": [
10863 {
10864 "id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10865 "name": "Protect main",
10866 "level": "repository",
10867 "enforcement": "active",
10868 "bypass_actors": [
10869 {
10870 "kind": "role",
10871 "value": "admin",
10872 "mode": "pull_requests"
10873 }
10874 ]
10875 },
10876 {
10877 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
10878 "name": "Release freeze",
10879 "level": "workspace",
10880 "enforcement": "evaluate",
10881 "bypass_actors": [
10882 {
10883 "kind": "team",
10884 "value": "flagon-io/release",
10885 "mode": "always"
10886 }
10887 ]
10888 }
10889 ]
10890 },
10891 "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."
10892 },
10893 "list_rule_evaluations": {
10894 "params": {
10895 "owner": "flagon-io",
10896 "name": "hello"
10897 },
10898 "query": {
10899 "problems_only": "true"
10900 },
10901 "response": {
10902 "evaluations": [
10903 {
10904 "id": "rev_01kq3c4d5e6f7g8h9j0k1m2n3p",
10905 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
10906 "workspace": "flagon-io",
10907 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10908 "ruleset_name": "Protect main",
10909 "enforcement": "active",
10910 "action": "push",
10911 "git_ref": "refs/heads/main",
10912 "actor": "g1t",
10913 "actor_kind": "agent",
10914 "verdict": "fail",
10915 "violations": [
10916 {
10917 "rule": "pull_request",
10918 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10919 "ruleset_name": "Protect main",
10920 "enforcement": "active",
10921 "message": "Changes to main must be made through a pull request.",
10922 "remedy": "Push a branch, open a pull request into main, and merge it."
10923 }
10924 ],
10925 "number": null,
10926 "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
10927 "repository": "flagon-io/hello",
10928 "created_at": "2026-10-07T14:02:11.318Z"
10929 }
10930 ],
10931 "next": null,
10932 "insights": {
10933 "days": 30,
10934 "total": 214,
10935 "passed": 198,
10936 "blocked": 9,
10937 "would_block": 5,
10938 "bypassed": 2,
10939 "by_ruleset": [
10940 {
10941 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
10942 "ruleset_name": "Protect main",
10943 "enforcement": "active",
10944 "total": 120,
10945 "blocked": 9,
10946 "would_block": 0,
10947 "bypassed": 2
10948 }
10949 ],
10950 "by_rule": [
10951 {
10952 "rule": "pull_request",
10953 "count": 7
10954 },
10955 {
10956 "rule": "non_fast_forward",
10957 "count": 2
10958 }
10959 ]
10960 }
10961 },
10962 "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."
10963 },
10964 "list_workspace_rulesets": {
10965 "params": {
10966 "workspace": "flagon-io"
10967 },
10968 "response": [
10969 {
10970 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
10971 "level": "workspace",
10972 "workspace": "flagon-io",
10973 "name": "Release freeze",
10974 "enforcement": "evaluate",
10975 "target": "branch",
10976 "conditions": {
10977 "ref_name": {
10978 "include": [
10979 "~DEFAULT_BRANCH",
10980 "release/**"
10981 ],
10982 "exclude": []
10983 },
10984 "repository": {
10985 "include": [
10986 "~ALL"
10987 ],
10988 "exclude": [
10989 "sandbox-*"
10990 ],
10991 "visibility": "any",
10992 "topics": []
10993 }
10994 },
10995 "bypass_actors": [
10996 {
10997 "kind": "team",
10998 "value": "flagon-io/release",
10999 "mode": "always"
11000 }
11001 ],
11002 "rules": [
11003 {
11004 "type": "merge_window",
11005 "parameters": {
11006 "time_zone": "-05:00",
11007 "windows": [
11008 {
11009 "days": [
11010 "mon",
11011 "tue",
11012 "wed",
11013 "thu"
11014 ],
11015 "start": "09:00",
11016 "end": "17:00"
11017 }
11018 ],
11019 "freezes": [
11020 {
11021 "start": "2026-12-20T00:00:00Z",
11022 "end": "2027-01-04T00:00:00Z",
11023 "reason": "Holidays"
11024 }
11025 ],
11026 "exceptions": []
11027 },
11028 "applies_to": "everyone"
11029 }
11030 ],
11031 "created_by": "syntaqx",
11032 "created_at": "2026-10-07T14:02:11.318Z",
11033 "updated_by": "syntaqx",
11034 "updated_at": "2026-10-07T14:02:11.318Z"
11035 }
11036 ]
11037 },
11038 "get_workspace_ruleset": {
11039 "params": {
11040 "workspace": "flagon-io",
11041 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n"
11042 },
11043 "response": {
11044 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
11045 "level": "workspace",
11046 "workspace": "flagon-io",
11047 "name": "Release freeze",
11048 "enforcement": "evaluate",
11049 "target": "branch",
11050 "conditions": {
11051 "ref_name": {
11052 "include": [
11053 "~DEFAULT_BRANCH",
11054 "release/**"
11055 ],
11056 "exclude": []
11057 },
11058 "repository": {
11059 "include": [
11060 "~ALL"
11061 ],
11062 "exclude": [
11063 "sandbox-*"
11064 ],
11065 "visibility": "any",
11066 "topics": []
11067 }
11068 },
11069 "bypass_actors": [
11070 {
11071 "kind": "team",
11072 "value": "flagon-io/release",
11073 "mode": "always"
11074 }
11075 ],
11076 "rules": [
11077 {
11078 "type": "merge_window",
11079 "parameters": {
11080 "time_zone": "-05:00",
11081 "windows": [
11082 {
11083 "days": [
11084 "mon",
11085 "tue",
11086 "wed",
11087 "thu"
11088 ],
11089 "start": "09:00",
11090 "end": "17:00"
11091 }
11092 ],
11093 "freezes": [
11094 {
11095 "start": "2026-12-20T00:00:00Z",
11096 "end": "2027-01-04T00:00:00Z",
11097 "reason": "Holidays"
11098 }
11099 ],
11100 "exceptions": []
11101 },
11102 "applies_to": "everyone"
11103 }
11104 ],
11105 "created_by": "syntaqx",
11106 "created_at": "2026-10-07T14:02:11.318Z",
11107 "updated_by": "syntaqx",
11108 "updated_at": "2026-10-07T14:02:11.318Z"
11109 }
11110 },
11111 "create_workspace_ruleset": {
11112 "params": {
11113 "workspace": "flagon-io"
11114 },
11115 "request": {
11116 "ruleset_name": "Release freeze",
11117 "enforcement": "evaluate",
11118 "target": "branch",
11119 "conditions": {
11120 "ref_name": {
11121 "include": [
11122 "~DEFAULT_BRANCH",
11123 "release/**"
11124 ],
11125 "exclude": []
11126 },
11127 "repository": {
11128 "include": [
11129 "~ALL"
11130 ],
11131 "exclude": [
11132 "sandbox-*"
11133 ],
11134 "visibility": "any",
11135 "topics": []
11136 }
11137 },
11138 "bypass_actors": [
11139 {
11140 "kind": "team",
11141 "value": "flagon-io/release",
11142 "mode": "always"
11143 }
11144 ],
11145 "rules": [
11146 {
11147 "type": "merge_window",
11148 "parameters": {
11149 "time_zone": "-05:00",
11150 "windows": [
11151 {
11152 "days": [
11153 "mon",
11154 "tue",
11155 "wed",
11156 "thu"
11157 ],
11158 "start": "09:00",
11159 "end": "17:00"
11160 }
11161 ],
11162 "freezes": [
11163 {
11164 "start": "2026-12-20T00:00:00Z",
11165 "end": "2027-01-04T00:00:00Z",
11166 "reason": "Holidays"
11167 }
11168 ],
11169 "exceptions": []
11170 },
11171 "applies_to": "everyone"
11172 }
11173 ]
11174 },
11175 "response": {
11176 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
11177 "level": "workspace",
11178 "workspace": "flagon-io",
11179 "name": "Release freeze",
11180 "enforcement": "evaluate",
11181 "target": "branch",
11182 "conditions": {
11183 "ref_name": {
11184 "include": [
11185 "~DEFAULT_BRANCH",
11186 "release/**"
11187 ],
11188 "exclude": []
11189 },
11190 "repository": {
11191 "include": [
11192 "~ALL"
11193 ],
11194 "exclude": [
11195 "sandbox-*"
11196 ],
11197 "visibility": "any",
11198 "topics": []
11199 }
11200 },
11201 "bypass_actors": [
11202 {
11203 "kind": "team",
11204 "value": "flagon-io/release",
11205 "mode": "always"
11206 }
11207 ],
11208 "rules": [
11209 {
11210 "type": "merge_window",
11211 "parameters": {
11212 "time_zone": "-05:00",
11213 "windows": [
11214 {
11215 "days": [
11216 "mon",
11217 "tue",
11218 "wed",
11219 "thu"
11220 ],
11221 "start": "09:00",
11222 "end": "17:00"
11223 }
11224 ],
11225 "freezes": [
11226 {
11227 "start": "2026-12-20T00:00:00Z",
11228 "end": "2027-01-04T00:00:00Z",
11229 "reason": "Holidays"
11230 }
11231 ],
11232 "exceptions": []
11233 },
11234 "applies_to": "everyone"
11235 }
11236 ],
11237 "created_by": "syntaqx",
11238 "created_at": "2026-10-07T14:02:11.318Z",
11239 "updated_by": "syntaqx",
11240 "updated_at": "2026-10-07T14:02:11.318Z"
11241 },
11242 "notes": "`conditions.repository` chooses the repositories it holds in; left out, every repository of the workspace."
11243 },
11244 "update_workspace_ruleset": {
11245 "params": {
11246 "workspace": "flagon-io",
11247 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n"
11248 },
11249 "request": {
11250 "enforcement": "active"
11251 },
11252 "response": {
11253 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n",
11254 "level": "workspace",
11255 "workspace": "flagon-io",
11256 "name": "Release freeze",
11257 "enforcement": "active",
11258 "target": "branch",
11259 "conditions": {
11260 "ref_name": {
11261 "include": [
11262 "~DEFAULT_BRANCH",
11263 "release/**"
11264 ],
11265 "exclude": []
11266 },
11267 "repository": {
11268 "include": [
11269 "~ALL"
11270 ],
11271 "exclude": [
11272 "sandbox-*"
11273 ],
11274 "visibility": "any",
11275 "topics": []
11276 }
11277 },
11278 "bypass_actors": [
11279 {
11280 "kind": "team",
11281 "value": "flagon-io/release",
11282 "mode": "always"
11283 }
11284 ],
11285 "rules": [
11286 {
11287 "type": "merge_window",
11288 "parameters": {
11289 "time_zone": "-05:00",
11290 "windows": [
11291 {
11292 "days": [
11293 "mon",
11294 "tue",
11295 "wed",
11296 "thu"
11297 ],
11298 "start": "09:00",
11299 "end": "17:00"
11300 }
11301 ],
11302 "freezes": [
11303 {
11304 "start": "2026-12-20T00:00:00Z",
11305 "end": "2027-01-04T00:00:00Z",
11306 "reason": "Holidays"
11307 }
11308 ],
11309 "exceptions": []
11310 },
11311 "applies_to": "everyone"
11312 }
11313 ],
11314 "created_by": "syntaqx",
11315 "created_at": "2026-10-07T14:02:11.318Z",
11316 "updated_by": "syntaqx",
11317 "updated_at": "2026-10-07T14:02:11.318Z"
11318 }
11319 },
11320 "delete_workspace_ruleset": {
11321 "params": {
11322 "workspace": "flagon-io",
11323 "id": "rs_01kq3b2c3d4e5f6g7h8j9k0m1n"
11324 },
11325 "response": {
11326 "deleted": true
11327 }
11328 },
11329 "list_workspace_rule_evaluations": {
11330 "params": {
11331 "workspace": "flagon-io"
11332 },
11333 "response": {
11334 "evaluations": [
11335 {
11336 "id": "rev_01kq3c4d5e6f7g8h9j0k1m2n3p",
11337 "repo_id": "rep_01kq0f3a7b8c9d0e1f2g3h4j5k",
11338 "workspace": "flagon-io",
11339 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
11340 "ruleset_name": "Protect main",
11341 "enforcement": "active",
11342 "action": "push",
11343 "git_ref": "refs/heads/main",
11344 "actor": "g1t",
11345 "actor_kind": "agent",
11346 "verdict": "fail",
11347 "violations": [
11348 {
11349 "rule": "pull_request",
11350 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
11351 "ruleset_name": "Protect main",
11352 "enforcement": "active",
11353 "message": "Changes to main must be made through a pull request.",
11354 "remedy": "Push a branch, open a pull request into main, and merge it."
11355 }
11356 ],
11357 "number": null,
11358 "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
11359 "repository": "flagon-io/hello",
11360 "created_at": "2026-10-07T14:02:11.318Z"
11361 }
11362 ],
11363 "next": null,
11364 "insights": {
11365 "days": 30,
11366 "total": 214,
11367 "passed": 198,
11368 "blocked": 9,
11369 "would_block": 5,
11370 "bypassed": 2,
11371 "by_ruleset": [
11372 {
11373 "ruleset_id": "rs_01kq3a8b9c0d1e2f3g4h5j6k7m",
11374 "ruleset_name": "Protect main",
11375 "enforcement": "active",
11376 "total": 120,
11377 "blocked": 9,
11378 "would_block": 0,
11379 "bypassed": 2
11380 }
11381 ],
11382 "by_rule": [
11383 {
11384 "rule": "pull_request",
11385 "count": 7
11386 },
11387 {
11388 "rule": "non_fast_forward",
11389 "count": 2
11390 }
11391 ]
11392 }
11393 }
11394 },
11395 "list_deployments": {
11396 "params": {
11397 "owner": "flagon-io",
11398 "name": "g1t"
11399 },
11400 "query": {
11401 "environment": "production",
11402 "per_page": "2"
11403 },
11404 "response": {
11405 "deployments": [
11406 {
11407 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11408 "environment": "production",
11409 "ref": "main",
11410 "sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
11411 "task": "deploy",
11412 "description": "Deploy",
11413 "payload": {},
11414 "transient_environment": false,
11415 "production_environment": true,
11416 "state": "success",
11417 "environment_url": "https://g1t.sh",
11418 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11419 "creator": "syntaqx",
11420 "source": "actions",
11421 "run_id": "run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11422 "run_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11423 "project": null,
11424 "number": null,
11425 "created_at": "2026-10-07T18:02:11.204Z",
11426 "updated_at": "2026-10-07T18:19:47.881Z"
11427 }
11428 ],
11429 "total_count": 304,
11430 "page": 1,
11431 "per_page": 2
11432 },
11433 "notes": "Every deployment of the repository in one list, wherever it ran: `source` is `api` for those reported with [`POST /repos/{owner}/{name}/deployments`](/reference/api/deployments/create-deployment/), `actions` for those a g1t Actions job with an `environment:` made, and `g1t_page` for [g1t.page](/guides/deployments/) builds, whose ids start `dpl_`. `state` is the latest status's. See [Deployments API](/guides/deployments-api/)."
11434 },
11435 "create_deployment": {
11436 "params": {
11437 "owner": "flagon-io",
11438 "name": "g1t"
11439 },
11440 "request": {
11441 "ref": "main",
11442 "environment": "staging",
11443 "description": "Deployed by the release pipeline",
11444 "payload": {
11445 "pipeline": 4182,
11446 "region": "us-east"
11447 },
11448 "state": "in_progress",
11449 "log_url": "https://ci.example.com/pipelines/4182"
11450 },
11451 "response": {
11452 "id": "dep_01kq7z9a1c3e5g7j9m1p3r5t7v",
11453 "environment": "staging",
11454 "ref": "main",
11455 "sha": "4b8d0f2a6c1e3579bd02468ace13579bdf02468a",
11456 "task": "deploy",
11457 "description": "Deployed by the release pipeline",
11458 "payload": {
11459 "pipeline": 4182,
11460 "region": "us-east"
11461 },
11462 "transient_environment": false,
11463 "production_environment": false,
11464 "state": "in_progress",
11465 "environment_url": null,
11466 "log_url": "https://ci.example.com/pipelines/4182",
11467 "creator": "flagon-io",
11468 "source": "api",
11469 "run_id": null,
11470 "run_url": null,
11471 "project": null,
11472 "number": null,
11473 "created_at": "2026-10-06T21:40:03.512Z",
11474 "updated_at": "2026-10-06T21:40:03.512Z",
11475 "statuses": [
11476 {
11477 "id": "dst_01kq7z9a1d4f6h8k0m2p4r6t8v",
11478 "deployment_id": "dep_01kq7z9a1c3e5g7j9m1p3r5t7v",
11479 "state": "in_progress",
11480 "description": "Deployed by the release pipeline",
11481 "environment_url": null,
11482 "log_url": "https://ci.example.com/pipelines/4182",
11483 "creator": "flagon-io",
11484 "created_at": "2026-10-06T21:40:03.512Z"
11485 }
11486 ]
11487 },
11488 "notes": "Report from any CI with an access token that has `deployments:write` (the CI preset has it) and the Write role. Then report each step with [`POST …/deployments/{id}/statuses`](/reference/api/deployments/create-deployment-status/). Each status sets the check `deploy / <environment>` on the commit. A g1t Actions job with an `environment:` does all of this itself. See [Deployments API](/guides/deployments-api/)."
11489 },
11490 "get_deployment": {
11491 "params": {
11492 "owner": "flagon-io",
11493 "name": "g1t",
11494 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m"
11495 },
11496 "response": {
11497 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11498 "environment": "production",
11499 "ref": "main",
11500 "sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
11501 "task": "deploy",
11502 "description": "Deploy",
11503 "payload": {},
11504 "transient_environment": false,
11505 "production_environment": true,
11506 "state": "success",
11507 "environment_url": "https://g1t.sh",
11508 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11509 "creator": "syntaqx",
11510 "source": "actions",
11511 "run_id": "run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11512 "run_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11513 "project": null,
11514 "number": null,
11515 "created_at": "2026-10-07T18:02:11.204Z",
11516 "updated_at": "2026-10-07T18:19:47.881Z",
11517 "statuses": [
11518 {
11519 "id": "dst_01kq8m3t5w0a2c4e6g8j0m2p4r",
11520 "deployment_id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11521 "state": "in_progress",
11522 "description": "Deploy is deploying",
11523 "environment_url": "https://g1t.sh",
11524 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11525 "creator": "syntaqx",
11526 "created_at": "2026-10-07T18:02:11.204Z"
11527 },
11528 {
11529 "id": "dst_01kq8n4v6x8z0b2d4f6h8k0m2p",
11530 "deployment_id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11531 "state": "success",
11532 "description": "Deploy deployed",
11533 "environment_url": "https://g1t.sh",
11534 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11535 "creator": "syntaqx",
11536 "created_at": "2026-10-07T18:19:47.881Z"
11537 }
11538 ]
11539 },
11540 "notes": "`statuses` are oldest first. A g1t.page build's (`dpl_…`) are read from the build: queued, building, how it ended, and `inactive` once a newer build replaced it or it was taken down."
11541 },
11542 "list_deployment_statuses": {
11543 "params": {
11544 "owner": "flagon-io",
11545 "name": "g1t",
11546 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m"
11547 },
11548 "response": [
11549 {
11550 "id": "dst_01kq8n4v6x8z0b2d4f6h8k0m2p",
11551 "deployment_id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11552 "state": "success",
11553 "description": "Deploy deployed",
11554 "environment_url": "https://g1t.sh",
11555 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11556 "creator": "syntaqx",
11557 "created_at": "2026-10-07T18:19:47.881Z"
11558 },
11559 {
11560 "id": "dst_01kq8m3t5w0a2c4e6g8j0m2p4r",
11561 "deployment_id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11562 "state": "in_progress",
11563 "description": "Deploy is deploying",
11564 "environment_url": "https://g1t.sh",
11565 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11566 "creator": "syntaqx",
11567 "created_at": "2026-10-07T18:02:11.204Z"
11568 }
11569 ]
11570 },
11571 "create_deployment_status": {
11572 "params": {
11573 "owner": "flagon-io",
11574 "name": "g1t",
11575 "id": "dep_01kq7z9a1c3e5g7j9m1p3r5t7v"
11576 },
11577 "request": {
11578 "state": "failure",
11579 "description": "Smoke tests failed",
11580 "log_url": "https://ci.example.com/pipelines/4182"
11581 },
11582 "response": {
11583 "id": "dst_01kq7zc2e4g6j8m0p2r4t6v8x0",
11584 "deployment_id": "dep_01kq7z9a1c3e5g7j9m1p3r5t7v",
11585 "state": "failure",
11586 "description": "Smoke tests failed",
11587 "environment_url": null,
11588 "log_url": "https://ci.example.com/pipelines/4182",
11589 "creator": "flagon-io",
11590 "created_at": "2026-10-06T21:44:58.020Z"
11591 },
11592 "notes": "`queued` and `in_progress` set the commit's `deploy / <environment>` check pending; `success`, `failure` and `error` settle it; `inactive` leaves it. A success makes the environment's older successful deployments `inactive` unless `auto_inactive` is false. A g1t.page build (`dpl_…`) answers `409`: its statuses come from the build."
11593 },
11594 "list_environments": {
11595 "params": {
11596 "owner": "flagon-io",
11597 "name": "g1t"
11598 },
11599 "response": {
11600 "total_count": 304,
11601 "environments": [
11602 {
11603 "name": "production",
11604 "url": "https://g1t.sh",
11605 "production_environment": true,
11606 "transient_environment": false,
11607 "deployments_count": 281,
11608 "latest": {
11609 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11610 "environment": "production",
11611 "ref": "main",
11612 "sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
11613 "task": "deploy",
11614 "description": "Deploy",
11615 "payload": {},
11616 "transient_environment": false,
11617 "production_environment": true,
11618 "state": "success",
11619 "environment_url": "https://g1t.sh",
11620 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11621 "creator": "syntaqx",
11622 "source": "actions",
11623 "run_id": "run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11624 "run_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11625 "project": null,
11626 "number": null,
11627 "created_at": "2026-10-07T18:02:11.204Z",
11628 "updated_at": "2026-10-07T18:19:47.881Z"
11629 },
11630 "current": {
11631 "id": "dep_01kq8m3t5v7x9z1b3d5f7h9k2m",
11632 "environment": "production",
11633 "ref": "main",
11634 "sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
11635 "task": "deploy",
11636 "description": "Deploy",
11637 "payload": {},
11638 "transient_environment": false,
11639 "production_environment": true,
11640 "state": "success",
11641 "environment_url": "https://g1t.sh",
11642 "log_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11643 "creator": "syntaqx",
11644 "source": "actions",
11645 "run_id": "run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11646 "run_url": "https://g1t.sh/flagon-io/g1t/actions/runs/run_01kq8m2r4t6v8x0z2b4d6f8h0k",
11647 "project": null,
11648 "number": null,
11649 "created_at": "2026-10-07T18:02:11.204Z",
11650 "updated_at": "2026-10-07T18:19:47.881Z"
11651 },
11652 "updated_at": "2026-10-07T18:19:47.881Z"
11653 },
11654 {
11655 "name": "staging",
11656 "url": null,
11657 "production_environment": false,
11658 "transient_environment": false,
11659 "deployments_count": 19,
11660 "latest": {
11661 "id": "dep_01kq7z9a1c3e5g7j9m1p3r5t7v",
11662 "environment": "staging",
11663 "ref": "main",
11664 "sha": "4b8d0f2a6c1e3579bd02468ace13579bdf02468a",
11665 "task": "deploy",
11666 "description": "Deployed by the release pipeline",
11667 "payload": {
11668 "pipeline": 4182,
11669 "region": "us-east"
11670 },
11671 "transient_environment": false,
11672 "production_environment": false,
11673 "state": "failure",
11674 "environment_url": null,
11675 "log_url": "https://ci.example.com/pipelines/4182",
11676 "creator": "flagon-io",
11677 "source": "api",
11678 "run_id": null,
11679 "run_url": null,
11680 "project": null,
11681 "number": null,
11682 "created_at": "2026-10-06T21:40:03.512Z",
11683 "updated_at": "2026-10-06T21:44:58.020Z"
11684 },
11685 "current": null,
11686 "updated_at": "2026-10-06T21:44:58.020Z"
11687 }
11688 ]
11689 },
11690 "notes": "Production comes first, then the most recently deployed. `latest` is the newest deployment whatever its state; `current` is the newest that succeeded and is still active, and `url` is where it is served."
11691 },
11692 "start_deployment_build": {
11693 "params": {
11694 "owner": "flagon-io",
11695 "name": "hello"
11696 },
11697 "request": {
11698 "project": "hello"
11699 },
11700 "response": {
11701 "deploy_id": "dpl_01kq9c4e6g8j0m2p4r6t8v0x2z",
11702 "token": "…",
11703 "kind": "preview",
11704 "project": "hello",
11705 "branch": "new-header",
11706 "number": 42,
11707 "commit": "9f2c4e6a8b0d1f3e5a7c9b1d3f5e7a9c0b2d4f6e",
11708 "url": "https://hello-git-new-header-flagonio.g1t.page",
11709 "trusted": true,
11710 "root_dir": "",
11711 "build_command": null,
11712 "output_dir": null,
11713 "build_as": "auto",
11714 "dockerfile": null,
11715 "build_env": {
11716 "PUBLIC_API_URL": "https://api.example.com"
11717 },
11718 "build_secrets": {
11719 "SENTRY_AUTH_TOKEN": "…"
11720 }
11721 },
11722 "notes": "Called from a workflow step with the job's own token, `${{ github.token }}`, in a job with `permissions: deployments: write`; the [`g1t/deploy`](/guides/deployments/#deploying-from-a-workflow) action calls it, masks the token and the secrets, and runs `g1t-runner deploy` with them. Any other token is refused. This is a pull request's run, so it builds the pull request's preview; the same workflow on the production branch builds production. See [Deploying from a workflow](/guides/deployments/#deploying-from-a-workflow)."
11723 },
11724 "get_environment": {
11725 "params": {
11726 "owner": "flagon-io",
11727 "name": "docs",
11728 "environment": "preview"
11729 },
11730 "response": {
11731 "name": "preview",
11732 "url": "https://docs-git-docs-deployments-flagon-io.g1t.page",
11733 "production_environment": false,
11734 "transient_environment": true,
11735 "deployments_count": 87,
11736 "latest": {
11737 "id": "dpl_01kq8p2b4d6f8h0k2m4p6r8t0v",
11738 "environment": "preview",
11739 "ref": "docs-deployments",
11740 "sha": "e2f4a6c8b0d1e3f5a7c9b1d3e5f7a9c1b3d5e7f9",
11741 "task": "deploy",
11742 "description": "Preview of docs-deployments on g1t.page",
11743 "payload": {},
11744 "transient_environment": true,
11745 "production_environment": false,
11746 "state": "success",
11747 "environment_url": "https://docs-git-docs-deployments-flagon-io.g1t.page",
11748 "log_url": "https://g1t.sh/flagon-io/docs/deployments/dpl_01kq8p2b4d6f8h0k2m4p6r8t0v",
11749 "creator": "syntaqx",
11750 "source": "g1t_page",
11751 "run_id": null,
11752 "run_url": null,
11753 "project": "docs",
11754 "number": 412,
11755 "created_at": "2026-10-08T01:12:44.630Z",
11756 "updated_at": "2026-10-08T01:13:52.101Z"
11757 },
11758 "current": {
11759 "id": "dpl_01kq8p2b4d6f8h0k2m4p6r8t0v",
11760 "environment": "preview",
11761 "ref": "docs-deployments",
11762 "sha": "e2f4a6c8b0d1e3f5a7c9b1d3e5f7a9c1b3d5e7f9",
11763 "task": "deploy",
11764 "description": "Preview of docs-deployments on g1t.page",
11765 "payload": {},
11766 "transient_environment": true,
11767 "production_environment": false,
11768 "state": "success",
11769 "environment_url": "https://docs-git-docs-deployments-flagon-io.g1t.page",
11770 "log_url": "https://g1t.sh/flagon-io/docs/deployments/dpl_01kq8p2b4d6f8h0k2m4p6r8t0v",
11771 "creator": "syntaqx",
11772 "source": "g1t_page",
11773 "run_id": null,
11774 "run_url": null,
11775 "project": "docs",
11776 "number": 412,
11777 "created_at": "2026-10-08T01:12:44.630Z",
11778 "updated_at": "2026-10-08T01:13:52.101Z"
11779 },
11780 "updated_at": "2026-10-08T01:13:52.101Z"
11781 }
11782 },
11783 "update_environment": {
11784 "params": {
11785 "owner": "flagon-io",
11786 "name": "g1t",
11787 "environment": "production"
11788 },
11789 "request": {
11790 "wait_timer": 10,
11791 "prevent_self_review": true,
11792 "reviewers": [
11793 {
11794 "type": "User",
11795 "name": "syntaqx"
11796 },
11797 {
11798 "type": "Team",
11799 "name": "deployers"
11800 }
11801 ],
11802 "deployment_branch_policy": {
11803 "protected_branches": true,
11804 "custom_branch_policies": false
11805 }
11806 },
11807 "response": {
11808 "name": "production",
11809 "protection_rules": [
11810 {
11811 "type": "required_reviewers",
11812 "prevent_self_review": true,
11813 "reviewers": [
11814 {
11815 "type": "User",
11816 "reviewer": {
11817 "login": "syntaqx"
11818 }
11819 },
11820 {
11821 "type": "Team",
11822 "reviewer": {
11823 "slug": "deployers"
11824 }
11825 }
11826 ]
11827 },
11828 {
11829 "type": "wait_timer",
11830 "wait_timer": 10
11831 },
11832 {
11833 "type": "branch_policy"
11834 }
11835 ],
11836 "deployment_branch_policy": {
11837 "protected_branches": true,
11838 "custom_branch_policies": false
11839 },
11840 "branch_policies": [],
11841 "can_admins_bypass": true,
11842 "protected": true,
11843 "updated_at": "2026-10-08T09:12:44.103Z",
11844 "updated_by": "syntaqx"
11845 },
11846 "notes": "Fields left out stay as they are. A job with `environment: production` now waits for syntaqx or someone in deployers to approve it, then ten minutes, and runs only on a protected branch."
11847 },
11848 "delete_environment": {
11849 "params": {
11850 "owner": "flagon-io",
11851 "name": "g1t",
11852 "environment": "staging"
11853 },
11854 "response": {
11855 "deleted": true
11856 }
11857 },
11858 "get_pending_deployments": {
11859 "params": {
11860 "owner": "flagon-io",
11861 "name": "g1t",
11862 "id": "run_01kq9b3d5f7h9k1n3q5s7u9w1y"
11863 },
11864 "response": [
11865 {
11866 "environment": {
11867 "name": "production"
11868 },
11869 "state": "waiting",
11870 "needs_review": true,
11871 "wait_until": "2026-10-08T09:31:02.551Z",
11872 "current_user_can_approve": true,
11873 "reviewers": [
11874 {
11875 "type": "User",
11876 "reviewer": {
11877 "login": "syntaqx"
11878 }
11879 },
11880 {
11881 "type": "Team",
11882 "reviewer": {
11883 "slug": "deployers"
11884 }
11885 }
11886 ],
11887 "jobs": [
11888 "Deploy the core services"
11889 ],
11890 "reviewed_by": null,
11891 "comment": null,
11892 "reviewed_at": null
11893 }
11894 ]
11895 },
11896 "review_pending_deployments": {
11897 "params": {
11898 "owner": "flagon-io",
11899 "name": "g1t",
11900 "id": "run_01kq9b3d5f7h9k1n3q5s7u9w1y"
11901 },
11902 "request": {
11903 "environment_names": [
11904 "production"
11905 ],
11906 "state": "approved",
11907 "comment": "Release notes checked."
11908 },
11909 "response": [
11910 {
11911 "environment": {
11912 "name": "production"
11913 },
11914 "state": "approved",
11915 "needs_review": true,
11916 "wait_until": "2026-10-08T09:31:02.551Z",
11917 "current_user_can_approve": false,
11918 "reviewers": [
11919 {
11920 "type": "User",
11921 "reviewer": {
11922 "login": "syntaqx"
11923 }
11924 },
11925 {
11926 "type": "Team",
11927 "reviewer": {
11928 "slug": "deployers"
11929 }
11930 }
11931 ],
11932 "jobs": [
11933 "Deploy the core services"
11934 ],
11935 "reviewed_by": "syntaqx",
11936 "comment": "Release notes checked.",
11937 "reviewed_at": "2026-10-08T09:22:15.871Z"
11938 }
11939 ],
11940 "notes": "The jobs still wait for the wait timer, until `wait_until`, unless an admin approved past the rules."
11941 },
11942 "approve_workflow_run": {
11943 "params": {
11944 "owner": "flagon-io",
11945 "name": "g1t",
11946 "id": "run_01kq9a2c4e6g8j0m2p4r6t8v0x"
11947 },
11948 "response": {
11949 "id": "run_01kq9a2c4e6g8j0m2p4r6t8v0x",
11950 "workflow_id": "wfl_01kpw2c5d8e1f4g7h0j3k6m9np",
11951 "path": ".g1t/workflows/ci.yml",
11952 "name": "CI",
11953 "title": "Fix a typo in the README",
11954 "number": 41,
11955 "attempt": 1,
11956 "event": "pull_request",
11957 "ref": "refs/pull/88/merge",
11958 "sha": "4c1e7a9b2d5f8e0a3c6b9d2f5a8c1e4b7d0f3a6c",
11959 "pull": 88,
11960 "status": "queued",
11961 "conclusion": null,
11962 "error": null,
11963 "actor": "octo-fan",
11964 "created_at": "2026-10-08T08:02:11.004Z",
11965 "started_at": null,
11966 "finished_at": null
11967 }
11968 },
11969 "get_workflow_permissions": {
11970 "params": {
11971 "owner": "flagon-io",
11972 "name": "g1t"
11973 },
11974 "response": {
11975 "default_workflow_permissions": "read",
11976 "default_chosen": true,
11977 "max_workflow_permissions": "write",
11978 "can_approve_pull_request_reviews": false
11979 }
11980 },
11981 "set_workflow_permissions": {
11982 "params": {
11983 "owner": "flagon-io",
11984 "name": "g1t"
11985 },
11986 "request": {
11987 "default_workflow_permissions": "write"
11988 },
11989 "response": {
11990 "default_workflow_permissions": "write",
11991 "default_chosen": true,
11992 "max_workflow_permissions": "write",
11993 "can_approve_pull_request_reviews": false
11994 }
11995 },
11996 "get_fork_pr_approval": {
11997 "params": {
11998 "owner": "flagon-io",
11999 "name": "g1t"
12000 },
12001 "response": {
12002 "approval_policy": "outside_contributors"
12003 }
12004 },
12005 "set_fork_pr_approval": {
12006 "params": {
12007 "owner": "flagon-io",
12008 "name": "g1t"
12009 },
12010 "request": {
12011 "approval_policy": "all_external_contributors"
12012 },
12013 "response": {
12014 "approval_policy": "all_external_contributors"
12015 }
12016 },
12017 "get_actions_access": {
12018 "params": {
12019 "owner": "flagon-io",
12020 "name": "shared-workflows"
12021 },
12022 "response": {
12023 "access_level": "none"
12024 }
12025 },
12026 "get_actions_permissions": {
12027 "params": {
12028 "owner": "ada",
12029 "name": "hello"
12030 },
12031 "response": {
12032 "enabled": false,
12033 "enabled_chosen": false,
12034 "allowed_actions": "all"
12035 },
12036 "notes": "A fork's workflows are off until someone turns them on: here `ada/hello` is a fork nobody has chosen for yet. See [Forks](/concepts/forks/)."
12037 },
12038 "set_actions_permissions": {
12039 "params": {
12040 "owner": "ada",
12041 "name": "hello"
12042 },
12043 "request": {
12044 "enabled": true
12045 },
12046 "response": {
12047 "enabled": true,
12048 "enabled_chosen": true,
12049 "allowed_actions": "all"
12050 },
12051 "notes": "Needs the Admin role (`403` otherwise); a workflow job's own token is refused. Turning workflows on starts nothing by itself. See [Turn workflows off](/guides/actions/#turn-workflows-on-or-off)."
12052 },
12053 "set_actions_access": {
12054 "params": {
12055 "owner": "flagon-io",
12056 "name": "shared-workflows"
12057 },
12058 "request": {
12059 "access_level": "organization"
12060 },
12061 "response": {
12062 "access_level": "organization"
12063 }
12064 },
12065 "create_repository_dispatch": {
12066 "params": {
12067 "owner": "flagon-io",
12068 "name": "g1t"
12069 },
12070 "request": {
12071 "event_type": "docs-published",
12072 "client_payload": {
12073 "version": "2026.10.08"
12074 }
12075 },
12076 "response": {
12077 "runs": 1
12078 }
12079 },
12080 "get_workspace_workflow_permissions": {
12081 "params": {
12082 "workspace": "flagon-io"
12083 },
12084 "response": {
12085 "default_workflow_permissions": "read",
12086 "max_workflow_permissions": "write",
12087 "can_approve_pull_request_reviews": false
12088 }
12089 },
12090 "set_workspace_workflow_permissions": {
12091 "params": {
12092 "workspace": "flagon-io"
12093 },
12094 "request": {
12095 "max_workflow_permissions": "read"
12096 },
12097 "response": {
12098 "default_workflow_permissions": "read",
12099 "max_workflow_permissions": "read",
12100 "can_approve_pull_request_reviews": false
12101 },
12102 "notes": "A maximum of read holds every repository's default to read-only, and makes the workspace's default read too."
12103 },
12104 "list_workspace_managed_workflows": {
12105 "params": {
12106 "workspace": "flagon-io"
12107 },
12108 "response": {
12109 "total_count": 1,
12110 "managed_workflows": [
12111 {
12112 "name": "security-scan",
12113 "path": "managed/security-scan.yml",
12114 "workflow_name": "Security scan",
12115 "source": "flagon-io/policies/.g1t/workflows/security-scan.yml@main",
12116 "source_sha": "4f1c2a9e0b7d3c5a8e6f1b2d4c7a9e0f3b5d8c1a",
12117 "source_private": false,
12118 "mode": "required",
12119 "repositories": [
12120 "*",
12121 "!sandbox-*"
12122 ],
12123 "visibility": "all",
12124 "content": "name: Security scan\non: [push, pull_request]\njobs:\n scan:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n - run: ./scripts/scan.sh\n",
12125 "created_at": "2026-10-12T09:30:00Z",
12126 "updated_at": "2026-10-12T09:30:00Z",
12127 "updated_by": "ada"
12128 }
12129 ]
12130 }
12131 },
12132 "create_workspace_managed_workflow": {
12133 "params": {
12134 "workspace": "flagon-io"
12135 },
12136 "request": {
12137 "name": "security-scan",
12138 "source": "flagon-io/policies/.g1t/workflows/security-scan.yml@main",
12139 "mode": "required",
12140 "repositories": [
12141 "*",
12142 "!sandbox-*"
12143 ]
12144 },
12145 "response": {
12146 "name": "security-scan",
12147 "path": "managed/security-scan.yml",
12148 "workflow_name": "Security scan",
12149 "source": "flagon-io/policies/.g1t/workflows/security-scan.yml@main",
12150 "source_sha": "4f1c2a9e0b7d3c5a8e6f1b2d4c7a9e0f3b5d8c1a",
12151 "source_private": false,
12152 "mode": "required",
12153 "repositories": [
12154 "*",
12155 "!sandbox-*"
12156 ],
12157 "visibility": "all",
12158 "content": "name: Security scan\non: [push, pull_request]\njobs:\n scan:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n - run: ./scripts/scan.sh\n",
12159 "created_at": "2026-10-12T09:30:00Z",
12160 "updated_at": "2026-10-12T09:30:00Z",
12161 "updated_by": "ada"
12162 },
12163 "notes": "g1t copies the source when you save it, and that copy runs in each repository the workflow targets, as the repository's own workflow, with its token and secrets. A source in a private repository runs in private repositories only: give visibility private."
12164 },
12165 "update_workspace_managed_workflow": {
12166 "params": {
12167 "workspace": "flagon-io",
12168 "workflow": "security-scan"
12169 },
12170 "request": {
12171 "refresh": true
12172 },
12173 "response": {
12174 "name": "security-scan",
12175 "path": "managed/security-scan.yml",
12176 "workflow_name": "Security scan",
12177 "source": "flagon-io/policies/.g1t/workflows/security-scan.yml@main",
12178 "source_sha": "4f1c2a9e0b7d3c5a8e6f1b2d4c7a9e0f3b5d8c1a",
12179 "source_private": false,
12180 "mode": "required",
12181 "repositories": [
12182 "*",
12183 "!sandbox-*"
12184 ],
12185 "visibility": "all",
12186 "content": "name: Security scan\non: [push, pull_request]\njobs:\n scan:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n - run: ./scripts/scan.sh\n",
12187 "created_at": "2026-10-12T09:30:00Z",
12188 "updated_at": "2026-10-12T09:30:00Z",
12189 "updated_by": "ada"
12190 },
12191 "notes": "refresh copies the source again at the commit its ref names now. Fields left out stay as they are."
12192 },
12193 "delete_workspace_managed_workflow": {
12194 "params": {
12195 "workspace": "flagon-io",
12196 "workflow": "security-scan"
12197 },
12198 "response": {
12199 "deleted": true
12200 }
12201 },
12202 "get_token_policy": {
12203 "params": {
12204 "workspace": "flagon-io"
12205 },
12206 "response": {
12207 "allow_tokens_for_all_workspaces": true,
12208 "allow_tokens_for_this_workspace": true,
12209 "require_approval": true,
12210 "max_lifetime_days": null,
12211 "forbid_no_expiry": false,
12212 "updated_by": null,
12213 "updated_at": null
12214 }
12215 },
12216 "set_token_policy": {
12217 "params": {
12218 "workspace": "flagon-io"
12219 },
12220 "request": {
12221 "allow_tokens_for_all_workspaces": false,
12222 "max_lifetime_days": 90
12223 },
12224 "response": {
12225 "allow_tokens_for_all_workspaces": false,
12226 "allow_tokens_for_this_workspace": true,
12227 "require_approval": true,
12228 "max_lifetime_days": 90,
12229 "forbid_no_expiry": false,
12230 "updated_by": "ada",
12231 "updated_at": "2026-10-08T09:30:00.000Z"
12232 },
12233 "notes": "From each token's next request, tokens made for all of a member's workspaces no longer reach this one (tokens made for it alone still do), and neither does a token that lasts longer than 90 days or never expires. They keep working everywhere else."
12234 },
12235 "get_onboarding": {
12236 "params": {
12237 "workspace": "flagon-io"
12238 },
12239 "response": {
12240 "dismissed_at": null,
12241 "skipped": [],
12242 "updated_at": null
12243 },
12244 "notes": "Your own: each person has their own Getting started in each workspace they belong to. A person who never dismissed it gets `dismissed_at` null, and the guide opens by itself on the workspace's Home while they own it and steps are left. Whether a step is done is not kept here but read from the workspace: its AI providers (`GET /workspaces/{workspace}/ai/providers`), repositories, members and runners. `404` for anyone who is not a member. See [Getting started](/guides/workspaces/#getting-started)."
12245 },
12246 "update_onboarding": {
12247 "params": {
12248 "workspace": "flagon-io"
12249 },
12250 "request": {
12251 "dismissed": true,
12252 "skipped": ["people", "runner"]
12253 },
12254 "response": {
12255 "dismissed_at": "2026-10-14T21:05:00.000Z",
12256 "skipped": ["people", "runner"],
12257 "updated_at": "2026-10-14T21:05:00.000Z"
12258 },
12259 "notes": "Dismissing it again keeps the first `dismissed_at`; `\"dismissed\": false` makes it open by itself again. A step that is not one of `ai`, `ask`, `code`, `harness`, `people` and `runner` is refused with `422`. Opening the guide again from the workspace's settings or its AI page changes nothing here."
12260 },
12261 "list_member_tokens": {
12262 "params": {
12263 "workspace": "flagon-io"
12264 },
12265 "response": [
12266 {
12267 "id": "tok_01HZX3K2M9V7Q4N8B6D5C3A2E1",
12268 "name": "release-bot",
12269 "owner": "ada",
12270 "description": "Publishes releases from CI",
12271 "created_at": "2026-10-08T09:00:00.000Z",
12272 "created_by": null,
12273 "last_used_at": null,
12274 "expires_at": "2026-11-07T09:00:00.000Z",
12275 "scopes": ["repo:read", "code:write"],
12276 "workspace": "flagon-io",
12277 "repository_selection": "selected",
12278 "repositories": ["flagon-io/hello"],
12279 "permissions": { "code": "write", "repo": "read" },
12280 "status": "pending",
12281 "review_reason": null,
12282 "reaches": false,
12283 "blocked_by": "pending approval"
12284 }
12285 ]
12286 },
12287 "list_token_requests": {
12288 "params": {
12289 "workspace": "flagon-io"
12290 },
12291 "response": [
12292 {
12293 "id": "tok_01HZX3K2M9V7Q4N8B6D5C3A2E1",
12294 "name": "release-bot",
12295 "owner": "ada",
12296 "description": "Publishes releases from CI",
12297 "created_at": "2026-10-08T09:00:00.000Z",
12298 "created_by": null,
12299 "last_used_at": null,
12300 "expires_at": "2026-11-07T09:00:00.000Z",
12301 "scopes": ["repo:read", "code:write"],
12302 "workspace": "flagon-io",
12303 "repository_selection": "selected",
12304 "repositories": ["flagon-io/hello"],
12305 "permissions": { "code": "write", "repo": "read" },
12306 "status": "pending",
12307 "review_reason": null,
12308 "reaches": false,
12309 "blocked_by": "pending approval"
12310 }
12311 ]
12312 },
12313 "review_token_request": {
12314 "params": {
12315 "workspace": "flagon-io",
12316 "id": "tok_01HZX3K2M9V7Q4N8B6D5C3A2E1"
12317 },
12318 "request": {
12319 "decision": "approve"
12320 },
12321 "response": {
12322 "id": "tok_01HZX3K2M9V7Q4N8B6D5C3A2E1",
12323 "name": "release-bot",
12324 "owner": "ada",
12325 "description": "Publishes releases from CI",
12326 "created_at": "2026-10-08T09:00:00.000Z",
12327 "created_by": null,
12328 "last_used_at": null,
12329 "expires_at": "2026-11-07T09:00:00.000Z",
12330 "scopes": ["repo:read", "code:write"],
12331 "workspace": "flagon-io",
12332 "repository_selection": "selected",
12333 "repositories": ["flagon-io/hello"],
12334 "permissions": { "code": "write", "repo": "read" },
12335 "status": "active",
12336 "review_reason": null,
12337 "reaches": true,
12338 "blocked_by": null
12339 },
12340 "notes": "The token's owner hears of it in their inbox. A denied token reaches public repositories only."
12341 },
12342 "revoke_member_token": {
12343 "params": {
12344 "workspace": "flagon-io",
12345 "id": "tok_01HZX3K2M9V7Q4N8B6D5C3A2E1"
12346 },
12347 "request": {
12348 "reason": "Rotated after the laptop was lost"
12349 },
12350 "response": {
12351 "revoked": true
12352 }
12353 },
12354 "get_languages": {
12355 "response": {
12356 "head": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12357 "commit": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12358 "computed_at": "2026-10-07T09:14:03.000Z",
12359 "pending": false,
12360 "partial": false,
12361 "languages": [
12362 {
12363 "name": "Rust",
12364 "color": "#dea584",
12365 "bytes": 184213,
12366 "percent": 71.4
12367 },
12368 {
12369 "name": "TypeScript",
12370 "color": "#3178c6",
12371 "bytes": 61022,
12372 "percent": 23.7
12373 },
12374 {
12375 "name": "Shell",
12376 "color": "#89e051",
12377 "bytes": 12650,
12378 "percent": 4.9
12379 }
12380 ]
12381 },
12382 "notes": "While `pending` is true, `languages` is empty: the default branch is being read for the first time. When `commit` is not `head`, the answer is for an older commit while the newer one is read."
12383 },
12384 "list_contributors": {
12385 "response": {
12386 "head": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12387 "commit": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12388 "computed_at": "2026-10-07T09:14:03.000Z",
12389 "pending": false,
12390 "partial": false,
12391 "total": 3,
12392 "commits": 126,
12393 "contributors": [
12394 {
12395 "kind": "g1t",
12396 "name": "g1t",
12397 "username": null,
12398 "avatar": null,
12399 "commits": 71,
12400 "first_at": "2026-09-29T08:00:00.000Z",
12401 "last_at": "2026-10-07T08:41:00.000Z",
12402 "weeks": [
12403 {
12404 "week": "2026-09-28",
12405 "commits": 40
12406 },
12407 {
12408 "week": "2026-10-05",
12409 "commits": 31
12410 }
12411 ]
12412 },
12413 {
12414 "kind": "user",
12415 "name": "ada",
12416 "username": "ada",
12417 "display_username": "Ada",
12418 "avatar": "5f2b8c1d9e7a3f6b4c0d2e8a1b9c7d5e3f1a0b2c4d6e8f0a1b3c5d7e9f0a2b4c",
12419 "commits": 52,
12420 "first_at": "2026-09-28T14:11:52.000Z",
12421 "last_at": "2026-10-06T16:02:11.000Z",
12422 "weeks": [
12423 {
12424 "week": "2026-09-28",
12425 "commits": 30
12426 },
12427 {
12428 "week": "2026-10-05",
12429 "commits": 22
12430 }
12431 ]
12432 },
12433 {
12434 "kind": "author",
12435 "name": "Sam Okafor",
12436 "username": null,
12437 "avatar": null,
12438 "commits": 3,
12439 "first_at": "2026-10-02T11:20:00.000Z",
12440 "last_at": "2026-10-03T09:05:00.000Z",
12441 "weeks": [
12442 {
12443 "week": "2026-09-28",
12444 "commits": 3
12445 }
12446 ]
12447 }
12448 ],
12449 "weeks": [
12450 {
12451 "week": "2026-09-28",
12452 "commits": 73
12453 },
12454 {
12455 "week": "2026-10-05",
12456 "commits": 53
12457 }
12458 ]
12459 },
12460 "notes": "Read from the newest 3,000 commits of the default branch. A person's addresses count as one when they confirmed them on their account; their noreply address counts too."
12461 },
12462 "get_license": {
12463 "response": {
12464 "spdx_id": "MIT",
12465 "name": "MIT License",
12466 "path": "LICENSE"
12467 }
12468 },
12469 "list_stargazers": {
12470 "query": {
12471 "page": 1
12472 },
12473 "response": [
12474 {
12475 "username": "ada",
12476 "display_username": "Ada",
12477 "avatar": null,
12478 "starred_at": "2026-10-06T18:30:00.000Z"
12479 },
12480 {
12481 "username": "sam",
12482 "display_username": "sam",
12483 "avatar": null,
12484 "starred_at": "2026-10-02T09:12:00.000Z"
12485 }
12486 ]
12487 },
12488 "list_starred": {
12489 "response": [
12490 {
12491 "repo": {
12492 "id": "rep_01m3m5q6p0e2qaw6mmjahk0qrr",
12493 "namespace": "flagon-io",
12494 "name": "hello",
12495 "is_private": false,
12496 "owner_id": "usr_01kkntcg1eeb98j62xjm7eh09p",
12497 "default_branch": "main",
12498 "fork_of": null,
12499 "protected": true,
12500 "created_at": "2026-09-28T14:11:52.640Z",
12501 "topics": [
12502 "cli"
12503 ],
12504 "website": "https://hello.g1t.page",
12505 "archived_at": null
12506 },
12507 "starred_at": "2026-10-06T18:30:00.000Z",
12508 "stars": 12
12509 }
12510 ]
12511 },
12512 "check_starred": {
12513 "response": {
12514 "starred": true,
12515 "stars": 12
12516 }
12517 },
12518 "star_repo": {
12519 "response": {
12520 "starred": true,
12521 "stars": 13
12522 }
12523 },
12524 "unstar_repo": {
12525 "response": {
12526 "starred": false,
12527 "stars": 12
12528 }
12529 },
12530 "list_releases": {
12531 "response": [
12532 {
12533 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12534 "tag_name": "v1.2.0",
12535 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12536 "name": "Greetings by name",
12537 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12538 "draft": false,
12539 "prerelease": false,
12540 "author": "ada",
12541 "created_at": "2026-10-06T16:02:11.000Z",
12542 "published_at": "2026-10-06T16:02:11.000Z",
12543 "latest": true
12544 },
12545 {
12546 "id": "rel_01m3x8q2w4e6r8t0y2u4i6o8p0",
12547 "tag_name": "v1.1.0",
12548 "target": "3b2a19f8e7d6c5b4a392817069f3c2a1b7e5d4c3",
12549 "name": "First release",
12550 "body": "The first release.",
12551 "draft": false,
12552 "prerelease": false,
12553 "author": "ada",
12554 "created_at": "2026-09-30T10:00:00.000Z",
12555 "published_at": "2026-09-30T10:00:00.000Z",
12556 "latest": false
12557 }
12558 ],
12559 "notes": "Drafts are listed only to those with the Write role; their `published_at` is null."
12560 },
12561 "get_latest_release": {
12562 "response": {
12563 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12564 "tag_name": "v1.2.0",
12565 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12566 "name": "Greetings by name",
12567 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12568 "draft": false,
12569 "prerelease": false,
12570 "author": "ada",
12571 "created_at": "2026-10-06T16:02:11.000Z",
12572 "published_at": "2026-10-06T16:02:11.000Z",
12573 "latest": true
12574 }
12575 },
12576 "get_release_by_tag": {
12577 "params": {
12578 "tag": "v1.2.0"
12579 },
12580 "response": {
12581 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12582 "tag_name": "v1.2.0",
12583 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12584 "name": "Greetings by name",
12585 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12586 "draft": false,
12587 "prerelease": false,
12588 "author": "ada",
12589 "created_at": "2026-10-06T16:02:11.000Z",
12590 "published_at": "2026-10-06T16:02:11.000Z",
12591 "latest": true
12592 }
12593 },
12594 "get_release": {
12595 "params": {
12596 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7"
12597 },
12598 "response": {
12599 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12600 "tag_name": "v1.2.0",
12601 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12602 "name": "Greetings by name",
12603 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12604 "draft": false,
12605 "prerelease": false,
12606 "author": "ada",
12607 "created_at": "2026-10-06T16:02:11.000Z",
12608 "published_at": "2026-10-06T16:02:11.000Z",
12609 "latest": true
12610 }
12611 },
12612 "create_release": {
12613 "request": {
12614 "tag_name": "v1.2.0",
12615 "target": "main",
12616 "release_name": "Greetings by name",
12617 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12618 "draft": false,
12619 "prerelease": false
12620 },
12621 "response": {
12622 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12623 "tag_name": "v1.2.0",
12624 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12625 "name": "Greetings by name",
12626 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)",
12627 "draft": false,
12628 "prerelease": false,
12629 "author": "ada",
12630 "created_at": "2026-10-06T16:02:11.000Z",
12631 "published_at": "2026-10-06T16:02:11.000Z",
12632 "latest": true
12633 },
12634 "notes": "A tag that already exists is released as it is, and `target` is ignored. One release per tag: releasing a tag again is refused with `conflict`."
12635 },
12636 "update_release": {
12637 "params": {
12638 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7"
12639 },
12640 "request": {
12641 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)\n- Docs for `--name`"
12642 },
12643 "response": {
12644 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7",
12645 "tag_name": "v1.2.0",
12646 "target": "9f3c2a1b7e5d4c3b2a19f8e7d6c5b4a39281706f",
12647 "name": "Greetings by name",
12648 "body": "## What changed\n\n- `hello` greets the caller by name (#12)\n- Faster start-up (#15)\n- Docs for `--name`",
12649 "draft": false,
12650 "prerelease": false,
12651 "author": "ada",
12652 "created_at": "2026-10-06T16:02:11.000Z",
12653 "published_at": "2026-10-06T16:02:11.000Z",
12654 "latest": true
12655 }
12656 },
12657 "delete_release": {
12658 "params": {
12659 "id": "rel_01m4a2b7c9d3e5f7g9h1j3k5m7"
12660 },
12661 "response": {
12662 "deleted": true
12663 }
12664 },
12665 "create_commit_status": {
12666 "params": {
12667 "owner": "flagon-io",
12668 "name": "hello",
12669 "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e"
12670 },
12671 "request": {
12672 "state": "success",
12673 "context": "ci/build",
12674 "description": "Build #4821 passed",
12675 "target_url": "https://ci.example.com/builds/4821"
12676 },
12677 "response": {
12678 "context": "ci/build",
12679 "state": "success",
12680 "description": "Build #4821 passed",
12681 "target_url": "https://ci.example.com/builds/4821",
12682 "updated_at": "2026-10-07T14:03:02.118Z",
12683 "source": "api"
12684 },
12685 "notes": "Setting a context again replaces its status on that commit. A status counts as a check: a required check named `ci/build`, in branch protection or a ruleset's `required_status_checks`, is met by it, and a ruleset check pinned to the `api` integration only by statuses and check runs reported through the API. See the [Checks guide](/guides/checks/)."
12686 },
12687 "list_commit_statuses": {
12688 "params": {
12689 "owner": "flagon-io",
12690 "name": "hello",
12691 "ref": "main"
12692 },
12693 "response": [
12694 {
12695 "context": "ci/build",
12696 "state": "success",
12697 "description": "Build #4821 passed",
12698 "target_url": "https://ci.example.com/builds/4821",
12699 "updated_at": "2026-10-07T14:03:02.118Z",
12700 "source": "api"
12701 }
12702 ]
12703 },
12704 "get_combined_status": {
12705 "params": {
12706 "owner": "flagon-io",
12707 "name": "hello",
12708 "ref": "main"
12709 },
12710 "response": {
12711 "state": "success",
12712 "sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12713 "total_count": 1,
12714 "statuses": [
12715 {
12716 "context": "ci/build",
12717 "state": "success",
12718 "description": "Build #4821 passed",
12719 "target_url": "https://ci.example.com/builds/4821",
12720 "updated_at": "2026-10-07T14:03:02.118Z",
12721 "source": "api"
12722 }
12723 ]
12724 }
12725 },
12726 "create_check_run": {
12727 "params": {
12728 "owner": "flagon-io",
12729 "name": "hello"
12730 },
12731 "request": {
12732 "name": "lint",
12733 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12734 "status": "completed",
12735 "conclusion": "failure",
12736 "details_url": "https://ci.example.com/builds/4821",
12737 "external_id": "4821",
12738 "output": {
12739 "title": "2 problems",
12740 "summary": "**2** problems in 1 file.",
12741 "annotations": [
12742 {
12743 "path": "src/parse.rs",
12744 "start_line": 42,
12745 "end_line": 42,
12746 "annotation_level": "warning",
12747 "message": "unused variable: `depth`"
12748 }
12749 ]
12750 },
12751 "actions": [
12752 {
12753 "label": "Fix this",
12754 "description": "Apply the suggested fixes",
12755 "identifier": "fix"
12756 }
12757 ]
12758 },
12759 "response": {
12760 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12761 "name": "lint",
12762 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12763 "status": "completed",
12764 "conclusion": "failure",
12765 "started_at": "2026-10-07T14:02:11.000Z",
12766 "completed_at": "2026-10-07T14:02:36.000Z",
12767 "details_url": "https://ci.example.com/builds/4821",
12768 "external_id": "4821",
12769 "html_url": "https://g1t.sh/flagon-io/hello/checks/cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12770 "output": {
12771 "title": "2 problems",
12772 "summary": "**2** problems in 1 file.",
12773 "text": null,
12774 "annotations_count": 2
12775 },
12776 "actions": [
12777 {
12778 "label": "Fix this",
12779 "description": "Apply the suggested fixes",
12780 "identifier": "fix"
12781 }
12782 ],
12783 "check_suite": {
12784 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p"
12785 },
12786 "app": {
12787 "slug": "buildkite",
12788 "name": "Buildkite"
12789 },
12790 "created_at": "2026-10-07T14:02:11.318Z"
12791 },
12792 "notes": "Start a run as `queued` or `in_progress` and complete it later with [`update_check_run`](/reference/api/checks/update-check-run/), or create it completed. `app` names who reports it; by default it is your token's name, and a g1t Actions job's `G1T_TOKEN` reports as g1t Actions. Each reporter's runs on a commit form one check suite. The run also stands as a status of its name, so a required check `lint` is met by it: `success`, `neutral` and `skipped` pass, any other conclusion fails. See the [Checks guide](/guides/checks/)."
12793 },
12794 "update_check_run": {
12795 "params": {
12796 "owner": "flagon-io",
12797 "name": "hello",
12798 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n"
12799 },
12800 "request": {
12801 "conclusion": "success",
12802 "output": {
12803 "title": "No problems",
12804 "summary": "All clear."
12805 }
12806 },
12807 "response": {
12808 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12809 "name": "lint",
12810 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12811 "status": "completed",
12812 "conclusion": "success",
12813 "started_at": "2026-10-07T14:02:11.000Z",
12814 "completed_at": "2026-10-07T14:02:36.000Z",
12815 "details_url": "https://ci.example.com/builds/4821",
12816 "external_id": "4821",
12817 "html_url": "https://g1t.sh/flagon-io/hello/checks/cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12818 "output": {
12819 "title": "No problems",
12820 "summary": "All clear.",
12821 "text": null,
12822 "annotations_count": 2
12823 },
12824 "actions": [
12825 {
12826 "label": "Fix this",
12827 "description": "Apply the suggested fixes",
12828 "identifier": "fix"
12829 }
12830 ],
12831 "check_suite": {
12832 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p"
12833 },
12834 "app": {
12835 "slug": "buildkite",
12836 "name": "Buildkite"
12837 },
12838 "created_at": "2026-10-07T14:02:11.318Z"
12839 },
12840 "notes": "Annotations given here are added to the ones the run has, at most 50 a request and 1000 in all."
12841 },
12842 "get_check_run": {
12843 "params": {
12844 "owner": "flagon-io",
12845 "name": "hello",
12846 "id": "job_01kq4b6a7b8c9d0e1f2g3h4j5k"
12847 },
12848 "response": {
12849 "id": "job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12850 "name": "Test",
12851 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12852 "status": "completed",
12853 "conclusion": "success",
12854 "started_at": "2026-10-07T14:01:02.000Z",
12855 "completed_at": "2026-10-07T14:01:27.000Z",
12856 "details_url": "https://g1t.sh/flagon-io/hello/actions/runs/run_01kq4b6a7b8c9d0e1f2g3h4j5m?job=job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12857 "external_id": null,
12858 "html_url": "https://g1t.sh/flagon-io/hello/actions/runs/run_01kq4b6a7b8c9d0e1f2g3h4j5m?job=job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12859 "output": {
12860 "title": null,
12861 "summary": null,
12862 "text": null,
12863 "annotations_count": 0
12864 },
12865 "actions": [],
12866 "check_suite": {
12867 "id": "run_01kq4b6a7b8c9d0e1f2g3h4j5m"
12868 },
12869 "app": {
12870 "slug": "actions",
12871 "name": "g1t Actions"
12872 },
12873 "workflow": {
12874 "run_id": "run_01kq4b6a7b8c9d0e1f2g3h4j5m",
12875 "name": "CI",
12876 "event": "push"
12877 },
12878 "created_at": "2026-10-07T14:01:00.512Z"
12879 }
12880 },
12881 "list_check_run_annotations": {
12882 "params": {
12883 "owner": "flagon-io",
12884 "name": "hello",
12885 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n"
12886 },
12887 "response": [
12888 {
12889 "path": "src/parse.rs",
12890 "start_line": 42,
12891 "end_line": 42,
12892 "start_column": 9,
12893 "end_column": 14,
12894 "annotation_level": "warning",
12895 "message": "unused variable: `depth`",
12896 "title": "unused_variables",
12897 "raw_details": "#[warn(unused_variables)] on by default"
12898 }
12899 ]
12900 },
12901 "rerequest_check_run": {
12902 "params": {
12903 "owner": "flagon-io",
12904 "name": "hello",
12905 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n"
12906 },
12907 "response": {
12908 "rerequested": true
12909 }
12910 },
12911 "list_check_runs_for_ref": {
12912 "params": {
12913 "owner": "flagon-io",
12914 "name": "hello",
12915 "ref": "main"
12916 },
12917 "query": {
12918 "filter": "latest"
12919 },
12920 "response": {
12921 "total_count": 2,
12922 "check_runs": [
12923 {
12924 "id": "cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12925 "name": "lint",
12926 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12927 "status": "completed",
12928 "conclusion": "failure",
12929 "started_at": "2026-10-07T14:02:11.000Z",
12930 "completed_at": "2026-10-07T14:02:36.000Z",
12931 "details_url": "https://ci.example.com/builds/4821",
12932 "external_id": "4821",
12933 "html_url": "https://g1t.sh/flagon-io/hello/checks/cr_01kq4b7c8d9e0f1g2h3j4k5m6n",
12934 "output": {
12935 "title": "2 problems",
12936 "summary": "**2** problems in 1 file.",
12937 "text": null,
12938 "annotations_count": 2
12939 },
12940 "actions": [
12941 {
12942 "label": "Fix this",
12943 "description": "Apply the suggested fixes",
12944 "identifier": "fix"
12945 }
12946 ],
12947 "check_suite": {
12948 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p"
12949 },
12950 "app": {
12951 "slug": "buildkite",
12952 "name": "Buildkite"
12953 },
12954 "created_at": "2026-10-07T14:02:11.318Z"
12955 },
12956 {
12957 "id": "job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12958 "name": "Test",
12959 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
12960 "status": "completed",
12961 "conclusion": "success",
12962 "started_at": "2026-10-07T14:01:02.000Z",
12963 "completed_at": "2026-10-07T14:01:27.000Z",
12964 "details_url": "https://g1t.sh/flagon-io/hello/actions/runs/run_01kq4b6a7b8c9d0e1f2g3h4j5m?job=job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12965 "external_id": null,
12966 "html_url": "https://g1t.sh/flagon-io/hello/actions/runs/run_01kq4b6a7b8c9d0e1f2g3h4j5m?job=job_01kq4b6a7b8c9d0e1f2g3h4j5k",
12967 "output": {
12968 "title": null,
12969 "summary": null,
12970 "text": null,
12971 "annotations_count": 0
12972 },
12973 "actions": [],
12974 "check_suite": {
12975 "id": "run_01kq4b6a7b8c9d0e1f2g3h4j5m"
12976 },
12977 "app": {
12978 "slug": "actions",
12979 "name": "g1t Actions"
12980 },
12981 "workflow": {
12982 "run_id": "run_01kq4b6a7b8c9d0e1f2g3h4j5m",
12983 "name": "CI",
12984 "event": "push"
12985 },
12986 "created_at": "2026-10-07T14:01:00.512Z"
12987 }
12988 ]
12989 }
12990 },
12991 "list_check_suites_for_ref": {
12992 "params": {
12993 "owner": "flagon-io",
12994 "name": "hello",
12995 "ref": "main"
12996 },
12997 "response": {
12998 "total_count": 2,
12999 "check_suites": [
13000 {
13001 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p",
13002 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
13003 "head_branch": "main",
13004 "status": "completed",
13005 "conclusion": "failure",
13006 "app": {
13007 "slug": "buildkite",
13008 "name": "Buildkite"
13009 },
13010 "latest_check_runs_count": 1,
13011 "created_at": "2026-10-07T14:02:11.318Z",
13012 "updated_at": "2026-10-07T14:02:36.502Z"
13013 },
13014 {
13015 "id": "run_01kq4b6a7b8c9d0e1f2g3h4j5m",
13016 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
13017 "head_branch": "main",
13018 "status": "completed",
13019 "conclusion": "success",
13020 "app": {
13021 "slug": "actions",
13022 "name": "g1t Actions"
13023 },
13024 "name": "CI",
13025 "latest_check_runs_count": 1,
13026 "created_at": "2026-10-07T14:01:00.512Z",
13027 "updated_at": "2026-10-07T14:01:28.040Z"
13028 }
13029 ]
13030 }
13031 },
13032 "get_check_suite": {
13033 "params": {
13034 "owner": "flagon-io",
13035 "name": "hello",
13036 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p"
13037 },
13038 "response": {
13039 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p",
13040 "head_sha": "9f3c2a1b7e6d5c4b3a2918f7e6d5c4b3a2918f7e",
13041 "head_branch": "main",
13042 "status": "completed",
13043 "conclusion": "failure",
13044 "app": {
13045 "slug": "buildkite",
13046 "name": "Buildkite"
13047 },
13048 "latest_check_runs_count": 1,
13049 "created_at": "2026-10-07T14:02:11.318Z",
13050 "updated_at": "2026-10-07T14:02:36.502Z"
13051 }
13052 },
13053 "rerequest_check_suite": {
13054 "params": {
13055 "owner": "flagon-io",
13056 "name": "hello",
13057 "id": "cs_01kq4b7c8d9e0f1g2h3j4k5m6p"
13058 },
13059 "response": {
13060 "rerequested": true
13061 }
13062 },
13063 "list_artifacts": {
13064 "params": {
13065 "owner": "flagon-io",
13066 "name": "g1t"
13067 },
13068 "query": {
13069 "name": "web-dist",
13070 "per_page": "1"
13071 },
13072 "response": {
13073 "total_count": 9,
13074 "artifacts": [
13075 {
13076 "id": 4182,
13077 "node_id": "artifact_4182",
13078 "name": "web-dist",
13079 "size_in_bytes": 18734120,
13080 "url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182",
13081 "archive_download_url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182/zip",
13082 "expired": false,
13083 "digest": "sha256:5f1c3a9e7b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a",
13084 "created_at": "2026-10-08T14:03:51.204Z",
13085 "updated_at": "2026-10-08T14:03:52.880Z",
13086 "expires_at": "2026-10-22T14:03:51.204Z",
13087 "workflow_run": {
13088 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z",
13089 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13090 "head_repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13091 "head_branch": "main",
13092 "head_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7"
13093 }
13094 }
13095 ]
13096 },
13097 "notes": "Expired and deleted artifacts are not listed. `workflow_run.id` is the run's id, which `get_workflow_run` takes."
13098 },
13099 "list_workflow_run_artifacts": {
13100 "params": {
13101 "owner": "flagon-io",
13102 "name": "g1t",
13103 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z"
13104 },
13105 "response": {
13106 "total_count": 2,
13107 "artifacts": [
13108 {
13109 "id": 4181,
13110 "node_id": "artifact_4181",
13111 "name": "coverage",
13112 "size_in_bytes": 412870,
13113 "url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4181",
13114 "archive_download_url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4181/zip",
13115 "expired": false,
13116 "digest": "sha256:5f1c3a9e7b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a",
13117 "created_at": "2026-10-08T14:03:51.204Z",
13118 "updated_at": "2026-10-08T14:03:52.880Z",
13119 "expires_at": "2026-10-22T14:03:51.204Z",
13120 "workflow_run": {
13121 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z",
13122 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13123 "head_repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13124 "head_branch": "main",
13125 "head_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7"
13126 }
13127 },
13128 {
13129 "id": 4182,
13130 "node_id": "artifact_4182",
13131 "name": "web-dist",
13132 "size_in_bytes": 18734120,
13133 "url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182",
13134 "archive_download_url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182/zip",
13135 "expired": false,
13136 "digest": "sha256:5f1c3a9e7b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a",
13137 "created_at": "2026-10-08T14:03:51.204Z",
13138 "updated_at": "2026-10-08T14:03:52.880Z",
13139 "expires_at": "2026-10-22T14:03:51.204Z",
13140 "workflow_run": {
13141 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z",
13142 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13143 "head_repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13144 "head_branch": "main",
13145 "head_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7"
13146 }
13147 }
13148 ]
13149 }
13150 },
13151 "get_artifact": {
13152 "params": {
13153 "owner": "flagon-io",
13154 "name": "g1t",
13155 "id": "4182"
13156 },
13157 "response": {
13158 "id": 4182,
13159 "node_id": "artifact_4182",
13160 "name": "web-dist",
13161 "size_in_bytes": 18734120,
13162 "url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182",
13163 "archive_download_url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182/zip",
13164 "expired": false,
13165 "digest": "sha256:5f1c3a9e7b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a",
13166 "created_at": "2026-10-08T14:03:51.204Z",
13167 "updated_at": "2026-10-08T14:03:52.880Z",
13168 "expires_at": "2026-10-22T14:03:51.204Z",
13169 "workflow_run": {
13170 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z",
13171 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13172 "head_repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13173 "head_branch": "main",
13174 "head_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7"
13175 }
13176 }
13177 },
13178 "download_artifact": {
13179 "params": {
13180 "owner": "flagon-io",
13181 "name": "g1t",
13182 "id": "4182"
13183 },
13184 "response": {
13185 "url": "https://api.g1t.sh/actions/toolkit/blobs/eyJrIjoiYXJ0aWZhY3QiLCJpIjoiNDE4MiJ9.q3VbS1x9",
13186 "expires_at": "2026-10-08T15:13:00.000Z",
13187 "artifact": {
13188 "id": 4182,
13189 "node_id": "artifact_4182",
13190 "name": "web-dist",
13191 "size_in_bytes": 18734120,
13192 "url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182",
13193 "archive_download_url": "https://api.g1t.sh/repos/flagon-io/g1t/actions/artifacts/4182/zip",
13194 "expired": false,
13195 "digest": "sha256:5f1c3a9e7b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a",
13196 "created_at": "2026-10-08T14:03:51.204Z",
13197 "updated_at": "2026-10-08T14:03:52.880Z",
13198 "expires_at": "2026-10-22T14:03:51.204Z",
13199 "workflow_run": {
13200 "id": "run_01kq9c4e6g8j0m2p4r6t8v0x2z",
13201 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13202 "head_repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13203 "head_branch": "main",
13204 "head_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7"
13205 }
13206 }
13207 },
13208 "notes": "Over REST the answer is `302 Found` with the link in `Location`, as GitHub's is, so `curl -L -o web-dist.zip …/zip` saves the file; the body above is what the MCP `workflow` tool's `download_artifact` returns. The link needs no token and stops working after 10 minutes."
13209 },
13210 "download_tarball_archive": {
13211 "params": {
13212 "owner": "flagon-io",
13213 "name": "hello",
13214 "ref": "main"
13215 },
13216 "response": {
13217 "url": "https://g1t.sh/flagon-io/hello/archive/7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7.tar.gz?token=…",
13218 "commit": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
13219 "expires_at": "2026-10-12T15:13:00.000Z"
13220 },
13221 "notes": "Over REST the answer is `302 Found` with the link in `Location`, as GitHub's is, so `curl -L -H \"Authorization: Bearer g1t_…\" -o hello.tar.gz https://api.g1t.sh/repos/flagon-io/hello/tarball/main` saves the file and `tar -xzf hello.tar.gz` makes one folder, `flagon-io-hello-7c1e9a4/`; the body above is what the MCP `repository` tool's `tarball` returns. The link is for the commit the ref named when you asked, needs no token and stops working after 10 minutes. `actions/checkout` uses this route in a job container without git."
13222 },
13223 "download_zipball_archive": {
13224 "params": {
13225 "owner": "flagon-io",
13226 "name": "hello",
13227 "ref": "v1.2.0"
13228 },
13229 "response": {
13230 "url": "https://g1t.sh/flagon-io/hello/archive/7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7.zip?token=…",
13231 "commit": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
13232 "expires_at": "2026-10-12T15:13:00.000Z"
13233 },
13234 "notes": "Over REST the answer is `302 Found` with the link in `Location`, as GitHub's is, so `curl -L -o hello.zip …/zipball/v1.2.0` saves the file, with one folder, `flagon-io-hello-7c1e9a4/`; the body above is what the MCP `repository` tool's `zipball` returns. The link needs no token and stops working after 10 minutes."
13235 },
13236 "delete_artifact": {
13237 "params": {
13238 "owner": "flagon-io",
13239 "name": "g1t",
13240 "id": "4181"
13241 },
13242 "response": {
13243 "deleted": true,
13244 "id": 4181,
13245 "name": "coverage"
13246 }
13247 },
13248 "get_artifact_retention": {
13249 "params": {
13250 "owner": "flagon-io",
13251 "name": "g1t"
13252 },
13253 "response": {
13254 "days": 14,
13255 "maximum_allowed_days": 90
13256 }
13257 },
13258 "set_artifact_retention": {
13259 "params": {
13260 "owner": "flagon-io",
13261 "name": "g1t"
13262 },
13263 "request": {
13264 "days": 30
13265 },
13266 "response": {
13267 "days": 30,
13268 "maximum_allowed_days": 90
13269 },
13270 "notes": "Only artifacts uploaded afterwards are kept the new number of days. A workflow's `retention-days` asks for fewer, never more."
13271 },
13272 "list_caches": {
13273 "params": {
13274 "owner": "flagon-io",
13275 "name": "g1t"
13276 },
13277 "query": {
13278 "key": "cargo-test-",
13279 "sort": "size_in_bytes",
13280 "per_page": "2"
13281 },
13282 "response": {
13283 "total_count": 3,
13284 "actions_caches": [
13285 {
13286 "id": 9184,
13287 "key": "cargo-test-Linux-rustc-1.99.0-5f1c3a9e7b2d",
13288 "ref": "refs/heads/main",
13289 "version": "",
13290 "size_in_bytes": 1687203840,
13291 "created_at": "2026-10-12T09:14:02.511Z",
13292 "last_accessed_at": "2026-10-12T15:40:19.087Z"
13293 },
13294 {
13295 "id": 9102,
13296 "key": "cargo-test-Linux-rustc-1.99.0-5f1c3a9e7b2d",
13297 "ref": "refs/pull/412/merge",
13298 "version": "",
13299 "size_in_bytes": 702545920,
13300 "created_at": "2026-10-12T11:02:44.930Z",
13301 "last_accessed_at": "2026-10-12T11:02:44.930Z"
13302 }
13303 ]
13304 },
13305 "notes": "`key` matches keys that start with it. Entries past their 28 days, or unused for 7, are swept within the hour and are not listed once they are."
13306 },
13307 "get_cache_usage": {
13308 "params": {
13309 "owner": "flagon-io",
13310 "name": "g1t"
13311 },
13312 "response": {
13313 "full_name": "flagon-io/g1t",
13314 "active_caches_size_in_bytes": 8813275136,
13315 "active_caches_count": 41,
13316 "quota_bytes": 10737418240
13317 },
13318 "notes": "Saving past `quota_bytes` evicts the entries restored longest ago."
13319 },
13320 "delete_caches_by_key": {
13321 "params": {
13322 "owner": "flagon-io",
13323 "name": "g1t"
13324 },
13325 "query": {
13326 "key": "cargo-test-Linux-rustc-1.99.0-5f1c3a9e7b2d",
13327 "ref": "refs/pull/412/merge"
13328 },
13329 "response": {
13330 "total_count": 1,
13331 "actions_caches": [
13332 {
13333 "id": 9102,
13334 "key": "cargo-test-Linux-rustc-1.99.0-5f1c3a9e7b2d",
13335 "ref": "refs/pull/412/merge",
13336 "version": "",
13337 "size_in_bytes": 702545920,
13338 "created_at": "2026-10-12T11:02:44.930Z",
13339 "last_accessed_at": "2026-10-12T11:02:44.930Z"
13340 }
13341 ]
13342 },
13343 "notes": "The key is matched exactly. Without `ref`, the key's entries on every ref are deleted."
13344 },
13345 "delete_cache": {
13346 "params": {
13347 "owner": "flagon-io",
13348 "name": "g1t",
13349 "id": "9102"
13350 },
13351 "notes": "Answers `204` with no body."
13352 },
13353 "list_packages": {
13354 "params": {
13355 "workspace": "acme"
13356 },
13357 "query": {
13358 "package_type": "container"
13359 },
13360 "response": [
13361 {
13362 "id": "pkg_01kq7b3d5f7h9k1m3p5r7t9v1x",
13363 "name": "web",
13364 "package_type": "container",
13365 "workspace": "acme",
13366 "address": "g1t.sh/acme/web",
13367 "visibility": "private",
13368 "repository": {
13369 "id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13370 "name": "web",
13371 "full_name": "acme/web"
13372 },
13373 "description": null,
13374 "version_count": 12,
13375 "latest": "latest",
13376 "size_in_bytes": 48211932,
13377 "download_count": 1840,
13378 "inherit_access": true,
13379 "created_at": "2026-09-14T10:02:11.000Z",
13380 "updated_at": "2026-10-08T14:05:20.000Z",
13381 "deleted_at": null,
13382 "deleted_by": null,
13383 "purge_at": null,
13384 "html_url": "https://g1t.sh/acme/-/packages/container/web"
13385 }
13386 ],
13387 "notes": "Only packages you may pull are listed. With `state=deleted`, the workspace's deleted packages you administer that can still be restored, each with `deleted_at`, `deleted_by` and `purge_at`."
13388 },
13389 "get_package": {
13390 "params": {
13391 "workspace": "acme",
13392 "package_type": "npm",
13393 "package_name": "ui"
13394 },
13395 "response": {
13396 "id": "pkg_01kq7b4e6g8j0m2p4r6t8v0x2z",
13397 "name": "ui",
13398 "package_type": "npm",
13399 "workspace": "acme",
13400 "address": "g1t.sh/-/npm/@acme/ui",
13401 "visibility": "public",
13402 "repository": {
13403 "id": "rep_01kpw0b3d5f7h9k1m3p5r7t9v1",
13404 "name": "ui",
13405 "full_name": "acme/ui"
13406 },
13407 "description": "Acme's design system components.",
13408 "version_count": 4,
13409 "latest": "2.1.0",
13410 "size_in_bytes": 391204,
13411 "download_count": 9213,
13412 "inherit_access": true,
13413 "created_at": "2026-08-02T09:30:00.000Z",
13414 "updated_at": "2026-10-07T16:44:02.000Z",
13415 "deleted_at": null,
13416 "deleted_by": null,
13417 "purge_at": null,
13418 "html_url": "https://g1t.sh/acme/-/packages/npm/ui"
13419 },
13420 "notes": "A name with a slash is one URL-encoded path segment: `/workspaces/acme/packages/container/web%2Fworker`. Not found when you may not pull it."
13421 },
13422 "update_package": {
13423 "params": {
13424 "workspace": "acme",
13425 "package_type": "container",
13426 "package_name": "web"
13427 },
13428 "request": {
13429 "inherit_access": false
13430 },
13431 "response": {
13432 "id": "pkg_01kq7b3d5f7h9k1m3p5r7t9v1x",
13433 "name": "web",
13434 "package_type": "container",
13435 "workspace": "acme",
13436 "address": "g1t.sh/acme/web",
13437 "visibility": "private",
13438 "repository": {
13439 "id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13440 "name": "web",
13441 "full_name": "acme/web"
13442 },
13443 "description": null,
13444 "version_count": 12,
13445 "latest": "latest",
13446 "size_in_bytes": 48211932,
13447 "download_count": 1840,
13448 "inherit_access": false,
13449 "created_at": "2026-09-14T10:02:11.000Z",
13450 "updated_at": "2026-10-08T15:01:40.000Z",
13451 "deleted_at": null,
13452 "deleted_by": null,
13453 "purge_at": null,
13454 "html_url": "https://g1t.sh/acme/-/packages/container/web"
13455 },
13456 "notes": "With `inherit_access` off, the repository's roles no longer reach the package: only the roles given on it (`set_package_access`) and the workspace's owners. `visibility` is for an unlinked package; a linked one has its repository's."
13457 },
13458 "delete_package": {
13459 "params": {
13460 "workspace": "acme",
13461 "package_type": "container",
13462 "package_name": "web-old"
13463 },
13464 "response": {
13465 "deleted": true
13466 },
13467 "notes": "The package and every version are gone from the registry at once. Restore it with `restore_package` within 30 days; until then nobody can publish a package of its name."
13468 },
13469 "restore_package": {
13470 "params": {
13471 "workspace": "acme",
13472 "package_type": "container",
13473 "package_name": "web-old"
13474 },
13475 "response": {
13476 "id": "pkg_01kq7b5f7h9k1m3p5r7t9v1x3z",
13477 "name": "web-old",
13478 "package_type": "container",
13479 "workspace": "acme",
13480 "address": "g1t.sh/acme/web-old",
13481 "visibility": "private",
13482 "repository": null,
13483 "description": null,
13484 "version_count": 3,
13485 "latest": "latest",
13486 "size_in_bytes": 20112840,
13487 "download_count": 112,
13488 "inherit_access": true,
13489 "created_at": "2026-07-01T08:00:00.000Z",
13490 "updated_at": "2026-10-08T15:10:00.000Z",
13491 "deleted_at": null,
13492 "deleted_by": null,
13493 "purge_at": null,
13494 "html_url": "https://g1t.sh/acme/-/packages/container/web-old"
13495 }
13496 },
13497 "list_package_versions": {
13498 "params": {
13499 "workspace": "acme",
13500 "package_type": "container",
13501 "package_name": "web"
13502 },
13503 "response": [
13504 {
13505 "id": "ver_01kq9c5f7h9k1m3p5r7t9v1x3z",
13506 "name": "sha256:9b2e4d6f8a0c1e3b5d7f9a2c4e6b8d0f1a3c5e7b9d2f4a6c8e0b1d3f5a7c9e2b",
13507 "digest": "sha256:9b2e4d6f8a0c1e3b5d7f9a2c4e6b8d0f1a3c5e7b9d2f4a6c8e0b1d3f5a7c9e2b",
13508 "size_in_bytes": 48211932,
13509 "download_count": 611,
13510 "tags": [
13511 "latest",
13512 "v1.4.0"
13513 ],
13514 "media_type": "application/vnd.oci.image.index.v1+json",
13515 "artifact_type": null,
13516 "subject": null,
13517 "platforms": [
13518 "linux/amd64",
13519 "linux/arm64"
13520 ],
13521 "published_by": "ana",
13522 "created_at": "2026-10-08T14:05:20.000Z",
13523 "deprecated": null,
13524 "deleted_at": null,
13525 "deleted_by": null,
13526 "purge_at": null
13527 }
13528 ],
13529 "notes": "A container image's versions are its manifests, named by digest; every other package's by version. `download_count` counts pulls and downloads of the version itself, approximately. With `state=deleted`, the deleted versions that can still be restored, for the package's admins."
13530 },
13531 "get_package_version": {
13532 "params": {
13533 "workspace": "acme",
13534 "package_type": "npm",
13535 "package_name": "ui",
13536 "version_id": "2.1.0"
13537 },
13538 "response": {
13539 "id": "ver_01kq9c6g8j0m2p4r6t8v0x2z4b",
13540 "name": "2.1.0",
13541 "digest": "sha256:3c5e7b9d2f4a6c8e0b1d3f5a7c9e2b4d6f8a0c1e3b5d7f9a2c4e6b8d0f1a3c5e",
13542 "size_in_bytes": 97412,
13543 "download_count": 2204,
13544 "tags": [
13545 "latest"
13546 ],
13547 "media_type": null,
13548 "artifact_type": null,
13549 "subject": null,
13550 "platforms": [],
13551 "published_by": "bo",
13552 "created_at": "2026-10-07T16:44:02.000Z",
13553 "deprecated": null,
13554 "deleted_at": null,
13555 "deleted_by": null,
13556 "purge_at": null
13557 },
13558 "notes": "`version_id` is the version's id (`ver_…`), its version, its digest, or a tag that points to it."
13559 },
13560 "delete_package_version": {
13561 "params": {
13562 "workspace": "acme",
13563 "package_type": "npm",
13564 "package_name": "ui",
13565 "version_id": "2.0.0-beta.1"
13566 },
13567 "response": {
13568 "deleted": true
13569 },
13570 "notes": "The version and its tags are gone from the registry at once. It can be restored for 30 days, and its version cannot be published again until it is purged."
13571 },
13572 "restore_package_version": {
13573 "params": {
13574 "workspace": "acme",
13575 "package_type": "npm",
13576 "package_name": "ui",
13577 "version_id": "2.0.0-beta.1"
13578 },
13579 "response": {
13580 "id": "ver_01kq9c7h9k1m3p5r7t9v1x3z5c",
13581 "name": "2.0.0-beta.1",
13582 "digest": "sha256:7d9f2a4c6e8b0d1f3a5c7e9b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f",
13583 "size_in_bytes": 96880,
13584 "download_count": 41,
13585 "tags": [
13586 "beta"
13587 ],
13588 "media_type": null,
13589 "artifact_type": null,
13590 "subject": null,
13591 "platforms": [],
13592 "published_by": "bo",
13593 "created_at": "2026-09-30T11:20:00.000Z",
13594 "deprecated": null,
13595 "deleted_at": null,
13596 "deleted_by": null,
13597 "purge_at": null
13598 },
13599 "notes": "Tags that pointed to it come back with it, unless one was moved to another version meanwhile."
13600 },
13601 "link_package": {
13602 "params": {
13603 "workspace": "acme",
13604 "package_type": "container",
13605 "package_name": "tools"
13606 },
13607 "request": {
13608 "repository": "acme/infra"
13609 },
13610 "response": {
13611 "id": "pkg_01kq7b6g8j0m2p4r6t8v0x2z4b",
13612 "name": "tools",
13613 "package_type": "container",
13614 "workspace": "acme",
13615 "address": "g1t.sh/acme/tools",
13616 "visibility": "private",
13617 "repository": {
13618 "id": "rep_01kpw0c4e6g8j0m2p4r6t8v0x2",
13619 "name": "infra",
13620 "full_name": "acme/infra"
13621 },
13622 "description": null,
13623 "version_count": 2,
13624 "latest": "latest",
13625 "size_in_bytes": 7340032,
13626 "download_count": 88,
13627 "inherit_access": true,
13628 "created_at": "2026-09-20T12:00:00.000Z",
13629 "updated_at": "2026-10-08T15:20:00.000Z",
13630 "deleted_at": null,
13631 "deleted_by": null,
13632 "purge_at": null,
13633 "html_url": "https://g1t.sh/acme/-/packages/container/tools"
13634 },
13635 "notes": "The package takes the repository's visibility. You need the Admin role on the package and on the repository."
13636 },
13637 "unlink_package": {
13638 "params": {
13639 "workspace": "acme",
13640 "package_type": "container",
13641 "package_name": "tools"
13642 },
13643 "response": {
13644 "id": "pkg_01kq7b6g8j0m2p4r6t8v0x2z4b",
13645 "name": "tools",
13646 "package_type": "container",
13647 "workspace": "acme",
13648 "address": "g1t.sh/acme/tools",
13649 "visibility": "private",
13650 "repository": null,
13651 "description": null,
13652 "version_count": 2,
13653 "latest": "latest",
13654 "size_in_bytes": 7340032,
13655 "download_count": 88,
13656 "inherit_access": true,
13657 "created_at": "2026-09-20T12:00:00.000Z",
13658 "updated_at": "2026-10-08T15:22:00.000Z",
13659 "deleted_at": null,
13660 "deleted_by": null,
13661 "purge_at": null,
13662 "html_url": "https://g1t.sh/acme/-/packages/container/tools"
13663 }
13664 },
13665 "list_package_access": {
13666 "params": {
13667 "workspace": "acme",
13668 "package_type": "container",
13669 "package_name": "web"
13670 },
13671 "response": {
13672 "inherit_access": true,
13673 "access": [
13674 {
13675 "type": "team",
13676 "id": "team_01kq1a3c5e7g9j1l3n5q7s9u1w",
13677 "name": "acme/platform",
13678 "role": "admin",
13679 "created_at": "2026-10-01T09:00:00.000Z"
13680 },
13681 {
13682 "type": "user",
13683 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13684 "name": "dana",
13685 "role": "read",
13686 "created_at": "2026-10-02T13:30:00.000Z"
13687 }
13688 ]
13689 },
13690 "notes": "Only the roles given on the package itself. With `inherit_access` on, a linked package's repository roles count too, and the workspace's owners administer every package."
13691 },
13692 "set_package_access": {
13693 "params": {
13694 "workspace": "acme",
13695 "package_type": "container",
13696 "package_name": "web"
13697 },
13698 "request": {
13699 "username": "dana",
13700 "role": "write"
13701 },
13702 "response": [
13703 {
13704 "type": "team",
13705 "id": "team_01kq1a3c5e7g9j1l3n5q7s9u1w",
13706 "name": "acme/platform",
13707 "role": "admin",
13708 "created_at": "2026-10-01T09:00:00.000Z"
13709 },
13710 {
13711 "type": "user",
13712 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13713 "name": "dana",
13714 "role": "write",
13715 "created_at": "2026-10-02T13:30:00.000Z"
13716 }
13717 ],
13718 "notes": "Give `username` or `team` (a team of the workspace, by slug). The role adds to what the repository or workspace already gives."
13719 },
13720 "remove_package_access": {
13721 "params": {
13722 "workspace": "acme",
13723 "package_type": "container",
13724 "package_name": "web"
13725 },
13726 "query": {
13727 "username": "dana"
13728 },
13729 "response": [
13730 {
13731 "type": "team",
13732 "id": "team_01kq1a3c5e7g9j1l3n5q7s9u1w",
13733 "name": "acme/platform",
13734 "role": "admin",
13735 "created_at": "2026-10-01T09:00:00.000Z"
13736 }
13737 ],
13738 "notes": "Over REST, name who in the query: `?username=dana` or `?team=platform`."
13739 },
13740 "list_package_actions_access": {
13741 "params": {
13742 "workspace": "acme",
13743 "package_type": "container",
13744 "package_name": "web"
13745 },
13746 "response": {
13747 "repositories": [
13748 {
13749 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13750 "repository": "acme/web",
13751 "role": "write",
13752 "linked": true,
13753 "created_at": null
13754 },
13755 {
13756 "repository_id": "rep_01kpw0d5f7h9k1m3p5r7t9v1x3",
13757 "repository": "acme/deploy",
13758 "role": "read",
13759 "linked": false,
13760 "created_at": "2026-10-03T10:00:00.000Z"
13761 }
13762 ]
13763 },
13764 "notes": "A workflow job's `G1T_TOKEN` reaches the package only from these repositories. The linked repository is always listed, with write."
13765 },
13766 "set_package_actions_access": {
13767 "params": {
13768 "workspace": "acme",
13769 "package_type": "container",
13770 "package_name": "web"
13771 },
13772 "request": {
13773 "repository": "deploy",
13774 "role": "read"
13775 },
13776 "response": {
13777 "repositories": [
13778 {
13779 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13780 "repository": "acme/web",
13781 "role": "write",
13782 "linked": true,
13783 "created_at": null
13784 },
13785 {
13786 "repository_id": "rep_01kpw0d5f7h9k1m3p5r7t9v1x3",
13787 "repository": "acme/deploy",
13788 "role": "read",
13789 "linked": false,
13790 "created_at": "2026-10-03T10:00:00.000Z"
13791 }
13792 ]
13793 }
13794 },
13795 "remove_package_actions_access": {
13796 "params": {
13797 "workspace": "acme",
13798 "package_type": "container",
13799 "package_name": "web",
13800 "repository": "deploy"
13801 },
13802 "response": {
13803 "repositories": [
13804 {
13805 "repository_id": "rep_01kpw0a2c4e6g8j0m2p4r6t8v0",
13806 "repository": "acme/web",
13807 "role": "write",
13808 "linked": true,
13809 "created_at": null
13810 }
13811 ]
13812 }
13813 },
13814 "list_workspace_artifacts": {
13815 "params": {
13816 "workspace": "acme"
13817 },
13818 "query": {
13819 "kind": "doc",
13820 "space": "general"
13821 },
13822 "response": {
13823 "items": [
13824 {
13825 "id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13826 "kind": "doc",
13827 "title": "Q4 roadmap",
13828 "icon": "🗺️",
13829 "slug": "q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13830 "space": {
13831 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
13832 "slug": "general",
13833 "name": "General",
13834 "kind": "workspace"
13835 },
13836 "parent_id": null,
13837 "has_children": false,
13838 "owner": {
13839 "type": "user",
13840 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13841 "username": "ana",
13842 "display_name": "Ana Lima"
13843 },
13844 "created_by": {
13845 "type": "user",
13846 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13847 "username": "ana",
13848 "display_name": "Ana Lima"
13849 },
13850 "created_at": "2026-10-06T09:12:00.000Z",
13851 "updated_at": "2026-10-08T16:40:12.000Z",
13852 "edited_by": {
13853 "type": "user",
13854 "id": "usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
13855 "username": "bo",
13856 "display_name": "Bo Chen"
13857 },
13858 "edited_at": "2026-10-08T16:40:12.000Z",
13859 "trashed_at": null,
13860 "viewer_role": "manage",
13861 "private": false,
13862 "shared_count": 1,
13863 "general_access": "workspace",
13864 "general_role": "view",
13865 "inherit": true,
13866 "agent_mode": "suggest",
13867 "excerpt": "What we ship this quarter, and what we leave for next.",
13868 "source": null,
13869 "stale": false,
13870 "html_url": "https://g1t.sh/acme/-/artifacts/q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
13871 }
13872 ],
13873 "next_cursor": null
13874 },
13875 "notes": "Only artifacts you can open are listed, with `viewer_role` your own role on each. Page on with `cursor` set to `next_cursor` until it is null. With `state=trashed`, what you can restore from the trash. With `q`, the best matches first. These are Artifacts mode's docs, slides, designs and dashboards, not workflow runs' artifacts (`list_artifacts`)."
13876 },
13877 "search_workspace_artifacts": {
13878 "params": {
13879 "workspace": "acme"
13880 },
13881 "query": {
13882 "q": "what ships in Q4"
13883 },
13884 "response": [
13885 {
13886 "id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13887 "kind": "doc",
13888 "title": "Q4 roadmap",
13889 "icon": "🗺️",
13890 "slug": "q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13891 "html_url": "https://g1t.sh/acme/-/artifacts/q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13892 "space_name": "General",
13893 "snippet": "We ship the merge queue and Artifacts in Q4; dashboards follow.",
13894 "heading": "This quarter",
13895 "matched": "both",
13896 "edited_at": "2026-10-08T16:40:12.000Z"
13897 }
13898 ],
13899 "notes": "Matches words and meaning, and is checked again against who can read each artifact now: one shared with you a minute ago is found, one taken away is not."
13900 },
13901 "get_workspace_artifact": {
13902 "params": {
13903 "workspace": "acme",
13904 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
13905 },
13906 "response": {
13907 "id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13908 "kind": "doc",
13909 "title": "Q4 roadmap",
13910 "icon": "🗺️",
13911 "slug": "q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13912 "space": {
13913 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
13914 "slug": "general",
13915 "name": "General",
13916 "kind": "workspace"
13917 },
13918 "parent_id": null,
13919 "has_children": false,
13920 "owner": {
13921 "type": "user",
13922 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13923 "username": "ana",
13924 "display_name": "Ana Lima"
13925 },
13926 "created_by": {
13927 "type": "user",
13928 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
13929 "username": "ana",
13930 "display_name": "Ana Lima"
13931 },
13932 "created_at": "2026-10-06T09:12:00.000Z",
13933 "updated_at": "2026-10-08T16:40:12.000Z",
13934 "edited_by": {
13935 "type": "user",
13936 "id": "usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
13937 "username": "bo",
13938 "display_name": "Bo Chen"
13939 },
13940 "edited_at": "2026-10-08T16:40:12.000Z",
13941 "trashed_at": null,
13942 "viewer_role": "manage",
13943 "private": false,
13944 "shared_count": 1,
13945 "general_access": "workspace",
13946 "general_role": "view",
13947 "inherit": true,
13948 "agent_mode": "suggest",
13949 "excerpt": "What we ship this quarter, and what we leave for next.",
13950 "source": null,
13951 "stale": false,
13952 "html_url": "https://g1t.sh/acme/-/artifacts/q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
13953 },
13954 "notes": "`artifact_id` is the id, or the artifact's address (`q4-roadmap-fol_…`, or its whole link). Not found when you cannot open it, the same as when it does not exist."
13955 },
13956 "get_workspace_artifact_content": {
13957 "params": {
13958 "workspace": "acme",
13959 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
13960 },
13961 "response": {
13962 "artifact": {
13963 "id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13964 "kind": "doc",
13965 "title": "Q4 roadmap",
13966 "icon": "🗺️",
13967 "slug": "q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13968 "html_url": "https://g1t.sh/acme/-/artifacts/q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
13969 "edited_at": "2026-10-08T16:40:12.000Z"
13970 },
13971 "space": {
13972 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
13973 "slug": "general",
13974 "name": "General",
13975 "agent_mode": "suggest"
13976 },
13977 "content": "# Q4 roadmap\n\n## This quarter\n\nWe ship the merge queue and Artifacts.\n",
13978 "blocks": [
13979 {
13980 "id": "b_4f1c",
13981 "type": "heading",
13982 "level": 1,
13983 "markdown": "# Q4 roadmap"
13984 },
13985 {
13986 "id": "b_9a02",
13987 "type": "heading",
13988 "level": 2,
13989 "markdown": "## This quarter"
13990 },
13991 {
13992 "id": "b_77d3",
13993 "type": "paragraph",
13994 "level": null,
13995 "markdown": "We ship the merge queue and Artifacts."
13996 }
13997 ],
13998 "can": {
13999 "read": true,
14000 "suggest": true,
14001 "edit": true
14002 }
14003 },
14004 "notes": "A doc's content is Markdown. `blocks` are its top-level blocks, whose ids an edit with a `blocks` target names. Slides, designs and dashboards answer `422` saying they are not here yet."
14005 },
14006 "list_workspace_artifact_versions": {
14007 "params": {
14008 "workspace": "acme",
14009 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
14010 },
14011 "response": [
14012 {
14013 "id": "ver_01kq9e6g8j0m2p4r6t8v0x2z4b",
14014 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14015 "created_at": "2026-10-08T16:40:12.000Z",
14016 "kind": "edit",
14017 "note": null,
14018 "authors": [
14019 {
14020 "type": "user",
14021 "id": "usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
14022 "username": "bo",
14023 "display_name": "Bo Chen"
14024 }
14025 ]
14026 },
14027 {
14028 "id": "ver_01kq7c4e6g8j0m2p4r6t8v0x2y",
14029 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14030 "created_at": "2026-10-06T09:12:00.000Z",
14031 "kind": "created",
14032 "note": null,
14033 "authors": [
14034 {
14035 "type": "user",
14036 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14037 "username": "ana",
14038 "display_name": "Ana Lima"
14039 }
14040 ]
14041 }
14042 ]
14043 },
14044 "get_workspace_artifact_access": {
14045 "params": {
14046 "workspace": "acme",
14047 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
14048 },
14049 "response": {
14050 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14051 "owner": {
14052 "type": "user",
14053 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14054 "username": "ana",
14055 "display_name": "Ana Lima"
14056 },
14057 "shared_with": [
14058 {
14059 "principal": "user:usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
14060 "member": {
14061 "type": "user",
14062 "id": "usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
14063 "username": "bo",
14064 "display_name": "Bo Chen"
14065 },
14066 "role": "edit",
14067 "inherited_from": null
14068 },
14069 {
14070 "principal": "team:design",
14071 "member": {
14072 "type": "team",
14073 "slug": "design",
14074 "display_name": "@acme/design"
14075 },
14076 "role": "comment",
14077 "inherited_from": null
14078 }
14079 ],
14080 "general_access": "workspace",
14081 "general_role": "view",
14082 "inherit": true,
14083 "inherited_from": {
14084 "type": "space",
14085 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
14086 "name": "General"
14087 },
14088 "agent_mode": null,
14089 "can_share": true
14090 },
14091 "notes": "Its owner always has full access and is not in `shared_with`. `inherited_from` on a row is the doc above it that gives that access; on the whole list, the space or doc it follows while `inherit` is true."
14092 },
14093 "list_workspace_artifact_templates": {
14094 "params": {
14095 "workspace": "acme"
14096 },
14097 "query": {
14098 "kind": "doc"
14099 },
14100 "response": [
14101 {
14102 "id": "builtin:doc:meeting-notes",
14103 "kind": "doc",
14104 "name": "Meeting notes",
14105 "description": "Who came, what was decided, and what happens next.",
14106 "icon": "📝",
14107 "builtin": true,
14108 "body": "# Meeting notes\n\n## Attendees\n\n## Decisions\n\n## Next steps\n"
14109 }
14110 ]
14111 },
14112 "list_workspace_artifact_spaces": {
14113 "params": {
14114 "workspace": "acme"
14115 },
14116 "response": [
14117 {
14118 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
14119 "slug": "general",
14120 "name": "General",
14121 "description": null,
14122 "icon": null,
14123 "kind": "workspace",
14124 "is_default": true,
14125 "joined": true,
14126 "viewer_role": "edit",
14127 "artifact_count": 14
14128 },
14129 {
14130 "id": "spc_01kq2b4d6f8h0k2m4p6r8t0v2x",
14131 "slug": "design",
14132 "name": "Design",
14133 "description": "The design team's specs.",
14134 "icon": "🎨",
14135 "kind": "team",
14136 "is_default": false,
14137 "joined": true,
14138 "viewer_role": "view",
14139 "artifact_count": 6
14140 }
14141 ],
14142 "notes": "Open spaces show once you join them in Artifacts; General always shows. Give a space's `slug` or `id` as `space` to the other artifact calls."
14143 },
14144 "query_workspace_dataset": {
14145 "params": {
14146 "workspace": "acme"
14147 },
14148 "request": {
14149 "query": {
14150 "dataset": "pull_requests",
14151 "measure": {
14152 "op": "count"
14153 },
14154 "group_by": "repo",
14155 "range": {
14156 "from": "2026-09-01",
14157 "to": "2026-09-30"
14158 }
14159 }
14160 },
14161 "response": {
14162 "columns": [
14163 {
14164 "name": "repo",
14165 "type": "string"
14166 },
14167 {
14168 "name": "count",
14169 "type": "number"
14170 }
14171 ],
14172 "rows": [
14173 [
14174 "acme/web",
14175 42
14176 ],
14177 [
14178 "acme/api",
14179 7
14180 ]
14181 ],
14182 "truncated": false,
14183 "partial": false,
14184 "as_of": "2026-10-09T12:00:00.000Z"
14185 },
14186 "notes": "Runs as you, over what you can read: `partial` is true when some of it was left out because you cannot read it. Until dashboards ship this answers `422` saying they are not here yet."
14187 },
14188 "create_workspace_artifact": {
14189 "params": {
14190 "workspace": "acme"
14191 },
14192 "request": {
14193 "kind": "doc",
14194 "title": "Release notes",
14195 "markdown": "# Release notes\n\nWhat changed in 2.4.\n"
14196 },
14197 "response": {
14198 "id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14199 "kind": "doc",
14200 "title": "Release notes",
14201 "icon": null,
14202 "slug": "release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14203 "space": null,
14204 "parent_id": null,
14205 "has_children": false,
14206 "owner": {
14207 "type": "user",
14208 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14209 "username": "ana",
14210 "display_name": "Ana Lima"
14211 },
14212 "created_by": {
14213 "type": "user",
14214 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14215 "username": "ana",
14216 "display_name": "Ana Lima"
14217 },
14218 "created_at": "2026-10-09T10:00:00.000Z",
14219 "updated_at": "2026-10-09T10:00:00.000Z",
14220 "edited_by": null,
14221 "edited_at": "2026-10-09T10:00:00.000Z",
14222 "trashed_at": null,
14223 "viewer_role": "manage",
14224 "private": true,
14225 "shared_count": 0,
14226 "general_access": "none",
14227 "general_role": null,
14228 "inherit": true,
14229 "agent_mode": null,
14230 "excerpt": "What changed in 2.4.",
14231 "source": null,
14232 "stale": false,
14233 "html_url": "https://g1t.sh/acme/-/artifacts/release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14234 },
14235 "notes": "Left out `space` and `parent_id`, it lands in your Private, where only you can open it until you share it. `kind` is `doc` until slides, designs and dashboards ship; they answer `422` saying they are not here yet."
14236 },
14237 "update_workspace_artifact": {
14238 "params": {
14239 "workspace": "acme",
14240 "artifact_id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14241 },
14242 "request": {
14243 "title": "Release notes 2.4",
14244 "space": "general"
14245 },
14246 "response": {
14247 "id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14248 "kind": "doc",
14249 "title": "Release notes 2.4",
14250 "icon": null,
14251 "slug": "release-notes-2-4-fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14252 "space": {
14253 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
14254 "slug": "general",
14255 "name": "General",
14256 "kind": "workspace"
14257 },
14258 "parent_id": null,
14259 "has_children": false,
14260 "owner": {
14261 "type": "user",
14262 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14263 "username": "ana",
14264 "display_name": "Ana Lima"
14265 },
14266 "created_by": {
14267 "type": "user",
14268 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14269 "username": "ana",
14270 "display_name": "Ana Lima"
14271 },
14272 "created_at": "2026-10-09T10:00:00.000Z",
14273 "updated_at": "2026-10-09T10:00:00.000Z",
14274 "edited_by": null,
14275 "edited_at": "2026-10-09T10:00:00.000Z",
14276 "trashed_at": null,
14277 "viewer_role": "manage",
14278 "private": false,
14279 "shared_count": 0,
14280 "general_access": "none",
14281 "general_role": null,
14282 "inherit": true,
14283 "agent_mode": null,
14284 "excerpt": "What changed in 2.4.",
14285 "source": null,
14286 "stale": false,
14287 "html_url": "https://g1t.sh/acme/-/artifacts/release-notes-2-4-fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14288 },
14289 "notes": "Moving it into a space it follows (`inherit`) gives the space's members its access. `space` set to `private` moves it to the top of your Private, which only its owner can do."
14290 },
14291 "edit_workspace_artifact": {
14292 "params": {
14293 "workspace": "acme",
14294 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
14295 },
14296 "request": {
14297 "target": {
14298 "kind": "section",
14299 "heading": "This quarter"
14300 },
14301 "markdown": "## This quarter\n\nWe ship the merge queue, Artifacts and the API for both.\n",
14302 "note": "Adds the API"
14303 },
14304 "response": {
14305 "mode": "applied",
14306 "artifact": {
14307 "id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14308 "kind": "doc",
14309 "title": "Q4 roadmap",
14310 "icon": "🗺️",
14311 "slug": "q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14312 "html_url": "https://g1t.sh/acme/-/artifacts/q4-roadmap-fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
14313 },
14314 "version_id": "ver_01kqa7h9k1n3q5s7u9w1y3a5c",
14315 "summary": "Replaced the section This quarter."
14316 },
14317 "notes": "With only the comment role, or with `suggest_only`, the change is filed as a suggestion instead: `mode` is `suggested`, with the `suggestion` its editors accept or reject. A target that is not there any more answers `404`: read the content again."
14318 },
14319 "trash_workspace_artifact": {
14320 "params": {
14321 "workspace": "acme",
14322 "artifact_id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14323 },
14324 "response": {
14325 "id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14326 "kind": "doc",
14327 "title": "Release notes",
14328 "icon": null,
14329 "slug": "release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14330 "space": null,
14331 "parent_id": null,
14332 "has_children": false,
14333 "owner": {
14334 "type": "user",
14335 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14336 "username": "ana",
14337 "display_name": "Ana Lima"
14338 },
14339 "created_by": {
14340 "type": "user",
14341 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14342 "username": "ana",
14343 "display_name": "Ana Lima"
14344 },
14345 "created_at": "2026-10-09T10:00:00.000Z",
14346 "updated_at": "2026-10-09T10:00:00.000Z",
14347 "edited_by": null,
14348 "edited_at": "2026-10-09T10:00:00.000Z",
14349 "trashed_at": "2026-10-09T11:30:00.000Z",
14350 "viewer_role": "manage",
14351 "private": true,
14352 "shared_count": 0,
14353 "general_access": "none",
14354 "general_role": null,
14355 "inherit": true,
14356 "agent_mode": null,
14357 "excerpt": "What changed in 2.4.",
14358 "source": null,
14359 "stale": false,
14360 "html_url": "https://g1t.sh/acme/-/artifacts/release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14361 },
14362 "notes": "Everything under it goes to the trash with it. It is deleted for good 30 days later, or with `purge_workspace_artifact`."
14363 },
14364 "restore_workspace_artifact": {
14365 "params": {
14366 "workspace": "acme",
14367 "artifact_id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14368 },
14369 "response": {
14370 "id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14371 "kind": "doc",
14372 "title": "Release notes",
14373 "icon": null,
14374 "slug": "release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a",
14375 "space": null,
14376 "parent_id": null,
14377 "has_children": false,
14378 "owner": {
14379 "type": "user",
14380 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14381 "username": "ana",
14382 "display_name": "Ana Lima"
14383 },
14384 "created_by": {
14385 "type": "user",
14386 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14387 "username": "ana",
14388 "display_name": "Ana Lima"
14389 },
14390 "created_at": "2026-10-09T10:00:00.000Z",
14391 "updated_at": "2026-10-09T10:00:00.000Z",
14392 "edited_by": null,
14393 "edited_at": "2026-10-09T10:00:00.000Z",
14394 "trashed_at": null,
14395 "viewer_role": "manage",
14396 "private": true,
14397 "shared_count": 0,
14398 "general_access": "none",
14399 "general_role": null,
14400 "inherit": true,
14401 "agent_mode": null,
14402 "excerpt": "What changed in 2.4.",
14403 "source": null,
14404 "stale": false,
14405 "html_url": "https://g1t.sh/acme/-/artifacts/release-notes-fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14406 }
14407 },
14408 "restore_workspace_artifact_version": {
14409 "params": {
14410 "workspace": "acme",
14411 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14412 "version_id": "ver_01kq7c4e6g8j0m2p4r6t8v0x2y"
14413 },
14414 "response": {
14415 "id": "ver_01kqb8j0m2p4r6t8v0x2z4b6d",
14416 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14417 "created_at": "2026-10-09T12:00:00.000Z",
14418 "kind": "restore",
14419 "note": null,
14420 "authors": [
14421 {
14422 "type": "user",
14423 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14424 "username": "ana",
14425 "display_name": "Ana Lima"
14426 }
14427 ]
14428 }
14429 },
14430 "set_workspace_artifact_access": {
14431 "params": {
14432 "workspace": "acme",
14433 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z"
14434 },
14435 "request": {
14436 "username": "bo",
14437 "role": "edit",
14438 "notify": "Can you fill in the dates?"
14439 },
14440 "response": {
14441 "artifact_id": "fol_01kq7c4e6g8j0m2p4r6t8v0x2z",
14442 "owner": {
14443 "type": "user",
14444 "id": "usr_01kkntcg1eeb98j62xjm7eh09q",
14445 "username": "ana",
14446 "display_name": "Ana Lima"
14447 },
14448 "shared_with": [
14449 {
14450 "principal": "user:usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
14451 "member": {
14452 "type": "user",
14453 "id": "usr_01kmb2d4f6h8k0m2p4r6t8v0x2",
14454 "username": "bo",
14455 "display_name": "Bo Chen"
14456 },
14457 "role": "edit",
14458 "inherited_from": null
14459 },
14460 {
14461 "principal": "team:design",
14462 "member": {
14463 "type": "team",
14464 "slug": "design",
14465 "display_name": "@acme/design"
14466 },
14467 "role": "comment",
14468 "inherited_from": null
14469 }
14470 ],
14471 "general_access": "workspace",
14472 "general_role": "view",
14473 "inherit": true,
14474 "inherited_from": {
14475 "type": "space",
14476 "id": "spc_01kq1a3c5e7g9j1l3n5q7s9u1w",
14477 "name": "General"
14478 },
14479 "agent_mode": null,
14480 "can_share": true
14481 },
14482 "notes": "One call can share with one person, team or agent, and change `general_access`, `inherit` and `agent_mode`, in that order. `role` set to `none` takes someone's access away. General access never gives full access. On an artifact that follows the doc it is under, change general access on that doc, or set `inherit` to false first."
14483 },
14484 "purge_workspace_artifact": {
14485 "params": {
14486 "workspace": "acme",
14487 "artifact_id": "fol_01kq8d5f7h9k1n3q5s7u9w1y3a"
14488 },
14489 "response": {
14490 "deleted": true
14491 },
14492 "notes": "Only an artifact in the trash can be deleted for good: `trash_workspace_artifact` first."
14493 },
14494 "get_observability_overview": {
14495 "params": {
14496 "workspace": "flagon-io",
14497 "project": "g1t"
14498 },
14499 "query": {
14500 "from": "2026-10-12T13:00:00Z",
14501 "to": "2026-10-12T14:00:00Z",
14502 "environment": "production"
14503 },
14504 "response": {
14505 "from_us": 1791810000000000,
14506 "to_us": 1791813600000000,
14507 "step_s": 60,
14508 "totals": {
14509 "requests": 18204,
14510 "errors": 41,
14511 "error_rate": 0.0023,
14512 "latency": {
14513 "p50": 38.2,
14514 "p75": 71.5,
14515 "p95": 212.0,
14516 "p99": 640.0
14517 },
14518 "cpu": {
14519 "p50": 4.1,
14520 "p75": 6.8,
14521 "p95": 14.2,
14522 "p99": 29.5
14523 }
14524 },
14525 "previous": {
14526 "requests": 17650,
14527 "errors": 3,
14528 "error_rate": 0.0002,
14529 "latency": {
14530 "p50": 35.9,
14531 "p75": 66.0,
14532 "p95": 188.0,
14533 "p99": 402.0
14534 },
14535 "cpu": {
14536 "p50": 3.9,
14537 "p75": 6.5,
14538 "p95": 13.0,
14539 "p99": 22.1
14540 }
14541 },
14542 "points": [
14543 {
14544 "time_us": 1791810000000000,
14545 "requests": 302,
14546 "errors": 0,
14547 "status_2xx": 288,
14548 "status_3xx": 9,
14549 "status_4xx": 5,
14550 "status_5xx": 0,
14551 "latency": {
14552 "p50": 36.0,
14553 "p75": 68.0,
14554 "p95": 190.0,
14555 "p99": 410.0
14556 },
14557 "cpu": {
14558 "p50": 4.0,
14559 "p75": 6.6,
14560 "p95": 13.1,
14561 "p99": 22.0
14562 }
14563 }
14564 ],
14565 "routes": [
14566 {
14567 "route": "/:workspace/:repo/pulls/:number",
14568 "method": "GET",
14569 "requests": 2210,
14570 "errors": 37,
14571 "latency": {
14572 "p50": 61.0,
14573 "p75": 120.0,
14574 "p95": 480.0,
14575 "p99": 842.0
14576 }
14577 }
14578 ],
14579 "deployments": [
14580 {
14581 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14582 "environment": "production",
14583 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14584 "first_us": 1791813041000000,
14585 "requests": 2904,
14586 "errors": 39,
14587 "latency": {
14588 "p50": 40.1,
14589 "p75": 77.0,
14590 "p95": 260.0,
14591 "p99": 720.0
14592 }
14593 }
14594 ],
14595 "services": [
14596 {
14597 "service": "g1t-web",
14598 "source": "cloudflare",
14599 "requests": 18204,
14600 "errors": 41,
14601 "last_us": 1791813599000000
14602 }
14603 ],
14604 "regions": [
14605 {
14606 "region": "IAD",
14607 "requests": 9120
14608 },
14609 {
14610 "region": "AMS",
14611 "requests": 4410
14612 }
14613 ]
14614 },
14615 "notes": "`totals` is the period and `previous` the period of the same length before it, to compare. Latency and CPU are in milliseconds. `deployments` lists each deployment that answered in the period, newest first: when the error rate or latency rose, the deployment it began with is usually the first one with the higher numbers. Points are one per `step_s` seconds, chosen from the period unless `step` says. See [Observability](/guides/observability/)."
14616 },
14617 "list_requests": {
14618 "params": {
14619 "workspace": "flagon-io",
14620 "project": "g1t"
14621 },
14622 "query": {
14623 "errors_only": "true",
14624 "limit": "1"
14625 },
14626 "response": {
14627 "items": [
14628 {
14629 "id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14630 "time_us": 1791813807418000,
14631 "duration_us": 842000,
14632 "trigger": "fetch",
14633 "method": "GET",
14634 "url": "g1t.sh/flagon-io/g1t/pulls/412",
14635 "route": "/:workspace/:repo/pulls/:number",
14636 "status": 500,
14637 "outcome": "exception",
14638 "cpu_ms": 31.4,
14639 "region": "IAD",
14640 "country": "US",
14641 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14642 "log_count": 2,
14643 "error": {
14644 "name": "TypeError",
14645 "message": "Cannot read properties of undefined (reading 'head')"
14646 },
14647 "service": "g1t-web",
14648 "environment": "production",
14649 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14650 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14651 "source": "cloudflare"
14652 }
14653 ],
14654 "next": "eyJ0IjoxNzkxODEzODA3NDE4MDAwfQ"
14655 },
14656 "notes": "Apps on g1t.page send their requests with nothing to set up; software hosted elsewhere sends them as OpenTelemetry server spans. `route` is the path with ids taken out, which the overview groups by. Pass `next` back as `cursor` for the next page; it is null on the last."
14657 },
14658 "get_request": {
14659 "params": {
14660 "workspace": "flagon-io",
14661 "project": "g1t",
14662 "id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x"
14663 },
14664 "response": {
14665 "request": {
14666 "id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14667 "time_us": 1791813807418000,
14668 "duration_us": 842000,
14669 "trigger": "fetch",
14670 "method": "GET",
14671 "url": "g1t.sh/flagon-io/g1t/pulls/412",
14672 "route": "/:workspace/:repo/pulls/:number",
14673 "status": 500,
14674 "outcome": "exception",
14675 "cpu_ms": 31.4,
14676 "region": "IAD",
14677 "country": "US",
14678 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14679 "log_count": 2,
14680 "error": {
14681 "name": "TypeError",
14682 "message": "Cannot read properties of undefined (reading 'head')"
14683 },
14684 "service": "g1t-web",
14685 "environment": "production",
14686 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14687 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14688 "source": "cloudflare"
14689 },
14690 "logs": [
14691 {
14692 "id": "log_01kq9b7d9f1h3k5m7p9r1t3v5y",
14693 "time_us": 1791813808251000,
14694 "severity": "error",
14695 "severity_number": 17,
14696 "body": "loading pull request 412 failed: Cannot read properties of undefined (reading 'head')",
14697 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14698 "span_id": "00f067aa0ba902b7",
14699 "request_id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14700 "attributes": {
14701 "code.function": "loadPull",
14702 "http.route": "/:workspace/:repo/pulls/:number"
14703 },
14704 "service": "g1t-web",
14705 "environment": "production",
14706 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14707 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14708 "source": "cloudflare"
14709 }
14710 ]
14711 },
14712 "notes": "`404` when the project has no request with that id, or it is older than the project's retention."
14713 },
14714 "list_logs": {
14715 "params": {
14716 "workspace": "flagon-io",
14717 "project": "g1t"
14718 },
14719 "query": {
14720 "q": "\"failed\"",
14721 "level": "error,fatal",
14722 "limit": "1"
14723 },
14724 "response": {
14725 "items": [
14726 {
14727 "id": "log_01kq9b7d9f1h3k5m7p9r1t3v5y",
14728 "time_us": 1791813808251000,
14729 "severity": "error",
14730 "severity_number": 17,
14731 "body": "loading pull request 412 failed: Cannot read properties of undefined (reading 'head')",
14732 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14733 "span_id": "00f067aa0ba902b7",
14734 "request_id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14735 "attributes": {
14736 "code.function": "loadPull",
14737 "http.route": "/:workspace/:repo/pulls/:number"
14738 },
14739 "service": "g1t-web",
14740 "environment": "production",
14741 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14742 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14743 "source": "cloudflare"
14744 }
14745 ],
14746 "next": null
14747 },
14748 "notes": "`q` finds lines holding all of its words, or a phrase in quotes. `level` takes one or more of `trace`, `debug`, `info`, `warn`, `error` and `fatal`. Follow `trace_id` to [the trace](/reference/api/observability/get-trace/) or `request_id` to [the request](/reference/api/observability/get-request/)."
14749 },
14750 "list_traces": {
14751 "params": {
14752 "workspace": "flagon-io",
14753 "project": "g1t"
14754 },
14755 "query": {
14756 "errors_only": "true",
14757 "min_duration_ms": "500"
14758 },
14759 "response": {
14760 "items": [
14761 {
14762 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14763 "name": "GET /:workspace/:repo/pulls/:number",
14764 "start_us": 1791813807418000,
14765 "duration_us": 842000,
14766 "span_count": 6,
14767 "error_count": 1,
14768 "services": [
14769 "g1t-web",
14770 "g1t-work"
14771 ],
14772 "status": 500,
14773 "service": "g1t-web",
14774 "environment": "production",
14775 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14776 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14777 "source": "otlp"
14778 }
14779 ],
14780 "next": null
14781 },
14782 "notes": "Each trace is its root span (or its earliest, when the root has not arrived), with what the rest add up to."
14783 },
14784 "get_trace": {
14785 "params": {
14786 "workspace": "flagon-io",
14787 "project": "g1t",
14788 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736"
14789 },
14790 "response": {
14791 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14792 "spans": [
14793 {
14794 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14795 "span_id": "00f067aa0ba902b7",
14796 "parent_span_id": null,
14797 "name": "GET /:workspace/:repo/pulls/:number",
14798 "kind": "server",
14799 "start_us": 1791813807418000,
14800 "duration_us": 842000,
14801 "status": "error",
14802 "status_message": "TypeError",
14803 "attributes": {
14804 "http.request.method": "GET",
14805 "http.response.status_code": 500
14806 },
14807 "resource": {
14808 "service.name": "g1t-web",
14809 "deployment.environment.name": "production"
14810 },
14811 "events": [],
14812 "links": [],
14813 "service": "g1t-web",
14814 "environment": "production",
14815 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14816 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14817 "source": "otlp"
14818 }
14819 ],
14820 "logs": [
14821 {
14822 "id": "log_01kq9b7d9f1h3k5m7p9r1t3v5y",
14823 "time_us": 1791813808251000,
14824 "severity": "error",
14825 "severity_number": 17,
14826 "body": "loading pull request 412 failed: Cannot read properties of undefined (reading 'head')",
14827 "trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14828 "span_id": "00f067aa0ba902b7",
14829 "request_id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14830 "attributes": {
14831 "code.function": "loadPull",
14832 "http.route": "/:workspace/:repo/pulls/:number"
14833 },
14834 "service": "g1t-web",
14835 "environment": "production",
14836 "deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14837 "commit_sha": "7c1e9a4b2d6f80135ac9e2b7d4f6a8c0e1b3d5f7",
14838 "source": "cloudflare"
14839 }
14840 ]
14841 },
14842 "notes": "Spans are in the order they started. `404` when the project has no spans of that trace."
14843 },
14844 "list_errors": {
14845 "params": {
14846 "workspace": "flagon-io",
14847 "project": "g1t"
14848 },
14849 "query": {
14850 "state": "open"
14851 },
14852 "response": [
14853 {
14854 "fingerprint": "9f2c41d07ab3e815",
14855 "name": "TypeError",
14856 "message": "Cannot read properties of undefined (reading 'head')",
14857 "stack": "TypeError: Cannot read properties of undefined (reading 'head')\n at loadPull (app/routes/pulls.ts:88:31)",
14858 "service": "g1t-web",
14859 "environment": "production",
14860 "first_us": 1791813062000000,
14861 "last_us": 1791813808000000,
14862 "count": 37,
14863 "first_deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14864 "last_request_id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14865 "last_trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14866 "state": "open",
14867 "issue_number": null
14868 }
14869 ],
14870 "notes": "The same exception is one group: its name, its message with numbers and ids taken out, and the top frame of its stack. `first_deployment_id` is the deployment it was first seen on, what likely brought it in. At most 200 groups, most recently seen first."
14871 },
14872 "update_error": {
14873 "params": {
14874 "workspace": "flagon-io",
14875 "project": "g1t",
14876 "fingerprint": "9f2c41d07ab3e815"
14877 },
14878 "request": {
14879 "state": "resolved",
14880 "issue_number": 418
14881 },
14882 "response": {
14883 "fingerprint": "9f2c41d07ab3e815",
14884 "name": "TypeError",
14885 "message": "Cannot read properties of undefined (reading 'head')",
14886 "stack": "TypeError: Cannot read properties of undefined (reading 'head')\n at loadPull (app/routes/pulls.ts:88:31)",
14887 "service": "g1t-web",
14888 "environment": "production",
14889 "first_us": 1791813062000000,
14890 "last_us": 1791813808000000,
14891 "count": 37,
14892 "first_deployment_id": "dpl_01kq9a2c4e6g8j0m2p4r6t8v0x",
14893 "last_request_id": "req_01kq9b7d9f1h3k5m7p9r1t3v5x",
14894 "last_trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
14895 "state": "resolved",
14896 "issue_number": 418
14897 },
14898 "notes": "A resolved group that happens again opens again. `issue_number` links the issue made for it, so an agent can take it; null unlinks it. Needs the Triage role or higher."
14899 },
14900 "list_metrics": {
14901 "params": {
14902 "workspace": "flagon-io",
14903 "project": "g1t"
14904 },
14905 "response": [
14906 {
14907 "name": "http.server.request.duration",
14908 "kind": "histogram",
14909 "unit": "s",
14910 "description": "Duration of HTTP server requests.",
14911 "services": [
14912 "g1t-api"
14913 ],
14914 "last_us": 1791813800000000
14915 },
14916 {
14917 "name": "queue.depth",
14918 "kind": "gauge",
14919 "unit": "{message}",
14920 "description": "Messages waiting.",
14921 "services": [
14922 "g1t-work"
14923 ],
14924 "last_us": 1791813780000000
14925 }
14926 ]
14927 },
14928 "get_metric": {
14929 "params": {
14930 "workspace": "flagon-io",
14931 "project": "g1t",
14932 "metric": "http.server.request.duration"
14933 },
14934 "query": {
14935 "aggregate": "p95",
14936 "group_by": "http.route",
14937 "step": "300"
14938 },
14939 "response": {
14940 "name": "http.server.request.duration",
14941 "unit": "s",
14942 "step_s": 300,
14943 "series": [
14944 {
14945 "group": "/repos/:owner/:name/pulls",
14946 "points": [
14947 {
14948 "time_us": 1791813300000000,
14949 "value": 0.212
14950 },
14951 {
14952 "time_us": 1791813600000000,
14953 "value": 0.236
14954 }
14955 ]
14956 }
14957 ]
14958 },
14959 "notes": "A metric name with characters outside letters, digits, `.`, `_` and `-` is URL-encoded in the path. Gauges average in each step unless `aggregate` says `min` or `max`; sums add, and a cumulative sum becomes its increase; histograms give their mean, or a percentile from their buckets."
14960 },
14961 "get_observability_settings": {
14962 "params": {
14963 "workspace": "flagon-io",
14964 "project": "g1t"
14965 },
14966 "response": {
14967 "retention_days": 7,
14968 "deployments": true
14969 },
14970 "notes": "Requests, logs and spans are kept for `retention_days`; the overview's charts are kept longer, as per-minute counts. Needs the Admin role."
14971 },
14972 "update_observability_settings": {
14973 "params": {
14974 "workspace": "flagon-io",
14975 "project": "g1t"
14976 },
14977 "request": {
14978 "retention_days": 14
14979 },
14980 "response": {
14981 "retention_days": 14,
14982 "deployments": true
14983 },
14984 "notes": "`retention_days` is 1, 3, 7, 14 or 30. Turning `deployments` off stops the project's apps on g1t.page from sending and keeps its tokens and history. Needs the Admin role."
14985 },
14986 "list_ingest_tokens": {
14987 "params": {
14988 "workspace": "flagon-io",
14989 "project": "g1t"
14990 },
14991 "response": [
14992 {
14993 "id": "a1b2c3d4",
14994 "name": "Deployments on g1t.page",
14995 "hint": "g1to_prj_…2c8e",
14996 "created_by": null,
14997 "created_us": 1790841600000000,
14998 "last_used_us": 1791813809000000,
14999 "managed": true
15000 },
15001 {
15002 "id": "k3m9q2x7",
15003 "name": "fly.io collector",
15004 "hint": "g1to_prj_…9f3a",
15005 "created_by": "syntaqx",
15006 "created_us": 1791796364000000,
15007 "last_used_us": 1791813790000000,
15008 "managed": false
15009 }
15010 ],
15011 "notes": "Secrets are never returned: `hint` tells tokens apart. The `managed` one is g1t's own, for the project's apps on g1t.page, and is replaced by g1t, not by people. Needs the Admin role."
15012 },
15013 "create_ingest_token": {
15014 "params": {
15015 "workspace": "flagon-io",
15016 "project": "g1t"
15017 },
15018 "request": {
15019 "name": "fly.io collector"
15020 },
15021 "response": {
15022 "token": {
15023 "id": "k3m9q2x7",
15024 "name": "fly.io collector",
15025 "hint": "g1to_prj_…9f3a",
15026 "created_by": "syntaqx",
15027 "created_us": 1791796364000000,
15028 "last_used_us": null,
15029 "managed": false
15030 },
15031 "secret": "g1to_prj_…"
15032 },
15033 "notes": "The secret is returned this once. Send it as `Authorization: Bearer <secret>` (or the `x-g1t-token` header) with OTLP over HTTP, in JSON or protobuf, to `https://otel.g1t.sh/v1/traces`, `/v1/logs` and `/v1/metrics`, or to `/otlp/v1/…` on the API's own address. Needs the Admin role."
15034 },
15035 "delete_ingest_token": {
15036 "params": {
15037 "workspace": "flagon-io",
15038 "project": "g1t",
15039 "id": "k3m9q2x7"
15040 },
15041 "response": true,
15042 "notes": "What sends with it is refused from then on. `404` for the managed token, which people cannot delete. Needs the Admin role."
15043 },
15044 "list_telemetry_exports": {
15045 "params": {
15046 "workspace": "flagon-io",
15047 "project": "g1t"
15048 },
15049 "response": [
15050 {
15051 "id": "x7d2k9m4",
15052 "name": "Honeycomb",
15053 "endpoint": "https://api.honeycomb.io",
15054 "signals": [
15055 "traces",
15056 "logs"
15057 ],
15058 "header_names": [
15059 "x-honeycomb-team"
15060 ],
15061 "enabled": true,
15062 "last_error": null,
15063 "last_sent_us": 1791813809000000
15064 }
15065 ],
15066 "notes": "Header values are secrets: written, never read back, so only `header_names` are shown. `last_error` is what the endpoint answered the last time sending failed. Needs the Admin role."
15067 },
15068 "create_telemetry_export": {
15069 "params": {
15070 "workspace": "flagon-io",
15071 "project": "g1t"
15072 },
15073 "request": {
15074 "name": "Honeycomb",
15075 "endpoint": "https://api.honeycomb.io",
15076 "signals": [
15077 "traces",
15078 "logs"
15079 ],
15080 "headers": {
15081 "x-honeycomb-team": "hcaik_…"
15082 }
15083 },
15084 "response": {
15085 "id": "x7d2k9m4",
15086 "name": "Honeycomb",
15087 "endpoint": "https://api.honeycomb.io",
15088 "signals": [
15089 "traces",
15090 "logs"
15091 ],
15092 "header_names": [
15093 "x-honeycomb-team"
15094 ],
15095 "enabled": true,
15096 "last_error": null,
15097 "last_sent_us": null
15098 },
15099 "notes": "`endpoint` is the OTLP/HTTP base address; `/v1/traces`, `/v1/logs` and `/v1/metrics` are added. Requests go as log records. Telemetry is sent on as it arrives, from then on. Needs the Admin role."
15100 },
15101 "update_telemetry_export": {
15102 "params": {
15103 "workspace": "flagon-io",
15104 "project": "g1t",
15105 "id": "x7d2k9m4"
15106 },
15107 "request": {
15108 "enabled": false
15109 },
15110 "response": {
15111 "id": "x7d2k9m4",
15112 "name": "Honeycomb",
15113 "endpoint": "https://api.honeycomb.io",
15114 "signals": [
15115 "traces",
15116 "logs"
15117 ],
15118 "header_names": [
15119 "x-honeycomb-team"
15120 ],
15121 "enabled": false,
15122 "last_error": null,
15123 "last_sent_us": 1791813809000000
15124 },
15125 "notes": "Only what is given changes. A header given is set, a header given as `\"\"` is removed, and the rest are kept. Needs the Admin role."
15126 },
15127 "delete_telemetry_export": {
15128 "params": {
15129 "workspace": "flagon-io",
15130 "project": "g1t",
15131 "id": "x7d2k9m4"
15132 },
15133 "response": true,
15134 "notes": "Needs the Admin role."
15135 },
15136 "get_observability_usage": {
15137 "params": {
15138 "workspace": "flagon-io",
15139 "project": "g1t"
15140 },
15141 "response": {
15142 "month": "2026-10",
15143 "ingested_bytes": 4831920112,
15144 "requests": 1840221,
15145 "logs": 6204118,
15146 "spans": 9921540,
15147 "metric_points": 3120400,
15148 "stored_bytes": 1210443776
15149 },
15150 "notes": "This month so far. `ingested_bytes` is what arrived, after decoding: what ingest is metered by. Needs the Admin role."
15151 }
15152}