@bongos/core 1.24.13 → 1.24.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (163) hide show
  1. package/.bongos-core.json +302 -137
  2. package/.claude/skills/blocker-review/SKILL.md +2 -0
  3. package/.claude/skills/session-board/SKILL.md +29 -0
  4. package/.claude/skills/strand-fix/SKILL.md +1 -1
  5. package/clients/bongos-client/README.md +1 -1
  6. package/clients/bongos-client/bongos-client.global.js +14 -0
  7. package/clients/bongos-client/index.cjs +14 -0
  8. package/clients/bongos-client/index.d.ts +23 -2
  9. package/clients/bongos-client/index.mjs +14 -0
  10. package/docs/adr/0385-money-lives-with-a-processor-credits-stay-a-project-meter.md +4 -0
  11. package/docs/adr/0397-the-payment-rail-is-stripe-connect-with-one-connected-account-per-project.md +71 -0
  12. package/docs/adr/README.md +1 -0
  13. package/docs/api/openapi.json +369 -6
  14. package/docs/api-reference.md +19 -4
  15. package/docs/architecture.md +6 -0
  16. package/docs/copy-inventory.md +138 -123
  17. package/docs/copy-registry.json +296 -171
  18. package/docs/file-map.md +1 -0
  19. package/docs/module-api-changelog.md +2 -0
  20. package/docs/page-inventory.json +6 -1
  21. package/docs/page-readings.json +1040 -1021
  22. package/migrations/core_289_task_short_name.sql +34 -0
  23. package/modules/ai-studio/db.js +10 -0
  24. package/modules/ai-studio/gemini.js +73 -5
  25. package/modules/ai-studio/openrouter.js +17 -2
  26. package/modules/ai-studio/routes/ai-studio.js +7 -1
  27. package/modules/ai-studio/studio.js +8 -0
  28. package/modules/builder-settings/checkout-freshness.js +71 -0
  29. package/modules/builder-settings/routes/settings.js +26 -0
  30. package/modules/builder-settings/settings.js +2 -0
  31. package/modules/economy/migrations/economy_002_project_account.sql +83 -0
  32. package/modules/economy/module.json +1 -1
  33. package/modules/economy/project-account.js +166 -0
  34. package/modules/economy/routes/project-account.js +40 -0
  35. package/modules/hall-ui/public/ai-studio.css +3 -0
  36. package/modules/hall-ui/public/ai-studio.html +2 -1
  37. package/modules/hall-ui/public/ai-studio.js +72 -1
  38. package/modules/hall-ui/public/atlas.html +1 -1
  39. package/modules/hall-ui/public/blockers.html +1 -1
  40. package/modules/hall-ui/public/board-room.html +1 -1
  41. package/modules/hall-ui/public/city.html +1 -1
  42. package/modules/hall-ui/public/collab.html +1 -1
  43. package/modules/hall-ui/public/commands.html +1 -1
  44. package/modules/hall-ui/public/copy-desk.html +1 -1
  45. package/modules/hall-ui/public/deploy.html +1 -1
  46. package/modules/hall-ui/public/diagrams.html +1 -1
  47. package/modules/hall-ui/public/drachmae.html +1 -1
  48. package/modules/hall-ui/public/fleet.html +1 -1
  49. package/modules/hall-ui/public/gate.html +1 -1
  50. package/modules/hall-ui/public/github-chip.js +85 -0
  51. package/modules/hall-ui/public/goal-map.html +1 -1
  52. package/modules/hall-ui/public/goals.html +1 -1
  53. package/modules/hall-ui/public/government.html +1 -1
  54. package/modules/hall-ui/public/idea.html +1 -1
  55. package/modules/hall-ui/public/ideas.html +1 -1
  56. package/modules/hall-ui/public/index.html +1 -1
  57. package/modules/hall-ui/public/market-watch-item.html +2 -2
  58. package/modules/hall-ui/public/market-watch-item.js +10 -3
  59. package/modules/hall-ui/public/market-watch-item.states.json +41 -0
  60. package/modules/hall-ui/public/market-watch-lib.js +36 -5
  61. package/modules/hall-ui/public/market-watch-rules.html +1 -1
  62. package/modules/hall-ui/public/market-watch-settings.html +1 -1
  63. package/modules/hall-ui/public/market-watch.css +5 -0
  64. package/modules/hall-ui/public/market-watch.html +2 -2
  65. package/modules/hall-ui/public/modules.html +1 -1
  66. package/modules/hall-ui/public/my-agents.html +1 -1
  67. package/modules/hall-ui/public/my-agents.js +3 -0
  68. package/modules/hall-ui/public/primer.html +1 -1
  69. package/modules/hall-ui/public/profile.html +1 -1
  70. package/modules/hall-ui/public/project-settings.html +1 -1
  71. package/modules/hall-ui/public/ranks.html +1 -1
  72. package/modules/hall-ui/public/roadmap.html +1 -1
  73. package/modules/hall-ui/public/roster.html +1 -1
  74. package/modules/hall-ui/public/sessions.html +1 -1
  75. package/modules/hall-ui/public/settings.html +1 -1
  76. package/modules/hall-ui/public/shell.js +22 -22
  77. package/modules/hall-ui/public/street.html +1 -1
  78. package/modules/hall-ui/public/studio.html +1 -1
  79. package/modules/hall-ui/public/style.css +28 -0
  80. package/modules/hall-ui/public/task.html +1 -1
  81. package/modules/hall-ui/public/thinking.html +1 -1
  82. package/modules/hall-ui/public/tweak-editor.html +1 -1
  83. package/modules/hall-ui/public/watch.html +1 -1
  84. package/modules/hall-ui/public/work.html +1 -1
  85. package/modules/ideas/blockers.js +13 -7
  86. package/modules/lifecycle/db-claim-reads.js +1 -1
  87. package/modules/lifecycle/db-ship.js +2 -2
  88. package/modules/lifecycle/db-tasks.js +4 -4
  89. package/modules/lifecycle/migrations/lifecycle_019_pay_type_gates.sql +50 -0
  90. package/modules/lifecycle/module.json +1 -0
  91. package/modules/lifecycle/pay-type-gates.js +180 -0
  92. package/modules/lifecycle/publish-reconciler.js +31 -1
  93. package/modules/lifecycle/rebase-gate.js +3 -2
  94. package/modules/lifecycle/routes/claims.js +3 -2
  95. package/modules/lifecycle/routes/pay-type-gates.js +59 -0
  96. package/modules/lifecycle/routes/project-settings.js +4 -0
  97. package/modules/lifecycle/routes/task-write-routes.js +43 -0
  98. package/modules/lifecycle/ship-card.js +4 -1
  99. package/modules/lifecycle/task-name-db.js +55 -0
  100. package/modules/lifecycle/task-name.js +140 -0
  101. package/modules/market-watch/db.js +10 -1
  102. package/modules/market-watch/migrations/market_watch_004_entry_corrections.sql +20 -0
  103. package/modules/market-watch/pages.js +20 -1
  104. package/modules/market-watch/proposals.js +57 -7
  105. package/modules/market-watch/routes/pages.js +2 -0
  106. package/modules/market-watch/routes/rules.js +4 -0
  107. package/modules/platform-identity/terms-acceptance.js +9 -9
  108. package/modules/public-landing/public/account-google.states.json +14 -0
  109. package/modules/public-landing/public/assets/cosmos.css +12 -0
  110. package/modules/public-landing/public/assets/hub-bar.js +44 -1
  111. package/modules/public-landing/public/privacy.html +5 -1
  112. package/modules/public-landing/public/projects-google.states.json +14 -0
  113. package/modules/public-landing/public/projects.html +39 -0
  114. package/modules/public-landing/public/terms.html +12 -2
  115. package/modules/ui-design/kit/fixtures/me-google.json +10 -0
  116. package/modules/ui-design/kit/fixtures/me-sign-in-methods-google.json +4 -0
  117. package/modules/ui-design/kit/serve.js +7 -1
  118. package/package-lock.json +2 -2
  119. package/package.json +1 -1
  120. package/release-notes.json +54 -0
  121. package/scripts/bongos/claim.js +4 -2
  122. package/scripts/bongos/land-watch.js +1 -0
  123. package/scripts/bongos/report-checkout.js +30 -0
  124. package/scripts/bongos/run-unit-tests.js +11 -0
  125. package/scripts/bongos/sessions-board.js +264 -0
  126. package/scripts/bongos/ship-finish.js +1 -0
  127. package/scripts/bongos/ship-flow.js +5 -2
  128. package/scripts/bongos/strand-lease.js +5 -3
  129. package/scripts/bongos/strand-watch.js +38 -7
  130. package/scripts/gds/report-checkout.js +7 -0
  131. package/scripts/gds/sessions-board.js +7 -0
  132. package/src/bongos/agent-standing-rules.js +13 -3
  133. package/src/bongos/routes/me.js +7 -1
  134. package/src/module-api.js +1 -1
  135. package/tests/agent_standing_rules.mjs +18 -1
  136. package/tests/ai_studio_billing.mjs +13 -0
  137. package/tests/ai_studio_gemini_models.mjs +81 -0
  138. package/tests/ai_studio_requests.mjs +24 -0
  139. package/tests/blocker_detail_hydration.mjs +5 -3
  140. package/tests/blocker_tasks_named_db.mjs +74 -0
  141. package/tests/claim_gate_ci_unblock.mjs +1 -1
  142. package/tests/github_chip.mjs +217 -0
  143. package/tests/hall_ai_studio.mjs +129 -5
  144. package/tests/host_topology_skips.mjs +1 -0
  145. package/tests/hub_account_page.mjs +3 -2
  146. package/tests/landing_legal_pages.mjs +3 -2
  147. package/tests/market_watch_data_db.mjs +6 -0
  148. package/tests/market_watch_pages.mjs +87 -2
  149. package/tests/market_watch_rules.mjs +101 -5
  150. package/tests/market_watch_rules_db.mjs +42 -0
  151. package/tests/nav_permission_atoms.mjs +1 -1
  152. package/tests/pay_terms.mjs +8 -0
  153. package/tests/pay_type_gates.mjs +234 -0
  154. package/tests/pay_type_gates_db.mjs +84 -0
  155. package/tests/project_account.mjs +125 -0
  156. package/tests/project_account_db.mjs +97 -0
  157. package/tests/self_healing_start.mjs +162 -0
  158. package/tests/sessions_board.mjs +153 -0
  159. package/tests/stop_refcheck.mjs +40 -0
  160. package/tests/task_name.mjs +237 -0
  161. package/tests/task_name_db.mjs +79 -0
  162. package/tests/terms_acceptance.mjs +25 -3
  163. package/tests/terms_grandfather_db.mjs +11 -4
