keboola-cli 0.63.4__py3-none-any.whl
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.
- keboola_agent_cli/__init__.py +34 -0
- keboola_agent_cli/__main__.py +5 -0
- keboola_agent_cli/_ui_dist/assets/arc-DhFYIddx.js +2 -0
- keboola_agent_cli/_ui_dist/assets/arc-DhFYIddx.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/architecture-7EHR7CIX-hNCijx_H.js +1 -0
- keboola_agent_cli/_ui_dist/assets/architectureDiagram-3BPJPVTR-C6hUlprM.js +37 -0
- keboola_agent_cli/_ui_dist/assets/architectureDiagram-3BPJPVTR-C6hUlprM.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/array-BifhSqXX.js +2 -0
- keboola_agent_cli/_ui_dist/assets/array-BifhSqXX.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/blockDiagram-GPEHLZMM-DC7qY9i4.js +133 -0
- keboola_agent_cli/_ui_dist/assets/blockDiagram-GPEHLZMM-DC7qY9i4.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/c4Diagram-AAUBKEIU-5Lh44evt.js +11 -0
- keboola_agent_cli/_ui_dist/assets/c4Diagram-AAUBKEIU-5Lh44evt.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/channel-DBMrXlxx.js +2 -0
- keboola_agent_cli/_ui_dist/assets/channel-DBMrXlxx.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-2J33WTMH-Coy82EBh.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-2J33WTMH-Coy82EBh.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-3OPIFGDE-BQC5CRHI.js +63 -0
- keboola_agent_cli/_ui_dist/assets/chunk-3OPIFGDE-BQC5CRHI.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-4BX2VUAB-DUuEt70o.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-4BX2VUAB-DUuEt70o.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-55IACEB6-BvR-6chF.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-55IACEB6-BvR-6chF.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-5ZQYHXKU-BjcTN7ul.js +3 -0
- keboola_agent_cli/_ui_dist/assets/chunk-5ZQYHXKU-BjcTN7ul.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-727SXJPM-C0zxqqRN.js +207 -0
- keboola_agent_cli/_ui_dist/assets/chunk-727SXJPM-C0zxqqRN.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-AQP2D5EJ-CXf7rIlZ.js +232 -0
- keboola_agent_cli/_ui_dist/assets/chunk-AQP2D5EJ-CXf7rIlZ.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-BSJP7CBP-Oj_FO9Q7.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-BSJP7CBP-Oj_FO9Q7.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-CSCIHK7Q-CcTsLrFc.js +124 -0
- keboola_agent_cli/_ui_dist/assets/chunk-CSCIHK7Q-CcTsLrFc.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-FMBD7UC4-FH-zLkkW.js +16 -0
- keboola_agent_cli/_ui_dist/assets/chunk-FMBD7UC4-FH-zLkkW.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-L5ZTLDWV-B1Ky_e7O.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-L5ZTLDWV-B1Ky_e7O.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-ND2GUHAM-BHz1rpbm.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-ND2GUHAM-BHz1rpbm.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-NNHCCRGN-DlpIbxXb.js +160 -0
- keboola_agent_cli/_ui_dist/assets/chunk-NNHCCRGN-DlpIbxXb.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-NZK2D7GU-tnrSoegS.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-NZK2D7GU-tnrSoegS.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-O5CBEL6O-DxxqDH0l.js +71 -0
- keboola_agent_cli/_ui_dist/assets/chunk-O5CBEL6O-DxxqDH0l.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/chunk-QZHKN3VN-CSjc2gjj.js +2 -0
- keboola_agent_cli/_ui_dist/assets/chunk-QZHKN3VN-CSjc2gjj.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/classDiagram-4FO5ZUOK-BuZcZu85.js +2 -0
- keboola_agent_cli/_ui_dist/assets/classDiagram-4FO5ZUOK-BuZcZu85.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/classDiagram-v2-Q7XG4LA2-BuZcZu85.js +2 -0
- keboola_agent_cli/_ui_dist/assets/classDiagram-v2-Q7XG4LA2-BuZcZu85.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/cose-bilkent-S5V4N54A-Y0L8LDMa.js +2 -0
- keboola_agent_cli/_ui_dist/assets/cose-bilkent-S5V4N54A-Y0L8LDMa.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/cytoscape.esm-C8YCVR3_.js +322 -0
- keboola_agent_cli/_ui_dist/assets/cytoscape.esm-C8YCVR3_.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/dagre-BM42HDAG-UZ-9BTqF.js +5 -0
- keboola_agent_cli/_ui_dist/assets/dagre-BM42HDAG-UZ-9BTqF.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/dagre-Bx709z4p.js +2 -0
- keboola_agent_cli/_ui_dist/assets/dagre-Bx709z4p.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/defaultLocale-C8Fc0cco.js +2 -0
- keboola_agent_cli/_ui_dist/assets/defaultLocale-C8Fc0cco.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/diagram-2AECGRRQ-DoDQ60wi.js +44 -0
- keboola_agent_cli/_ui_dist/assets/diagram-2AECGRRQ-DoDQ60wi.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/diagram-5GNKFQAL-CMGFxpUs.js +11 -0
- keboola_agent_cli/_ui_dist/assets/diagram-5GNKFQAL-CMGFxpUs.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/diagram-KO2AKTUF-1uGDa-Iu.js +4 -0
- keboola_agent_cli/_ui_dist/assets/diagram-KO2AKTUF-1uGDa-Iu.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/diagram-LMA3HP47-XtFH7B51.js +25 -0
- keboola_agent_cli/_ui_dist/assets/diagram-LMA3HP47-XtFH7B51.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/diagram-OG6HWLK6-B4_Te1T5.js +25 -0
- keboola_agent_cli/_ui_dist/assets/diagram-OG6HWLK6-B4_Te1T5.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/dist-Di6zmlv0.js +2 -0
- keboola_agent_cli/_ui_dist/assets/dist-Di6zmlv0.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/erDiagram-TEJ5UH35-NjQkrdFt.js +86 -0
- keboola_agent_cli/_ui_dist/assets/erDiagram-TEJ5UH35-NjQkrdFt.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/eventmodeling-FCH6USID-BrJMIks8.js +1 -0
- keboola_agent_cli/_ui_dist/assets/flowDiagram-I6XJVG4X-CIr8DWl7.js +163 -0
- keboola_agent_cli/_ui_dist/assets/flowDiagram-I6XJVG4X-CIr8DWl7.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/ganttDiagram-6RSMTGT7-C1VY_xbQ.js +293 -0
- keboola_agent_cli/_ui_dist/assets/ganttDiagram-6RSMTGT7-C1VY_xbQ.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/gitGraph-WXDBUCRP-COacYjo-.js +1 -0
- keboola_agent_cli/_ui_dist/assets/gitGraphDiagram-PVQCEYII-DQT8-kg2.js +107 -0
- keboola_agent_cli/_ui_dist/assets/gitGraphDiagram-PVQCEYII-DQT8-kg2.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/graphlib-B8gBHxth.js +2 -0
- keboola_agent_cli/_ui_dist/assets/graphlib-B8gBHxth.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/index-CMq50kkV.css +1 -0
- keboola_agent_cli/_ui_dist/assets/index-D8W97DAz.js +118 -0
- keboola_agent_cli/_ui_dist/assets/index-D8W97DAz.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/info-J43DQDTF-DdCTRIzU.js +1 -0
- keboola_agent_cli/_ui_dist/assets/infoDiagram-5YYISTIA-C77rsoTp.js +3 -0
- keboola_agent_cli/_ui_dist/assets/infoDiagram-5YYISTIA-C77rsoTp.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/init-D6jRqBbL.js +2 -0
- keboola_agent_cli/_ui_dist/assets/init-D6jRqBbL.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/ishikawaDiagram-YF4QCWOH-BcTbXaLy.js +71 -0
- keboola_agent_cli/_ui_dist/assets/ishikawaDiagram-YF4QCWOH-BcTbXaLy.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/journeyDiagram-JHISSGLW-BejeAJQ_.js +140 -0
- keboola_agent_cli/_ui_dist/assets/journeyDiagram-JHISSGLW-BejeAJQ_.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/kanban-definition-UN3LZRKU-BRNz_UrH.js +90 -0
- keboola_agent_cli/_ui_dist/assets/kanban-definition-UN3LZRKU-BRNz_UrH.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/katex-C4eR7coU.js +258 -0
- keboola_agent_cli/_ui_dist/assets/katex-C4eR7coU.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/line-CzAQKFbJ.js +2 -0
- keboola_agent_cli/_ui_dist/assets/line-CzAQKFbJ.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/linear-DUNFFdck.js +2 -0
- keboola_agent_cli/_ui_dist/assets/linear-DUNFFdck.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/mermaid-parser.core-CpuBOkFa.js +5 -0
- keboola_agent_cli/_ui_dist/assets/mermaid-parser.core-CpuBOkFa.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/mindmap-definition-RKZ34NQL-9EJQNjH0.js +97 -0
- keboola_agent_cli/_ui_dist/assets/mindmap-definition-RKZ34NQL-9EJQNjH0.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/ordinal-hYBb2elL.js +2 -0
- keboola_agent_cli/_ui_dist/assets/ordinal-hYBb2elL.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/packet-YPE3B663-DLiiw_B2.js +1 -0
- keboola_agent_cli/_ui_dist/assets/path-BWPyau1x.js +2 -0
- keboola_agent_cli/_ui_dist/assets/path-BWPyau1x.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/pie-LRSECV5Y-CRoO8G1g.js +1 -0
- keboola_agent_cli/_ui_dist/assets/pieDiagram-4H26LBE5-XH4cy6Cb.js +31 -0
- keboola_agent_cli/_ui_dist/assets/pieDiagram-4H26LBE5-XH4cy6Cb.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/quadrantDiagram-W4KKPZXB-fdhc93U8.js +8 -0
- keboola_agent_cli/_ui_dist/assets/quadrantDiagram-W4KKPZXB-fdhc93U8.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/radar-GUYGQ44K-DAlLVJHm.js +1 -0
- keboola_agent_cli/_ui_dist/assets/requirementDiagram-4Y6WPE33-a94eP3R9.js +85 -0
- keboola_agent_cli/_ui_dist/assets/requirementDiagram-4Y6WPE33-a94eP3R9.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/rough.esm-CSKSodPl.js +2 -0
- keboola_agent_cli/_ui_dist/assets/rough.esm-CSKSodPl.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/sankeyDiagram-5OEKKPKP-jcBa02sp.js +41 -0
- keboola_agent_cli/_ui_dist/assets/sankeyDiagram-5OEKKPKP-jcBa02sp.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/sequenceDiagram-3UESZ5HK-A5-GGM-e.js +163 -0
- keboola_agent_cli/_ui_dist/assets/sequenceDiagram-3UESZ5HK-A5-GGM-e.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/src-ZI-V_AF0.js +2 -0
- keboola_agent_cli/_ui_dist/assets/src-ZI-V_AF0.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/stateDiagram-AJRCARHV-BKAA5rqE.js +2 -0
- keboola_agent_cli/_ui_dist/assets/stateDiagram-AJRCARHV-BKAA5rqE.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/stateDiagram-v2-BHNVJYJU-DnJwJBsE.js +2 -0
- keboola_agent_cli/_ui_dist/assets/stateDiagram-v2-BHNVJYJU-DnJwJBsE.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/timeline-definition-PNZ67QCA-Cy39jp8b.js +121 -0
- keboola_agent_cli/_ui_dist/assets/timeline-definition-PNZ67QCA-Cy39jp8b.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/treeView-BLDUP644-DbLYl23-.js +1 -0
- keboola_agent_cli/_ui_dist/assets/treemap-LRROVOQU-Bp0eGlOt.js +1 -0
- keboola_agent_cli/_ui_dist/assets/vennDiagram-CIIHVFJN-BGECKubd.js +35 -0
- keboola_agent_cli/_ui_dist/assets/vennDiagram-CIIHVFJN-BGECKubd.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/wardley-L42UT6IY-D4yH4jqS.js +1 -0
- keboola_agent_cli/_ui_dist/assets/wardleyDiagram-YWT4CUSO-D6XRG3cZ.js +79 -0
- keboola_agent_cli/_ui_dist/assets/wardleyDiagram-YWT4CUSO-D6XRG3cZ.js.map +1 -0
- keboola_agent_cli/_ui_dist/assets/xychartDiagram-2RQKCTM6-DRre-pfZ.js +8 -0
- keboola_agent_cli/_ui_dist/assets/xychartDiagram-2RQKCTM6-DRre-pfZ.js.map +1 -0
- keboola_agent_cli/_ui_dist/index.html +50 -0
- keboola_agent_cli/ai_client.py +83 -0
- keboola_agent_cli/auto_update.py +550 -0
- keboola_agent_cli/changelog.py +1198 -0
- keboola_agent_cli/cli.py +448 -0
- keboola_agent_cli/client.py +3422 -0
- keboola_agent_cli/commands/__init__.py +0 -0
- keboola_agent_cli/commands/_data_app_git.py +343 -0
- keboola_agent_cli/commands/_helpers.py +377 -0
- keboola_agent_cli/commands/_metadata_input.py +49 -0
- keboola_agent_cli/commands/_semantic_layer_crud.py +632 -0
- keboola_agent_cli/commands/_semantic_layer_helpers.py +44 -0
- keboola_agent_cli/commands/_semantic_layer_reference_data.py +247 -0
- keboola_agent_cli/commands/agent.py +968 -0
- keboola_agent_cli/commands/branch.py +423 -0
- keboola_agent_cli/commands/changelog.py +168 -0
- keboola_agent_cli/commands/component.py +216 -0
- keboola_agent_cli/commands/config.py +2442 -0
- keboola_agent_cli/commands/context.py +1481 -0
- keboola_agent_cli/commands/data_app.py +1279 -0
- keboola_agent_cli/commands/dev_portal.py +584 -0
- keboola_agent_cli/commands/doctor.py +37 -0
- keboola_agent_cli/commands/encrypt.py +145 -0
- keboola_agent_cli/commands/feature.py +311 -0
- keboola_agent_cli/commands/flow.py +948 -0
- keboola_agent_cli/commands/http_client.py +157 -0
- keboola_agent_cli/commands/init.py +279 -0
- keboola_agent_cli/commands/job.py +661 -0
- keboola_agent_cli/commands/kai.py +301 -0
- keboola_agent_cli/commands/lineage.py +1464 -0
- keboola_agent_cli/commands/org.py +292 -0
- keboola_agent_cli/commands/permissions.py +360 -0
- keboola_agent_cli/commands/project.py +1192 -0
- keboola_agent_cli/commands/repl.py +243 -0
- keboola_agent_cli/commands/schedule.py +340 -0
- keboola_agent_cli/commands/search.py +178 -0
- keboola_agent_cli/commands/semantic_layer.py +939 -0
- keboola_agent_cli/commands/serve.py +272 -0
- keboola_agent_cli/commands/sharing.py +340 -0
- keboola_agent_cli/commands/storage.py +2630 -0
- keboola_agent_cli/commands/stream.py +266 -0
- keboola_agent_cli/commands/sync.py +1277 -0
- keboola_agent_cli/commands/tool.py +206 -0
- keboola_agent_cli/commands/version.py +186 -0
- keboola_agent_cli/commands/workspace.py +635 -0
- keboola_agent_cli/config_store.py +582 -0
- keboola_agent_cli/constants.py +528 -0
- keboola_agent_cli/data_science_client.py +342 -0
- keboola_agent_cli/dev_portal_client.py +323 -0
- keboola_agent_cli/errors.py +248 -0
- keboola_agent_cli/http_base.py +315 -0
- keboola_agent_cli/json_utils.py +126 -0
- keboola_agent_cli/lib.py +536 -0
- keboola_agent_cli/manage_client.py +324 -0
- keboola_agent_cli/metastore_client.py +214 -0
- keboola_agent_cli/models.py +427 -0
- keboola_agent_cli/output.py +1084 -0
- keboola_agent_cli/permissions.py +469 -0
- keboola_agent_cli/py.typed +3 -0
- keboola_agent_cli/result_models.py +271 -0
- keboola_agent_cli/server/__init__.py +34 -0
- keboola_agent_cli/server/agent_runner.py +1289 -0
- keboola_agent_cli/server/agents_store.py +325 -0
- keboola_agent_cli/server/app.py +764 -0
- keboola_agent_cli/server/auth.py +117 -0
- keboola_agent_cli/server/dependencies.py +149 -0
- keboola_agent_cli/server/pricing.py +303 -0
- keboola_agent_cli/server/routers/__init__.py +1 -0
- keboola_agent_cli/server/routers/agents.py +616 -0
- keboola_agent_cli/server/routers/ai_chat.py +129 -0
- keboola_agent_cli/server/routers/branches.py +133 -0
- keboola_agent_cli/server/routers/components.py +48 -0
- keboola_agent_cli/server/routers/configs.py +507 -0
- keboola_agent_cli/server/routers/data_apps.py +384 -0
- keboola_agent_cli/server/routers/dev_portal.py +67 -0
- keboola_agent_cli/server/routers/encrypt.py +35 -0
- keboola_agent_cli/server/routers/feature.py +179 -0
- keboola_agent_cli/server/routers/flows.py +204 -0
- keboola_agent_cli/server/routers/health.py +53 -0
- keboola_agent_cli/server/routers/jobs.py +175 -0
- keboola_agent_cli/server/routers/kai.py +80 -0
- keboola_agent_cli/server/routers/lineage.py +226 -0
- keboola_agent_cli/server/routers/mcp.py +70 -0
- keboola_agent_cli/server/routers/members.py +170 -0
- keboola_agent_cli/server/routers/org.py +96 -0
- keboola_agent_cli/server/routers/projects.py +106 -0
- keboola_agent_cli/server/routers/schedules.py +54 -0
- keboola_agent_cli/server/routers/search.py +30 -0
- keboola_agent_cli/server/routers/semantic_layer.py +650 -0
- keboola_agent_cli/server/routers/sharing.py +86 -0
- keboola_agent_cli/server/routers/storage.py +574 -0
- keboola_agent_cli/server/routers/stream.py +100 -0
- keboola_agent_cli/server/routers/workspaces.py +302 -0
- keboola_agent_cli/server/run_broadcaster.py +329 -0
- keboola_agent_cli/server/sse.py +25 -0
- keboola_agent_cli/services/__init__.py +0 -0
- keboola_agent_cli/services/_encryption.py +217 -0
- keboola_agent_cli/services/_semantic_layer_cascade.py +147 -0
- keboola_agent_cli/services/_semantic_layer_crud.py +382 -0
- keboola_agent_cli/services/_semantic_layer_internals.py +1078 -0
- keboola_agent_cli/services/_semantic_layer_lookup.py +181 -0
- keboola_agent_cli/services/_semantic_layer_reference_data.py +217 -0
- keboola_agent_cli/services/_sync_bindings.py +456 -0
- keboola_agent_cli/services/_sync_branch.py +191 -0
- keboola_agent_cli/services/_sync_bulk.py +228 -0
- keboola_agent_cli/services/_sync_clone.py +163 -0
- keboola_agent_cli/services/_sync_models.py +97 -0
- keboola_agent_cli/services/_sync_push_ops.py +369 -0
- keboola_agent_cli/services/_sync_storage.py +376 -0
- keboola_agent_cli/services/_sync_writeback.py +167 -0
- keboola_agent_cli/services/agent_service.py +458 -0
- keboola_agent_cli/services/base.py +175 -0
- keboola_agent_cli/services/branch_service.py +588 -0
- keboola_agent_cli/services/component_service.py +694 -0
- keboola_agent_cli/services/config_service.py +2099 -0
- keboola_agent_cli/services/data_app_git_service.py +224 -0
- keboola_agent_cli/services/data_app_service.py +2082 -0
- keboola_agent_cli/services/deep_lineage_service.py +1322 -0
- keboola_agent_cli/services/dev_portal_service.py +345 -0
- keboola_agent_cli/services/doctor_service.py +445 -0
- keboola_agent_cli/services/encrypt_service.py +87 -0
- keboola_agent_cli/services/feature_service.py +268 -0
- keboola_agent_cli/services/flow_service.py +769 -0
- keboola_agent_cli/services/flow_validation.py +188 -0
- keboola_agent_cli/services/http_forwarder_service.py +236 -0
- keboola_agent_cli/services/job_idempotency_store.py +285 -0
- keboola_agent_cli/services/job_service.py +797 -0
- keboola_agent_cli/services/kai_service.py +367 -0
- keboola_agent_cli/services/lineage_service.py +274 -0
- keboola_agent_cli/services/mcp_service.py +1498 -0
- keboola_agent_cli/services/mcp_transport.py +259 -0
- keboola_agent_cli/services/member_service.py +593 -0
- keboola_agent_cli/services/org_service.py +619 -0
- keboola_agent_cli/services/project_service.py +947 -0
- keboola_agent_cli/services/repo_validate_service.py +767 -0
- keboola_agent_cli/services/schedule_service.py +731 -0
- keboola_agent_cli/services/search_service.py +331 -0
- keboola_agent_cli/services/semantic_layer_service.py +1497 -0
- keboola_agent_cli/services/sharing_service.py +307 -0
- keboola_agent_cli/services/storage_service.py +2524 -0
- keboola_agent_cli/services/stream_service.py +395 -0
- keboola_agent_cli/services/sync_service.py +2244 -0
- keboola_agent_cli/services/variables_service.py +447 -0
- keboola_agent_cli/services/version_service.py +1038 -0
- keboola_agent_cli/services/workspace_service.py +1103 -0
- keboola_agent_cli/stream_client.py +217 -0
- keboola_agent_cli/sync/__init__.py +1 -0
- keboola_agent_cli/sync/branch_mapping.py +174 -0
- keboola_agent_cli/sync/clone.py +211 -0
- keboola_agent_cli/sync/code_extraction.py +655 -0
- keboola_agent_cli/sync/config_format.py +290 -0
- keboola_agent_cli/sync/diff_engine.py +566 -0
- keboola_agent_cli/sync/git_utils.py +93 -0
- keboola_agent_cli/sync/manifest.py +162 -0
- keboola_agent_cli/sync/naming.py +90 -0
- keboola_agent_cli/sync/secrets.py +62 -0
- keboola_agent_cli/sync/sql_split.py +134 -0
- keboola_cli-0.63.4.dist-info/METADATA +308 -0
- keboola_cli-0.63.4.dist-info/RECORD +306 -0
- keboola_cli-0.63.4.dist-info/WHEEL +4 -0
- keboola_cli-0.63.4.dist-info/entry_points.txt +2 -0
|
@@ -0,0 +1,1481 @@
|
|
|
1
|
+
"""Context command - provides compact usage reference for AI agents.
|
|
2
|
+
|
|
3
|
+
Outputs a curated text block that any AI agent (Claude, Codex, Gemini, etc.)
|
|
4
|
+
can consume to understand how to use kbagent effectively.
|
|
5
|
+
For detailed workflows, install the kbagent Claude Code plugin or use
|
|
6
|
+
`kbagent <command> --help`.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
import typer
|
|
10
|
+
|
|
11
|
+
from .. import __version__
|
|
12
|
+
from ._helpers import get_formatter
|
|
13
|
+
|
|
14
|
+
AGENT_CONTEXT = f"""\
|
|
15
|
+
# kbagent - Keboola Agent CLI v{__version__}
|
|
16
|
+
|
|
17
|
+
## What is kbagent?
|
|
18
|
+
|
|
19
|
+
AI-friendly CLI for managing Keboola projects. Connect to multiple projects
|
|
20
|
+
across stacks, browse configs/jobs/lineage, sync configs as local files,
|
|
21
|
+
create workspaces for SQL debugging, and manage dev branches -- all with
|
|
22
|
+
structured JSON output for programmatic consumption.
|
|
23
|
+
|
|
24
|
+
## IMPORTANT: Set Conversation ID
|
|
25
|
+
|
|
26
|
+
Before running any kbagent commands, set KBAGENT_CONVERSATION_ID to a unique
|
|
27
|
+
identifier for the current conversation/session. This is REQUIRED for platform
|
|
28
|
+
observability -- all API requests will include the X-Conversation-ID header.
|
|
29
|
+
|
|
30
|
+
export KBAGENT_CONVERSATION_ID="<unique-conversation-id>"
|
|
31
|
+
|
|
32
|
+
## Quick Start
|
|
33
|
+
|
|
34
|
+
# Add a single project
|
|
35
|
+
kbagent --json project add --project my-project --url https://connection.keboola.com --token YOUR_TOKEN
|
|
36
|
+
|
|
37
|
+
# Or bulk-onboard all projects from an organization
|
|
38
|
+
KBC_MANAGE_API_TOKEN=xxx kbagent --allow-env-manage-token --json org setup --org-id 123 --url https://connection.keboola.com --yes
|
|
39
|
+
|
|
40
|
+
# Explore
|
|
41
|
+
kbagent --json project list
|
|
42
|
+
kbagent --json config list
|
|
43
|
+
|
|
44
|
+
## Global Flags
|
|
45
|
+
|
|
46
|
+
--json / -j JSON output (always use for programmatic parsing)
|
|
47
|
+
--verbose / -v Verbose output
|
|
48
|
+
--no-color Disable colors (auto-disabled in non-TTY)
|
|
49
|
+
--config-dir Override config directory path
|
|
50
|
+
--deny-writes Session-only firewall: block the WIDE NET -- every write, destructive, AND admin op (project add/remove/edit, org setup, all storage mutations)
|
|
51
|
+
--deny-destructive Session-only firewall: NARROW -- block only data-destructive ops in Keboola (delete-table/bucket/column, terminate-job, branch delete). Admin ops (project remove, org setup) stay allowed -- use --deny-writes for those
|
|
52
|
+
|
|
53
|
+
## All Commands
|
|
54
|
+
|
|
55
|
+
Use `kbagent <command> --help` for full flag details and examples.
|
|
56
|
+
|
|
57
|
+
### Project Management
|
|
58
|
+
|
|
59
|
+
kbagent project add --project NAME --url URL --token TOKEN
|
|
60
|
+
Add a new project connection. Token verified against API.
|
|
61
|
+
|
|
62
|
+
kbagent project list
|
|
63
|
+
List all connected projects (tokens always masked).
|
|
64
|
+
|
|
65
|
+
kbagent project remove --project NAME
|
|
66
|
+
Remove a project connection.
|
|
67
|
+
|
|
68
|
+
kbagent project edit --project NAME [--url URL] [--token TOKEN] [--new-alias NEW]
|
|
69
|
+
Edit project connection. Re-verifies token if changed. --new-alias renames
|
|
70
|
+
the alias and cascades the rename through config.json and the nested sync
|
|
71
|
+
directory at <cwd>/<old-alias>/. Lineage cache embeds the alias in FQNs
|
|
72
|
+
and is NOT auto-updated; rebuild via `kbagent lineage build` after rename.
|
|
73
|
+
|
|
74
|
+
kbagent project status [--project NAME]
|
|
75
|
+
Test connectivity. Shows OK/ERROR with response time.
|
|
76
|
+
|
|
77
|
+
kbagent project refresh --project ALIAS [--dry-run] [--force] [--yes] [--token-description ...] [--token-expires-in N]
|
|
78
|
+
kbagent project refresh --all [--dry-run] [--force] [--yes] [--token-description ...] [--token-expires-in N]
|
|
79
|
+
Refresh project tokens via Manage API. --all refreshes all projects. --force replaces non-expiring tokens.
|
|
80
|
+
|
|
81
|
+
kbagent project description-get --project NAME
|
|
82
|
+
Read the Keboola dashboard project description (markdown). Backed by
|
|
83
|
+
the KBC.projectDescription metadata key on the default branch. Returns
|
|
84
|
+
an empty string if no description has been set.
|
|
85
|
+
|
|
86
|
+
kbagent project description-set --project NAME [--text STR | --file PATH | --stdin]
|
|
87
|
+
Set the dashboard project description. Pass exactly one of --text,
|
|
88
|
+
--file, or --stdin. Writes KBC.projectDescription to the default branch.
|
|
89
|
+
|
|
90
|
+
kbagent project use ALIAS
|
|
91
|
+
Pin ALIAS as the default project. Persists to config.json.
|
|
92
|
+
Env var KBAGENT_PROJECT=ALIAS overrides the pin for a single shell/session;
|
|
93
|
+
an explicit --project flag overrides both.
|
|
94
|
+
|
|
95
|
+
kbagent project current
|
|
96
|
+
Print the effective default project and its source (env / pin / none).
|
|
97
|
+
Resolution order for single-project operations: --project > KBAGENT_PROJECT > pin.
|
|
98
|
+
|
|
99
|
+
kbagent project info --project NAME
|
|
100
|
+
Return full project details: ID, name, stack URL, default backend, enabled features,
|
|
101
|
+
quota limits, and usage metrics. Useful for auditing project capabilities.
|
|
102
|
+
|
|
103
|
+
### Project Members & Invitations (since v0.29.0)
|
|
104
|
+
|
|
105
|
+
Requires KBC_MANAGE_API_TOKEN (Manage API auth). Allowed roles: admin, guest, readOnly, share.
|
|
106
|
+
|
|
107
|
+
kbagent project invite --project ALIAS --email EMAIL --role ROLE [--reason TEXT] [--dry-run]
|
|
108
|
+
Send an invitation email. Re-inviting an existing invitee or member is a no-op
|
|
109
|
+
(HTTP 400 from the Manage API; the service returns status="noop" with note
|
|
110
|
+
"already_invited" / "already_member").
|
|
111
|
+
|
|
112
|
+
kbagent project invite --from-csv FILE [--default-role ROLE] [--workers N] [--dry-run]
|
|
113
|
+
Bulk invite. CSV must have a header row with columns: email, project (alias or
|
|
114
|
+
numeric ID), role (optional if --default-role is given), reason (optional).
|
|
115
|
+
Parallelised with ThreadPoolExecutor (default 8 workers). Per-row results in
|
|
116
|
+
`rows[]` with status=ok|noop|failed; `failed_rows` ordering is not deterministic.
|
|
117
|
+
|
|
118
|
+
kbagent project member-list --project ALIAS [--include-pending]
|
|
119
|
+
List active project members. --include-pending also fetches pending invitations.
|
|
120
|
+
|
|
121
|
+
kbagent project invitation-list --project ALIAS
|
|
122
|
+
List pending (unaccepted) invitations only.
|
|
123
|
+
|
|
124
|
+
kbagent project invitation-cancel --project ALIAS --email EMAIL [--invitation-id ID] [--yes]
|
|
125
|
+
Cancel a pending invitation. Without --invitation-id, the service resolves the
|
|
126
|
+
ID by listing pending invitations and matching --email (case-insensitive).
|
|
127
|
+
|
|
128
|
+
kbagent project member-remove --project ALIAS --email EMAIL [--yes]
|
|
129
|
+
Remove an active member (destructive). Service resolves --email to user_id.
|
|
130
|
+
|
|
131
|
+
kbagent project member-set-role --project ALIAS --email EMAIL --role ROLE
|
|
132
|
+
Change an existing member's role via PATCH /manage/projects/{{id}}/users/{{userId}}.
|
|
133
|
+
|
|
134
|
+
### Component Discovery
|
|
135
|
+
|
|
136
|
+
kbagent component list [--project NAME] [--type TYPE] [--query "search"]
|
|
137
|
+
List or AI-search available components. --type: extractor, writer, transformation, application.
|
|
138
|
+
|
|
139
|
+
kbagent component detail --component-id ID [--project NAME]
|
|
140
|
+
Show component docs, config schema, and examples count.
|
|
141
|
+
|
|
142
|
+
### Configuration Browsing
|
|
143
|
+
|
|
144
|
+
kbagent config list [--project NAME] [--component-type TYPE] [--component-id ID] [--branch ID] [--include-rows]
|
|
145
|
+
List configs from one/many/all projects. --project repeatable. Branch-aware.
|
|
146
|
+
--include-rows extends each row with full configuration + rows bodies
|
|
147
|
+
(significantly larger payload -- use only when bodies are needed).
|
|
148
|
+
|
|
149
|
+
kbagent config detail --project NAME [--project NAME ...] --component-id ID [--config-id ID] [--branch ID] [--with-state]
|
|
150
|
+
Full config detail. TWO MODES:
|
|
151
|
+
- Single (--config-id given): returns the full config dict (shape unchanged).
|
|
152
|
+
- Bulk (--config-id omitted): returns {{"configs": [...], "errors": [...]}}
|
|
153
|
+
with every config of --component-id. --project repeatable for multi-project
|
|
154
|
+
fan-out (one API call per project, not per config).
|
|
155
|
+
--with-state attaches the runtime state dict. Single: dedicated get_config_state
|
|
156
|
+
call. Bulk: include=state ridesalong (no N+1, still one call per project).
|
|
157
|
+
--branch requires exactly one --project (branch IDs are per-project).
|
|
158
|
+
Sandbox annotation (since v0.42.0, single-config mode only):
|
|
159
|
+
--component-id keboola.sandboxes adds a sandbox_annotation block with
|
|
160
|
+
sandbox_service_id (the misleading parameters.id) and storage_workspace_id
|
|
161
|
+
(the actual Storage workspace ID -- resolved via workspace list lookup).
|
|
162
|
+
Use storage_workspace_id with `kbagent workspace detail --workspace-id ID`,
|
|
163
|
+
NOT parameters.id (which 404s).
|
|
164
|
+
|
|
165
|
+
kbagent config update --project NAME --component-id ID --config-id ID [--name N] [--description D] [--configuration JSON|@file|-] [--configuration-file PATH] [--set PATH=VALUE ...] [--merge] [--dry-run] [--branch ID] [--allow-plaintext-on-encrypt-failure]
|
|
166
|
+
Update config metadata and/or configuration content. --set targets a
|
|
167
|
+
nested key (e.g. parameters.db.host=new-host). --merge deep-merges into
|
|
168
|
+
existing config (preserves sibling keys). --dry-run previews changes.
|
|
169
|
+
Paths are always relative to the configuration root. #-prefixed secrets
|
|
170
|
+
auto-encrypt via the Encryption API before write (fail-closed; since
|
|
171
|
+
0.54.0); --allow-plaintext-on-encrypt-failure overrides. --dry-run keeps
|
|
172
|
+
plaintext in the diff. Note --set '#k=v' sets a top-level key; for a
|
|
173
|
+
nested secret use --set 'parameters.#k=v'.
|
|
174
|
+
Auto-normalize (0.28.0+; #245): parameters.blocks[].codes[].script
|
|
175
|
+
strings are silently rewritten to arrays before pushing to Storage --
|
|
176
|
+
SQL transformations split on statement boundaries (state machine
|
|
177
|
+
respects 'string' / "ident" / $$..$$ / -- / # / // / /* */); Python /
|
|
178
|
+
R / kds-team.app-custom-python wrap as [script]. The result envelope
|
|
179
|
+
gains a normalizations: [{{path, action, before_type, after_type,
|
|
180
|
+
after_length}}] field listing every change (empty when input was
|
|
181
|
+
already valid). Closes the runtime "Expected array, got string" trap
|
|
182
|
+
that the lax Storage API silently lets through.
|
|
183
|
+
|
|
184
|
+
kbagent config set-default-bucket --project NAME --component-id ID --config-id ID (--bucket BUCKET_ID | --clear) [--dry-run] [--branch ID]
|
|
185
|
+
Set or clear configuration.storage.output.default_bucket on a config without
|
|
186
|
+
raw-mode JSON edits. --bucket/--clear are mutually exclusive. Read-modify-write
|
|
187
|
+
that preserves sibling keys under storage.output and the rest of the config.
|
|
188
|
+
No-op (with changed=false) when the value is already what you'd be setting.
|
|
189
|
+
|
|
190
|
+
kbagent config rename --project NAME --component-id ID --config-id ID --name "New Name" [--branch ID] [--directory DIR]
|
|
191
|
+
Rename a configuration. Updates name via API. If a local sync directory
|
|
192
|
+
exists (.keboola/manifest.json), renames the directory and updates the
|
|
193
|
+
manifest path. Uses git mv when inside a git repo for cleaner history.
|
|
194
|
+
|
|
195
|
+
kbagent config delete --project NAME --component-id ID --config-id ID [--branch ID]
|
|
196
|
+
Delete a configuration. Branch-aware.
|
|
197
|
+
|
|
198
|
+
kbagent config new --component-id ID [--name NAME] [--project NAME] [--output-dir DIR]
|
|
199
|
+
[--push --no-files --description D --configuration JSON|@file|- --configuration-file PATH --no-validate --branch ID --dry-run --allow-plaintext-on-encrypt-failure]
|
|
200
|
+
Default: generate boilerplate config from component schema (scaffold to --output-dir or stdout).
|
|
201
|
+
With --push (0.33.0+): also create the config remotely via Storage API in one shot.
|
|
202
|
+
--push requires --project AND a non-empty --name. --no-files skips the filesystem step
|
|
203
|
+
entirely for FIIA-style one-shot creates. Schema validation runs by default when an explicit
|
|
204
|
+
--configuration body is given (fail-closed; --no-validate opts out). Default body is {{}}
|
|
205
|
+
(empty shell, validation auto-skipped). Works for ALL component types including
|
|
206
|
+
keboola.snowflake-transformation (unlike tool call create_config which refuses it).
|
|
207
|
+
|
|
208
|
+
kbagent config search --query PATTERN [--project NAME] [--component-type TYPE] [-i] [-r] [--branch ID]
|
|
209
|
+
Search config bodies for string/regex. Reports match location in JSON tree. Branch-aware.
|
|
210
|
+
|
|
211
|
+
kbagent config variables-set --project NAME --component-id ID --config-id ID --var KEY=VALUE [--var ...] [--replace] [--variables-id ID] [--values-id ID] [--branch ID] [--dry-run]
|
|
212
|
+
Assign variables to any config. Auto-creates the backing keboola.variables + default row
|
|
213
|
+
on first call and links the parent; subsequent calls update the same row (merge by default;
|
|
214
|
+
--replace for full overwrite). Prefix KEY with # to auto-encrypt as a secret.
|
|
215
|
+
|
|
216
|
+
kbagent config variables-get --project NAME --component-id ID --config-id ID [--branch ID]
|
|
217
|
+
Read variable values attached to a config. Returns linked, variables_id, values_id, values.
|
|
218
|
+
|
|
219
|
+
kbagent config variables-clear --project NAME --component-id ID --config-id ID [--branch ID] [--yes]
|
|
220
|
+
Unlink variables from a config. Does NOT delete the underlying keboola.variables config
|
|
221
|
+
(it may be shared). Delete it explicitly via `kbagent config delete` if needed.
|
|
222
|
+
|
|
223
|
+
### Config Metadata (folder organisation + arbitrary key/value)
|
|
224
|
+
|
|
225
|
+
kbagent config metadata-list --project NAME --component-id ID --config-id ID [--branch ID]
|
|
226
|
+
List all metadata entries on a configuration. Each entry: id, key, value, provider, timestamp.
|
|
227
|
+
|
|
228
|
+
kbagent config get-metadata --project NAME --component-id ID --config-id ID --key KEY [--branch ID]
|
|
229
|
+
Read a single metadata value by key. Exits 1 (NOT_FOUND) if absent.
|
|
230
|
+
|
|
231
|
+
kbagent config set-metadata --project NAME --component-id ID --config-id ID --key KEY --value VALUE [--branch ID]
|
|
232
|
+
Set (upsert) a metadata key/value on a configuration.
|
|
233
|
+
|
|
234
|
+
kbagent config delete-metadata --project NAME --component-id ID --config-id ID --metadata-id ID [--branch ID] [--yes]
|
|
235
|
+
Delete a configuration metadata entry by numeric ID (from metadata-list).
|
|
236
|
+
|
|
237
|
+
kbagent config set-folder --project NAME --component-id ID --config-id ID --name "FolderName" [--branch ID]
|
|
238
|
+
Sugar: writes KBC.configuration.folderName metadata. Groups the config in the Keboola UI.
|
|
239
|
+
Pass --name "" to remove the folder assignment.
|
|
240
|
+
|
|
241
|
+
kbagent config row-create --project NAME --component-id ID --config-id ID --name ROW_NAME [--description D] [--configuration JSON|@file|-] [--is-disabled] [--branch ID] [--allow-plaintext-on-encrypt-failure]
|
|
242
|
+
Create a new configuration row. Returns the new row ID. Optional --configuration accepts JSON inline, @file, or stdin. #-prefixed secrets auto-encrypt before write (fail-closed; since 0.54.0).
|
|
243
|
+
|
|
244
|
+
kbagent config row-update --project NAME --component-id ID --config-id ID --row-id ID [--name N] [--description D] [--configuration JSON|@file|-] [--is-disabled | --is-enabled] [--branch ID] [--allow-plaintext-on-encrypt-failure]
|
|
245
|
+
Update an existing configuration row. Pass only the fields you want to change. #-prefixed secrets auto-encrypt before write (fail-closed; since 0.54.0).
|
|
246
|
+
|
|
247
|
+
kbagent config row-delete --project NAME --component-id ID --config-id ID --row-id ID [--branch ID] [--yes]
|
|
248
|
+
Delete a configuration row. Destructive; --yes to skip confirmation prompt.
|
|
249
|
+
|
|
250
|
+
kbagent config oauth-url --project NAME --component-id ID --config-id ID [--redirect-url URL]
|
|
251
|
+
Return the OAuth authorization URL for a component that uses OAuth authentication.
|
|
252
|
+
Open the URL in a browser to complete the OAuth flow.
|
|
253
|
+
|
|
254
|
+
### Cross-Project Search
|
|
255
|
+
|
|
256
|
+
kbagent search QUERY [--project NAME] [--type table|bucket|config|flow|data-app|transformation] [--search-type textual|config-based] [--limit N]
|
|
257
|
+
Search for items across one or more projects. Textual mode (default) searches item names
|
|
258
|
+
via the Storage API global-search endpoint. Config-based mode scans full configuration JSON bodies.
|
|
259
|
+
--type is repeatable. --limit applies per project in textual mode (1-100, default 50).
|
|
260
|
+
|
|
261
|
+
### Job History
|
|
262
|
+
|
|
263
|
+
kbagent job list [--project NAME] [--component-id ID] [--config-id ID] [--status STATUS] [--limit N]
|
|
264
|
+
List jobs from Queue API. --status: processing, terminated, cancelled, success, error.
|
|
265
|
+
|
|
266
|
+
kbagent job detail --project NAME --job-id ID
|
|
267
|
+
Full job detail including result message and timing.
|
|
268
|
+
|
|
269
|
+
kbagent job run --project NAME --component-id ID --config-id ID [--row-id ID ...] [--wait] [--timeout N] [--branch ID] [--mode run|debug] [--variable-values-id ID] [--no-variables] [--poll-strategy exponential|fixed] [--log-tail-lines N] [--idempotency-key KEY] [--force-rerun]
|
|
270
|
+
Run a Queue API job. --row-id selects specific config rows (repeatable; omit to run entire config).
|
|
271
|
+
--wait polls until job finishes. --timeout sets max wait in seconds (default 300). Branch-aware.
|
|
272
|
+
When the config has linked variables (configuration.variables_id), kbagent auto-resolves
|
|
273
|
+
a variableValuesId so the job binds to the deployed values row. --variable-values-id
|
|
274
|
+
overrides; --no-variables skips resolution. Error code NO_VARIABLE_ROWS when the linked
|
|
275
|
+
variables config has zero rows (run `kbagent config variables-set` to create one).
|
|
276
|
+
Polling under --wait uses an exponential curve by default (2s x 30 -> 5s x 48 -> 15s);
|
|
277
|
+
--poll-strategy fixed keeps a constant 1s interval. On FAILED/WARNING/TERMINATED, the last
|
|
278
|
+
--log-tail-lines events (default 200, 0 disables -- recommended for automation pipelines) are
|
|
279
|
+
surfaced as `logTail` in --json output.
|
|
280
|
+
--mode run (default) writes to mapped output tables. --mode debug runs the component but
|
|
281
|
+
redirects the output to a Storage File tagged `debug-<jobId>` instead of into destination
|
|
282
|
+
buckets -- safe for dry-runs and for reproducing a failing run on a production configuration
|
|
283
|
+
without touching production data. Invalid values exit 2 via Click choice gate (since v0.43.6).
|
|
284
|
+
--json response shapes by exit code:
|
|
285
|
+
- exit 0 (success): {{status:"ok", data:{{..., logTail?:[...]}}}}
|
|
286
|
+
- exit 1 (QUEUE_JOB_FAILED, remote job status=error):
|
|
287
|
+
{{status:"error", error:{{code:"QUEUE_JOB_FAILED", details:{{logTail:[...]}}}}}}
|
|
288
|
+
- exit 4 (QUEUE_JOB_TIMEOUT, local timeout + remote kill also failed):
|
|
289
|
+
{{status:"error", error:{{code:"QUEUE_JOB_TIMEOUT", retryable:true, details:{{logTail:[...]}}}}}}
|
|
290
|
+
- exit 7 (JOB_TIMEOUT_TERMINATED, local timeout + remote kill succeeded):
|
|
291
|
+
{{status:"error", error:{{code:"JOB_TIMEOUT_TERMINATED", details:{{job:{{...}}, logTail:[...]}}}}}}
|
|
292
|
+
jq pattern: `.error.details.logTail? // .data.logTail? // []` picks up the tail regardless of exit.
|
|
293
|
+
|
|
294
|
+
kbagent job terminate --project NAME (--job-id ID [--job-id ID ...] | --status any|created|waiting|processing [--component-id ID] [--config-id ID] [--branch ID] [--limit N]) [--dry-run] [--yes]
|
|
295
|
+
Kill running jobs via Queue API (POST /jobs/{{id}}/kill). Use to stop runaway loops or pile-ups.
|
|
296
|
+
Two modes: single/batch by --job-id, or bulk by --status. --status any covers all killable states
|
|
297
|
+
(created+waiting+processing). Response partitions into killed / already_finished / not_found / failed.
|
|
298
|
+
Idempotent: re-running on terminal jobs reports them as already_finished rather than failing.
|
|
299
|
+
|
|
300
|
+
### Storage
|
|
301
|
+
|
|
302
|
+
Note on branches: storage READ commands (buckets, bucket-detail, tables,
|
|
303
|
+
table-detail, files, file-detail) use the production endpoint by default,
|
|
304
|
+
even when a dev branch is active via `branch use`. The Storage API
|
|
305
|
+
branch-scoped endpoint returns only resources that were locally modified
|
|
306
|
+
in the dev branch, so a freshly-created branch lists nothing. Pass
|
|
307
|
+
`--branch ID` explicitly to query dev-branch-local tables/buckets.
|
|
308
|
+
Storage WRITE commands (create-*, upload-*, delete-*, file-upload, etc.)
|
|
309
|
+
remain branch-aware because modifying a dev branch is the expected intent.
|
|
310
|
+
|
|
311
|
+
kbagent storage buckets [--project NAME] [--branch ID]
|
|
312
|
+
List buckets with sharing/linked info. Shows source project for linked buckets.
|
|
313
|
+
Uses production by default; pass --branch to query a dev branch explicitly.
|
|
314
|
+
|
|
315
|
+
kbagent storage bucket-detail --project NAME --bucket-id BUCKET_ID [--branch ID]
|
|
316
|
+
Bucket detail with backend-native direct-access paths. Resolves linked bucket source DB/dataset.
|
|
317
|
+
Output adapts to the bucket's backend:
|
|
318
|
+
- Snowflake -> snowflake_database / snowflake_schema / per-table snowflake_path quoted with "..."
|
|
319
|
+
- BigQuery -> bigquery_dataset (and bigquery_project when surfaced via API databaseName) /
|
|
320
|
+
per-table bigquery_path quoted with backticks `dataset`.`table` (or
|
|
321
|
+
`project`.`dataset`.`table` when project is known).
|
|
322
|
+
Always-present backend-agnostic keys: sql_dialect ("snowflake" | "bigquery") and per-table sql_path.
|
|
323
|
+
Prefer sql_path/sql_dialect in agent code instead of branching on backend yourself.
|
|
324
|
+
Uses production by default; pass --branch to query a dev branch explicitly.
|
|
325
|
+
|
|
326
|
+
kbagent storage tables [--project NAME ...] [--bucket-id BUCKET_ID] [--branch ID]
|
|
327
|
+
List storage tables from one or more projects (in parallel). Omit --project
|
|
328
|
+
to query all connected projects. Repeat --project for a specific subset.
|
|
329
|
+
Multi-project by default, matching `storage buckets`, `config list`, `job list`.
|
|
330
|
+
Each row is tagged with project_alias; per-project errors accumulate in the
|
|
331
|
+
response envelope. --branch is only valid with a single --project.
|
|
332
|
+
--bucket-id is applied independently per project; missing buckets are
|
|
333
|
+
reported as per-project errors, not fatal.
|
|
334
|
+
Uses production by default; pass --branch to query a dev branch explicitly.
|
|
335
|
+
|
|
336
|
+
kbagent storage table-detail --project NAME --table-id TABLE_ID [--branch ID]
|
|
337
|
+
Show detailed table info: columns (with types if available), primary key, row count, size, last import date.
|
|
338
|
+
Uses production by default; pass --branch to query a dev branch explicitly.
|
|
339
|
+
|
|
340
|
+
kbagent storage create-bucket --project NAME --stage STAGE --name BUCKET_NAME [--description D] [--backend B] [--branch ID]
|
|
341
|
+
Create a new storage bucket. Stage must be "in" or "out". Branch-aware.
|
|
342
|
+
On projects WITHOUT the `storage-branches` feature (legacy fake-branch), --branch
|
|
343
|
+
writes succeed at the API level but the transformation runner ignores the bucket
|
|
344
|
+
and creates a parallel `out.c-<branch_id>-*` bucket in the default branch at job
|
|
345
|
+
time. Response includes `legacy_branch_storage: true` and human mode prints a
|
|
346
|
+
warning when this applies. See storage-types-workflow.md.
|
|
347
|
+
|
|
348
|
+
kbagent storage create-table --project NAME --bucket-id BUCKET_ID --name TABLE_NAME --column col:TYPE[(length)] [...] [--primary-key COL] [--not-null COL ...] [--default NAME=VALUE ...] [--branch ID] [--if-not-exists]
|
|
349
|
+
Create a typed table. --column repeatable.
|
|
350
|
+
- --if-not-exists (since 0.47.0): opt-in idempotency. On a duplicate-display-name failure,
|
|
351
|
+
probe get-table-detail at the expected id and, if the table really exists, return
|
|
352
|
+
`action: "skipped", skip_reason: "table already exists"` instead of raising. A different
|
|
353
|
+
table with the same display name still surfaces the original error. Safe for parallel workers.
|
|
354
|
+
Since 0.47.1: the skipped envelope reports the EXISTING table's actual `columns`/`primary_key`/`name`
|
|
355
|
+
(not the request); requested values are mirrored under `requested_columns`/`requested_primary_key`,
|
|
356
|
+
and `schema_drift: true` flags when the existing table diverges from what was requested.
|
|
357
|
+
- Base types: STRING, INTEGER, NUMERIC, FLOAT, BOOLEAN, DATE, TIMESTAMP. Type defaults to STRING if omitted.
|
|
358
|
+
- Native backend types with length pass through to the Storage API: VARCHAR(40), NUMBER(18,2), CHAR(10), TIMESTAMP_TZ, TIMESTAMP_NTZ, VARIANT, OBJECT, ARRAY, etc.
|
|
359
|
+
The API validates type/length per backend; e.g. INTEGER(10) is rejected with "'10' is not valid length for INTEGER".
|
|
360
|
+
- --not-null COL marks a column NOT NULL (nullable=false). Must match a defined --column name.
|
|
361
|
+
- --default NAME=VALUE sets a DEFAULT expression. Booleans must be lowercase (true/false).
|
|
362
|
+
- In a dev branch, the bucket is auto-materialized if it has not yet been written to in the branch
|
|
363
|
+
(response includes auto_created_bucket=true). Mirrors the official Keboola Go CLI's EnsureBucketExists.
|
|
364
|
+
- Auto-materialized buckets get KBC.createdBy.branch.id system metadata stamped on them,
|
|
365
|
+
so transformation runners on branched-storage projects accept them as output destinations.
|
|
366
|
+
A 403/5xx on the metadata write is logged and the create-table call still proceeds.
|
|
367
|
+
- On legacy fake-branch projects (no `storage-branches` feature), response carries
|
|
368
|
+
`legacy_branch_storage: true` and human mode prints a warning. The bucket and
|
|
369
|
+
metadata stamp still happen but the runner will not use them -- it creates a
|
|
370
|
+
parallel `out.c-<branch_id>-*` bucket in the default branch at job time.
|
|
371
|
+
Branch-aware. Examples:
|
|
372
|
+
--column pk:VARCHAR(40) --column amount:NUMERIC(18,2) --not-null pk --default amount=0
|
|
373
|
+
--column ts:TIMESTAMP_TZ --column meta:VARIANT
|
|
374
|
+
|
|
375
|
+
kbagent storage upload-table --project NAME --table-id TABLE_ID --file PATH [--incremental] [--delimiter D] [--enclosure E] [--no-auto-create] [--branch ID]
|
|
376
|
+
Upload CSV into a table. Auto-creates bucket and table if missing (columns inferred as STRING from CSV header).
|
|
377
|
+
Use --no-auto-create to require the table to already exist.
|
|
378
|
+
Full load by default; --incremental to append rows. Supports files up to 5 GB via async file-first upload flow. Branch-aware.
|
|
379
|
+
|
|
380
|
+
kbagent storage download-table --project NAME --table-id TABLE_ID [--output FILE] [--columns COL ...] [--limit N] [--where-column COL --where-value VAL ... [--where-operator eq|neq]] [--changed-since WHEN] [--changed-until WHEN] [--branch ID]
|
|
381
|
+
Export table data to a local CSV file. Async export with streaming download.
|
|
382
|
+
--where-column + --where-value (repeatable) + --where-operator eq|neq filter rows; --changed-since/--changed-until (unix ts or strtotime) filter by import time.
|
|
383
|
+
Default filename: TABLE_NAME.csv. Use --columns to select columns (see table-detail for names).
|
|
384
|
+
Use --limit to cap row count. Handles sliced files and gzip decompression transparently. Branch-aware.
|
|
385
|
+
kbagent storage add-column --project NAME --table-id ID --column COL:TYPE[(length)] [--not-null] [--default VALUE] [--branch ID]
|
|
386
|
+
Add a single column to an existing table (synchronous). Same name:TYPE(length) grammar as create-table --column.
|
|
387
|
+
|
|
388
|
+
kbagent storage delete-table --project NAME --table-id ID [--table-id ...] [--force] [--dry-run] [--yes] [--branch ID]
|
|
389
|
+
Delete one or more tables. Batch: repeat --table-id. --force to cascade-delete aliased tables. --dry-run to preview. Branch-aware.
|
|
390
|
+
|
|
391
|
+
kbagent storage truncate-table --project NAME --table-id ID [--table-id ...] [--dry-run] [--yes] [--branch ID]
|
|
392
|
+
Truncate one or more tables (delete all rows; preserve schema, primary key, descriptions, sharing edges, and dependents).
|
|
393
|
+
Batch: repeat --table-id. Endpoint is async-via-job on every branch (the client polls to completion before returning;
|
|
394
|
+
do not pass async=true -- the API rejects it). Idempotent (truncating an empty table is a no-op). Use this when re-seeding
|
|
395
|
+
a table without losing the schema contract.
|
|
396
|
+
|
|
397
|
+
kbagent storage delete-column --project NAME --table-id ID --column COL [--column ...] [--force] [--dry-run] [--yes] [--branch ID]
|
|
398
|
+
Delete one or more columns from a table. Batch: repeat --column. --force when column is referenced by aliases. --dry-run to preview. Branch-aware.
|
|
399
|
+
|
|
400
|
+
kbagent storage delete-bucket --project NAME --bucket-id ID [--bucket-id ...] [--force] [--dry-run] [--yes] [--branch ID]
|
|
401
|
+
Delete one or more buckets. --force cascade-deletes tables. Linked/shared buckets protected. Branch-aware.
|
|
402
|
+
|
|
403
|
+
kbagent storage swap-tables --project NAME --table-id ID --target-table-id ID --branch ID [--dry-run] [--yes]
|
|
404
|
+
Swap two storage tables in any branch, including the default/production branch (POST /tables/{{id}}/swap). Both tables exchange physical positions;
|
|
405
|
+
aliases are NOT transferred (they keep pointing at the same physical position and therefore expose the
|
|
406
|
+
OTHER table's data after the swap). Use to promote a typed rebuild back into the original name without
|
|
407
|
+
touching downstream config references. branch_id is mandatory (--branch or active branch via 'kbagent
|
|
408
|
+
branch use'); service guards before any HTTP call when none is set. Any branch works, INCLUDING the
|
|
409
|
+
default/production branch -- a default-branch swap is how a typed rebuild reaches prod (dev-branch merge
|
|
410
|
+
does not carry storage schema).
|
|
411
|
+
|
|
412
|
+
kbagent storage clone-table --project NAME --table-id ID --branch ID [--dry-run]
|
|
413
|
+
Clone (pull) a production table into a dev branch (POST /tables/{{id}}/pull). On storage-branches projects a
|
|
414
|
+
dev branch reads prod tables transparently until first write, so mutating a table's schema in the branch
|
|
415
|
+
(swap-tables, dropping columns) first needs a branch-local copy. This materializes that copy (one-way:
|
|
416
|
+
default -> branch). Branch is mandatory; service guards before any HTTP call when no branch is set.
|
|
417
|
+
|
|
418
|
+
### Storage Descriptions
|
|
419
|
+
|
|
420
|
+
kbagent storage describe-bucket --project NAME --bucket-id ID [--text STR | --file PATH | --stdin] [--branch ID]
|
|
421
|
+
Set the KBC.description metadata on a bucket (upsert). Visible in bucket-detail.
|
|
422
|
+
|
|
423
|
+
kbagent storage describe-table --project NAME --table-id ID [--text STR | --file PATH | --stdin] [--branch ID]
|
|
424
|
+
Set the KBC.description metadata on a table (upsert). Readable via table-detail --json .data.description.
|
|
425
|
+
|
|
426
|
+
kbagent storage describe-column --project NAME --table-id ID --column NAME=DESC [--column ...] [--branch ID]
|
|
427
|
+
Set per-column descriptions stored as KBC.column.{{name}}.description in table metadata (upsert).
|
|
428
|
+
Readable via table-detail --json .data.column_details[].description.
|
|
429
|
+
|
|
430
|
+
kbagent storage describe-batch --project NAME --from-file YAML [--branch ID]
|
|
431
|
+
Apply bucket/table/column descriptions from a YAML file. Sections: buckets, tables, columns (all optional).
|
|
432
|
+
Failures collected; one error does not abort remaining items.
|
|
433
|
+
|
|
434
|
+
### Storage Files
|
|
435
|
+
|
|
436
|
+
kbagent storage files --project NAME [--tag TAG ...] [--limit N] [--offset N] [--query Q] [--branch ID]
|
|
437
|
+
List Storage Files. --tag filters by tags (AND logic, repeat for multiple). --query for full-text search on name.
|
|
438
|
+
Uses production by default; pass --branch to query a dev branch explicitly.
|
|
439
|
+
|
|
440
|
+
kbagent storage file-upload --project NAME --file PATH [--name NAME] [--tag TAG ...] [--permanent] [--branch ID]
|
|
441
|
+
Upload any file to Storage Files. --tag assigns tags (repeatable). --permanent prevents auto-deletion after 15 days.
|
|
442
|
+
--name overrides the filename (default: local filename). Branch-aware.
|
|
443
|
+
|
|
444
|
+
kbagent storage file-download --project NAME [--file-id ID | --tag TAG ...] [--output FILE]
|
|
445
|
+
Download a Storage File. Either --file-id (by ID) or --tag (latest file matching all tags).
|
|
446
|
+
--output sets local path (default: original filename). Handles sliced and gzipped files transparently.
|
|
447
|
+
|
|
448
|
+
kbagent storage file-detail --project NAME --file-id ID
|
|
449
|
+
Show file metadata: name, size, tags, sliced/permanent status, creator token. Does not download.
|
|
450
|
+
|
|
451
|
+
kbagent storage file-delete --project NAME --file-id ID [--file-id ...] [--dry-run] [--yes]
|
|
452
|
+
Delete one or more Storage Files. Batch: repeat --file-id. --dry-run to preview.
|
|
453
|
+
|
|
454
|
+
kbagent storage file-tag --project NAME --file-id ID [--add TAG ...] [--remove TAG ...]
|
|
455
|
+
Add and/or remove tags on a file in a single operation. Both --add and --remove are repeatable.
|
|
456
|
+
|
|
457
|
+
kbagent storage load-file --project NAME --file-id ID --table-id TABLE_ID [--incremental] [--delimiter D] [--enclosure E] [--branch ID]
|
|
458
|
+
Import an already-uploaded Storage File into a table. Useful for files uploaded by components or file-upload.
|
|
459
|
+
--incremental to append rows. Branch-aware.
|
|
460
|
+
|
|
461
|
+
kbagent storage unload-table --project NAME --table-id TABLE_ID [--columns COL ...] [--limit N] [--tag TAG ...] [--download] [--output FILE|DIR] [--file-type csv|parquet] [--branch ID]
|
|
462
|
+
Export a table to a Storage File. The file stays in Keboola for other components to use.
|
|
463
|
+
--tag assigns tags to the exported file. --download also saves it locally. Branch-aware.
|
|
464
|
+
--file-type parquet produces a sliced Parquet file (CSV default). With --download, --output
|
|
465
|
+
is a directory that will hold one .parquet file per slice plus _manifest.json.
|
|
466
|
+
Default parquet directory: ./{{project}}/{{table_id}}.parquet/ (mirrors Keboola addressing).
|
|
467
|
+
|
|
468
|
+
### Data Streams (OpenTelemetry / OTLP)
|
|
469
|
+
|
|
470
|
+
kbagent stream list --project NAME [--branch ID]
|
|
471
|
+
List Data Streams sources (id, name, type, secret-free base endpoint).
|
|
472
|
+
kbagent stream create-source --project NAME --name NAME [--type otlp|http] [--branch ID] [--if-not-exists] [--no-sinks] [--reveal]
|
|
473
|
+
Create an OTLP (default) or HTTP source; polls the async task and returns the endpoint.
|
|
474
|
+
For OTLP, auto-provisions the logs/metrics/traces sinks (bucket in.c-otlp-<source>) so data
|
|
475
|
+
lands in Storage (idempotent; --no-sinks for a bare source).
|
|
476
|
+
--if-not-exists returns an existing same-named source as status=skipped.
|
|
477
|
+
kbagent stream detail [SOURCE_ID | --name NAME] --project NAME [--branch ID] [--reveal]
|
|
478
|
+
Show base + per-signal endpoints (/v1/logs|/v1/traces|/v1/metrics), protocol http/protobuf,
|
|
479
|
+
and destination bucket/tables (from sinks). The secret embedded in the OTLP URL is MASKED
|
|
480
|
+
by default; pass --reveal to print it (e.g. to wire OTEL_EXPORTER_OTLP_ENDPOINT).
|
|
481
|
+
kbagent stream delete SOURCE_ID --project NAME [--branch ID] [--dry-run] [--yes|--force]
|
|
482
|
+
Delete a source (destructive; async task polled to completion).
|
|
483
|
+
Notes: uses the per-project Storage token (no manage token). Control plane = stream.<region>
|
|
484
|
+
derived from connection.<region>. The OTLP ingest host is stream-in.<region>, returned in
|
|
485
|
+
source.otlp.url -- never derived. The raw Stream API does not auto-create sinks, so kbagent
|
|
486
|
+
provisions the 3 OTLP sinks itself on create-source --type otlp (--no-sinks to opt out). Send
|
|
487
|
+
OTLP/HTTP to <endpoint>/v1/logs|/v1/traces|/v1/metrics; data lands in in.c-otlp-<source>.* tables.
|
|
488
|
+
|
|
489
|
+
### Sharing (Cross-Project)
|
|
490
|
+
|
|
491
|
+
kbagent sharing list [--project NAME]
|
|
492
|
+
List shared buckets available for linking. Multi-project, uses regular token.
|
|
493
|
+
|
|
494
|
+
kbagent sharing share --project ALIAS --bucket-id ID --type TYPE [--target-project-ids IDs] [--target-users EMAILS]
|
|
495
|
+
Enable sharing on a bucket. Requires master token (KBC_MASTER_TOKEN_{{ALIAS}} or KBC_MASTER_TOKEN).
|
|
496
|
+
Types: organization, organization-project, selected-projects, selected-users.
|
|
497
|
+
|
|
498
|
+
kbagent sharing unshare --project ALIAS --bucket-id ID
|
|
499
|
+
Disable sharing. Fails if linked buckets exist. Requires master token.
|
|
500
|
+
|
|
501
|
+
kbagent sharing link --project ALIAS --source-project-id ID --bucket-id ID [--name NAME]
|
|
502
|
+
Link a shared bucket into a project (read-only). Uses regular token.
|
|
503
|
+
|
|
504
|
+
kbagent sharing unlink --project ALIAS --bucket-id ID
|
|
505
|
+
Remove a linked bucket from a project. Uses regular token.
|
|
506
|
+
|
|
507
|
+
kbagent sharing edges [--project NAME]
|
|
508
|
+
Show cross-project data flow edges via bucket sharing. --project repeatable.
|
|
509
|
+
|
|
510
|
+
### Data Lineage
|
|
511
|
+
|
|
512
|
+
kbagent lineage build --directory PATH --output PATH [--ai] [--refresh]
|
|
513
|
+
Build column-level lineage graph from sync'd data. Scans all sync'd projects,
|
|
514
|
+
detects dependencies via config mappings and SQL parsing, saves to cache file.
|
|
515
|
+
Auto-detects both sync layouts: flat (./.keboola/manifest.json from
|
|
516
|
+
sync pull --project X) and nested (./<alias>/.keboola/manifest.json from
|
|
517
|
+
sync pull --all-projects). Emits a warning in response data if no projects
|
|
518
|
+
are found. --refresh runs sync pull first. --ai generates
|
|
519
|
+
.lineage_ai_tasks.json with AI analysis tasks for an AI agent to process
|
|
520
|
+
(2-step flow).
|
|
521
|
+
|
|
522
|
+
kbagent lineage show --load PATH [--upstream NODE] [--downstream NODE]
|
|
523
|
+
[--column COL] [--columns] [--project ALIAS] [--depth N]
|
|
524
|
+
[--format text|mermaid|html|er]
|
|
525
|
+
Query upstream/downstream from cached lineage graph (from lineage build).
|
|
526
|
+
Node identifiers: full FQN project-alias:bucket_id.table_name or just table_id.
|
|
527
|
+
--columns shows column-level mapping. -c COL traces one column.
|
|
528
|
+
|
|
529
|
+
kbagent lineage info --load PATH
|
|
530
|
+
Show what's in a cached lineage graph: projects, tables, most connected nodes.
|
|
531
|
+
|
|
532
|
+
kbagent lineage server --load PATH [--port N] [--host HOST]
|
|
533
|
+
Start interactive lineage browser in the web browser. Sidebar-based node
|
|
534
|
+
picker with mermaid/ER diagram rendering and export.
|
|
535
|
+
|
|
536
|
+
### Organization Management
|
|
537
|
+
|
|
538
|
+
kbagent org setup --org-id ID --url URL [--dry-run] [--yes] [--token-description PREFIX] [--refresh]
|
|
539
|
+
Bulk-onboard all org projects. Requires org-admin manage token. Idempotent.
|
|
540
|
+
--refresh also refreshes tokens for already-registered projects with invalid tokens.
|
|
541
|
+
|
|
542
|
+
kbagent org setup --project-ids 901,9621,10539 --url URL [--dry-run] [--yes] [--refresh]
|
|
543
|
+
Non-admin mode: onboard specific projects by ID. Works with Personal Access Token (PAT).
|
|
544
|
+
Use --org-id OR --project-ids (at least one required).
|
|
545
|
+
Token via interactive hidden prompt by default; pass top-level
|
|
546
|
+
--allow-env-manage-token to read KBC_MANAGE_API_TOKEN from env (CI/CD).
|
|
547
|
+
Default-deny since 0.29.0 -- closes the AI-exfiltration risk where
|
|
548
|
+
subprocesses inherit the manage token via env.
|
|
549
|
+
|
|
550
|
+
### Feature Flags (since v0.48.0)
|
|
551
|
+
|
|
552
|
+
Requires a SUPER-ADMIN Manage API token (same kind as `org setup`). Same
|
|
553
|
+
default-deny token policy: interactive hidden prompt by default; pass
|
|
554
|
+
top-level --allow-env-manage-token to read KBC_MANAGE_API_TOKEN from env.
|
|
555
|
+
--project resolves the stack URL (and, for project ops, the numeric
|
|
556
|
+
project_id) from config -- the alias is the only handle you pass.
|
|
557
|
+
|
|
558
|
+
kbagent feature list --project ALIAS
|
|
559
|
+
Stack-wide feature catalogue (GET /manage/features).
|
|
560
|
+
kbagent feature project-show --project ALIAS
|
|
561
|
+
Features assigned to a project.
|
|
562
|
+
kbagent feature project-add --project ALIAS --feature NAME [--dry-run] [--yes]
|
|
563
|
+
kbagent feature project-remove --project ALIAS --feature NAME [--dry-run] [--yes]
|
|
564
|
+
Enable / disable a feature on a project. add=admin, remove=destructive.
|
|
565
|
+
kbagent feature user-show --project ALIAS --email EMAIL
|
|
566
|
+
kbagent feature user-add --project ALIAS --email EMAIL --feature NAME [--dry-run] [--yes]
|
|
567
|
+
kbagent feature user-remove --project ALIAS --email EMAIL --feature NAME [--dry-run] [--yes]
|
|
568
|
+
Per-user features (GET/POST/DELETE /manage/users/{{email}}/features).
|
|
569
|
+
|
|
570
|
+
### Flows (Conditional Flows -- keboola.flow only; orchestrator dropped in 0.57.0)
|
|
571
|
+
|
|
572
|
+
kbagent flow list [--project NAME] [--branch ID] [--with-schedules]
|
|
573
|
+
List conditional flows (keboola.flow) across projects. Legacy keboola.orchestrator
|
|
574
|
+
flows are NOT listed; their count is surfaced as legacy_orchestrator_count + a warning.
|
|
575
|
+
--with-schedules enriches each row with {{schedule_id, cron, timezone, enabled}}
|
|
576
|
+
entries from keboola.scheduler (one extra API call per project, NOT per flow).
|
|
577
|
+
|
|
578
|
+
kbagent flow detail --project NAME --flow-id ID [--branch ID]
|
|
579
|
+
Show phases, transitions (next[].goto + conditions), typed tasks, and full configuration.
|
|
580
|
+
|
|
581
|
+
kbagent flow schema [--full --project NAME]
|
|
582
|
+
Plain: print the offline conditional-flow YAML template. --full fetches and dumps the
|
|
583
|
+
live JSON Schema from the stack (AI Service configurationSchema for keboola.flow) and
|
|
584
|
+
REQUIRES --project (the schema is no longer bundled).
|
|
585
|
+
|
|
586
|
+
kbagent flow validate --file YAML|@file|- [--project NAME]
|
|
587
|
+
With --project: fetch the live schema from the stack -> full structural + semantic
|
|
588
|
+
validation (fetch failure degrades to semantic-only + a note). Without --project:
|
|
589
|
+
semantic-only validation + a note that structural validation was skipped (no schema
|
|
590
|
+
source). Exit 0 valid, exit 2 on errors. --json adds {{valid, errors, warnings, notes}}.
|
|
591
|
+
|
|
592
|
+
kbagent flow new --project NAME --name "Name" [--description D] [--file YAML|@file|-] [--branch ID]
|
|
593
|
+
Create a new conditional flow. --file accepts YAML with 'phases' and 'tasks' keys.
|
|
594
|
+
Validated against the LIVE conditional-flow schema fetched from the stack
|
|
595
|
+
(INVALID_FLOW_DEFINITION on failure). A schema-fetch failure does NOT block the write:
|
|
596
|
+
structural check skipped, semantic checks still run, a warning is surfaced.
|
|
597
|
+
IDs are STRINGS; phases use next[].goto (a phase id or null); tasks are typed
|
|
598
|
+
(job/notification/variable). Execute with: job run --component-id keboola.flow --config-id ID.
|
|
599
|
+
|
|
600
|
+
kbagent flow update --project NAME --flow-id ID [--name N] [--description D] [--file YAML] [--branch ID]
|
|
601
|
+
Update a flow's name, description, or phases/tasks. --file replaces both phases and tasks.
|
|
602
|
+
Omitting --file leaves the flow body unchanged. Validated against the live conditional-flow
|
|
603
|
+
schema on write (merge-aware; INVALID_FLOW_DEFINITION on failure; schema-fetch failure ->
|
|
604
|
+
semantic-only + warning).
|
|
605
|
+
|
|
606
|
+
kbagent flow delete --project NAME --flow-id ID [--branch ID] [--yes]
|
|
607
|
+
Delete a flow. Does NOT remove associated keboola.scheduler configs.
|
|
608
|
+
Run 'flow schedule-remove' first if you want to clean up schedules.
|
|
609
|
+
|
|
610
|
+
kbagent flow schedule --project NAME --flow-id ID --cron "0 6 * * *" [--timezone TZ] [--enabled/--disabled] [--name NAME] [--branch ID]
|
|
611
|
+
Upsert a cron schedule: updates the existing keboola.scheduler config if one exists, creates one
|
|
612
|
+
otherwise. Calling twice with a new cron replaces the old schedule — no duplicates created.
|
|
613
|
+
Schedules are stored as Storage API configs, not a separate scheduler service.
|
|
614
|
+
|
|
615
|
+
kbagent flow schedule-remove --project NAME --flow-id ID [--branch ID] [--yes]
|
|
616
|
+
Remove all schedules bound to this flow (deletes all matching keboola.scheduler configs).
|
|
617
|
+
Idempotent: safe to run when no schedules exist.
|
|
618
|
+
|
|
619
|
+
### Schedule Discovery & Audit (Fleet-Wide)
|
|
620
|
+
|
|
621
|
+
kbagent schedule list [--project NAME ...] [--enabled-only] [--branch ID]
|
|
622
|
+
Fleet-wide list of every keboola.scheduler config across one, many, or all
|
|
623
|
+
projects (multi-project fan-out; no --project means all). Each row shows
|
|
624
|
+
project_alias, schedule_id, schedule_name, parent_component_id, parent_config_id,
|
|
625
|
+
parent_name, cron, timezone, and enabled. Use --enabled-only to hide disabled
|
|
626
|
+
schedules. Answers issue #195: "which flows are on cron triggers across N projects?".
|
|
627
|
+
|
|
628
|
+
kbagent schedule detail --project NAME --schedule-id ID [--branch ID]
|
|
629
|
+
Full detail for a single schedule: cron, timezone, enabled state, plus the
|
|
630
|
+
parent config's component_id/config_id/name. Orphaned schedules (parent
|
|
631
|
+
deleted) still return with parent_name="" -- never hard-fails.
|
|
632
|
+
|
|
633
|
+
kbagent schedule find [--cron-window START-END] [--not-run-since DAYS] [--project NAME ...] [--branch ID]
|
|
634
|
+
Audit filters, combinable with AND:
|
|
635
|
+
* --cron-window "02:00-04:00" matches schedules whose cron's hour field
|
|
636
|
+
is entirely inside the window. Hour-level approximation -- see gotchas.md.
|
|
637
|
+
* --not-run-since N matches schedules whose parent config's latest job is
|
|
638
|
+
older than N days (or never ran). Pass N=0 to force last_run_at lookup
|
|
639
|
+
without applying a staleness filter.
|
|
640
|
+
Columns last_run_at and matches_cron_window are ALWAYS present in the
|
|
641
|
+
output but populated only when the corresponding filter is active --
|
|
642
|
+
they stay None otherwise so LLM consumers do not treat unevaluated
|
|
643
|
+
cells as positive match signals. Queue API is not branch-aware:
|
|
644
|
+
--branch + --not-run-since still compares against production jobs.
|
|
645
|
+
|
|
646
|
+
### Development Branches
|
|
647
|
+
|
|
648
|
+
kbagent branch list [--project NAME]
|
|
649
|
+
List dev branches. --project repeatable.
|
|
650
|
+
|
|
651
|
+
kbagent branch create --project ALIAS --name "name" [--description "..."]
|
|
652
|
+
Create dev branch and auto-activate it. Async, CLI waits for completion.
|
|
653
|
+
|
|
654
|
+
kbagent branch use --project ALIAS --branch ID
|
|
655
|
+
Set existing branch as active for subsequent commands.
|
|
656
|
+
|
|
657
|
+
kbagent branch reset --project ALIAS
|
|
658
|
+
Reset to main/production branch.
|
|
659
|
+
|
|
660
|
+
kbagent branch delete --project ALIAS --branch ID
|
|
661
|
+
Delete branch (async). Auto-resets to main if it was active.
|
|
662
|
+
|
|
663
|
+
kbagent branch merge --project ALIAS [--branch ID]
|
|
664
|
+
Get KBC UI merge URL (does NOT merge via API). Resets active branch.
|
|
665
|
+
|
|
666
|
+
kbagent branch metadata-list --project NAME [--branch ID|default]
|
|
667
|
+
List all metadata entries on a branch (id, key, value, provider, timestamp).
|
|
668
|
+
|
|
669
|
+
kbagent branch metadata-get --project NAME --key KEY [--branch ID|default]
|
|
670
|
+
Read a single metadata value by key. Exits with NOT_FOUND if absent.
|
|
671
|
+
|
|
672
|
+
kbagent branch metadata-set --project NAME --key KEY [--text STR | --file PATH | --stdin] [--branch ID|default]
|
|
673
|
+
Set a metadata key/value. Useful for KBC.projectDescription and similar
|
|
674
|
+
dashboard-visible fields. --branch defaults to "default" (main branch).
|
|
675
|
+
|
|
676
|
+
kbagent branch metadata-delete --project NAME --metadata-id ID [--branch ID|default]
|
|
677
|
+
Delete a metadata entry by its numeric ID (from metadata-list).
|
|
678
|
+
|
|
679
|
+
### Workspaces (SQL Debugging)
|
|
680
|
+
|
|
681
|
+
kbagent workspace create --project ALIAS [--name NAME] [--backend TYPE] [--ui] [--read-only/--no-read-only]
|
|
682
|
+
Create workspace. Backend auto-detected from project (or override with --backend). Default: headless (~1s). --ui: visible in KBC UI (~15s).
|
|
683
|
+
Since 0.47.1, Snowflake headless creates return private_key and an empty password field; use key-pair auth.
|
|
684
|
+
|
|
685
|
+
kbagent workspace list [--project NAME] [--orphaned] [--branch ID] [--qs-compatible]
|
|
686
|
+
List workspaces. Read command: ignores active dev branch (production endpoint) with an Info banner;
|
|
687
|
+
pass --branch to opt in. Each entry carries login_type, read_only, qs_compatible so callers can pick a
|
|
688
|
+
Query-Service-compatible workspace without firing a probe query. --qs-compatible filters to RO +
|
|
689
|
+
confirmed-whitelist loginType (canonical data-app shape). --orphaned shows orphaned workspaces.
|
|
690
|
+
|
|
691
|
+
kbagent workspace detail --project ALIAS --workspace-id ID [--branch ID]
|
|
692
|
+
Workspace connection details (no password). Includes login_type, read_only, qs_compatible.
|
|
693
|
+
Read command: ignores active dev branch with an Info banner; pass --branch to opt in.
|
|
694
|
+
|
|
695
|
+
kbagent workspace delete --project ALIAS --workspace-id ID
|
|
696
|
+
Delete workspace. They also expire automatically.
|
|
697
|
+
|
|
698
|
+
kbagent workspace password --project ALIAS --workspace-id ID
|
|
699
|
+
Reset and return new workspace password.
|
|
700
|
+
|
|
701
|
+
kbagent workspace load --project ALIAS --workspace-id ID --tables TABLE_ID [...] [--preserve]
|
|
702
|
+
Load storage tables into workspace. --preserve keeps existing tables.
|
|
703
|
+
|
|
704
|
+
kbagent workspace query --project ALIAS --workspace-id ID --sql "SQL" [--file F] [--transactional] [--full] [--limit N]
|
|
705
|
+
Execute SQL via Query Service. No Snowflake credentials needed.
|
|
706
|
+
Default reads results inline (fast JSON columns+rows), capped at --limit (default 500).
|
|
707
|
+
--full uses the complete CSV export instead (slower, uncapped).
|
|
708
|
+
|
|
709
|
+
kbagent workspace from-transformation --project ALIAS --component-id ID --config-id ID [--row-id ID]
|
|
710
|
+
Create workspace from transformation config. Loads input tables automatically.
|
|
711
|
+
|
|
712
|
+
kbagent workspace gc [--project NAME] [--dry-run] [--yes]
|
|
713
|
+
Garbage-collect orphaned workspaces (keboola.sandboxes config missing). Use --dry-run to preview.
|
|
714
|
+
|
|
715
|
+
### Data Apps (Streamlit / Flask / Node deployments)
|
|
716
|
+
|
|
717
|
+
Lifecycle for `keboola.data-apps`. Combines the Storage API (config body --
|
|
718
|
+
git block, slug, runtime size, encrypted secrets) with the Data Science API
|
|
719
|
+
(/apps -- deployment record, state, URL, configVersion). Encapsulates the
|
|
720
|
+
§9 redeploy contract so callers cannot pin to the empty-shell v2.
|
|
721
|
+
|
|
722
|
+
kbagent data-app list [--project NAME ...] [--branch ID]
|
|
723
|
+
List data apps across one or many projects. Merges Data Science /apps
|
|
724
|
+
index with Storage config names. Multi-project parallel.
|
|
725
|
+
|
|
726
|
+
kbagent data-app detail --project NAME --app-id ID [--branch ID]
|
|
727
|
+
Full merged view: state, desiredState, url, deployed configVersion, slug,
|
|
728
|
+
runtime size, git settings (PAT redacted as <encrypted>).
|
|
729
|
+
|
|
730
|
+
kbagent data-app create --project ALIAS --name NAME --slug SLUG --git-repo URL
|
|
731
|
+
[--description STR | --description-file PATH] [--git-branch main]
|
|
732
|
+
[--git-public/--no-git-public] [--git-username USER]
|
|
733
|
+
[--git-pat-env VAR | --git-pat-file PATH | --git-pat-encrypted KBC::Project...]
|
|
734
|
+
[--auth password|public] [--size tiny|small|medium|large] [--auto-suspend SECONDS]
|
|
735
|
+
[--type python-js|python|streamlit|r|...] [--branch ID]
|
|
736
|
+
[--no-deploy] [--wait] [--timeout SECONDS] [--keep-on-failure] [--dry-run]
|
|
737
|
+
Create + configure + deploy in one call. Default `--auth password` mints
|
|
738
|
+
a 20-char hex simpleAuth password (retrievable via `data-app password`).
|
|
739
|
+
PAT input (private repo): env var (recommended) > file > pre-encrypted.
|
|
740
|
+
Pre-encrypted PATs MUST start with KBC::Project (project-scoped KMS).
|
|
741
|
+
Cleanup-in-finally if PUT or initial deploy fails (orphan shell deleted
|
|
742
|
+
by default; --keep-on-failure preserves it for forensics).
|
|
743
|
+
|
|
744
|
+
kbagent data-app deploy --project NAME --app-id ID [--config-version N]
|
|
745
|
+
[--wait] [--timeout SECONDS] [--branch ID]
|
|
746
|
+
The §9 redeploy contract. Default reads the latest Storage config version
|
|
747
|
+
and pins to it; --config-version pins an older version (rollback).
|
|
748
|
+
Always sends {{desiredState=running, configVersion, restartIfRunning=true}}
|
|
749
|
+
together -- HTTP 422 otherwise.
|
|
750
|
+
|
|
751
|
+
kbagent data-app start --project NAME --app-id ID [--wait] [--timeout SECONDS]
|
|
752
|
+
Wake an auto-suspended data app at its currently-pinned configVersion.
|
|
753
|
+
Distinct from deploy: does NOT bump the version.
|
|
754
|
+
|
|
755
|
+
kbagent data-app stop --project NAME --app-id ID [--wait] [--timeout SECONDS]
|
|
756
|
+
Stop a running data app. Preserves URL and Storage config; container is
|
|
757
|
+
torn down.
|
|
758
|
+
|
|
759
|
+
kbagent data-app delete --project NAME --app-id ID [--yes]
|
|
760
|
+
Delete the deployment AND the Storage config (cascade, irreversible).
|
|
761
|
+
URL is permanently retired. Confirmation prompt unless --yes.
|
|
762
|
+
|
|
763
|
+
kbagent data-app password --project NAME --app-id ID
|
|
764
|
+
Retrieve the simpleAuth password. Requires the Manage API token in
|
|
765
|
+
addition to the project's Storage token. Token is read from interactive
|
|
766
|
+
hidden prompt by default; pass top-level --allow-env-manage-token to
|
|
767
|
+
use KBC_MANAGE_API_TOKEN from env (default-deny since 0.29.0). Never
|
|
768
|
+
persisted, never logged. Password is auto-generated at create time
|
|
769
|
+
and CANNOT be rotated -- delete and recreate the app to mint a new one.
|
|
770
|
+
|
|
771
|
+
kbagent data-app logs --project NAME --app-id ID [--lines N] [--since ISO8601]
|
|
772
|
+
Tail the container log buffer (Data Science /apps/{{id}}/logs/tail).
|
|
773
|
+
Plain-text body covering the full spin-up trace ([TIMING] git_clone,
|
|
774
|
+
Cloning into /app, uv install, supervisord boot, runtime stack traces).
|
|
775
|
+
Default --lines 500; pass --lines 0 to fetch the full current buffer
|
|
776
|
+
(no server-side cap). --lines and --since are mutually exclusive;
|
|
777
|
+
--since requires a timezone (Z or +00:00). App must be running or
|
|
778
|
+
recently-stopped -- never-started apps return 400 "App X is not
|
|
779
|
+
running"; recover with 'kbagent data-app start' or 'data-app deploy'.
|
|
780
|
+
Closes the gap where the upstream keboola-mcp-server's get_data_apps
|
|
781
|
+
tool hardcodes a 20-line cap on log output (structurally too small to
|
|
782
|
+
capture a healthy spin-up). The log buffer can echo runtime secrets
|
|
783
|
+
the app printed to stdout/stderr -- consider hygiene before piping
|
|
784
|
+
--json output into AI agent context.
|
|
785
|
+
|
|
786
|
+
kbagent data-app secrets-set --project ALIAS --app-id ID --secret '#KEY=VALUE'
|
|
787
|
+
[--secret '#KEY2=VALUE2' ...] [--secrets-file PATH] [--branch ID]
|
|
788
|
+
[--allow-plaintext-on-encrypt-failure] [--dry-run] [--no-hint-next]
|
|
789
|
+
Encrypt and write '#'-prefixed secrets into parameters.dataApp.secrets.
|
|
790
|
+
Per-project KMS via the Encryption API; ciphertext does not cross
|
|
791
|
+
projects (writeup §8). Read-modify-write at the service layer to
|
|
792
|
+
preserve sibling keys; never use Storage merge=True for nested edits.
|
|
793
|
+
The runtime exposes each key as an env var with '#' stripped, '-'
|
|
794
|
+
replaced with '_', uppercased ('#my-api-key' -> 'MY_API_KEY').
|
|
795
|
+
Adding a secret bumps the Storage version; the running container
|
|
796
|
+
keeps the OLD config until the next 'kbagent data-app deploy'.
|
|
797
|
+
|
|
798
|
+
kbagent data-app secrets-list --project ALIAS --app-id ID [--branch ID]
|
|
799
|
+
[--show-fingerprint]
|
|
800
|
+
List the keys in parameters.dataApp.secrets with derived runtime
|
|
801
|
+
env-var names. Never echoes encrypted ciphertext in full and never
|
|
802
|
+
decrypts. --show-fingerprint includes a short fingerprint per key.
|
|
803
|
+
|
|
804
|
+
kbagent data-app secrets-get --project ALIAS --app-id ID --key 'KEY'
|
|
805
|
+
[--branch ID]
|
|
806
|
+
Show ONE key from parameters.dataApp.secrets. Leading '#' is OPTIONAL
|
|
807
|
+
-- the block holds both encrypted secrets (#) and plain env-var
|
|
808
|
+
values, both enumerated by secrets-list. ENCRYPTED secret -> metadata
|
|
809
|
+
only (encrypted: true, value: null); the decrypted plaintext is NEVER
|
|
810
|
+
echoed (Encryption API has no decrypt endpoint). PLAIN value -> the
|
|
811
|
+
literal value (encrypted: false), already visible via config detail.
|
|
812
|
+
NOT_FOUND on absent key (exact match); never enumerates siblings.
|
|
813
|
+
|
|
814
|
+
kbagent data-app secrets-remove --project ALIAS --app-id ID --key 'KEY'
|
|
815
|
+
[--key 'KEY2' ...] [--branch ID] [--yes] [--dry-run]
|
|
816
|
+
Remove one or more keys (encrypted secrets OR plain env vars; leading
|
|
817
|
+
'#' optional). Idempotent (missing keys -> exit 0, removed: 0).
|
|
818
|
+
Destructive: a removal can break the running app at next deploy if it
|
|
819
|
+
depends on the value. Confirmation prompt unless --yes or --json.
|
|
820
|
+
|
|
821
|
+
kbagent data-app validate-repo --git-repo URL [--git-branch BRANCH]
|
|
822
|
+
[--git-public/--no-git-public] [--git-pat-env VAR | --git-pat-file PATH]
|
|
823
|
+
[--type python-js] [--strict]
|
|
824
|
+
Pre-flight check that a git repo follows the Keboola data-app
|
|
825
|
+
Golden Rule (https://help.keboola.com/data-apps/python-js/). Walks
|
|
826
|
+
the repo via GitHub Contents + Trees API (<=5 calls -- 1 tree +
|
|
827
|
+
up to 4 contents -- regardless of
|
|
828
|
+
repo size); each check emits BLOCKING / WARN / OK with a help-doc
|
|
829
|
+
citation. --type currently restricted to python-js; streamlit /
|
|
830
|
+
pure-Python / R / Node-only follow-up. --strict treats WARNs as
|
|
831
|
+
failures (exit 1).
|
|
832
|
+
|
|
833
|
+
kbagent data-app git-repo --project NAME --app-id ID
|
|
834
|
+
Show the clone URLs (ssh_url / https_url) of the app's configured git
|
|
835
|
+
repository plus is_managed_git_repo (sandboxes-service
|
|
836
|
+
GET /apps/{{id}}/git-repo). Read-only; project storage token only.
|
|
837
|
+
GOTCHA: returns 409 "no Git repository configured" until the app has
|
|
838
|
+
been DEPLOYED at least once -- the git block is synced from the Storage
|
|
839
|
+
config into the Data Science app record at deploy time, so a fresh
|
|
840
|
+
--no-deploy app has no git repo from the service's point of view.
|
|
841
|
+
|
|
842
|
+
kbagent data-app git-branches --project NAME --app-id ID
|
|
843
|
+
List the remote branches of the app's git repository with commit
|
|
844
|
+
metadata (branch, sha, comment, author name+email, date). Raw
|
|
845
|
+
top-level array from the server. Same deploy-once precondition as
|
|
846
|
+
git-repo.
|
|
847
|
+
|
|
848
|
+
kbagent data-app git-entrypoints --project NAME --app-id ID
|
|
849
|
+
List root-level .py entrypoint files of the app's git repository on the
|
|
850
|
+
configured branch. Extension is hardcoded to py server-side (non-Python
|
|
851
|
+
entrypoints are not listable). Same deploy-once precondition.
|
|
852
|
+
|
|
853
|
+
kbagent data-app git-credentials --project NAME --app-id ID
|
|
854
|
+
List the credentials of the app's MANAGED git repository (id, type,
|
|
855
|
+
permissions, name, owner_admin_id, created_at). The secret is NEVER
|
|
856
|
+
returned here. Needs an admin storage token. External repos (the kind
|
|
857
|
+
`data-app create --git-repo` produces) have no managed credentials.
|
|
858
|
+
|
|
859
|
+
kbagent data-app git-credentials-create --project NAME --app-id ID
|
|
860
|
+
--type ssh_key|http_token --permissions readOnly|readWrite
|
|
861
|
+
[--public-key KEY | --public-key-file PATH] [--name LABEL] [--yes]
|
|
862
|
+
Mint a git credential for the app's MANAGED git repository. ssh_key
|
|
863
|
+
requires a public key; http_token returns a ONE-TIME secret printed
|
|
864
|
+
once and never retrievable again (mirrors data-app password). Requires
|
|
865
|
+
an admin storage token. Apps created via `data-app create --git-repo`
|
|
866
|
+
are EXTERNAL (not managed) -> 409 "no managed Git repository".
|
|
867
|
+
Confirmation prompt unless --yes or --json.
|
|
868
|
+
|
|
869
|
+
### Project Sync
|
|
870
|
+
|
|
871
|
+
kbagent sync init --project ALIAS [--directory DIR] [--git-branching] [--adopt-existing]
|
|
872
|
+
Initialize sync working directory. --git-branching enables git-to-Keboola branch mapping.
|
|
873
|
+
|
|
874
|
+
kbagent sync pull --project ALIAS [--all-projects] [--force] [--dry-run] [--with-samples] [--no-storage] [--no-jobs] [--job-limit N] [--branch ID]
|
|
875
|
+
Download configs as local files. Idempotent, protects local modifications.
|
|
876
|
+
--force (semantics corrected since 0.53.0): re-pull over locally-modified configs.
|
|
877
|
+
A config edited locally whose remote is UNCHANGED is PRESERVED (its pending delta stays
|
|
878
|
+
pushable -- NOT discarded, NOT silently re-stamped). A true merge conflict (the config
|
|
879
|
+
changed BOTH locally and on the remote since the last pull) ABORTS the pull (exit 1,
|
|
880
|
+
SYNC_CONFLICT) listing each conflict; resolve via sync diff then push-or-discard, then pull.
|
|
881
|
+
To intentionally drop local edits, delete the file/dir and pull. Applies to rows too.
|
|
882
|
+
--job-limit controls max recent jobs per config (default 5). For large projects,
|
|
883
|
+
automatically falls back to per-config job fetching to ensure all configs get job history.
|
|
884
|
+
Auto-detects renamed configs and renames local directories to match (uses git mv in git repos).
|
|
885
|
+
--branch (since 0.47.0): per-invocation dev-branch override. Same semantics as sync push/diff.
|
|
886
|
+
|
|
887
|
+
kbagent sync status [--directory DIR]
|
|
888
|
+
Show local changes since last pull (SHA256-based). Also returns
|
|
889
|
+
plaintext_secret_warnings (since 0.55.0): in-sync configs/rows whose
|
|
890
|
+
#-secrets are still plaintext on the remote (pre-0.54.0 leak; #378). Fix =
|
|
891
|
+
re-push on >=0.54.0 + rotate (version history keeps the plaintext).
|
|
892
|
+
|
|
893
|
+
kbagent sync diff --project ALIAS [--all-projects] [--directory DIR] [--branch ID]
|
|
894
|
+
3-way diff: local vs pull-time snapshot vs remote. Detects conflicts.
|
|
895
|
+
--branch (since 0.47.0): per-invocation dev-branch override. Wins over
|
|
896
|
+
manifest.branches[0] / 'branch use' active branch / git-branching mapping.
|
|
897
|
+
Requires exactly one --project.
|
|
898
|
+
|
|
899
|
+
kbagent sync push --project ALIAS [--all-projects] [--dry-run] [--force] [--allow-plaintext-on-encrypt-failure] [--branch ID] [--no-name-drift-warnings]
|
|
900
|
+
Push local changes. Auto-encrypts secrets. Skips conflicts (pull first).
|
|
901
|
+
Fails if encryption fails (plaintext secrets never pushed). Use escape hatch flag only if you know what you are doing.
|
|
902
|
+
Fresh-CREATE behavior (since 0.47.0): if the manifest contains a placeholder entry at
|
|
903
|
+
(component_id, path), the create path updates it in place (no manifest duplication)
|
|
904
|
+
and propagates any KBC.configuration.* metadata via set_config_metadata. Re-pushes
|
|
905
|
+
against the now-real config id are naturally idempotent.
|
|
906
|
+
Fresh-CREATE variable binding (since 0.47.2): when a keboola.variables config + its
|
|
907
|
+
values row are created alongside a transformation in the same push, the transformation's
|
|
908
|
+
variables_id / variables_values_id are rebound to the assigned ULIDs (not placeholder
|
|
909
|
+
dirnames), the row's values are hoisted even when the scaffold row file has no _keboola
|
|
910
|
+
block, and the row's placeholder parent is remapped before POST. job run then succeeds
|
|
911
|
+
without a post-push config variables-set step.
|
|
912
|
+
--branch (since 0.47.0): per-invocation dev-branch override. Same semantics as sync diff.
|
|
913
|
+
When no <branch_name>/ subtree exists on disk (since 0.47.2), the local default tree
|
|
914
|
+
(main/) is read as the source and promoted to the target branch; API writes still target
|
|
915
|
+
the branch id.
|
|
916
|
+
--no-name-drift-warnings (since 0.47.0): suppress the cosmetic name_drift_warnings
|
|
917
|
+
array from the result envelope.
|
|
918
|
+
|
|
919
|
+
kbagent sync clone --source DIR --target ALIAS --target-dir DIR [--bucket-map FILE] [--variable-values FILE] [--instance-rename FILE] [--dry-run] [--branch ID]
|
|
920
|
+
Clone a reference synced tree into a fresh target project + parameterize it
|
|
921
|
+
(bucket_map / variable_values / instance_rename overrides), then push so every
|
|
922
|
+
config CREATEs fresh. keboola.flow task configIds + variable links remap
|
|
923
|
+
reference->ULID. Idempotent (re-run -> no_changes); needs a fresh target.
|
|
924
|
+
Note: --dry-run still creates --target-dir on disk (copy + overrides + manifest)
|
|
925
|
+
but does not push.
|
|
926
|
+
|
|
927
|
+
kbagent sync branch-link --project ALIAS [--branch-id ID] [--branch-name NAME]
|
|
928
|
+
Link git branch to Keboola dev branch. Auto-creates if needed.
|
|
929
|
+
|
|
930
|
+
kbagent sync branch-unlink [--directory DIR]
|
|
931
|
+
Remove git-to-Keboola branch mapping.
|
|
932
|
+
|
|
933
|
+
kbagent sync branch-status [--directory DIR]
|
|
934
|
+
Show current branch mapping status.
|
|
935
|
+
|
|
936
|
+
### Encryption
|
|
937
|
+
|
|
938
|
+
kbagent encrypt values --project ALIAS --component-id ID --input JSON|@file|- [--output-file PATH]
|
|
939
|
+
Encrypt #-prefixed secret values via Keboola Encryption API (one-way, no decrypt).
|
|
940
|
+
Scope: ComponentSecure (project + component). Use for MCP tool call workflows
|
|
941
|
+
where ciphertext must exist before calling update_config / create_config.
|
|
942
|
+
--input accepts: inline JSON, @file.json (from file), or - (from stdin).
|
|
943
|
+
Already-encrypted values (KBC:: prefix) pass through unchanged.
|
|
944
|
+
|
|
945
|
+
### Semantic Layer (Metastore) (since v0.41.0)
|
|
946
|
+
|
|
947
|
+
Manage Keboola metastore models: datasets, metrics, relationships, constraints,
|
|
948
|
+
glossary terms. Metastore URL derived from stack URL by replacing `connection.`
|
|
949
|
+
with `metastore.`. Auth: same `X-StorageApi-Token` as Storage. Alias:
|
|
950
|
+
`kbagent sl ...` (hidden) is equivalent to `kbagent semantic-layer ...`.
|
|
951
|
+
|
|
952
|
+
kbagent semantic-layer model list --project P
|
|
953
|
+
List all semantic-layer models in a project.
|
|
954
|
+
|
|
955
|
+
kbagent semantic-layer model create --project P --name N [--description D] [--sql-dialect Snowflake]
|
|
956
|
+
Create a new model (default sql-dialect: Snowflake).
|
|
957
|
+
|
|
958
|
+
kbagent semantic-layer model delete --project P --model M [--yes]
|
|
959
|
+
Delete a model. Fails if the model still has child entities.
|
|
960
|
+
|
|
961
|
+
kbagent semantic-layer show --project P [--model M] [--type T]
|
|
962
|
+
Show a model's entities. --type filter: dataset|metric|relationship|constraint|glossary.
|
|
963
|
+
Without --type prints a per-type count summary.
|
|
964
|
+
|
|
965
|
+
kbagent semantic-layer search-context --project P [--pattern G ...] [--type model|dataset|metric|relationship|constraint|glossary|all] [--limit N]
|
|
966
|
+
(since 0.47.0) Project-wide glob search across semantic-layer entity names.
|
|
967
|
+
Mirrors the upstream keboola-mcp-server search_semantic_context tool so a
|
|
968
|
+
downstream caller can verify the model is populated without an MCP dependency.
|
|
969
|
+
Patterns are case-sensitive fnmatch, repeatable (union). Default pattern is "*".
|
|
970
|
+
Default --type is "all" (every CHILD type; "model" searches semantic models).
|
|
971
|
+
Returns {{project, contexts: [{{id, type, name, description, attributes}}], total_count}}.
|
|
972
|
+
|
|
973
|
+
kbagent semantic-layer get-context --project P --context-id ID
|
|
974
|
+
(since 0.47.0) Single-entry fetch by id, irrespective of type. Probes model first,
|
|
975
|
+
then datasets/metrics/relationships/constraints/glossary in order; raises NOT_FOUND
|
|
976
|
+
if no type matches (exit 1).
|
|
977
|
+
|
|
978
|
+
kbagent semantic-layer validate --project P [--model M] [--deep]
|
|
979
|
+
Basic structural checks (duplicates, dangling refs, sum-on-pct,
|
|
980
|
+
constraint orphans, severity-suffix). --deep adds parallel Snowflake
|
|
981
|
+
column-existence checks for phantom fields, phantom column refs, and
|
|
982
|
+
AGG-on-STRING via in-process StorageService.
|
|
983
|
+
|
|
984
|
+
kbagent semantic-layer export --project P [--model M] [--output PATH]
|
|
985
|
+
Snapshot the model to a self-describing JSON file. Default path:
|
|
986
|
+
./sl_export_{{model_name}}_{{YYYYMMDD_HHMMSS}}.json.
|
|
987
|
+
|
|
988
|
+
kbagent semantic-layer diff (--project-a A | --file-a P) (--project-b B | --file-b P) [--model-a M] [--model-b M]
|
|
989
|
+
Three-way diff: project<->project, project<->file, file<->file. Output
|
|
990
|
+
groups changes per entity type: added, removed, changed (with diff_keys).
|
|
991
|
+
|
|
992
|
+
kbagent semantic-layer reference-data list|get|set|delete ... (since 0.55.0)
|
|
993
|
+
Dimension-member records (semantic-reference-data): one record per
|
|
994
|
+
dimension holding the full member list in a members[] array (e.g. a
|
|
995
|
+
Chart of Accounts). Deliberately OUTSIDE build/export/diff/cascade.
|
|
996
|
+
list --project P [--model M] -> dimension summaries (id, dimension,
|
|
997
|
+
member_count). get --project P (--id ID | --dimension D) ->
|
|
998
|
+
one record + all members (dimension is project-unique, so no model
|
|
999
|
+
needed). set --project P [--model M] --dimension D
|
|
1000
|
+
--members-file PATH ('-' = stdin) [--dataset-id T] [--description X] ->
|
|
1001
|
+
create-or-replace, idempotent on dimension (project-wide lookup): an
|
|
1002
|
+
existing record is replaced in place via PUT (revision++), else POST.
|
|
1003
|
+
delete --project P --id ID [--yes]. Member keys mirror the DIM_COA
|
|
1004
|
+
columns (account_code, account_name, parent_code, is_leaf, ...).
|
|
1005
|
+
|
|
1006
|
+
kbagent semantic-layer add metric|dataset|relationship|constraint|glossary ...
|
|
1007
|
+
Add one entity. Dataset auto-derives `fqn` from --table-id; --deep-fields
|
|
1008
|
+
fetches the storage schema and synthesises role-classified fields
|
|
1009
|
+
(PK_/FK_->key, *_DATE/*_DT->timestamp, numeric amount/value/rate->measure,
|
|
1010
|
+
else dimension). Constraint name regex `^[a-z][a-z0-9_]*$`, severity is
|
|
1011
|
+
error|warning|info (the 4-band health convention lives in the NAME suffix
|
|
1012
|
+
`_critical/_warning/_healthy/_review`, not the API severity). `--rule` is
|
|
1013
|
+
a STRING expression (e.g. "value >= 0"), NEVER an object.
|
|
1014
|
+
|
|
1015
|
+
kbagent semantic-layer edit metric|dataset|constraint|relationship|glossary ...
|
|
1016
|
+
DELETE+POST (no PATCH on metastore). Metric rename cascades through every
|
|
1017
|
+
constraint referencing the old name (DELETE old + POST new with updated
|
|
1018
|
+
metrics[]); CODE_METRIC warning shown
|
|
1019
|
+
(re.sub(r"[^A-Z0-9]+", "_", name.upper()).strip("_")). On POST failure,
|
|
1020
|
+
rollback re-POSTs original_attrs and reports success/failure explicitly.
|
|
1021
|
+
--yes skips the confirm prompt. `edit relationship` accepts --new-from /
|
|
1022
|
+
--new-to / --new-on / --new-type (left|inner). `edit glossary` accepts
|
|
1023
|
+
--new-term (destructive cascade; requires --yes in non-TTY) / --new-definition.
|
|
1024
|
+
Partial-state envelope (since v0.41.10): when metric rename succeeds but
|
|
1025
|
+
one or more dependent constraints fail to repoint, the response sets
|
|
1026
|
+
`partial_state: true` at the top level + `recovery_hint: "<text>"`
|
|
1027
|
+
pointing at `semantic-layer validate` + manual `edit constraint
|
|
1028
|
+
--new-metrics ...`. Human-mode CLI prints a red `PARTIAL STATE` banner
|
|
1029
|
+
above the per-entry list. `edit_simple` (no-cascade variants) carries
|
|
1030
|
+
`partial_state: false, recovery_hint: null` for envelope uniformity.
|
|
1031
|
+
|
|
1032
|
+
kbagent semantic-layer remove metric|dataset|constraint|relationship|glossary ...
|
|
1033
|
+
Destructive. `remove metric` pre-scans constraints whose metrics[] includes
|
|
1034
|
+
the target; warns about dangling DIM_METRIC_THRESHOLD refs. --yes skips the
|
|
1035
|
+
prompt but the orphan warning is always printed. Non-TTY without --yes
|
|
1036
|
+
refuses with exit 2. `remove relationship` and `remove glossary` are leaf
|
|
1037
|
+
removes -- no orphan-check (those entities aren't referenced by others).
|
|
1038
|
+
`remove glossary` identifies the entity by --term, not --name.
|
|
1039
|
+
|
|
1040
|
+
kbagent semantic-layer import --project P --file PATH [--model M] [--types T,T,...] [--dry-run] [--yes] [--overwrite]
|
|
1041
|
+
Replay a snapshot. Default: skip on conflict. --overwrite opts into
|
|
1042
|
+
DELETE+POST. Dependency-ordered push (datasets -> metrics -> relationships
|
|
1043
|
+
-> glossary -> constraints).
|
|
1044
|
+
|
|
1045
|
+
kbagent semantic-layer promote --from-project A --to-project B [--from-model M] [--to-model M] [--types ...] [--dry-run] [--yes]
|
|
1046
|
+
Cross-project copy with modelUUID rewrite. Classifies items NEW / IDENTICAL
|
|
1047
|
+
/ CHANGED (deep-equality after stripping modelUUID + timestamps).
|
|
1048
|
+
Additive + overwrite only -- NEVER deletes target items absent from source.
|
|
1049
|
+
|
|
1050
|
+
kbagent semantic-layer build --project P [--model M] --tables T,T,... [--dry-run] [--keep-on-failure] [--output PATH]
|
|
1051
|
+
Non-interactive heuristic builder. AI caveat: the ai_client has no
|
|
1052
|
+
arbitrary-JSON endpoint, so `build` falls back to a deterministic
|
|
1053
|
+
heuristic (one dataset + one COUNT(*) metric + one glossary entry per
|
|
1054
|
+
table; FQN derived; fields[] role-classified). Response carries
|
|
1055
|
+
`fallback_used: "heuristic"`. Push loop iterates all 5 child types in
|
|
1056
|
+
dependency order (fixes the long-standing sl-build skill bug where
|
|
1057
|
+
semantic-constraint was silently dropped). On push failure rolls back
|
|
1058
|
+
every successfully-POSTed child in reverse order + deletes the model
|
|
1059
|
+
if we created it (since v0.41.10); pass --keep-on-failure to preserve
|
|
1060
|
+
the partial state for forensic inspection (mirrors data-app create).
|
|
1061
|
+
|
|
1062
|
+
kbagent semantic-layer token --encrypt --project P --component-id C
|
|
1063
|
+
Encrypt the project's storage token for transformation `user_properties`.
|
|
1064
|
+
Builds {{"#metastore_token": <token>}} and delegates to EncryptService.
|
|
1065
|
+
--encrypt is currently required; other modes refused with USAGE_ERROR.
|
|
1066
|
+
|
|
1067
|
+
|
|
1068
|
+
### Self-call HTTP (inside `kbagent serve` subprocesses)
|
|
1069
|
+
|
|
1070
|
+
kbagent http get PATH [--timeout SECONDS]
|
|
1071
|
+
kbagent http post PATH [--body JSON|@file|-] [--timeout SECONDS]
|
|
1072
|
+
kbagent http patch PATH [--body JSON|@file|-] [--timeout SECONDS]
|
|
1073
|
+
kbagent http delete PATH [--timeout SECONDS]
|
|
1074
|
+
Raw HTTP client against the running `kbagent serve`. Reads KBAGENT_SERVE_URL +
|
|
1075
|
+
KBAGENT_SERVE_TOKEN env vars (auto-injected into AI-agent / cli_command
|
|
1076
|
+
subprocesses by the scheduler). Example:
|
|
1077
|
+
kbagent http get /openapi.json # browse server's OpenAPI schema
|
|
1078
|
+
kbagent http get /projects # list projects via HTTP
|
|
1079
|
+
kbagent http post /agents/test --body @task.json
|
|
1080
|
+
Prefer this over forking `kbagent` CLI inside scheduled-agent tasks --
|
|
1081
|
+
`kbagent http` calls the serve directly so you always see the same config
|
|
1082
|
+
the operator configured (not the global ~/.config one). Outside a serve
|
|
1083
|
+
subprocess context the command refuses to run.
|
|
1084
|
+
|
|
1085
|
+
### Agent Tasks (CLI parity with the `/agents` REST surface)
|
|
1086
|
+
|
|
1087
|
+
Reads/writes <config_dir>/agents.json -- the same on-disk format the
|
|
1088
|
+
cron loop inside `kbagent serve` consumes. CLI CRUD + ad-hoc `run`
|
|
1089
|
+
work offline; cron firing still requires the live server.
|
|
1090
|
+
|
|
1091
|
+
Every subcommand below that takes TASK_ID / RUN_ID accepts it either
|
|
1092
|
+
positionally (`agent show TASK_ID`) or via flag (`--id` / `--task-id`,
|
|
1093
|
+
plus `--run-id` for run-detail / run-events) -- the flag form matches
|
|
1094
|
+
the rest of the CLI (`--job-id`, `--config-id`, ...).
|
|
1095
|
+
|
|
1096
|
+
kbagent agent list
|
|
1097
|
+
List all registered tasks (id, name, cron, type, state, last/next run).
|
|
1098
|
+
|
|
1099
|
+
kbagent agent show TASK_ID
|
|
1100
|
+
Full task detail including the action payload.
|
|
1101
|
+
|
|
1102
|
+
kbagent agent create --name N [--description D] [--cron CRON] [--manual]
|
|
1103
|
+
[--enabled/--disabled]
|
|
1104
|
+
(--type ai_agent --cli claude|codex|gemini --prompt P
|
|
1105
|
+
[--extra-arg ARG ...] [--timeout SECONDS]
|
|
1106
|
+
|--type cli_command --argv ARG [--argv ARG ...]
|
|
1107
|
+
[--timeout SECONDS]
|
|
1108
|
+
|--type mcp_tool --tool TOOL [--mcp-project ALIAS]
|
|
1109
|
+
[--mcp-branch ID] [--input JSON|@file|-]
|
|
1110
|
+
[--timeout SECONDS]
|
|
1111
|
+
|--from-file PATH|@path|-)
|
|
1112
|
+
[--trigger-task-id ID --trigger-on success|error|always]
|
|
1113
|
+
Persist a new scheduled task. --manual skips the cron loop. Use
|
|
1114
|
+
--from-file for the full {{"type":..., "params":...}} JSON envelope
|
|
1115
|
+
when prompts/args grow large. --extra-arg on an ai_agent task is
|
|
1116
|
+
honored only when the kbagent process (serve, or this `agent` run)
|
|
1117
|
+
has a truthy KBAGENT_ALLOW_AI_EXTRA_ARGS env (since 0.60.2);
|
|
1118
|
+
otherwise the args are dropped with a warning.
|
|
1119
|
+
|
|
1120
|
+
kbagent agent update TASK_ID [--name N] [--description D] [--cron C]
|
|
1121
|
+
[--enabled/--disabled] [--manual/--auto]
|
|
1122
|
+
[--clear-trigger]
|
|
1123
|
+
[--trigger-task-id ID --trigger-on ...]
|
|
1124
|
+
Patch one or more fields. Omitted flags leave the field unchanged.
|
|
1125
|
+
--manual nulls next_run_at; --auto recomputes it from the cron expr.
|
|
1126
|
+
|
|
1127
|
+
kbagent agent delete TASK_ID [--yes]
|
|
1128
|
+
Permanent removal. Run history on disk is preserved.
|
|
1129
|
+
|
|
1130
|
+
kbagent agent run TASK_ID [--stream]
|
|
1131
|
+
[--runtime-prompt TEXT | --runtime-input JSON|@file|-]
|
|
1132
|
+
Trigger immediately. --stream emits live events (one line per event;
|
|
1133
|
+
NDJSON in --json mode). --runtime-prompt appends ad-hoc text to an
|
|
1134
|
+
ai_agent's persisted prompt for this run only; --runtime-input merges
|
|
1135
|
+
arbitrary JSON into the action params.
|
|
1136
|
+
|
|
1137
|
+
kbagent agent runs TASK_ID [--limit N]
|
|
1138
|
+
Run history (newest first).
|
|
1139
|
+
|
|
1140
|
+
kbagent agent run-detail TASK_ID RUN_ID
|
|
1141
|
+
Single AgentRun record (status, summary, output, error).
|
|
1142
|
+
|
|
1143
|
+
kbagent agent run-events TASK_ID RUN_ID
|
|
1144
|
+
Replay the persisted ai_agent event timeline.
|
|
1145
|
+
|
|
1146
|
+
kbagent agent test [--type ... | --from-file PATH] [--stream] [--name N]
|
|
1147
|
+
[common action flags from `create`]
|
|
1148
|
+
Execute an action ad-hoc -- nothing is persisted. Useful for
|
|
1149
|
+
sanity-checking a prompt / tool / argv before saving.
|
|
1150
|
+
|
|
1151
|
+
kbagent agent cron-preview --cron "0 6 * * 1" [--count N]
|
|
1152
|
+
Validate a cron expression and show the next N firings (UTC, max 20).
|
|
1153
|
+
|
|
1154
|
+
kbagent agent prompt-improve --goal "..." [--draft "..."]
|
|
1155
|
+
[--cli claude|codex|gemini] [--project ALIAS]
|
|
1156
|
+
[--extra-arg X ...] [--stream/--no-stream]
|
|
1157
|
+
AI-polished single-shot prompt for an unattended agent task. Spawns
|
|
1158
|
+
the chosen AI CLI with a meta-prompt; the final `done` event's
|
|
1159
|
+
`data.prompt` carries the cleaned body ready to paste into
|
|
1160
|
+
`agent create --prompt ...`. --extra-arg follows the same
|
|
1161
|
+
KBAGENT_ALLOW_AI_EXTRA_ARGS opt-in as `agent create` (since 0.60.2).
|
|
1162
|
+
|
|
1163
|
+
See agent-tasks-cli-workflow.md skill reference for full walkthroughs.
|
|
1164
|
+
|
|
1165
|
+
### MCP Tools (Multi-Project)
|
|
1166
|
+
|
|
1167
|
+
kbagent tool list [--project NAME] [--branch ID]
|
|
1168
|
+
List MCP tools with inputSchema. Use --json to inspect accepted parameters.
|
|
1169
|
+
|
|
1170
|
+
kbagent tool call TOOL_NAME [--project NAME] [--input JSON|@file|-] [--branch ID]
|
|
1171
|
+
Call an MCP tool. Read tools auto-query all projects. Write tools need --project.
|
|
1172
|
+
--input accepts: inline JSON, @file.json (from file), or - (from stdin).
|
|
1173
|
+
--branch is a CLI flag (NOT a tool input param). Do not pass branch_id in --input.
|
|
1174
|
+
|
|
1175
|
+
### Kai -- Keboola AI Assistant (BETA)
|
|
1176
|
+
|
|
1177
|
+
Requires the project to be added with its MASTER Storage API token (the
|
|
1178
|
+
auto-generated 'owner' token, not a custom one) and the 'AI Agent Chat'
|
|
1179
|
+
feature flag enabled on the project. Custom Storage API tokens cannot
|
|
1180
|
+
access Kai -- all `kbagent kai *` calls will fail with KAI_NOT_ENABLED.
|
|
1181
|
+
|
|
1182
|
+
kbagent kai ping [--project NAME]
|
|
1183
|
+
Check Kai server health and MCP connection status.
|
|
1184
|
+
Fails with KAI_NOT_ENABLED if the project lacks the 'agent-chat' feature
|
|
1185
|
+
or was added with a non-master token.
|
|
1186
|
+
|
|
1187
|
+
kbagent kai preflight [--project NAME]
|
|
1188
|
+
Inspect the configured token's Kai readiness WITHOUT raising. Returns
|
|
1189
|
+
{{ok, is_master_token, has_agent_chat_feature, token_description, error}}.
|
|
1190
|
+
Use this when you need to render a warning instead of failing — UIs and
|
|
1191
|
+
automation pre-flight checks should use this instead of `ping`.
|
|
1192
|
+
|
|
1193
|
+
kbagent kai chat-detail --chat-id ID [--project NAME]
|
|
1194
|
+
Fetch the full message history of a single Kai chat. Returns a flat list
|
|
1195
|
+
of {{role, content, created_at}} records. Use to restore / continue a
|
|
1196
|
+
conversation with `kai chat --chat-id ID` or to export a transcript.
|
|
1197
|
+
|
|
1198
|
+
kbagent kai ask --message "question" [--project NAME]
|
|
1199
|
+
One-shot question to Kai. Collects full response. Use --json for structured output.
|
|
1200
|
+
Kai has MCP access to project data -- use for Keboola-specific questions
|
|
1201
|
+
(e.g. "What tables do I have?", "Is it safe to drop bucket X?").
|
|
1202
|
+
|
|
1203
|
+
kbagent kai chat --message "msg" [--chat-id ID] [--project NAME]
|
|
1204
|
+
Send message in a chat session. Use --chat-id to continue a conversation.
|
|
1205
|
+
Without --chat-id starts a new chat. Returns chat_id for continuation.
|
|
1206
|
+
|
|
1207
|
+
kbagent kai history [--project NAME] [--limit N]
|
|
1208
|
+
List recent Kai chat sessions. Default limit: 10.
|
|
1209
|
+
|
|
1210
|
+
### Developer Portal (since v0.49.0)
|
|
1211
|
+
|
|
1212
|
+
The `dev-portal` command group talks to `apps-api.keboola.com` (the Keboola
|
|
1213
|
+
Developer Portal) and lets component developers register and update components
|
|
1214
|
+
without leaving the terminal.
|
|
1215
|
+
|
|
1216
|
+
**Safety contract**: reads are unrestricted. Writes (`create`, `patch`,
|
|
1217
|
+
`upload-icon`, `publish`, `deprecate`) always print the full pending request
|
|
1218
|
+
and then require the user to type a random hex code on a real TTY. There is
|
|
1219
|
+
no `--yes` flag and no env-var bypass; non-TTY shells exit 6. Use `--dry-run`
|
|
1220
|
+
to get a clean exit-0 preview (the agent-safe path).
|
|
1221
|
+
|
|
1222
|
+
**Identity management** -- portal logins are stored per-alias in `config.json`:
|
|
1223
|
+
|
|
1224
|
+
kbagent dev-portal identity add --alias vendor-keboola \\
|
|
1225
|
+
--username service.keboola.xxxxx --password ... --vendor keboola \\
|
|
1226
|
+
--role-hint vendor # default; restricts PATCH to vendor endpoint
|
|
1227
|
+
kbagent dev-portal identity add --alias admin-keboola \\
|
|
1228
|
+
--username admin@keboola.com --role-hint admin --password-stdin
|
|
1229
|
+
kbagent dev-portal identity use vendor-keboola
|
|
1230
|
+
|
|
1231
|
+
**`role_hint` is load-bearing (since v0.51.1)**: `vendor` (default) routes
|
|
1232
|
+
`dev-portal patch` to `PATCH /vendors/{{vendor}}/apps/{{app}}` (restricted
|
|
1233
|
+
schema); `admin` routes it to `PATCH /admin/apps/{{app}}` (permissive
|
|
1234
|
+
schema). The admin endpoint is the **only** way to set the 9 fields
|
|
1235
|
+
apps-api `.forbidden()`s on vendor: `complexity`, `categories`, `category`,
|
|
1236
|
+
`features`, `forwardToken`, `forwardTokenDetails`, `injectEnvironment`,
|
|
1237
|
+
`processTimeout`, `requiredMemory`. Sending any of those with a `vendor`
|
|
1238
|
+
identity fails fast at preflight with the exact command to switch
|
|
1239
|
+
identity (server-side it would have returned a misleading 422 saying
|
|
1240
|
+
"must be one of: easy, medium, hard"; that message is a known apps-api
|
|
1241
|
+
bug -- the field is actually `forbidden()`, not enum-validated).
|
|
1242
|
+
|
|
1243
|
+
**`--password-stdin` (since v0.51.1)** works on TTY (hidden line-based
|
|
1244
|
+
prompt, Enter to confirm) AND on a pipe (`echo $PASS | … --password-stdin`,
|
|
1245
|
+
reads to EOF). Pre-0.51.1 the flag hung interactively because it always
|
|
1246
|
+
waited for EOF.
|
|
1247
|
+
|
|
1248
|
+
**Read commands** (unrestricted; good for peer-config research):
|
|
1249
|
+
|
|
1250
|
+
kbagent --json dev-portal list --vendor keboola
|
|
1251
|
+
List all apps for a vendor. Use for peer research: compare how existing
|
|
1252
|
+
extractors configure uiOptions, encryption, defaultBucket, etc.
|
|
1253
|
+
|
|
1254
|
+
kbagent --json dev-portal get --app keboola.ex-db-mysql
|
|
1255
|
+
Full portal entry for one component. Pull two peers and compare.
|
|
1256
|
+
|
|
1257
|
+
**Write commands** (require random-code TTY confirm; use --dry-run first):
|
|
1258
|
+
|
|
1259
|
+
kbagent dev-portal create --vendor V --data FILE [--dry-run]
|
|
1260
|
+
kbagent dev-portal patch --app VENDOR.APP_ID (--data FILE | --property KEY ...) [--dry-run]
|
|
1261
|
+
kbagent dev-portal upload-icon --app VENDOR.APP_ID --file PATH [--dry-run]
|
|
1262
|
+
kbagent dev-portal publish --app VENDOR.APP_ID [--dry-run]
|
|
1263
|
+
kbagent dev-portal deprecate --app VENDOR.APP_ID [--dry-run]
|
|
1264
|
+
|
|
1265
|
+
**Identity lifecycle**:
|
|
1266
|
+
|
|
1267
|
+
kbagent dev-portal identity add / list / remove / edit / use / current / verify
|
|
1268
|
+
|
|
1269
|
+
**Identity selection**: pass `--identity <alias>` on any command, or set the
|
|
1270
|
+
default with `dev-portal identity use <alias>`.
|
|
1271
|
+
|
|
1272
|
+
### Utility Commands
|
|
1273
|
+
|
|
1274
|
+
kbagent init [--from-global] [--project ALIAS ...]
|
|
1275
|
+
Create local .kbagent/ workspace. --from-global copies existing projects;
|
|
1276
|
+
--project ALIAS (repeatable) copies only the named project(s) and implies
|
|
1277
|
+
--from-global.
|
|
1278
|
+
|
|
1279
|
+
kbagent context
|
|
1280
|
+
Show this reference text.
|
|
1281
|
+
|
|
1282
|
+
kbagent serve [--host HOST] [--port PORT] [--ui] [--ui-dist PATH] [--reload]
|
|
1283
|
+
[--log-level LVL] [--cors-origin ORIGIN] [--config-dir DIR]
|
|
1284
|
+
Launch the FastAPI HTTP server backing the web UI. Two modes:
|
|
1285
|
+
|
|
1286
|
+
- `--ui` (single-process, recommended): bundles the built React SPA from
|
|
1287
|
+
`--ui-dist PATH` (default: shipped `web/frontend/dist`) and mounts it at
|
|
1288
|
+
`/`. The bearer token is injected via an HttpOnly `kbagent_session`
|
|
1289
|
+
cookie on the SPA bootstrap, so the browser is already authenticated
|
|
1290
|
+
and no token leaves the terminal. EventSource SSE connections use the
|
|
1291
|
+
same cookie; nothing leaks into URLs or proxy logs.
|
|
1292
|
+
- No `--ui`: API-only mode; the SPA must be served separately (the
|
|
1293
|
+
legacy three-process dev setup with web/backend + web/frontend).
|
|
1294
|
+
|
|
1295
|
+
Prints the bearer token to stdout on startup (use it for `kbagent http`
|
|
1296
|
+
subprocesses). Requires the optional 'server' extra:
|
|
1297
|
+
`uv pip install -e ".[server]"`.
|
|
1298
|
+
|
|
1299
|
+
kbagent doctor [--fix]
|
|
1300
|
+
Health checks. --fix auto-installs MCP server binary. Inside a sync working
|
|
1301
|
+
tree, the sync_secrets check (since 0.55.0) warns about in-sync configs that
|
|
1302
|
+
still hold plaintext #-secrets (#378); skipped outside a sync tree.
|
|
1303
|
+
|
|
1304
|
+
kbagent version [--beta]
|
|
1305
|
+
Version info for kbagent + keboola-mcp-server. Reports both the locally
|
|
1306
|
+
installed version and the latest available; flags any staleness.
|
|
1307
|
+
--beta (since 0.42.0) reports the latest pre-release (beta / rc) instead
|
|
1308
|
+
of the latest stable. Same env override: KBAGENT_INCLUDE_PRERELEASE=1.
|
|
1309
|
+
|
|
1310
|
+
kbagent update [--beta]
|
|
1311
|
+
Two-stage upgrade (since 0.30.1): kbagent itself AND keboola-mcp-server.
|
|
1312
|
+
The MCP server is detected (uv tool / pip env / uvx) and bumped via the
|
|
1313
|
+
matching command. Both stages always run, regardless of whether kbagent
|
|
1314
|
+
itself needed an upgrade. The same flow runs automatically on every
|
|
1315
|
+
kbagent startup -- the explicit `update` command forces a fresh check.
|
|
1316
|
+
--beta (since 0.42.0) opts into pre-release versions (PEP 440 betas/rc,
|
|
1317
|
+
e.g. 0.43.0b1). Without --beta the auto-update path uses GitHub's
|
|
1318
|
+
/releases/latest endpoint, which excludes prereleases server-side --
|
|
1319
|
+
stable users never silently land on a beta. Set
|
|
1320
|
+
KBAGENT_INCLUDE_PRERELEASE=1 in env to make every update in the session
|
|
1321
|
+
treat betas as installable without re-typing --beta.
|
|
1322
|
+
|
|
1323
|
+
kbagent changelog [--limit N] [--full]
|
|
1324
|
+
Show recent changelog (what changed in each version). Default: last 5
|
|
1325
|
+
versions, one-line summary each; --full (-v) expands every note.
|
|
1326
|
+
|
|
1327
|
+
kbagent permissions list [--category read|write|destructive|admin]
|
|
1328
|
+
List all operations with risk categories and current allowed/denied status.
|
|
1329
|
+
|
|
1330
|
+
kbagent permissions show
|
|
1331
|
+
Show current active permission policy.
|
|
1332
|
+
|
|
1333
|
+
kbagent permissions set --mode allow|deny [--allow PATTERN ...] [--deny PATTERN ...]
|
|
1334
|
+
Set firewall-style permission policy. Patterns: exact (branch.delete),
|
|
1335
|
+
glob (sync.*), category (cli:write, tool:read).
|
|
1336
|
+
|
|
1337
|
+
kbagent permissions reset
|
|
1338
|
+
Remove all restrictions.
|
|
1339
|
+
|
|
1340
|
+
kbagent permissions check OPERATION
|
|
1341
|
+
Check if operation is allowed. Exit 0=allowed, 6=denied. Reflects the
|
|
1342
|
+
EFFECTIVE policy: persisted policy MERGED with --deny-writes /
|
|
1343
|
+
--deny-destructive session flags (since 0.30.5; pre-0.30.5 consulted
|
|
1344
|
+
only the persisted policy and could mislead self-introspection).
|
|
1345
|
+
|
|
1346
|
+
## Tips for AI Agents
|
|
1347
|
+
|
|
1348
|
+
1. ALWAYS use --json flag for reliable, parseable output:
|
|
1349
|
+
kbagent --json project list
|
|
1350
|
+
|
|
1351
|
+
2. JSON response format:
|
|
1352
|
+
Success: {{"status": "ok", "data": ...}}
|
|
1353
|
+
Error: {{"status": "error", "error": {{"code": "...", "message": "...", "retryable": true/false}}}}
|
|
1354
|
+
Check "retryable" -- if true, retry the operation.
|
|
1355
|
+
|
|
1356
|
+
3. Multi-project: most read commands accept repeatable --project flag.
|
|
1357
|
+
Omit --project to query ALL connected projects in parallel.
|
|
1358
|
+
|
|
1359
|
+
4. Tokens are always masked in output (e.g. 901-...XXXX) -- expected behavior.
|
|
1360
|
+
|
|
1361
|
+
5. Common workflow -- explore a project:
|
|
1362
|
+
kbagent --json project list
|
|
1363
|
+
kbagent --json config list --project prod
|
|
1364
|
+
kbagent --json config detail --project prod --component-id ID --config-id ID
|
|
1365
|
+
kbagent --json job list --project prod --status error --limit 10
|
|
1366
|
+
|
|
1367
|
+
6. Health check and setup:
|
|
1368
|
+
kbagent --json doctor # full health check
|
|
1369
|
+
kbagent doctor --fix # auto-install MCP server
|
|
1370
|
+
kbagent --json project status # test all connections
|
|
1371
|
+
|
|
1372
|
+
7. Environment variables:
|
|
1373
|
+
KBAGENT_CONVERSATION_ID Conversation/session ID (REQUIRED -- sent as X-Conversation-ID header)
|
|
1374
|
+
KBC_TOKEN Storage API token (fallback for --token)
|
|
1375
|
+
KBC_STORAGE_API_URL Default stack URL (fallback for --url)
|
|
1376
|
+
KBC_MANAGE_API_TOKEN Manage API token (org setup, project refresh, data-app password).
|
|
1377
|
+
Default-DENY since 0.29.0: pass --allow-env-manage-token
|
|
1378
|
+
to opt in, otherwise this var is ignored and a TTY prompt
|
|
1379
|
+
is required. Closes AI-exfiltration via subprocess env.
|
|
1380
|
+
KBC_MASTER_TOKEN Master token for sharing ops (global fallback)
|
|
1381
|
+
KBC_MASTER_TOKEN_* Per-project master token (e.g. KBC_MASTER_TOKEN_PROD)
|
|
1382
|
+
KBAGENT_CONFIG_DIR Override config directory
|
|
1383
|
+
KBAGENT_PROJECT Override the pinned default project for this shell/session (beats pin, loses to --project)
|
|
1384
|
+
KBAGENT_PROJECT_FROM_ENV Set to "1" (or true/yes/on) to synthesize an in-memory project under the
|
|
1385
|
+
reserved alias __env__ from KBC_TOKEN + KBC_STORAGE_API_URL (since 0.50.0).
|
|
1386
|
+
Headless / token-only mode: no `project add`, no config.json on disk. Use
|
|
1387
|
+
`--project __env__` (or rely on it as the sole/default project). The token
|
|
1388
|
+
lives in memory only -- it is NEVER persisted, even if a write op runs.
|
|
1389
|
+
Works for both the CLI and `kbagent serve`. Fails fast if the flag is set
|
|
1390
|
+
but KBC_TOKEN / KBC_STORAGE_API_URL are missing.
|
|
1391
|
+
KBAGENT_MAX_PARALLEL_WORKERS Max concurrent threads for multi-project ops (default 10, max 100)
|
|
1392
|
+
KBAGENT_AUTO_UPDATE Set to "false" to disable automatic update on startup
|
|
1393
|
+
KBAGENT_UPDATE_TIMEOUT Integer seconds; overrides the 300s self-update subprocess timeout
|
|
1394
|
+
(raise for slow WSL git+ source builds). Since 0.60.0 install/update
|
|
1395
|
+
prefer a prebuilt wheel Release asset, so timeouts are rare.
|
|
1396
|
+
KBAGENT_UPDATED_FROM Set to an older version to trigger "What's new" display on next run
|
|
1397
|
+
KBAGENT_MCP_TRANSPORT MCP transport mode: "http" (default, persistent) or "stdio" (subprocess)
|
|
1398
|
+
KBAGENT_INCLUDE_PRERELEASE Set to "1" (or "true"/"yes"/"on") to opt into pre-release versions for
|
|
1399
|
+
`kbagent update` / `kbagent version` in this shell (equivalent to --beta flag,
|
|
1400
|
+
since 0.43.3). NEVER affects the startup auto-update hook -- that path is
|
|
1401
|
+
stable-channel-only by design so betas stay an explicit per-invocation choice.
|
|
1402
|
+
|
|
1403
|
+
8. Config resolution order:
|
|
1404
|
+
--config-dir flag > KBAGENT_CONFIG_DIR env > .kbagent/ in CWD/parents > ~/.config/keboola-agent-cli/
|
|
1405
|
+
|
|
1406
|
+
9. MCP tool parameters -- discover with `kbagent --json tool list`:
|
|
1407
|
+
- Only pass parameters defined in the tool's inputSchema via --input
|
|
1408
|
+
- branch_id is a CLI flag (--branch), NOT a tool input parameter
|
|
1409
|
+
- Example: get_configs uses "configs" (list of objects), not flat "config_id"
|
|
1410
|
+
kbagent --json tool call get_configs --project prod --branch 456 \\
|
|
1411
|
+
--input '{{"configs": [{{"component_id": "keboola.snowflake-transformation", "configuration_id": "12345"}}]}}'
|
|
1412
|
+
|
|
1413
|
+
10. Parquet export (typed analytics data, no CSV round-trip):
|
|
1414
|
+
# Export + download as Parquet dataset (default layout mirrors Keboola addressing)
|
|
1415
|
+
kbagent storage unload-table --project prod \\
|
|
1416
|
+
--table-id in.c-my-bucket.my-table \\
|
|
1417
|
+
--file-type parquet --download
|
|
1418
|
+
# -> ./prod/in.c-my-bucket.my-table.parquet/
|
|
1419
|
+
# ├── <slice>.parquet
|
|
1420
|
+
# └── _manifest.json (underscore -> skipped by pyarrow/Spark/DuckDB)
|
|
1421
|
+
|
|
1422
|
+
# Read the whole dataset in one line -- directory is a valid Parquet dataset:
|
|
1423
|
+
# python: pyarrow.parquet.read_table("./prod/in.c-my-bucket.my-table.parquet/")
|
|
1424
|
+
|
|
1425
|
+
# Export only (stays in Keboola Storage Files, no local copy):
|
|
1426
|
+
kbagent --json storage unload-table --project prod \\
|
|
1427
|
+
--table-id in.c-bucket.t --file-type parquet --tag daily
|
|
1428
|
+
# -> {{"file_id": 123, "file_type": "parquet", "is_sliced": true, ...}}
|
|
1429
|
+
|
|
1430
|
+
# Download an existing sliced .parquet Storage File (auto-detected):
|
|
1431
|
+
kbagent storage file-download --project prod --file-id 123 --output ./dir/
|
|
1432
|
+
|
|
1433
|
+
Notes:
|
|
1434
|
+
- Parquet output is ALWAYS sliced -> directory, never a single file.
|
|
1435
|
+
- Default download path: ./{{project_alias}}/{{table_id}}.parquet/ -- override with --output.
|
|
1436
|
+
- CSV concat logic is never used for parquet; slices have their own footers.
|
|
1437
|
+
|
|
1438
|
+
## Exit Codes
|
|
1439
|
+
|
|
1440
|
+
0 Success
|
|
1441
|
+
1 General error
|
|
1442
|
+
2 Usage error (invalid arguments)
|
|
1443
|
+
3 Authentication error (invalid or expired token)
|
|
1444
|
+
4 Network error (timeout, unreachable server)
|
|
1445
|
+
5 Configuration error (corrupt config, missing alias)
|
|
1446
|
+
6 Permission denied (operation blocked by policy)
|
|
1447
|
+
|
|
1448
|
+
When you receive a non-zero exit code, use --json to get structured error details.
|
|
1449
|
+
|
|
1450
|
+
## Claude Code Plugin
|
|
1451
|
+
|
|
1452
|
+
If you are using Claude Code, install the kbagent plugin for richer guidance:
|
|
1453
|
+
|
|
1454
|
+
/plugin marketplace add keboola/cli
|
|
1455
|
+
/plugin install kbagent@keboola-agent-cli
|
|
1456
|
+
|
|
1457
|
+
The plugin provides a skill with detailed workflow references including:
|
|
1458
|
+
- SQL transformation migration (input mapping removal, Snowflake paths)
|
|
1459
|
+
- Workspace SQL debugging
|
|
1460
|
+
- Development branch lifecycle
|
|
1461
|
+
- Configuration scaffolding and sync (GitOps)
|
|
1462
|
+
- Common Snowflake gotchas (MULTI_STATEMENT_COUNT, quoting, etc.)
|
|
1463
|
+
|
|
1464
|
+
The skill triggers automatically when you mention Keboola-related tasks.
|
|
1465
|
+
Without the plugin, this `kbagent context` output is your standalone reference.
|
|
1466
|
+
"""
|
|
1467
|
+
|
|
1468
|
+
|
|
1469
|
+
def context_command(ctx: typer.Context) -> None:
|
|
1470
|
+
"""Show usage instructions for AI agents interacting with Keboola."""
|
|
1471
|
+
formatter = get_formatter(ctx)
|
|
1472
|
+
|
|
1473
|
+
if formatter.json_mode:
|
|
1474
|
+
# In JSON mode, output the context text as structured data
|
|
1475
|
+
data = {
|
|
1476
|
+
"version": __version__,
|
|
1477
|
+
"context": AGENT_CONTEXT,
|
|
1478
|
+
}
|
|
1479
|
+
formatter.output(data)
|
|
1480
|
+
else:
|
|
1481
|
+
formatter.console.print(AGENT_CONTEXT)
|