imbi-api 2.56.0__tar.gz → 2.57.0__tar.gz

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 (452) hide show
  1. {imbi_api-2.56.0 → imbi_api-2.57.0}/PKG-INFO +2 -2
  2. {imbi_api-2.56.0 → imbi_api-2.57.0}/pyproject.toml +2 -2
  3. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/agent_api_routes.py +1 -0
  4. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/agents.py +6 -7
  5. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/harness.py +76 -6
  6. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/organizations.py +1 -11
  7. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/tickets.py +237 -65
  8. imbi_api-2.57.0/src/imbi/api/harness/schemata.toml +295 -0
  9. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/store.py +0 -3
  10. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/tickets/__init__.py +4 -0
  11. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/tickets/log.py +6 -5
  12. imbi_api-2.57.0/src/imbi/api/tickets/schemata.toml +590 -0
  13. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/tickets/store.py +215 -26
  14. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_task_harness.py +25 -11
  15. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_task_relations.py +0 -28
  16. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_tasks.py +16 -17
  17. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agents.py +13 -4
  18. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_harness.py +138 -0
  19. imbi_api-2.57.0/tests/endpoints/test_person_tickets.py +370 -0
  20. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_clickhouse_project_ids.py +0 -51
  21. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_tickets_rename.py +197 -26
  22. {imbi_api-2.56.0 → imbi_api-2.57.0}/.gitignore +0 -0
  23. {imbi_api-2.56.0 → imbi_api-2.57.0}/README.md +0 -0
  24. {imbi_api-2.56.0 → imbi_api-2.57.0}/moon.yml +0 -0
  25. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/README.md +0 -0
  26. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/__init__.py +0 -0
  27. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/agent_tools.py +0 -0
  28. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/app.py +0 -0
  29. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/__init__.py +0 -0
  30. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/agent_api.py +0 -0
  31. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/authorization_codes.py +0 -0
  32. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/autonomous.py +0 -0
  33. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/internal_services.py +0 -0
  34. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/local_auth.py +0 -0
  35. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/login_providers.py +0 -0
  36. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/membership.py +0 -0
  37. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/models.py +0 -0
  38. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/oauth_clients.py +0 -0
  39. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/organizations.py +0 -0
  40. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/password.py +0 -0
  41. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/permissions.py +0 -0
  42. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/principals.py +0 -0
  43. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/seed.py +0 -0
  44. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/sessions.py +0 -0
  45. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/tokens.py +0 -0
  46. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/auth/totp.py +0 -0
  47. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/backfill_embeddings.py +0 -0
  48. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/blueprint_attributes.py +0 -0
  49. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/blueprint_compliance.py +0 -0
  50. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/commit_pushed_at_repair.py +0 -0
  51. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/commit_sync/__init__.py +0 -0
  52. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/commit_sync/queue.py +0 -0
  53. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/commit_sync/service.py +0 -0
  54. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/component_facts.py +0 -0
  55. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/cves.py +0 -0
  56. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/deployment_status_repair.py +0 -0
  57. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/deployment_sweeper.py +0 -0
  58. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/deployment_sync/__init__.py +0 -0
  59. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/deployment_sync/queue.py +0 -0
  60. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/deployment_sync/service.py +0 -0
  61. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/documents/__init__.py +0 -0
  62. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/documents/read_sweeper.py +0 -0
  63. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/domain/__init__.py +0 -0
  64. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/domain/models.py +0 -0
  65. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/domain/scoring.py +0 -0
  66. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/drift.py +0 -0
  67. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/__init__.py +0 -0
  68. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/client.py +0 -0
  69. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/dependencies.py +0 -0
  70. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/models.py +0 -0
  71. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/base.html +0 -0
  72. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/base.txt +0 -0
  73. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/password_reset.html +0 -0
  74. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/password_reset.txt +0 -0
  75. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/welcome.html +0 -0
  76. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates/welcome.txt +0 -0
  77. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/email/templates.py +0 -0
  78. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/__init__.py +0 -0
  79. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_credentials.py +0 -0
  80. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_document_events.py +0 -0
  81. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_document_history.py +0 -0
  82. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_document_reads.py +0 -0
  83. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_document_scope.py +0 -0
  84. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_helpers.py +0 -0
  85. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_json_fields.py +0 -0
  86. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_local_time.py +0 -0
  87. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_pagination.py +0 -0
  88. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_request_urls.py +0 -0
  89. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/_search_index.py +0 -0
  90. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/admin.py +0 -0
  91. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/admin_plugins.py +0 -0
  92. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/agent_platform.py +0 -0
  93. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/agent_usage.py +0 -0
  94. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/ai_models.py +0 -0
  95. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/ai_providers.py +0 -0
  96. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/api_keys.py +0 -0
  97. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/auth.py +0 -0
  98. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/auth_providers.py +0 -0
  99. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/blueprints.py +0 -0
  100. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/client_credentials.py +0 -0
  101. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/comments.py +0 -0
  102. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/components.py +0 -0
  103. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/cves.py +0 -0
  104. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/dashboard.py +0 -0
  105. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/document_analytics.py +0 -0
  106. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/document_likes.py +0 -0
  107. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/document_presence.py +0 -0
  108. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/document_templates.py +0 -0
  109. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/document_versions.py +0 -0
  110. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/documents.py +0 -0
  111. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/environments.py +0 -0
  112. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/events.py +0 -0
  113. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/graph_query.py +0 -0
  114. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/iggy_connectors.py +0 -0
  115. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/integrations.py +0 -0
  116. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/link_definitions.py +0 -0
  117. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/local_auth.py +0 -0
  118. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/maintenance.py +0 -0
  119. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/mcp_servers.py +0 -0
  120. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/mfa.py +0 -0
  121. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/oauth_metadata.py +0 -0
  122. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/operations_log.py +0 -0
  123. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/plugin_edges.py +0 -0
  124. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/plugin_entities.py +0 -0
  125. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/plugins.py +0 -0
  126. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_analysis.py +0 -0
  127. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_commit_sync.py +0 -0
  128. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_configuration.py +0 -0
  129. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_deployments.py +0 -0
  130. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_incidents.py +0 -0
  131. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_integrations.py +0 -0
  132. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_lifecycle.py +0 -0
  133. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_logs.py +0 -0
  134. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_plugins.py +0 -0
  135. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_pr_sync.py +0 -0
  136. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/project_types.py +0 -0
  137. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/projects.py +0 -0
  138. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/prompts.py +0 -0
  139. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/pull_requests.py +0 -0
  140. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/releases.py +0 -0
  141. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/roles.py +0 -0
  142. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/sa_api_keys.py +0 -0
  143. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/scoring.py +0 -0
  144. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/scoring_policies.py +0 -0
  145. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/search.py +0 -0
  146. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/secret_broker.py +0 -0
  147. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/service_accounts.py +0 -0
  148. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/status.py +0 -0
  149. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/tags.py +0 -0
  150. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/teams.py +0 -0
  151. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/ticket_harness.py +0 -0
  152. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/uploads.py +0 -0
  153. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/user_activity.py +0 -0
  154. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/users.py +0 -0
  155. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/webhooks.py +0 -0
  156. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/workflow_runs.py +0 -0
  157. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/endpoints/workflows.py +0 -0
  158. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/entrypoint.py +0 -0
  159. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/graph_ids.py +0 -0
  160. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/graph_sql.py +0 -0
  161. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/__init__.py +0 -0
  162. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/auth.py +0 -0
  163. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/egress.py +0 -0
  164. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/marketplaces.py +0 -0
  165. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/metrics.py +0 -0
  166. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/platform.py +0 -0
  167. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/sweeper.py +0 -0
  168. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/harness/tokens.py +0 -0
  169. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/__init__.py +0 -0
  170. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/attribution.py +0 -0
  171. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/endpoints.py +0 -0
  172. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/errors.py +0 -0
  173. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/flows.py +0 -0
  174. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/host_integration.py +0 -0
  175. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/models.py +0 -0
  176. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/repository.py +0 -0
  177. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/resolution.py +0 -0
  178. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/state.py +0 -0
  179. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/identity/sweeper.py +0 -0
  180. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/iggy_metrics.py +0 -0
  181. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/lifespans.py +0 -0
  182. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/llm/__init__.py +0 -0
  183. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/llm/dependencies.py +0 -0
  184. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/llm/generate.py +0 -0
  185. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/llm/tokens.py +0 -0
  186. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/__init__.py +0 -0
  187. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/log.py +0 -0
  188. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/operations.py +0 -0
  189. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/registry.py +0 -0
  190. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/state.py +0 -0
  191. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/maintenance/worker.py +0 -0
  192. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/mcp_test.py +0 -0
  193. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/middleware/__init__.py +0 -0
  194. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/middleware/rate_limit.py +0 -0
  195. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/model_calls/__init__.py +0 -0
  196. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/model_calls/schemata.toml +0 -0
  197. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/models.py +0 -0
  198. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/openapi.py +0 -0
  199. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/orphan_releases.py +0 -0
  200. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/__init__.py +0 -0
  201. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/assignment_writer.py +0 -0
  202. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/assignments.py +0 -0
  203. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/credentials.py +0 -0
  204. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/installer.py +0 -0
  205. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/lifecycle.py +0 -0
  206. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/lifecycle_dispatch.py +0 -0
  207. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/release_dispatch.py +0 -0
  208. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/reload.py +0 -0
  209. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/resolution.py +0 -0
  210. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/plugins/schemas.py +0 -0
  211. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/pr_sync/__init__.py +0 -0
  212. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/pr_sync/queue.py +0 -0
  213. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/pr_sync/service.py +0 -0
  214. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/prompts/__init__.py +0 -0
  215. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/prompts/release_notes_system.md +0 -0
  216. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/prompts/seed.py +0 -0
  217. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/py.typed +0 -0
  218. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/relationships.py +0 -0
  219. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/release_promote/__init__.py +0 -0
  220. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/release_promote/queue.py +0 -0
  221. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/release_promote/service.py +0 -0
  222. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/sbom.py +0 -0
  223. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/scoring/__init__.py +0 -0
  224. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/scoring/queue.py +0 -0
  225. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/__init__.py +0 -0
  226. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/audit.py +0 -0
  227. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/broker.py +0 -0
  228. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/identity.py +0 -0
  229. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/providers.py +0 -0
  230. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/schemata.toml +0 -0
  231. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/secret_broker/store.py +0 -0
  232. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/settings.py +0 -0
  233. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/storage/__init__.py +0 -0
  234. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/storage/client.py +0 -0
  235. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/storage/dependencies.py +0 -0
  236. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/storage/thumbnails.py +0 -0
  237. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/storage/validation.py +0 -0
  238. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/tickets/sweeper.py +0 -0
  239. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/user_document_orgs.py +0 -0
  240. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/__init__.py +0 -0
  241. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/runs.py +0 -0
  242. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/runtime_schemata.toml +0 -0
  243. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/schemata.toml +0 -0
  244. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/store.py +0 -0
  245. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/sweeper.py +0 -0
  246. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/ticket_trigger.py +0 -0
  247. {imbi_api-2.56.0 → imbi_api-2.57.0}/src/imbi/api/workflows/tickets.py +0 -0
  248. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/__init__.py +0 -0
  249. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/__init__.py +0 -0
  250. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_authentication.py +0 -0
  251. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_authorization.py +0 -0
  252. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_encryption.py +0 -0
  253. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_internal_services.py +0 -0
  254. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_login_providers.py +0 -0
  255. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_membership.py +0 -0
  256. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_oauth_server.py +0 -0
  257. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_organizations.py +0 -0
  258. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_permissions.py +0 -0
  259. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_seed.py +0 -0
  260. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_sessions.py +0 -0
  261. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/auth/test_totp.py +0 -0
  262. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/clickhouse/__init__.py +0 -0
  263. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/clickhouse/test_client.py +0 -0
  264. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/clickhouse/test_init.py +0 -0
  265. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/clickhouse/test_privacy.py +0 -0
  266. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/__init__.py +0 -0
  267. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_audit_clickhouse.py +0 -0
  268. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_client.py +0 -0
  269. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_init.py +0 -0
  270. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_integration.py +0 -0
  271. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_models.py +0 -0
  272. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/email/test_templates.py +0 -0
  273. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/__init__.py +0 -0
  274. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_admin.py +0 -0
  275. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_admin_plugins.py +0 -0
  276. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_api.py +0 -0
  277. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_platform.py +0 -0
  278. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_task_actions.py +0 -0
  279. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_task_log.py +0 -0
  280. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_agent_usage.py +0 -0
  281. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_ai_models.py +0 -0
  282. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_ai_providers.py +0 -0
  283. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_api_keys.py +0 -0
  284. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_auth.py +0 -0
  285. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_auth_providers.py +0 -0
  286. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_blueprints.py +0 -0
  287. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_caller_org_slugs.py +0 -0
  288. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_client_credentials.py +0 -0
  289. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_comments.py +0 -0
  290. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_components.py +0 -0
  291. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_credentials.py +0 -0
  292. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_cross_org_reads.py +0 -0
  293. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_cves.py +0 -0
  294. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_dashboard.py +0 -0
  295. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_analytics.py +0 -0
  296. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_likes.py +0 -0
  297. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_presence.py +0 -0
  298. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_reads.py +0 -0
  299. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_reads_sql.py +0 -0
  300. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_templates.py +0 -0
  301. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_document_versions.py +0 -0
  302. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_documents.py +0 -0
  303. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_environments.py +0 -0
  304. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_events.py +0 -0
  305. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_github_app_repository.py +0 -0
  306. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_graph_query.py +0 -0
  307. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_harness_egress.py +0 -0
  308. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_harness_secrets.py +0 -0
  309. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_iggy_connectors.py +0 -0
  310. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_init.py +0 -0
  311. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_integrations.py +0 -0
  312. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_json_fields.py +0 -0
  313. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_link_definitions.py +0 -0
  314. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_local_auth.py +0 -0
  315. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_maintenance.py +0 -0
  316. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_mcp_servers.py +0 -0
  317. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_mfa.py +0 -0
  318. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_operations_log.py +0 -0
  319. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_organizations.py +0 -0
  320. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_pagination.py +0 -0
  321. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_plugin_label_validation.py +0 -0
  322. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_plugins.py +0 -0
  323. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_analysis.py +0 -0
  324. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_commit_sync.py +0 -0
  325. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_configuration.py +0 -0
  326. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_deployments.py +0 -0
  327. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_deployments_autonomous.py +0 -0
  328. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_incidents.py +0 -0
  329. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_integrations.py +0 -0
  330. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_lifecycle.py +0 -0
  331. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_logs.py +0 -0
  332. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_plugins.py +0 -0
  333. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_response_surfacing.py +0 -0
  334. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_project_types.py +0 -0
  335. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_projects.py +0 -0
  336. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_projects_helpers.py +0 -0
  337. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_prompt_decisions.py +0 -0
  338. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_prompt_generative.py +0 -0
  339. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_prompts.py +0 -0
  340. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_pull_requests.py +0 -0
  341. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_releases.py +0 -0
  342. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_request_urls.py +0 -0
  343. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_roles.py +0 -0
  344. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_sa_api_keys.py +0 -0
  345. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_scoring.py +0 -0
  346. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_scoring_policies.py +0 -0
  347. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_search.py +0 -0
  348. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_search_index.py +0 -0
  349. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_secret_broker.py +0 -0
  350. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_service_accounts.py +0 -0
  351. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_service_writeback.py +0 -0
  352. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_shared_identifier.py +0 -0
  353. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_status.py +0 -0
  354. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_tags.py +0 -0
  355. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_teams.py +0 -0
  356. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_uploads.py +0 -0
  357. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_user_activity.py +0 -0
  358. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_users.py +0 -0
  359. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_webhooks.py +0 -0
  360. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_workflow_run_history.py +0 -0
  361. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_workflow_runs.py +0 -0
  362. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_workflow_triggers.py +0 -0
  363. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/endpoints/test_workflows.py +0 -0
  364. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/marketplaces/claude-code.json +0 -0
  365. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/release_a/harness_schemata.toml +0 -0
  366. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/release_a/tickets_schemata.toml +0 -0
  367. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/release_a_minus_1/agent_runtime_schemata.toml +0 -0
  368. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/release_a_minus_1/harness_schemata.toml +0 -0
  369. /imbi_api-2.56.0/src/imbi/api/harness/schemata.toml → /imbi_api-2.57.0/tests/fixtures/release_b/harness_schemata.toml +0 -0
  370. /imbi_api-2.56.0/src/imbi/api/tickets/schemata.toml → /imbi_api-2.57.0/tests/fixtures/release_b/tickets_schemata.toml +0 -0
  371. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/sbom/npm-realistic.json +0 -0
  372. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/sbom/pypi-realistic.json +0 -0
  373. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/fixtures/sbom/tiny.json +0 -0
  374. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/__init__.py +0 -0
  375. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_endpoints.py +0 -0
  376. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_errors.py +0 -0
  377. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_flows.py +0 -0
  378. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_host_integration.py +0 -0
  379. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_repository.py +0 -0
  380. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_resolution.py +0 -0
  381. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_state.py +0 -0
  382. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/identity/test_sweeper.py +0 -0
  383. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/middleware/test_rate_limit.py +0 -0
  384. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/secret_support.py +0 -0
  385. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/storage/__init__.py +0 -0
  386. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/storage/test_client.py +0 -0
  387. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/storage/test_init.py +0 -0
  388. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/storage/test_thumbnails.py +0 -0
  389. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/storage/test_validation.py +0 -0
  390. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/support.py +0 -0
  391. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_agent_platform.py +0 -0
  392. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_agent_task_events_e2e.py +0 -0
  393. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_agent_tools.py +0 -0
  394. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_ai_provider_tokens.py +0 -0
  395. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_app.py +0 -0
  396. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_assignment_writer.py +0 -0
  397. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_auth_settings.py +0 -0
  398. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_backfill_embeddings.py +0 -0
  399. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_blueprint_attributes.py +0 -0
  400. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_blueprint_compliance.py +0 -0
  401. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_blueprints.py +0 -0
  402. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_commit_pushed_at_repair.py +0 -0
  403. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_commit_sync_queue.py +0 -0
  404. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_commit_sync_service.py +0 -0
  405. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_component_facts.py +0 -0
  406. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_cves.py +0 -0
  407. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_deployment_status_repair.py +0 -0
  408. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_deployment_sweeper.py +0 -0
  409. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_deployment_sync_queue.py +0 -0
  410. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_deployment_sync_service.py +0 -0
  411. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_drift.py +0 -0
  412. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_entrypoint.py +0 -0
  413. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_graph_ids.py +0 -0
  414. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_graph_sql.py +0 -0
  415. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_identity_attribution.py +0 -0
  416. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_iggy_metrics.py +0 -0
  417. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_init.py +0 -0
  418. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_installer.py +0 -0
  419. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_lifecycle_dispatch.py +0 -0
  420. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_lifespans.py +0 -0
  421. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_maintenance_log.py +0 -0
  422. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_maintenance_operations.py +0 -0
  423. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_maintenance_state.py +0 -0
  424. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_maintenance_worker.py +0 -0
  425. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_model_calls.py +0 -0
  426. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_models.py +0 -0
  427. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_openapi.py +0 -0
  428. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_orphan_releases.py +0 -0
  429. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_plugin_schemas.py +0 -0
  430. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_plugins.py +0 -0
  431. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_plugins_assignments.py +0 -0
  432. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_plugins_credentials.py +0 -0
  433. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_pr_sync_queue.py +0 -0
  434. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_pr_sync_service.py +0 -0
  435. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_projects_drift_ranges.py +0 -0
  436. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_prompt_seed.py +0 -0
  437. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_pull_request_resync_clickhouse.py +0 -0
  438. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_pull_request_reviews_clickhouse.py +0 -0
  439. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_pull_requests_pending_deploy.py +0 -0
  440. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_release_dispatch.py +0 -0
  441. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_release_promote_service.py +0 -0
  442. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_sbom.py +0 -0
  443. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_scoring_queue.py +0 -0
  444. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_scoring_triggers.py +0 -0
  445. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_secret_broker.py +0 -0
  446. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_secret_github_app.py +0 -0
  447. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_secret_identity.py +0 -0
  448. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_secret_providers.py +0 -0
  449. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_settings.py +0 -0
  450. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_task_trigger.py +0 -0
  451. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_workflow_reconcile.py +0 -0
  452. {imbi_api-2.56.0 → imbi_api-2.57.0}/tests/test_workflow_tickets.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: imbi-api