@@ -245,6 +245,10 @@
245
245
  "name": "pay-terms",
246
246
  "description": "Endpoints under `/api/bongos/pay-terms`."
247
247
  },
248
+ {
249
+ "name": "pay-type-gates",
250
+ "description": "Endpoints under `/api/bongos/pay-type-gates`."
251
+ },
248
252
  {
249
253
  "name": "payouts",
250
254
  "description": "Endpoints under `/api/bongos/payouts`."
@@ -257,6 +261,10 @@
257
261
  "name": "project",
258
262
  "description": "Endpoints under `/api/bongos/project`."
259
263
  },
264
+ {
265
+ "name": "project-account",
266
+ "description": "Endpoints under `/api/bongos/project-account`."
267
+ },
260
268
  {
261
269
  "name": "project-settings",
262
270
  "description": "Endpoints under `/api/bongos/project-settings`."
@@ -1637,7 +1645,7 @@
1637
1645
  "ai-studio"
1638
1646
  ],
1639
1647
  "summary": "POST /ai-studio/uploads",
1640
- "description": "One file per call, so a request body stays small; the global 64 KB parser skips this path (src/bongos/routes.js) and this parser takes it.\n\n**Rank:** `any-builder` — Any authenticated builder (row-level ownership enforced in-handler).",
1648
+ "description": "One file per call, so a request body stays small; the global 64 KB parser skips this path (src/bongos/routes.js) and this parser takes it. Not adults-gated on purpose: an upload is stored here and reaches no AI company until a request sends it, and /ai-studio/requests is gated.\n\n**Rank:** `any-builder` — Any authenticated builder (row-level ownership enforced in-handler).",
1641
1649
  "x-rank": "any-builder",