3
- Version: 2.56.0
3
+ Version: 2.57.0
4
4
  Summary: Imbi is the open-source service catalog that tracks every service's ownership, deployments, and health, and runs the AI agents and workflows that fix them.
5
5
  Author-email: Alex Campbell <alexc@aweber.com>, Dave Shawley <daves@aweber.com>, "Gavin M. Roy" <gavinr@aweber.com>
6
6
  License-Expression: BSD-3-Clause
@@ -20,7 +20,7 @@ Requires-Dist: fastapi
20
20
  Requires-Dist: filetype
21
21
  Requires-Dist: httpx<1,>=0.28.1
22
22
  Requires-Dist: idna>=3.18
23
- Requires-Dist: imbi-common[databases,llm,mcp,script,sentry,server]==2.56.0
23
+ Requires-Dist: imbi-common[databases,llm,mcp,script,sentry,server]==2.57.0
24
24
  Requires-Dist: jinja2
25
25
  Requires-Dist: jsonpatch>=1.33
26
26
  Requires-Dist: jsonschema>=4.26
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "imbi-api"
3
- version = "2.56.0"
3
+ version = "2.57.0"
4
4
  description = "Imbi is the open-source service catalog that tracks every service's ownership, deployments, and health, and runs the AI agents and workflows that fix them."
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.14"
@@ -29,7 +29,7 @@ dependencies = [
29
29
  "filetype",
30
30
  "httpx>=0.28.1,<1",
31
31
  "idna>=3.18",
32
- "imbi-common[databases,llm,mcp,script,sentry,server]==2.56.0",
32
+ "imbi-common[databases,llm,mcp,script,sentry,server]==2.57.0",
33
33
  "jinja2",
34
34
  "jsonpatch>=1.33",
35
35
  "jsonschema>=4.26",
@@ -264,6 +264,7 @@ REFUSED_ROUTES: frozenset[str] = frozenset(
264
264
  'POST /organizations/{org_slug}/tickets/{short_id}/requests/{request_id}/resolve',
265
265
  'POST /organizations/{org_slug}/tickets/{short_id}/resume',
266
266
  'POST /organizations/{org_slug}/tickets/{short_id}/retry',
267
+ 'POST /organizations/{org_slug}/tickets/{short_id}/status',
267
268
  'PUT /organizations/{org_slug}/tickets/{short_id}/parent',
268
269
  'PUT /organizations/{org_slug}/tickets/{short_id}/projects/{project_id}',
269
270
  'PUT /organizations/{org_slug}/tickets/{short_id}/requires/{prerequisite}',
@@ -927,16 +927,15 @@ async def _validate_tools(
927
927
  async def _validate_subagents(
928
928
  db: graph.Pool,
929
929
  org_slug: str,
930
- agent_id: str | None,
931
930
  subagents: list[models.AgentSubagent],
932
931
  ) -> None:
933
- """Raise 422 when a subagent is the agent itself or not in the org.
932
+ """Raise 422 when a subagent is not in the org.
934
933
 
935
- Cycles are allowed: the runtime caps the delegation depth.
934
+ An agent can be its own subagent, and cycles are allowed: the
935
+ harness caps the delegation depth at 2, so a child ticket never
936
+ starts another child.
936
937
  """
937
938
  ids = [item.agent_id for item in subagents]
938
- if agent_id is not None and agent_id in ids:
939
- raise _unprocessable('An agent cannot be its own subagent')
940
939
  found = await _find_subagents(db, org_slug, ids)
941
940
  missing = sorted(set(ids) - set(found))
942
941
  if missing:
@@ -1178,7 +1177,7 @@ async def _apply(
1178
1177
  if target.tools != current.tools:
1179
1178
  await _validate_tools(db, org_slug, target.tools)
1180
1179
  if target.subagents != current.subagents:
1181
- await _validate_subagents(db, org_slug, agent_id, target.subagents)
1180
+ await _validate_subagents(db, org_slug, target.subagents)
1182
1181
  n = int(existing['_latest']) + 1
1183
1182
  # The version is written first. Its unique index stops a
1184
1183
  # concurrent save before that save changes the agent.
@@ -1324,7 +1323,7 @@ async def create_agent(
1324
1323
  await _check_model_teams(db, org_slug, snapshot, team_id)
1325
1324
  await _validate_tag_slugs(db, org_slug, snapshot.tags)
1326
1325
  await _validate_tools(db, org_slug, snapshot.tools)
1327
- await _validate_subagents(db, org_slug, None, snapshot.subagents)
1326
+ await _validate_subagents(db, org_slug, snapshot.subagents)
1328
1327
  await _assert_slug_free(db, org_slug, data.slug)
1329
1328
 
1330
1329
  now = _now()
@@ -761,7 +761,13 @@ async def _identity(
761
761
  }
762
762
  ),
763
763
  'repositories': await _repositories(db, store, task, settings),
764
- 'subagents': await _subagents(db, bundle.snapshot),
764
+ # Delegation depth is capped at 2: a child ticket cannot
765
+ # start children, so it gets no subagents.
766
+ 'subagents': (
767
+ []
768
+ if task['origin_kind'] in ticket_store.CHILD_ORIGIN_KINDS
769
+ else await _subagents(db, bundle.snapshot)
770
+ ),
765
771
  }
766
772
  )
767
773
 
@@ -1892,6 +1898,63 @@ async def attach_harness_task_project(
1892
1898
  return {'project_id': project_id, 'project_slug': slug}
1893
1899
 
1894
1900
 
1901
+ @harness_router.delete(
1902
+ '/tickets/{short_id}/projects/{project}',
1903
+ response_model=AttachedProject,
1904
+ name='detach_harness_ticket_project',
1905
+ )
1906
+ async def detach_harness_task_project(
1907
+ short_id: str,
1908
+ project: str,
1909
+ caller: harness_auth.AgentCaller,
1910
+ db: graph.Pool,
1911
+ store: tickets.Store,
1912
+ ) -> dict[str, str]:
1913
+ """Remove a project of the org from a task of the chain.
1914
+
1915
+ ``project`` is a project id or slug. The task gets a
1916
+ ``project.dissociated`` event, with the agent as the actor. A secret
1917
+ resolution reads the task's projects when it is made, so the next
1918
+ one no longer covers the project. When the project is not
1919
+ associated, nothing changes.
1920
+
1921
+ The task keeps at least one project: a grant that lists projects
1922
+ never matches a task with none, so its next ``model_inference`` key
1923
+ renewal would fail. Attach the next project first.
1924
+
1925
+ Raises:
1926
+ 401: Not a current agent token.
1927
+ 403: Another chain or another agent.
1928
+ 404: No such task.
1929
+ 409: ``task_closed``, ``task_archived``, or ``last_project``
1930
+ (it is the task's only project).
1931
+ 422: The project is not in the org, or the slug is not unique.
1932
+
1933
+ """
1934
+ task = await _chain_task(caller, short_id, db, store)
1935
+ if task['status'] == 'closed':
1936
+ raise _conflict('task_closed', f'Task {task["short_id"]} is closed')
1937
+ org_id = task['organization_id']
1938
+ org_slug = (await organization_slugs(db, [org_id])).get(org_id, '')
1939
+ [(project_id, slug)] = await tasks_api.project_slugs(
1940
+ db, org_slug, [project]
1941
+ )
1942
+ if [p['project_id'] for p in task['projects']] == [project_id]:
1943
+ raise _conflict(
1944
+ 'last_project',
1945
+ f'Project {slug} is the only project of task '
1946
+ f'{task["short_id"]}; attach the next project first',
1947
+ )
1948
+ with tasks_api.relation_errors():
1949
+ await store.dissociate_project(
1950
+ org_id,
1951
+ task['short_id'],
1952
+ project_id,
1953
+ tickets.Actor('agent', task['agent_id'], 'harness'),
1954
+ )
1955
+ return {'project_id': project_id, 'project_slug': slug}
1956
+
1957
+
1895
1958
  @harness_router.post(
1896
1959
  '/tickets/{short_id}/children',
1897
1960
  status_code=201,
@@ -1924,11 +1987,12 @@ async def create_harness_child_task(
1924
1987
 
1925
1988
  Raises:
1926
1989
  401: Not a current agent token.
1927
- 403: Another chain or another agent, ``subagent_forbidden`` (the
1928
- child agent is not in the ``subagents`` of the parent's
1929
- pinned agent version), or ``owner_forbidden`` (the owner of
1930
- the parent can no longer make agent tasks in the
1931
- organization).
1990
+ 403: Another chain or another agent, ``delegation_depth`` (the
1991
+ parent is itself a child ticket: delegation depth is capped
1992
+ at 2), ``subagent_forbidden`` (the child agent is not in the
1993
+ ``subagents`` of the parent's pinned agent version), or
1994
+ ``owner_forbidden`` (the owner of the parent can no longer
1995
+ make agent tasks in the organization).
1932
1996
  404: No such task.
1933
1997
  409: The parent is closed, the child agent is disabled, or the
1934
1998
  runner of the chain does not have a label that the child
@@ -1941,6 +2005,12 @@ async def create_harness_child_task(
1941
2005
  parent = await _chain_task(caller, short_id, db, store)
1942
2006
  if parent['status'] == 'closed':
1943
2007
  raise _conflict('task_closed', f'Task {parent["short_id"]} is closed')
2008
+ if parent['origin_kind'] in ticket_store.CHILD_ORIGIN_KINDS:
2009
+ raise autonomous.forbidden(
2010
+ 'delegation_depth',
2011
+ f'Task {parent["short_id"]} is a child ticket; delegation '
2012
+ 'depth is capped at 2.',
2013
+ )
1944
2014
  org_slugs = await organization_slugs(db, [parent['organization_id']])
1945
2015
  if not await tasks_api.may_create(
1946
2016
  db, org_slugs.get(parent['organization_id'], ''), parent['owner']
@@ -219,17 +219,7 @@ organizations_router.include_router(
219
219
  agents_router,
220
220
  prefix='/{org_slug}/agents',
221
221
  )
222
- # ADR 0028: tickets at /tickets, with ticket operation ids. The old
223
- # /agent-tasks path stays out of the OpenAPI document, so imbi-mcp has no
224
- # tools with the old names, but a saved scheduled job or script that
225
- # posts to it keeps working. The release after B removes it.
226
- # The agent token rules (imbi.api.auth.agent_api) key a route by its
227
- # endpoint, so both paths share the rule of the path mounted last.
228
- organizations_router.include_router(
229
- tickets_router,
230
- prefix='/{org_slug}/agent-tasks',
231
- include_in_schema=False,
232
- )
222
+ # ADR 0028: tickets at /tickets, with ticket operation ids.
233
223
  organizations_router.include_router(
234
224
  tickets_router,
235
225
  prefix='/{org_slug}/tickets',
@@ -42,9 +42,11 @@ from imbi.api.endpoints._pagination import (
42
42
  )
43
43
  from imbi.api.tickets.store import (
44
44
  ActorKind,
45
+ AssigneeKind,
45
46
  Channel,
46
47
  Control,
47
48
  Group,
49
+ PersonOutcome,
48
50
  Priority,
49
51
  ResolvedStatus,
50
52
  Status,
@@ -93,11 +95,38 @@ _ShortText = typing.Annotated[
93
95
  # --- Schemas -----------------------------------------------------------
94
96
 
95
97
 
98
+ class TicketRequirement(pydantic.BaseModel):
99
+ """A prerequisite of a new ticket."""
100
+
101
+ short_id: str = pydantic.Field(min_length=1, max_length=50)
102
+ gates: bool = pydantic.Field(
103
+ default=False,
104
+ description='Hold the ticket until the prerequisite closes with a '
105
+ '``done_*`` outcome.',
106
+ )
107
+
108
+
96
109
  class AgentTaskCreate(pydantic.BaseModel):
97
- agent_slug: str = pydantic.Field(min_length=1)
110
+ assignee_kind: AssigneeKind = 'agent'
111
+ agent_slug: str | None = pydantic.Field(
112
+ default=None,
113
+ min_length=1,
114
+ description='The agent of an agent ticket.',
115
+ )
116
+ assignee: pydantic.EmailStr | None = pydantic.Field(
117
+ default=None,
118
+ description='The email of the person of a person ticket. Must be '
119
+ 'in the org.',
120
+ )
98
121
  title: str = pydantic.Field(min_length=1)
99
122
  description: str = pydantic.Field(
100
- min_length=1, description='The instruction for the agent.'
123
+ min_length=1, description='What the assignee should do.'
124
+ )
125
+ requires: list[TicketRequirement] = pydantic.Field(
126
+ default_factory=list,
127
+ max_length=50,
128
+ description='The prerequisites of the ticket, by short id. An open '
129
+ 'gating prerequisite makes the ticket start ``held``.',
101
130
  )
102
131
  project_ids: list[_ShortText] = pydantic.Field(
103
132
  default_factory=list,
@@ -140,6 +169,27 @@ class AgentTaskCreate(pydantic.BaseModel):
140
169
  fields['project_ids'] = [] if legacy is None else [legacy]
141
170
  return fields
142
171
 
172
+ @pydantic.model_validator(mode='after')
173
+ def _assignee(self) -> typing.Self:
174
+ """An agent ticket names an agent; a person ticket names a
175
+ person and has no budget."""
176
+ if self.assignee_kind == 'agent':
177
+ if self.agent_slug is None or self.assignee is not None:
178
+ raise ValueError('an agent ticket needs agent_slug only')
179
+ elif (
180
+ self.assignee is None
181
+ or self.agent_slug is not None
182
+ or self.budget is not None
183
+ ):
184
+ raise ValueError(
185
+ 'a person ticket needs assignee, and no agent_slug or budget'
186
+ )
187
+ if len({r.short_id.upper() for r in self.requires}) < len(
188
+ self.requires
189
+ ):
190
+ raise ValueError('requires names a ticket more than once')
191
+ return self
192
+
143
193
 
144
194
  class AgentTaskRetry(pydantic.BaseModel):
145
195
  note: str | None = pydantic.Field(
@@ -203,15 +253,17 @@ class TaskProject(pydantic.BaseModel):
203
253
  class AgentTaskResponse(pydantic.BaseModel):
204
254
  id: uuid.UUID
205
255
  short_id: str
206
- #: ``None`` on a ticket assigned to a person, which the next release
207
- #: writes; this release reads such a ticket during that rollout.
208
- agent_id: str | None
209
- agent_version: int | None
256
+ #: ``agent``: the agent columns are set. ``person``: ``assignee`` is
257
+ #: set and the agent columns are ``None`` (ADR 0028).
258
+ assignee_kind: AssigneeKind = 'agent'
259
+ assignee: str | None = None
260
+ agent_id: str | None = None
261
+ agent_version: int | None = None
210
262
  prompt_version: int | None = None
211
263
  #: The version of the organization's agent platform configuration
212
264
  #: when the task was made. ``None``: the defaults apply.
213
265
  platform_config_version: int | None = None
214
- service_account_id: str | None
266
+ service_account_id: str | None = None
215
267
  #: The projects of the task, oldest first. Each slug is the slug
216
268
  #: when the project was associated.
217
269
  projects: list[TaskProject]
@@ -386,8 +438,9 @@ class RelatedTask(pydantic.BaseModel):
386
438
 
387
439
  short_id: str
388
440
  title: str
389
- #: ``None`` on a ticket assigned to a person.
390
- agent_id: str | None
441
+ assignee_kind: AssigneeKind = 'agent'
442
+ assignee: str | None = None
443
+ agent_id: str | None = None
391
444
  status: Status
392
445
  outcome: str | None = None
393
446
  created_at: datetime.datetime
@@ -440,6 +493,29 @@ class TicketDependencySet(pydantic.BaseModel):
440
493
  )
441
494
 
442
495
 
496
+ class TicketStatusSet(pydantic.BaseModel):
497
+ """A status change of a person ticket (ADR 0028)."""
498
+
499
+ status: typing.Literal['open', 'in_progress', 'blocked', 'closed']
500
+ outcome: PersonOutcome | None = pydantic.Field(
501
+ default=None, description='Required to close, else not allowed.'
502
+ )
503
+ reason: str | None = pydantic.Field(
504
+ default=None,
505
+ min_length=1,
506
+ max_length=MAX_TEXT_LENGTH,
507
+ description='Why. Required to block.',
508
+ )
509
+
510
+ @pydantic.model_validator(mode='after')
511
+ def _fields(self) -> typing.Self:
512
+ if (self.status == 'closed') != (self.outcome is not None):
513
+ raise ValueError('send outcome to close, and only to close')
514
+ if self.status == 'blocked' and self.reason is None:
515
+ raise ValueError('send a reason to block')
516
+ return self
517
+
518
+
443
519
  class TicketParentSet(pydantic.BaseModel):
444
520
  """The new parent of a ticket."""
445
521
 
@@ -559,6 +635,15 @@ def check_payload_size(
559
635
  return size
560
636
 
561
637
 
638
+ def _person_ticket(short_id: str) -> fastapi.HTTPException:
639
+ """409 for a change that applies only to an agent ticket."""
640
+ return _conflict(
641
+ 'person_ticket',
642
+ f'Task {short_id!r} is a person ticket; this applies only to an '
643
+ 'agent ticket',
644
+ )
645
+
646
+
562
647
  def _conflict(
563
648
  error: str, message: str, **extra: typing.Any
564
649
  ) -> fastapi.HTTPException:
@@ -863,6 +948,8 @@ async def _set_control(
863
948
  status_code=409,
864
949
  detail=f'Task {short_id!r} has a cancel that is not done yet',
865
950
  ) from e
951
+ except tickets.WrongAssigneeKind as e:
952
+ raise _person_ticket(short_id) from e
866
953
 
867
954
 
868
955
  async def may_create(db: graph.Graph, org_slug: str, email: str) -> bool:
@@ -1081,8 +1168,11 @@ async def create_agent_task(
1081
1168
  str | None, _header('Idempotency-Key')
1082
1169
  ] = None,
1083
1170
  ) -> dict[str, typing.Any]:
1084
- """Make a task for an agent.
1171
+ """Make a ticket for an agent or, with ``assignee_kind`` ``person``,
1172
+ for a person (ADR 0028).
1085
1173
 
1174
+ An agent ticket starts ``queued`` and a person ticket ``open``; an
1175
+ open gating prerequisite in ``requires`` makes it start ``held``.
1086
1176
  A person owns the tasks that they make. The scheduler and the
1087
1177
  gateway also make tasks, with a ``schedule`` or a ``webhook``
1088
1178
  origin that they name in headers (see :func:`task_origin`). The
@@ -1099,10 +1189,11 @@ async def create_agent_task(
1099
1189
  :func:`_owner`).
1100
1190
  404: No such organization.
1101
1191
  409: The agent is disabled.
1102
- 422: The agent or the project is not in the org, the budget is
1103
- more than the agent's task budget, a service does not name
1104
- its origin, the webhook does not exist, or the key has the
1105
- shape of a workflow step key (``<uuid>:<node_key>``).
1192
+ 422: The agent, the assignee, or the project is not in the org,
1193
+ the budget is more than the agent's task budget, a service
1194
+ does not name its origin, the webhook does not exist, a
1195
+ prerequisite is not found, or the key has the shape of a
1196
+ workflow step key (``<uuid>:<node_key>``).
1106
1197
 
1107
1198
  """
1108
1199
  origin = task_origin(
@@ -1179,7 +1270,8 @@ async def make_task(
1179
1270
  actor: tickets.Actor,
1180
1271
  output_schema: dict[str, typing.Any] | None = None,
1181
1272
  ) -> tuple[dict[str, typing.Any], bool]:
1182
- """Make a task with the agent and prompt versions that it has now.
1273
+ """Make a ticket. An agent ticket gets the agent and prompt
1274
+ versions that the agent has now.
1183
1275
 
1184
1276
  Return the task, and ``False`` when a task with the key exists.
1185
1277
  ``output_schema`` is the JSON Schema of the structured output that
@@ -1187,59 +1279,81 @@ async def make_task(
1187
1279
 
1188
1280
  Raises:
1189
1281
  409: The agent is disabled.
1190
- 422: The agent or the project is not in the org, or the budget
1191
- is more than the agent's task budget.
1282
+ 422: The agent, the assignee, or the project is not in the org,
1283
+ the budget is more than the agent's task budget, or a
1284
+ prerequisite is not found.
1192
1285
 
1193
1286
  """
1194
- agent = await _fetch_agent(db, org_slug, data.agent_slug)
1195
- if not agent.get('enabled', True):
1196
- raise fastapi.HTTPException(
1197
- status_code=409, detail=f'Agent {data.agent_slug!r} is disabled'
1198
- )
1199
- raw_settings: typing.Any = agent.get('settings') or {}
1200
- settings = (
1201
- models.AgentSettings.model_validate_json(raw_settings)
1202
- if isinstance(raw_settings, str)
1203
- else models.AgentSettings.model_validate(raw_settings)
1204
- )
1205
- budget = task_budget(settings, data.budget)
1206
1287
  projects = await project_slugs(db, org_slug, data.project_ids)
1207
- agent_id = str(agent['id'])
1208
- service_account_id = await agents.ensure_service_account(
1209
- db, agent_id, str(agent.get('name', data.agent_slug))
1210
- )
1211
- agent_version = int(agent.get('version') or 1)
1212
- prompt_version = agent.get('prompt_version')
1213
- return await store.create(
1214
- tickets.NewTask(
1215
- organization_id=org_id,
1216
- agent_id=agent_id,
1217
- agent_version=agent_version,
1218
- prompt_version=prompt_version,
1219
- service_account_id=service_account_id,
1220
- projects=projects,
1221
- title=data.title,
1222
- description=data.description,
1223
- origin_kind=origin.kind,
1224
- origin_id=origin.id,
1225
- origin=origin.record,
1226
- idempotency_key=key,
1227
- owner=owner,
1228
- budget=budget,
1229
- output_schema=output_schema,
1230
- priority=data.priority,
1231
- ),
1232
- actor,
1233
- {
1234
- 'title': data.title,
1235
- 'description': data.description,
1236
- 'origin': origin.record,
1237
- 'budget': None if budget is None else str(budget),
1238
- 'agent_version': agent_version,
1239
- 'prompt_version': prompt_version,
1240
- 'priority': data.priority,
1241
- },
1242
- )
1288
+ agent_id = service_account_id = None
1289
+ agent_version = prompt_version = budget = None
1290
+ if data.assignee_kind == 'person':
1291
+ if not await db.execute(
1292
+ _MEMBER_QUERY,
1293
+ {'email': data.assignee, 'org_slug': org_slug},
1294
+ ['email'],
1295
+ ):
1296
+ raise _unprocessable(f'User {data.assignee!r} is not in the org')
1297
+ else:
1298
+ slug = data.agent_slug or ''
1299
+ agent = await _fetch_agent(db, org_slug, slug)
1300
+ if not agent.get('enabled', True):
1301
+ raise fastapi.HTTPException(
1302
+ status_code=409, detail=f'Agent {slug!r} is disabled'
1303
+ )
1304
+ raw_settings: typing.Any = agent.get('settings') or {}
1305
+ settings = (
1306
+ models.AgentSettings.model_validate_json(raw_settings)
1307
+ if isinstance(raw_settings, str)
1308
+ else models.AgentSettings.model_validate(raw_settings)
1309
+ )
1310
+ budget = task_budget(settings, data.budget)
1311
+ agent_id = str(agent['id'])
1312
+ service_account_id = await agents.ensure_service_account(
1313
+ db, agent_id, str(agent.get('name', slug))
1314
+ )
1315
+ agent_version = int(agent.get('version') or 1)
1316
+ prompt_version = agent.get('prompt_version')
1317
+ try:
1318
+ return await store.create(
1319
+ tickets.NewTask(
1320
+ organization_id=org_id,
1321
+ agent_id=agent_id,
1322
+ agent_version=agent_version,
1323
+ prompt_version=prompt_version,
1324
+ service_account_id=service_account_id,
1325
+ projects=projects,
1326
+ title=data.title,
1327
+ description=data.description,
1328
+ origin_kind=origin.kind,
1329
+ origin_id=origin.id,
1330
+ origin=origin.record,
1331
+ idempotency_key=key,
1332
+ owner=owner,
1333
+ budget=budget,
1334
+ output_schema=output_schema,
1335
+ priority=data.priority,
1336
+ assignee_kind=data.assignee_kind,
1337
+ assignee=data.assignee,
1338
+ requires=[
1339
+ (r.short_id.upper(), r.gates) for r in data.requires
1340
+ ],
1341
+ ),
1342
+ actor,
1343
+ {
1344
+ 'title': data.title,
1345
+ 'description': data.description,
1346
+ 'origin': origin.record,
1347
+ 'budget': None if budget is None else str(budget),
1348
+ 'agent_version': agent_version,
1349
+ 'prompt_version': prompt_version,
1350
+ 'priority': data.priority,
1351
+ 'assignee_kind': data.assignee_kind,
1352
+ 'assignee': data.assignee,
1353
+ },
1354
+ )
1355
+ except tickets.TaskNotFound as e:
1356
+ raise _unprocessable(f'Prerequisite {str(e)!r} not found') from e
1243
1357
 
1244
1358
 
1245
1359
  @tickets_router.get('/', response_model=list[AgentTaskListItem])
@@ -1724,6 +1838,8 @@ async def retry_agent_task(
1724
1838
  user = auth.require_user
1725
1839
  await _require_read(auth)
1726
1840
  task = await _get_task(store, org_id, short_id)
1841
+ if task['assignee_kind'] == 'person':
1842
+ raise _person_ticket(short_id)
1727
1843
  if task['status'] != 'closed':
1728
1844
  raise fastapi.HTTPException(
1729
1845
  status_code=409, detail=f'Task {short_id!r} is not closed'
@@ -1806,6 +1922,60 @@ async def reassign_agent_task(
1806
1922
  ) from e
1807
1923
 
1808
1924
 
1925
+ @tickets_router.post('/{short_id}/status', response_model=AgentTaskResponse)
1926
+ async def set_ticket_status(
1927
+ org_id: OrgId,
1928
+ short_id: str,
1929
+ data: TicketStatusSet,
1930
+ store: tickets.Store,
1931
+ auth: typing.Annotated[
1932
+ permissions.AuthContext, fastapi.Depends(permissions.get_current_user)
1933
+ ],
1934
+ ) -> dict[str, typing.Any]:
1935
+ """Move a person ticket to a status, or close it (ADR 0028).
1936
+
1937
+ ``open`` -> ``in_progress``; ``open`` or ``in_progress`` ->
1938
+ ``blocked`` (with a ``reason``) and back; ``closed`` with an
1939
+ ``outcome`` from every status. A ``held`` ticket opens when its
1940
+ gating prerequisites are done. The assignee makes these changes;
1941
+ other people need ``ticket:manage``.
1942
+
1943
+ Raises:
1944
+ 403: The caller is not a person, or is not the assignee and has
1945
+ no ``ticket:manage``.
1946
+ 404: No such task.
1947
+ 409: The task is closed (``Task ... is closed``), is an agent
1948
+ ticket (``agent_ticket``), or cannot move from its status
1949
+ (``transition_invalid``).
1950
+
1951
+ """
1952
+ user = auth.require_user
1953
+ task = await _get_task(store, org_id, short_id)
1954
+ if (task['assignee'] or '').lower() != user.email.lower():
1955
+ await _require_manage(auth)
1956
+ try:
1957
+ return await store.set_person_status(
1958
+ org_id,
1959
+ task['short_id'],
1960
+ data.status,
1961
+ _actor(auth),
1962
+ outcome=data.outcome,
1963
+ reason=data.reason,
1964
+ )
1965
+ except tickets.TaskClosed as e:
1966
+ raise fastapi.HTTPException(
1967
+ status_code=409, detail=f'Task {short_id!r} is closed'
1968
+ ) from e
1969
+ except tickets.WrongAssigneeKind as e:
1970
+ raise _conflict(
1971
+ 'agent_ticket',
1972
+ f'Task {short_id!r} is an agent ticket; its status follows its '
1973
+ 'sessions',
1974
+ ) from e
1975
+ except tickets.TransitionInvalid as e:
1976
+ raise _conflict('transition_invalid', str(e)) from e
1977
+
1978
+
1809
1979
  @tickets_router.post('/{short_id}/priority', response_model=AgentTaskResponse)
1810
1980
  async def set_agent_task_priority(
1811
1981
  org_id: OrgId,
@@ -1985,6 +2155,8 @@ async def reply_agent_task(
1985
2155
  status_code=409,
1986
2156
  detail=f'Task {short_id!r} has a cancel that is not done yet',
1987
2157
  ) from e
2158
+ except tickets.WrongAssigneeKind as e:
2159
+ raise _person_ticket(short_id) from e
1988
2160
 
1989
2161
 
1990
2162
  @tickets_router.get('/{short_id}/relations', response_model=AgentTaskRelations)