1642
1650
  "x-source": "modules/ai-studio/routes/ai-studio.js",
1643
1651
  "requestBody": {
@@ -14670,6 +14678,55 @@
14670
14678
  ]
14671
14679
  }
14672
14680
  },
14681
+ "/me/checkout-freshness": {
14682
+ "patch": {
14683
+ "operationId": "patch_me_checkout_freshness",
14684
+ "tags": [
14685
+ "me"
14686
+ ],
14687
+ "summary": "PATCH /me/checkout-freshness",
14688
+ "description": "How far behind this builder's local project folder is (task 1005021, checkout-freshness.js). Written by their own session start; read back by GET /me, which tells the person (and their agent) when the folder could not update itself. Body: { behind, branch, reason }. rank: any-builder — a builder's own report about their own computer; same posture as /me/core-move-seen.\n\n**Rank:** `any-builder` — Any authenticated builder (row-level ownership enforced in-handler).",
14689
+ "x-rank": "any-builder",
14690
+ "x-source": "modules/builder-settings/routes/settings.js",
14691
+ "requestBody": {
14692
+ "required": true,
14693
+ "content": {
14694
+ "application/json": {
14695
+ "schema": {
14696
+ "$ref": "#/components/schemas/PatchMeCheckoutFreshnessRequest"
14697
+ }
14698
+ }
14699
+ },
14700
+ "x-validated": true
14701
+ },
14702
+ "responses": {
14703
+ "200": {
14704
+ "description": "Success.",
14705
+ "content": {
14706
+ "application/json": {
14707
+ "schema": {
14708
+ "$ref": "#/components/schemas/PatchMeCheckoutFreshnessResponse"
14709
+ }
14710
+ }
14711
+ }
14712
+ },
14713
+ "400": {
14714
+ "$ref": "#/components/responses/ValidationFailed"
14715
+ },
14716
+ "401": {
14717
+ "$ref": "#/components/responses/Unauthorized"
14718
+ },
14719
+ "403": {
14720
+ "$ref": "#/components/responses/Forbidden"
14721
+ }
14722
+ },
14723
+ "security": [
14724
+ {
14725
+ "builderSession": []
14726
+ }
14727
+ ]
14728
+ }
14729
+ },
14673
14730
  "/me/core-move-seen": {
14674
14731
  "patch": {
14675
14732
  "operationId": "patch_me_core_move_seen",
@@ -19280,6 +19337,119 @@
19280
19337
  ]
19281
19338
  }
19282
19339
  },
19340
+ "/pay-type-gates": {
19341
+ "get": {
19342
+ "operationId": "get_pay_type_gates",
19343
+ "tags": [
19344
+ "pay-type-gates"
19345
+ ],
19346
+ "summary": "GET /pay-type-gates",
19347
+ "description": "for met/missing (the same pay information `GET /pay-terms` shows, no person's money); the evidence references and who cleared each requirement are the owner's records, so they come back for an archon only.\n\n**Rank:** `any-builder` — Any authenticated builder (row-level ownership enforced in-handler).",
19348
+ "x-rank": "any-builder",
19349
+ "x-source": "modules/lifecycle/routes/pay-type-gates.js",
19350
+ "responses": {
19351
+ "200": {
19352
+ "description": "Success.",
19353
+ "content": {
19354
+ "application/json": {
19355
+ "schema": {
19356
+ "$ref": "#/components/schemas/GetPayTypeGatesResponse"
19357
+ }
19358
+ }
19359
+ }
19360
+ },
19361
+ "400": {
19362
+ "$ref": "#/components/responses/BadRequest"
19363
+ },
19364
+ "401": {
19365
+ "$ref": "#/components/responses/Unauthorized"
19366
+ },
19367
+ "403": {
19368
+ "$ref": "#/components/responses/Forbidden"
19369
+ }
19370
+ },
19371
+ "security": [
19372
+ {
19373
+ "builderSession": []
19374
+ }
19375
+ ]
19376
+ }
19377
+ },
19378
+ "/pay-type-gates/{payType}/{requirement}": {
19379
+ "put": {
19380
+ "operationId": "put_pay_type_gates_payType_requirement",
19381
+ "tags": [
19382
+ "pay-type-gates"
19383
+ ],
19384
+ "summary": "PUT /pay-type-gates/:payType/:requirement",
19385
+ "description": ".approve (archon floor). Whether a pay type is legal for this project is the owner's call, often with counsel, and it is the same authority that approves payouts — no new atom is minted for it (ADR 0016: enforced here, on the server).\n\n**Rank:** `archon` — Archon only (rank and identity management + the escalation keys — the trust boundary).\n\n**Permissions:** `payout.approve` (all required).",
19386
+ "x-rank": "archon",
19387
+ "x-source": "modules/lifecycle/routes/pay-type-gates.js",
19388
+ "x-permissions": [
19389
+ "payout.approve"
19390
+ ],
19391
+ "parameters": [
19392
+ {
19393
+ "name": "payType",
19394
+ "in": "path",
19395
+ "required": true,
19396
+ "schema": {
19397
+ "type": "string"
19398
+ },
19399
+ "description": "Path parameter `payType`."
19400
+ },
19401
+ {
19402
+ "name": "requirement",
19403
+ "in": "path",
19404
+ "required": true,
19405
+ "schema": {
19406
+ "type": "string"
19407
+ },
19408
+ "description": "Path parameter `requirement`."
19409
+ }
19410
+ ],
19411
+ "requestBody": {
19412
+ "required": false,
19413
+ "content": {
19414
+ "application/json": {
19415
+ "schema": {
19416
+ "$ref": "#/components/schemas/PutPayTypeGatesPayTypeRequirementRequest"
19417
+ }
19418
+ }
19419
+ },
19420
+ "x-validated": true
19421
+ },
19422
+ "responses": {
19423
+ "200": {
19424
+ "description": "Success.",
19425
+ "content": {
19426
+ "application/json": {
19427
+ "schema": {
19428
+ "$ref": "#/components/schemas/PutPayTypeGatesPayTypeRequirementResponse"
19429
+ }
19430
+ }
19431
+ }
19432
+ },
19433
+ "400": {
19434
+ "$ref": "#/components/responses/ValidationFailed"
19435
+ },
19436
+ "401": {
19437
+ "$ref": "#/components/responses/Unauthorized"
19438
+ },
19439
+ "403": {
19440
+ "$ref": "#/components/responses/Forbidden"
19441
+ },
19442
+ "404": {
19443
+ "$ref": "#/components/responses/NotFound"
19444
+ }
19445
+ },
19446
+ "security": [
19447
+ {
19448
+ "builderSession": []
19449
+ }
19450
+ ]
19451
+ }
19452
+ },
19283
19453
  "/payouts/age-records": {
19284
19454
  "post": {
19285
19455
  "operationId": "post_payouts_age_records",
@@ -20176,6 +20346,40 @@
20176
20346
  "security": []
20177
20347
  }
20178
20348
  },
20349
+ "/project-account": {
20350
+ "get": {
20351
+ "operationId": "get_project_account",
20352
+ "tags": [
20353
+ "project-account"
20354
+ ],
20355
+ "summary": "GET /project-account",
20356
+ "description": ".approve (archon floor) — the owner. The account's balance and who was paid what is the project's own money, so only the payout authority reads it (ADR 0016: enforced here, server-side).\n\n**Rank:** `archon` — Archon only (rank and identity management + the escalation keys — the trust boundary).\n\n**Permissions:** `payout.approve` (all required).",
20357
+ "x-rank": "archon",
20358
+ "x-source": "modules/economy/routes/project-account.js",
20359
+ "x-permissions": [
20360
+ "payout.approve"
20361
+ ],
20362
+ "responses": {
20363
+ "200": {
20364
+ "description": "Success."
20365
+ },
20366
+ "400": {
20367
+ "$ref": "#/components/responses/BadRequest"
20368
+ },
20369
+ "401": {
20370
+ "$ref": "#/components/responses/Unauthorized"
20371
+ },
20372
+ "403": {
20373
+ "$ref": "#/components/responses/Forbidden"
20374
+ }
20375
+ },
20376
+ "security": [
20377
+ {
20378
+ "builderSession": []
20379
+ }
20380
+ ]
20381
+ }
20382
+ },
20179
20383
  "/project-settings": {
20180
20384
  "get": {
20181
20385
  "operationId": "get_project_settings",
@@ -29501,6 +29705,69 @@
29501
29705
  ]
29502
29706
  }
29503
29707
  },
29708
+ "/tasks/{id}/short-name": {
29709
+ "patch": {
29710
+ "operationId": "patch_tasks_id_short_name",
29711
+ "tags": [
29712
+ "tasks"
29713
+ ],
29714
+ "summary": "PATCH /tasks/:id/short-name",
29715
+ "description": "PATCH /tasks/:id/short-name { short_name } — rename a task's 2-3 word name, the one sessions print as \"task N - <name>\" (task 1004958). Its own route because the owner's rule is that the task's AUTHOR may change it, and PATCH /tasks/:id is gated on task.edit, which an author below Metic does not hold. The name is normalised to task-name.js's alphabet (three lowercase words at most), so what reaches the startup notes is a topic and nothing else; the table CHECK holds the same shape. rank: any-builder, narrowed in the handler — the task's author, or a Metic or Archon.\n\n**Rank:** `any-builder` — Any authenticated builder (row-level ownership enforced in-handler).",
29716
+ "x-rank": "any-builder",
29717
+ "x-source": "modules/lifecycle/routes/task-write-routes.js",
29718
+ "parameters": [
29719
+ {
29720
+ "name": "id",
29721
+ "in": "path",
29722
+ "required": true,
29723
+ "schema": {
29724
+ "type": "string"
29725
+ },
29726
+ "description": "Path parameter `id`."
29727
+ }
29728
+ ],
29729
+ "requestBody": {
29730
+ "required": true,
29731
+ "content": {
29732
+ "application/json": {
29733
+ "schema": {
29734
+ "$ref": "#/components/schemas/PatchTasksIdShortNameRequest"
29735
+ }
29736
+ }
29737
+ },
29738
+ "x-validated": true
29739
+ },
29740
+ "responses": {
29741
+ "200": {
29742
+ "description": "Success.",
29743
+ "content": {
29744
+ "application/json": {
29745
+ "schema": {
29746
+ "$ref": "#/components/schemas/PatchTasksIdShortNameResponse"
29747
+ }
29748
+ }
29749
+ }
29750
+ },
29751
+ "400": {
29752
+ "$ref": "#/components/responses/ValidationFailed"
29753
+ },
29754
+ "401": {
29755
+ "$ref": "#/components/responses/Unauthorized"
29756
+ },
29757
+ "403": {
29758
+ "$ref": "#/components/responses/Forbidden"
29759
+ },
29760
+ "404": {
29761
+ "$ref": "#/components/responses/NotFound"
29762
+ }
29763
+ },
29764
+ "security": [
29765
+ {
29766
+ "builderSession": []
29767
+ }
29768
+ ]
29769
+ }
29770
+ },
29504
29771
  "/tasks/{id}/visual": {
29505
29772
  "post": {
29506
29773
  "operationId": "post_tasks_id_visual",
@@ -30926,11 +31193,15 @@
30926
31193
  "ok": {
30927
31194
  "type": "boolean"
30928
31195
  },
30929
- "module": {}
31196
+ "module": {},
31197
+ "terms": {},
31198
+ "adult": {}
30930
31199
  },
30931
31200
  "required": [
30932
31201
  "ok",
30933
- "module"
31202
+ "module",
31203
+ "terms",
31204
+ "adult"
30934
31205
  ]
30935
31206
  },
30936
31207
  "GetAiStudioTopupQuoteResponse": {
@@ -32280,6 +32551,15 @@
32280
32551
  "pay_terms"
32281
32552
  ]
32282
32553
  },
32554
+ "GetPayTypeGatesResponse": {
32555
+ "type": "object",
32556
+ "properties": {
32557
+ "gates": {}
32558
+ },
32559
+ "required": [
32560
+ "gates"
32561
+ ]
32562
+ },
32283
32563
  "GetPayoutsApprovalsResponse": {
32284
32564
  "type": "object",
32285
32565
  "properties": {
@@ -33587,6 +33867,40 @@
33587
33867
  },
33588
33868
  "additionalProperties": false
33589
33869
  },
33870
+ "PatchMeCheckoutFreshnessRequest": {
33871
+ "type": "object",
33872
+ "properties": {
33873
+ "behind": {
33874
+ "type": "number"
33875
+ },
33876
+ "branch": {
33877
+ "type": "string",
33878
+ "maxLength": 120
33879
+ },
33880
+ "reason": {
33881
+ "type": "string",
33882
+ "maxLength": 40
33883
+ }
33884
+ },
33885
+ "required": [
33886
+ "behind",
33887
+ "reason"
33888
+ ],
33889
+ "additionalProperties": false
33890
+ },
33891
+ "PatchMeCheckoutFreshnessResponse": {
33892
+ "type": "object",
33893
+ "properties": {
33894
+ "ok": {
33895
+ "type": "boolean"
33896
+ },
33897
+ "checkout": {}
33898
+ },
33899
+ "required": [
33900
+ "ok",
33901
+ "checkout"
33902
+ ]
33903
+ },
33590
33904
  "PatchMeCoreMoveSeenRequest": {
33591
33905
  "type": "object",
33592
33906
  "properties": {
@@ -34282,6 +34596,28 @@
34282
34596
  },
34283
34597
  "additionalProperties": false
34284
34598
  },
34599
+ "PatchTasksIdShortNameRequest": {
34600
+ "type": "object",
34601
+ "properties": {
34602
+ "short_name": {
34603
+ "type": "string",
34604
+ "maxLength": 80
34605
+ }
34606
+ },
34607
+ "required": [
34608
+ "short_name"
34609
+ ],
34610
+ "additionalProperties": false
34611
+ },
34612
+ "PatchTasksIdShortNameResponse": {
34613
+ "type": "object",
34614
+ "properties": {
34615
+ "task": {}
34616
+ },
34617
+ "required": [
34618
+ "task"
34619
+ ]
34620
+ },
34285
34621
  "PostAccessRequestsInviteRequest": {
34286
34622
  "type": "object",
34287
34623
  "properties": {
@@ -37420,6 +37756,11 @@
37420
37756
  "log_entry_id": {
37421
37757
  "$ref": "#/components/schemas/StringifiableId"
37422
37758
  },
37759
+ "takeaway": {
37760
+ "type": "string",
37761
+ "maxLength": 2000
37762
+ },
37763
+ "wrong": {},
37423
37764
  "scout": {
37424
37765
  "type": "string"
37425
37766
  },
@@ -41013,6 +41354,28 @@
41013
41354
  ],
41014
41355
  "additionalProperties": false
41015
41356
  },
41357
+ "PutPayTypeGatesPayTypeRequirementRequest": {
41358
+ "type": "object",
41359
+ "properties": {
41360
+ "state": {},
41361
+ "evidence_ref": {},
41362
+ "acknowledged": {}
41363
+ },
41364
+ "additionalProperties": false
41365
+ },
41366
+ "PutPayTypeGatesPayTypeRequirementResponse": {
41367
+ "type": "object",
41368
+ "properties": {
41369
+ "ok": {
41370
+ "type": "boolean"
41371
+ },
41372
+ "gate": {}
41373
+ },
41374
+ "required": [
41375
+ "ok",
41376
+ "gate"
41377
+ ]
41378
+ },
41016
41379
  "PutProvisioningInstancesIdLogoRequest": {
41017
41380
  "type": "object",
41018
41381
  "properties": {
@@ -41279,9 +41642,9 @@
41279
41642
  "description": "A required dependency/feature is not configured or is temporarily down."
41280
41643
  }
41281
41644
  },
41282
- "x-endpoint-count": 652,
41283
- "x-schema-count": 698,
41645
+ "x-endpoint-count": 657,
41646
+ "x-schema-count": 705,
41284
41647
  "x-undocumented-bodies": 12,
41285
- "x-response-schemas": 447,
41648
+ "x-response-schemas": 451,
41286
41649
  "x-generated-by": "scripts/bongos/gen-api-docs.js"
41287
41650
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Bongos API reference
4
4
 
5
- > **Generated from the live route files** — the route file is authoritative. 652 endpoints across 109 route files.
5
+ > **Generated from the live route files** — the route file is authoritative. 657 endpoints across 111 route files.
6
6
  > Machine-readable spec: [`docs/api/openapi.json`](api/openapi.json) (OpenAPI 3.1). Rendered docs site: **`/docs`** (e.g. `cloudbongos.com/docs`).
7
7
 
8
8
  Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust-boundary-server-enforced-permissions.md)): `public` < `any-builder` < `metic+archon` < `archon`.
@@ -528,7 +528,7 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
528
528
  | POST | `/api/bongos/market-watch/ask/answer` | `any-builder` | `week_of`, `picks`, `names`, `nothing`, `builder_id` | a member answers for themselves only (isMember in gate()). |
529
529
  | GET | `/api/bongos/market-watch/home` | `any-builder` | — | every member reads the desk. |
530
530
  | GET | `/api/bongos/market-watch/items/:id` | `any-builder` | — | every member reads an item's case file. |
531
- | POST | `/api/bongos/market-watch/proposals` | `any-builder` | `kind`, `reason`, `item_id`, `dimension`, `value`, `url`, `log_entry_id`, `scout`, `name` | every member may propose; the government decides (task 1004941). |
531
+ | POST | `/api/bongos/market-watch/proposals` | `any-builder` | `kind`, `reason`, `item_id`, `dimension`, `value`, `url`, `log_entry_id`, `takeaway`, `wrong`, `scout`, `name` | every member may propose; the government decides (task 1004941). |
532
532
  | POST | `/api/bongos/market-watch/proposals/:id/decide` | `any-builder` | `decision` | THE OWNER'S DECISION. |
533
533
  | POST | `/api/bongos/market-watch/proposals/:id/vote` | `metic+archon` | — | PUT TO A VOTE. |
534
534
  | GET | `/api/bongos/market-watch/rules` | `any-builder` | — | every member reads the rules (the task); the read grants nothing. |
@@ -538,13 +538,14 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
538
538
  | PUT | `/api/bongos/market-watch/settings/key` | `metic+archon` | `key` | |
539
539
  | DELETE | `/api/bongos/market-watch/settings/key` | `metic+archon` | — | |
540
540
 
541
- ## `me` (55)
541
+ ## `me` (56)
542
542
 
543
543
  | Method | Path | Rank | Body | Description |
544
544
  |---|---|---|---|---|
545
545
  | GET | `/api/bongos/me` | `any-builder` | — | PMS-V2 task 188: response now also carries `unlocked` (server-joined achievement metadata) + `locked_with_progress` (server-computed huma… |
546
546
  | GET | `/api/bongos/me/achievements` | `any-builder` | — | The builder's unlocked achievements (joined to achievement metadata). |
547
547
  | POST | `/api/bongos/me/anthropic-link` | `any-builder` | `anthropic_email`, `anthropic_user_id` | V3.R10 (task 235), criterion C3 — link the authed builder's Anthropic account. |
548
+ | PATCH | `/api/bongos/me/checkout-freshness` | `any-builder` | `behind`, `branch`, `reason` | How far behind this builder's local project folder is (task 1005021, checkout-freshness.js). |
548
549
  | PATCH | `/api/bongos/me/core-move-seen` | `any-builder` | `id` | The core move this builder has been told about (task 1004731, core-move-seen.js): closing the hall's "Upgraded to core X" notice stores t… |
549
550
  | GET | `/api/bongos/me/credits` | `any-builder` | — | GET /me/credits — the caller's own ledger. |
550
551
  | GET | `/api/bongos/me/cross-project` | `any-builder` | — | the caller's OWN cross-project record + privacy flags (own data). |
@@ -700,6 +701,13 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
700
701
  |---|---|---|---|---|
701
702
  | GET | `/api/bongos/pay-terms` | `any-builder` | — | GET /pay-terms?task_ids=1,2,3 — what each task pays, in the project's words (task 1004990, ADR 0385 D3), for a list of tasks in one read:… |
702
703
 
704
+ ## `pay-type-gates` (2)
705
+
706
+ | Method | Path | Rank | Body | Description |
707
+ |---|---|---|---|---|
708
+ | GET | `/api/bongos/pay-type-gates` | `any-builder` | — | for met/missing (the same pay information `GET /pay-terms` shows, no person's money); the evidence references and who cleared each requir… |
709
+ | PUT | `/api/bongos/pay-type-gates/:payType/:requirement` | `archon` | `state`, `evidence_ref`, `acknowledged` | .approve (archon floor). |
710
+
703
711
  ## `payouts` (16)
704
712
 
705
713
  | Method | Path | Rank | Body | Description |
@@ -733,6 +741,12 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
733
741
  |---|---|---|---|---|
734
742
  | GET | `/api/bongos/project/manage-link` | `archon` | — | GET /project/manage-link — the hub's page for THIS project, where its owner takes it offline or disconnects it (task 1004570). |
735
743
 
744
+ ## `project-account` (1)
745
+
746
+ | Method | Path | Rank | Body | Description |
747
+ |---|---|---|---|---|
748
+ | GET | `/api/bongos/project-account` | `archon` | — | .approve (archon floor) — the owner. |
749
+
736
750
  ## `project-settings` (8)
737
751
 
738
752
  | Method | Path | Rank | Body | Description |
@@ -1000,7 +1014,7 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
1000
1014
  |---|---|---|---|---|
1001
1015
  | GET | `/api/bongos/task-visuals/:name` | `public` | — | the WIDEST path this route can take, declared honestly. |
1002
1016
 
1003
- ## `tasks` (36)
1017
+ ## `tasks` (37)
1004
1018
 
1005
1019
  | Method | Path | Rank | Body | Description |
1006
1020
  |---|---|---|---|---|
@@ -1027,6 +1041,7 @@ Base path: `/api/bongos`. Ranks (enforced server-side, [ADR 0016](adr/0016-trust
1027
1041
  | GET | `/api/bongos/tasks/:id/publish-status` | `any-builder` | — | GET /tasks/:id/publish-status?branch=<branch> — poll the PR + prod-deploy state for a server-mediated publish so ship.js can confirm the … |
1028
1042
  | GET | `/api/bongos/tasks/:id/recommendations` | `any-builder` | — | The per-task audit read: who recommended this task, to whom, and why. |
1029
1043
  | POST | `/api/bongos/tasks/:id/ship` | `any-builder` | validated | confirmed → shipped. |
1044
+ | PATCH | `/api/bongos/tasks/:id/short-name` | `any-builder` | `short_name` | PATCH /tasks/:id/short-name { short_name } — rename a task's 2-3 word name, the one sessions print as "task N - <name>" (task 1004958). |
1030
1045
  | POST | `/api/bongos/tasks/:id/visual` | `any-builder` | `image_b64`, `content_type`, `alt` | POST /tasks/:id/visual — attach (or replace) this task's ship-time visual. |
1031
1046
  | DELETE | `/api/bongos/tasks/:id/visual` | `any-builder` | — | DELETE /tasks/:id/visual — remove it again. |
1032
1047
  | GET | `/api/bongos/tasks/:id/visuals` | `any-builder` | — | GET /tasks/:id/visuals — the task's named visuals. |
@@ -110,6 +110,9 @@ versions(id PK 'V1'|'PMS-V1'..., name, track, status, scope_doc_path, ...) -- t
110
110
  tasks(id, version_id, title, description, status, touches text[], est_minutes, est_cost_usd,
111
111
  manual_degree, priority, automation_tag, credits_reward, source, source_ref,
112
112
  promoted_at, shipped_at, shipped_by, value_summary, created_at, updated_at)
113
+ + short_name text (mig core_289, task 1004958) -- 1-3 lowercase words a session writes as "task N - <name>";
114
+ derived from the title by modules/lifecycle/task-name.js on create, backfilled hourly by the
115
+ publish-reconciler, renamed by the author via PATCH /tasks/:id/short-name. CHECK holds the safe shape.
113
116
  + needs text[] NOT NULL DEFAULT '{}' (mig core_285, task 1004950 / ADR 0395) -- what the task needs beyond the build
114
117
  loop: ⊆ {owner, server}. The recommend lists show it only to a viewer holding those capabilities;
115
118
  a claim refuses only 'server' without the grant. Visibility elsewhere is unchanged.
@@ -256,6 +259,9 @@ lifecycle_pay_term_sets(id, task_id NULL = the project's standing terms, set_by,
256
259
  lifecycle_pay_terms(id, set_id, position, pay_type, amount text, unit, note)
257
260
  -- task 1004990 (module lifecycle, lifecycle_018): what a task pays, in the project's words; append-only
258
261
  -- history of whole sets (newest current), records only, no default amount.
262
+ lifecycle_pay_type_gates(id, pay_type, requirement, state cleared|revoked, evidence_ref, decided_by, decided_at)
263
+ -- task 1004991 (module lifecycle, lifecycle_019): ADR 0385's pay-type gates; append-only,
264
+ -- newest row per requirement is current; a pay term is refused until its type's gate is cleared; no eu_labour row exists.
259
265
  store_module_prices(id, module_key, price_cents, price_credits, set_by, set_at)
260
266
  -- history; newest row per module is current. Cash only since core_287 (task 1004989):
261
267
  -- price_credits is historical, a credit-only newest row reads "price coming". 0 cents = free.