@metabase/cli 0.1.0-alpha.workspaces-commands.28a297a → 0.1.0-alpha.workspaces-commands.aa383a1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (185) hide show
  1. package/README.md +59 -22
  2. package/dist/add-collection-Bw_KL6EH.mjs +11 -0
  3. package/dist/{add-collection-DB2C0Pdw.mjs → add-collection-Cvh_24_Q.mjs} +4 -4
  4. package/dist/{api-key-BqZV1nLg.mjs → api-key-d2kBtC3S.mjs} +1 -1
  5. package/dist/{archive-e-4fxNMq.mjs → archive-BbY8tyIA.mjs} +7 -7
  6. package/dist/{archive-c6NmnA8k.mjs → archive-CMEk6RsU.mjs} +6 -6
  7. package/dist/{archive-CuYuesnm.mjs → archive-O0WoU8LU.mjs} +5 -5
  8. package/dist/{archive-B1keZ1oV.mjs → archive-WgWmkexh.mjs} +7 -7
  9. package/dist/auth-DCoGwYKi.mjs +19 -0
  10. package/dist/{body-D_BRIb1g.mjs → body-C2lo4Axp.mjs} +3 -3
  11. package/dist/{branches-Dy_8vIh4.mjs → branches-ohsIXufV.mjs} +6 -6
  12. package/dist/{cancel-Djld5ex0.mjs → cancel-eV9xzouo.mjs} +5 -5
  13. package/dist/{cancel-task-DX_5nq_N.mjs → cancel-task-DEI788SO.mjs} +6 -6
  14. package/dist/card-CtK41cpb.mjs +20 -0
  15. package/dist/{cards-Bhu7cd67.mjs → cards-B_XNja43.mjs} +6 -6
  16. package/dist/cli.mjs +24 -23
  17. package/dist/collection-CWYozp35.mjs +19 -0
  18. package/dist/{collection-BsiGRKXh.mjs → collection-DFqH6N7s.mjs} +2 -2
  19. package/dist/{create-CeaThiSk.mjs → create-BL84c0N2.mjs} +7 -7
  20. package/dist/{create-DObs_ZQY.mjs → create-CVRcTydU.mjs} +7 -7
  21. package/dist/{create-D52ykhxx.mjs → create-D5GQ3L7D.mjs} +8 -8
  22. package/dist/{create-BLntykb-.mjs → create-D_WX4JYl.mjs} +7 -7
  23. package/dist/{create-CXqsPb0D.mjs → create-Dh7YG1mO.mjs} +7 -7
  24. package/dist/{create-branch-B7GstHWB.mjs → create-branch-NM1OQ9Vk.mjs} +6 -6
  25. package/dist/{create-B2QidM_x.mjs → create-lBZSfAKV.mjs} +24 -16
  26. package/dist/{create-C7306Nj2.mjs → create-lYoy27zG.mjs} +7 -7
  27. package/dist/{create-gL677HA2.mjs → create-oFRJZRJW.mjs} +8 -7
  28. package/dist/{create-Dm32X31o.mjs → create-o_cxdysF.mjs} +7 -7
  29. package/dist/{create-u53lHBvb.mjs → create-wIKFYXjw.mjs} +9 -8
  30. package/dist/{credentials-3xkVaa31.mjs → credentials-dN7n9-oM.mjs} +8 -8
  31. package/dist/{current-task-MW424eQU.mjs → current-task-1oigZEYp.mjs} +6 -6
  32. package/dist/dashboard-GeAXKl0W.mjs +20 -0
  33. package/dist/{database-zA2GgRgJ.mjs → database-DiSMWtmg.mjs} +3 -3
  34. package/dist/{database-GbK7OAPX.mjs → database-DzcFix9u.mjs} +1 -1
  35. package/dist/db-2G-o2xtr.mjs +22 -0
  36. package/dist/{delete-CuUZ7fBH.mjs → delete-BV0Dawne.mjs} +7 -7
  37. package/dist/{delete-5RYMpau4.mjs → delete-D1Apu5tv.mjs} +7 -7
  38. package/dist/{delete-runtime-DCc3Hie4.mjs → delete-runtime-D8z0lCJ2.mjs} +2 -2
  39. package/dist/{delete-table-DdtjSOzx.mjs → delete-table-DQHUlwKv.mjs} +7 -7
  40. package/dist/{deprovision-BD9cBJHd.mjs → deprovision-osrI7qAP.mjs} +11 -11
  41. package/dist/{dirty-6hyoJZf4.mjs → dirty-BTHmduNN.mjs} +6 -6
  42. package/dist/{docker-W7ITnCLd.mjs → docker-m-PE5frg.mjs} +3 -3
  43. package/dist/{eid-AISoTK5d.mjs → eid-CANLCfwr.mjs} +1 -1
  44. package/dist/{errors-C6w1eZ1F.mjs → errors-DqPLKwoK.mjs} +54 -8
  45. package/dist/{export-Dfki7m6s.mjs → export-hg-kX3d5.mjs} +7 -7
  46. package/dist/field-CzZEYFp6.mjs +18 -0
  47. package/dist/{fields-DV4ytEF-.mjs → fields-B_QxZGbf.mjs} +7 -7
  48. package/dist/{flag-pair-Dz-mbq0z.mjs → flag-pair-Byca1x-Q.mjs} +1 -1
  49. package/dist/{get-BnXEaySB.mjs → get-BBcrLO_W.mjs} +6 -6
  50. package/dist/{get-DNOdvjBL.mjs → get-BD7Vyb-k.mjs} +5 -5
  51. package/dist/{get-Er4CIEdM.mjs → get-BZcSoeSY.mjs} +6 -6
  52. package/dist/get-Bp_SqgyX.mjs +53 -0
  53. package/dist/{get-TNKECwY7.mjs → get-CONAtf64.mjs} +6 -6
  54. package/dist/{get-AUwMskl2.mjs → get-D-ZPuk_T.mjs} +6 -6
  55. package/dist/{get-BPRZaF53.mjs → get-DQjJhZRm.mjs} +6 -6
  56. package/dist/{get-B-UkMh-Y.mjs → get-Dxyz8B08.mjs} +6 -6
  57. package/dist/{get-CSiojYCN.mjs → get-TRJ6QpYc.mjs} +6 -6
  58. package/dist/{get-CNhRpCvU.mjs → get-huQZIpRI.mjs} +6 -6
  59. package/dist/{get-BnRMSv1G.mjs → get-lPU3jSyo.mjs} +8 -8
  60. package/dist/{get-run-Dyv3Bm6R.mjs → get-run-WxHde6zO.mjs} +6 -6
  61. package/dist/{get-CcUzva2o.mjs → get-slUdOmG4.mjs} +6 -6
  62. package/dist/{has-remote-changes-CYrO6398.mjs → has-remote-changes-CQCior6b.mjs} +6 -6
  63. package/dist/{import-CyAT3jWh.mjs → import-y-7_YKQH.mjs} +7 -7
  64. package/dist/{input-DMcm_A5s.mjs → input-a1VFtFBh.mjs} +1 -1
  65. package/dist/is-dirty-CJ5aaXXs.mjs +10 -0
  66. package/dist/{is-dirty-0l6YxY-x.mjs → is-dirty-ZgX5mDJq.mjs} +3 -3
  67. package/dist/{items-DJp96l7n.mjs → items-ZP8yJJTA.mjs} +8 -8
  68. package/dist/{key-CjpAYsPz.mjs → key-UvYm9cOw.mjs} +1 -1
  69. package/dist/{license-CHccrjDp.mjs → license-2t70RAE_.mjs} +3 -3
  70. package/dist/{list-DkaTIDOc.mjs → list-B2dOeeua.mjs} +5 -5
  71. package/dist/{list-BJn9elDD.mjs → list-BAEch4jn.mjs} +5 -5
  72. package/dist/{list-C_sUJ2Yc.mjs → list-BHzsTJmU.mjs} +7 -7
  73. package/dist/{list-CpsaUvI3.mjs → list-BmI-BGK_.mjs} +7 -7
  74. package/dist/{list-B-Kt_Mm-.mjs → list-BsmGs2Wf.mjs} +4 -4
  75. package/dist/{list-BseZmPLw.mjs → list-CQVnPfi1.mjs} +5 -5
  76. package/dist/{list-DlWhwK41.mjs → list-CV-cfKnu.mjs} +5 -5
  77. package/dist/{list-BLxdaPvq.mjs → list-DO-Dxbq3.mjs} +5 -5
  78. package/dist/{list-RDJdCGOR.mjs → list-DZKxyQw1.mjs} +5 -5
  79. package/dist/{list-C0vbiU9Q.mjs → list-DjO6IxiH.mjs} +5 -5
  80. package/dist/{list-oRK_VvRO.mjs → list-VIZSxtf3.mjs} +4 -4
  81. package/dist/{list-CI_jCedk.mjs → list-dSoWq6_Y.mjs} +5 -5
  82. package/dist/{list-0k71E5wJ.mjs → list-ehmXcC-t.mjs} +5 -5
  83. package/dist/{login-CxCs_C85.mjs → login-D4a3b52m.mjs} +6 -6
  84. package/dist/{logout-f05owqsV.mjs → logout-BhO5sEm8.mjs} +5 -5
  85. package/dist/{logs-XUAbckH-.mjs → logs-DS6fKVNx.mjs} +6 -6
  86. package/dist/{manifest-CdAV6-YB.mjs → manifest-DalRNBAy.mjs} +2 -2
  87. package/dist/measure-Bagaha3J.mjs +19 -0
  88. package/dist/{metadata-Bl8qs0rn.mjs → metadata-CKuOfkMS.mjs} +8 -8
  89. package/dist/{metadata-MEAm5q9I.mjs → metadata-DN4Mqj7s.mjs} +7 -7
  90. package/dist/{package-CtkDnX1U.mjs → package-BPEXn1Of.mjs} +1 -1
  91. package/dist/{paginate-CnTxzOh2.mjs → paginate-B9W7ZuBj.mjs} +2 -2
  92. package/dist/{parse-id-jvzdqaO1.mjs → parse-id-BqO2IY1b.mjs} +1 -1
  93. package/dist/{parse-ref-CyeuK_yM.mjs → parse-ref-Oyf_TeW-.mjs} +1 -1
  94. package/dist/{parse-schemas-Dr5c5urd.mjs → parse-schemas-CJ0dEiTk.mjs} +2 -2
  95. package/dist/{poll-48PVbWIx.mjs → poll-DJWznjP9.mjs} +2 -2
  96. package/dist/{poll-task-DlcGug4o.mjs → poll-task-CXSagHdO.mjs} +2 -2
  97. package/dist/preflight-DQv-qq5r.mjs +91 -0
  98. package/dist/{prompt-k9s4Ntk5.mjs → prompt-g87Vvbx8.mjs} +1 -1
  99. package/dist/{provision-BqKjBXr6.mjs → provision-DXr7ZG8I.mjs} +12 -12
  100. package/dist/{ps-DFLSO-al.mjs → ps-DWXhgZVf.mjs} +3 -3
  101. package/dist/ps-NVWIylrB.mjs +10 -0
  102. package/dist/{query-BoIeOotH.mjs → query-DR0R8J_B.mjs} +9 -8
  103. package/dist/{query-Cv5RkyWm.mjs → query-q7b2hzrE.mjs} +5 -5
  104. package/dist/{remove-BZFVrrRi.mjs → remove-32Z7lUm6.mjs} +8 -8
  105. package/dist/{remove-CtOb1Exs.mjs → remove-Brcrdtfx.mjs} +5 -5
  106. package/dist/{remove-collection-CiRwsouq.mjs → remove-collection-D3RQTzDz.mjs} +8 -8
  107. package/dist/{render-BYWlZPEH.mjs → render-D8GOkk4P.mjs} +5 -2
  108. package/dist/{rescan-values-LuCZs_-Y.mjs → rescan-values-BpRkyMZp.mjs} +8 -8
  109. package/dist/{run-f5GaSWrR.mjs → run-DGMovJHI.mjs} +8 -8
  110. package/dist/{runs-ChAmvhjK.mjs → runs-DRnBkXmG.mjs} +7 -7
  111. package/dist/{runtime-BfWVLqFk.mjs → runtime-Dwaw7sqU.mjs} +13 -8
  112. package/dist/{schema-tables-BPF2GaD5.mjs → schema-tables-C-Rslrnl.mjs} +7 -7
  113. package/dist/{schemas-DEprqU5v.mjs → schemas-DzUHirII.mjs} +5 -5
  114. package/dist/{search-BU6MBJkj.mjs → search-CKie8hjZ.mjs} +5 -5
  115. package/dist/segment-C66MvGDy.mjs +19 -0
  116. package/dist/{set-D_MQ_q20.mjs → set-DuwiAGUc.mjs} +6 -6
  117. package/dist/{set-B65rz1rA.mjs → set-xF9CP68x.mjs} +8 -8
  118. package/dist/{setting-BDbBiriX.mjs → setting-DWoyNzLC.mjs} +3 -3
  119. package/dist/{setup-DfWKuwgQ.mjs → setup-Cn54kGu2.mjs} +6 -6
  120. package/dist/snippet-TOO4F2a8.mjs +19 -0
  121. package/dist/{start-qqtkW4kF.mjs → start-DpzDRfxQ.mjs} +12 -12
  122. package/dist/{stash-RjmKwTnL.mjs → stash-BT5wUeNt.mjs} +7 -7
  123. package/dist/{status-Bq9Or4ap.mjs → status-D7PR1KJp.mjs} +7 -7
  124. package/dist/{status-CMV_Y9s8.mjs → status-DKMAE9zo.mjs} +4 -4
  125. package/dist/{status-C9OI3uvE.mjs → status-g9cjxsHd.mjs} +4 -4
  126. package/dist/{stop-DYG1Hk0D.mjs → stop-Da7M-CRc.mjs} +8 -8
  127. package/dist/{summary-CFIZw6Z_.mjs → summary-3quv6ksc.mjs} +6 -6
  128. package/dist/sync-CcYMBXTo.mjs +28 -0
  129. package/dist/{sync-schema-DHP2ut3W.mjs → sync-schema-HcO7DSYi.mjs} +8 -8
  130. package/dist/{table-DhB2_Dxd.mjs → table-Ck9sInse.mjs} +2 -2
  131. package/dist/table-CpsE5VUF.mjs +19 -0
  132. package/dist/transform-CUxV3WSi.mjs +24 -0
  133. package/dist/transform-job-Dry0r1Xz.mjs +19 -0
  134. package/dist/{translate-C1KCIueR.mjs → translate-Z7f_VDDn.mjs} +7 -7
  135. package/dist/{tree-DN8mtMcc.mjs → tree-DZNnXYjb.mjs} +5 -5
  136. package/dist/{update-DPDC9Z5Z.mjs → update--v4lsiLM.mjs} +10 -9
  137. package/dist/{update-C4IrhfoO.mjs → update-BmvyguU9.mjs} +8 -8
  138. package/dist/{update-oct4Rsd_.mjs → update-C9N9kLkB.mjs} +9 -9
  139. package/dist/{update-vJoiGxbD.mjs → update-CKrsR2vZ.mjs} +12 -12
  140. package/dist/{update-D876ZU92.mjs → update-CPc3u-aB.mjs} +8 -8
  141. package/dist/{update-pM-Gf5JQ.mjs → update-CfLDXi8m.mjs} +13 -9
  142. package/dist/{update-B_rysKwt.mjs → update-D2J1WtKn.mjs} +8 -8
  143. package/dist/{update-gilP1tVa.mjs → update-DE0DPo7n.mjs} +8 -8
  144. package/dist/{update-DF5zkSQK.mjs → update-D_2eMRda.mjs} +8 -8
  145. package/dist/{update-dashcard-DDsQTcDm.mjs → update-dashcard-28PIWnwP.mjs} +8 -8
  146. package/dist/{update-qh8LxZtb.mjs → update-fRqtvI5G.mjs} +9 -8
  147. package/dist/{url-sg5mpmoG.mjs → url-yVWrLimZ.mjs} +7 -7
  148. package/dist/uuid-D9rbiLTK.mjs +47 -0
  149. package/dist/{validate-query-D0aAFTUs.mjs → validate-DlXXSNQ-.mjs} +47 -35
  150. package/dist/validate-query-Bc1-_glK.mjs +21 -0
  151. package/dist/{values-Bifff37r.mjs → values-K_-V36xz.mjs} +6 -6
  152. package/dist/{wait-CmT20Yfw.mjs → wait-C2S1JuUq.mjs} +7 -7
  153. package/dist/{wait-BNcrEoQa.mjs → wait-Ch__WrKD.mjs} +2 -2
  154. package/dist/{wait-flags-DNJCAYmz.mjs → wait-flags-Jdygg1yT.mjs} +2 -2
  155. package/dist/workspace-DAlhADfI.mjs +24 -0
  156. package/dist/{workspace-credentials-D_ivv5vy.mjs → workspace-credentials-U6bazYof.mjs} +1 -1
  157. package/package.json +1 -1
  158. package/dist/add-collection-Dwu5Rcn3.mjs +0 -11
  159. package/dist/auth-DHOpcw11.mjs +0 -19
  160. package/dist/card-D1JLv6cG.mjs +0 -20
  161. package/dist/collection-C2C4HUz_.mjs +0 -19
  162. package/dist/dashboard-BLr8iCSU.mjs +0 -20
  163. package/dist/db-CBCfAbIZ.mjs +0 -22
  164. package/dist/field-DbuCWbv9.mjs +0 -18
  165. package/dist/get-DpDiG-Kd.mjs +0 -37
  166. package/dist/is-dirty-ChP4hRvg.mjs +0 -10
  167. package/dist/measure-CDMN4H2K.mjs +0 -19
  168. package/dist/ps-R3DY2-cz.mjs +0 -10
  169. package/dist/segment-CYr8A0Qx.mjs +0 -19
  170. package/dist/snippet-CbNr7l5W.mjs +0 -19
  171. package/dist/sync-CHqSTijq.mjs +0 -28
  172. package/dist/table-BjX5aZ_b.mjs +0 -19
  173. package/dist/transform-hfQvOcAS.mjs +0 -24
  174. package/dist/transform-job-BtJZYt5N.mjs +0 -19
  175. package/dist/workspace-DvZtoFEM.mjs +0 -24
  176. /package/dist/{dashboard-CztCJxke.mjs → dashboard-DyrRSbqQ.mjs} +0 -0
  177. /package/dist/{field-BakUM_Le.mjs → field-D6CJbmAR.mjs} +0 -0
  178. /package/dist/{measure-B1GKcZxO.mjs → measure-jbc7fsCs.mjs} +0 -0
  179. /package/dist/{revision-message-flag-BJiGjb5m.mjs → revision-message-flag-D4E1lKE5.mjs} +0 -0
  180. /package/dist/{segment-CQ5w3M_W.mjs → segment-D0XmKSU2.mjs} +0 -0
  181. /package/dist/{setting-DIXJ2haa.mjs → setting-DH7Kgx94.mjs} +0 -0
  182. /package/dist/{snippet-DRTklDg3.mjs → snippet-CBTV07b-.mjs} +0 -0
  183. /package/dist/{transform-92odFxg-.mjs → transform-IEX4Mx3X.mjs} +0 -0
  184. /package/dist/{transform-job-DgApCViL.mjs → transform-job-DZ38Xc3k.mjs} +0 -0
  185. /package/dist/{workspace-D93cDL8-.mjs → workspace-jfsegcq8.mjs} +0 -0
package/README.md CHANGED
@@ -271,39 +271,42 @@ metabase transform-job delete 1 --yes
271
271
 
272
272
  ## Databases
273
273
 
274
- Read warehouse metadata from `/api/database`. The `db` group exposes the full database list, the per-database record, hydrated metadata (tables + fields rolled up in one response), schema and table inspection, and the two manual-sync triggers.
274
+ Read warehouse metadata from `/api/database`. The `db` group exposes the full database list, the per-database record, schema and table inspection, the two manual-sync triggers, and (rarely useful) full-warehouse rollup endpoints.
275
275
 
276
276
  `db` is aliased to `database`.
277
277
 
278
+ > **Agent traversal:** prefer the granular path — `db list` → `db schemas <db-id>` → `db schema-tables <db-id> <schema>` → `table get <table-id> --include fields`. On a real warehouse (dozens of schemas, hundreds of tables, dozens of fields per table) the rollup commands (`db metadata`, `db get --include tables.fields`, `db list --include tables`) return megabytes of JSON and exhaust the agent context. Reach for them only on small/dev warehouses where you know the size up front.
279
+
278
280
  ### `metabase db list`
279
281
 
280
282
  ```sh
281
283
  metabase db list
282
284
  metabase db list --json
283
- metabase db list --include tables --full --json
284
285
  metabase db list --saved --json
286
+ metabase db list --include tables --full --json # rollup: every db with its full table list
285
287
  ```
286
288
 
287
- | Flag | Description |
288
- | ------------------- | ------------------------------------------------------------------------------------------------------------- |
289
- | `--include <which>` | Hydrate related entities. Currently only `tables` is supported (each database is returned with its `tables`). |
290
- | `--saved` | Include the Saved Questions virtual database in the list. The virtual db has id `-1337` and no `engine`. |
289
+ | Flag | Description |
290
+ | ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
291
+ | `--include <which>` | Hydrate related entities. Currently only `tables` is supported (each database is returned with its `tables`). On real warehouses this returns hundreds of table records per db — use the granular traversal instead. |
292
+ | `--saved` | Include the Saved Questions virtual database in the list. The virtual db has id `-1337` and no `engine`. |
291
293
 
292
294
  ### `metabase db get <id>`
293
295
 
294
296
  ```sh
295
297
  metabase db get 1
296
298
  metabase db get 1 --json
297
- metabase db get 1 --include tables.fields --full --json
299
+ metabase db get 1 --include tables --full --json # rollup: db + every table (compact)
300
+ metabase db get 1 --include tables.fields --full --json # rollup: db + every table + every field
298
301
  ```
299
302
 
300
- | Flag | Description |
301
- | ------------------- | ------------------------------------------------------------- |
302
- | `--include <which>` | Hydrate related entities. One of `tables` or `tables.fields`. |
303
+ | Flag | Description |
304
+ | ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
305
+ | `--include <which>` | Hydrate related entities. One of `tables` or `tables.fields`. `tables.fields` returns every column of every table in the database in one response — only safe on small/dev warehouses. For a real warehouse use `db schemas` → `db schema-tables` → `table get --include fields`. |
303
306
 
304
307
  ### `metabase db metadata <id>`
305
308
 
306
- Equivalent to `GET /api/database/:id/metadata`: a single database with all its tables and fields rolled up in one response. Use this when an agent needs a one-shot warehouse introspection rather than the per-table `metabase table get --full`.
309
+ Equivalent to `GET /api/database/:id/metadata`: a single database with all its tables and fields rolled up in one response. This is the largest read in the `db` group — on a real warehouse the response will exceed the agent context. Use only when you know the database is small (a seeded dev instance, a sample db, a freshly-bootstrapped test fixture). For agent-driven introspection on a real warehouse, walk `db schemas` → `db schema-tables` `table get --include fields` instead.
307
310
 
308
311
  ```sh
309
312
  metabase db metadata 1 --json --full --max-bytes 0
@@ -311,7 +314,7 @@ metabase db metadata 1 --json --full --max-bytes 0
311
314
 
312
315
  ### `metabase db schemas <id>`
313
316
 
314
- List the schemas in a database. Schemas with no tables are excluded.
317
+ List the schemas in a database. Schemas with no tables are excluded. Cheap and bounded — this is the right entry point for an agent walking a warehouse.
315
318
 
316
319
  ```sh
317
320
  metabase db schemas 1
@@ -320,7 +323,7 @@ metabase db schemas 1 --json
320
323
 
321
324
  ### `metabase db schema-tables <id> <schema>`
322
325
 
323
- List the tables in a given schema, sorted by display name.
326
+ List the tables in one schema, sorted by display name. Returns compact projections without fields — pair with `table get --include fields` (or `table fields <id>`) per table you actually need to introspect.
324
327
 
325
328
  ```sh
326
329
  metabase db schema-tables 1 public
@@ -347,10 +350,12 @@ metabase db rescan-values 1 --json
347
350
 
348
351
  ## Tables
349
352
 
350
- Inspect and edit warehouse tables via `/api/table`.
353
+ Inspect and edit warehouse tables via `/api/table`. For agent-driven field introspection, `table get --include fields` is the default — it returns the table plus its columns in a single bounded response.
351
354
 
352
355
  ### `metabase table list`
353
356
 
357
+ Returns every table in the chosen database (or across all databases) as a flat compact list — no fields, no per-table hydration. On a real warehouse with hundreds of tables this is still bounded (kilobytes), but `db schema-tables <db-id> <schema>` is the better starting point when you know the schema.
358
+
354
359
  ```sh
355
360
  metabase table list
356
361
  metabase table list --db-id 1 --json
@@ -362,28 +367,33 @@ metabase table list --db-id 1 --json
362
367
 
363
368
  ### `metabase table get <id>`
364
369
 
365
- Returns the basic table record (no fields). Use `metabase table metadata <id>` when you want the rollup with fields/FKs/dimensions hydrated.
370
+ Returns the basic table record (no fields). Pass `--include fields` to route through `/api/table/:id/query_metadata` so the response carries the table's columns compact-projected as `fields` — this is the default agent path for field introspection. Use `metabase table fields <id>` if you only want the fields as a list envelope, or `metabase table metadata <id>` when you also need FKs and dimensions hydrated.
366
371
 
367
372
  ```sh
368
373
  metabase table get 42
369
374
  metabase table get 42 --json
375
+ metabase table get 42 --include fields --json
370
376
  ```
371
377
 
372
- ### `metabase table metadata <id>`
378
+ | Flag | Description |
379
+ | ------------------- | --------------------------------------------------------------------------------------------------- |
380
+ | `--include <which>` | Hydrate related entities. Currently only `fields` is supported (bundles compact-projected columns). |
373
381
 
374
- `GET /api/table/:id/query_metadata`: the table with its fields, FKs, and dimensions hydrated. The agent-facing one-shot introspection for a single table.
382
+ ### `metabase table fields <id>`
383
+
384
+ List the fields on a table (a thin projection over `query_metadata.fields`). Use this when you want just the field array without the surrounding table metadata.
375
385
 
376
386
  ```sh
377
- metabase table metadata 42 --json --full --max-bytes 0
387
+ metabase table fields 42
388
+ metabase table fields 42 --json
378
389
  ```
379
390
 
380
- ### `metabase table fields <id>`
391
+ ### `metabase table metadata <id>`
381
392
 
382
- List the fields on a table (a thin projection over `query_metadata.fields`).
393
+ `GET /api/table/:id/query_metadata`: the table with its fields, FKs, dimensions, segments, and measures all hydrated. Heavier than `table get --include fields` — reach for it only when you actually need the FK / dimension / segment / measure data.
383
394
 
384
395
  ```sh
385
- metabase table fields 42
386
- metabase table fields 42 --json
396
+ metabase table metadata 42 --json --full --max-bytes 0
387
397
  ```
388
398
 
389
399
  ### `metabase table update <id>`
@@ -1365,6 +1375,33 @@ Agent discovery path: `metabase __manifest` lists every command's args and descr
1365
1375
 
1366
1376
  The bundled query schema is synced from a pinned `@metabase/representations` release via `bun run sync:representations`; CI guards against drift.
1367
1377
 
1378
+ ### Card-reference pre-flight in `dashboard create` / `dashboard update`
1379
+
1380
+ Before either command sends anything, every positive `card_id` referenced from the body's `dashcards` array is checked against `GET /api/card/:id` in parallel (de-duplicated per id). Cards that don't exist, are archived, or aren't readable fail pre-flight: the CLI writes a `{ ok: false, errors: [{ path, message }] }` envelope to stdout (one entry per offending dashcard, `path` is a JSON pointer like `/dashcards/3/card_id`) and exits **2** with `dashboard card-reference pre-flight failed: N error(s) — fix the dashcard card_id values listed above` on stderr. No dashboard is created or modified on a pre-flight miss — this is the contract that prevents orphan dashboards when a stale spec references an archived or missing card.
1381
+
1382
+ There is no `--skip-validate` escape hatch here. The pre-flight queries live server state (no bundled schema to drift from), so the only legitimate path on a pre-flight miss is to fix the input.
1383
+
1384
+ If the chained `PUT /api/dashboard/:id` fails _after_ the create has already inserted the row (rare with pre-flight in place, but possible on a permission / 5xx / network failure mid-flight), the user-facing error is rewritten to `dashboard <id> created but follow-up PUT /api/dashboard/<id> failed: <reason>; dashcards not applied`, so the caller knows the orphan exists. Recovery: `dashboard update <id> --body '{"dashcards":[...]}'` to retry the dashcards, or `dashboard update <id> --body '{"archived":true}'` to archive the orphan.
1385
+
1386
+ ## UUIDs
1387
+
1388
+ ### `metabase uuid`
1389
+
1390
+ Mint UUID v4 strings (Node `crypto.randomUUID`) for MBQL clause `lib/uuid` slots, native template-tag ids, and any other Metabase-side identifier whose schema enforces RFC 4122 format. Agents must call this command to obtain UUIDs rather than authoring them by hand: the bundled MBQL 5 schema rejects placeholder strings (`a1`, `uuid-1`, etc.) at `format: "uuid"` validation.
1391
+
1392
+ ```sh
1393
+ metabase uuid # one UUID
1394
+ metabase uuid --count 5 # five UUIDs, one per line (text mode in a TTY, JSON when piped)
1395
+ metabase uuid --count 5 --json # explicit JSON: ["…", "…", "…", "…", "…"]
1396
+ metabase uuid --count 5 --format text # explicit text: one UUID per line
1397
+ ```
1398
+
1399
+ Output: text mode prints one UUID per line; JSON mode prints a `string[]`. Default behavior follows the standard `--format auto` rule — JSON when stdout is a pipe, text when it's a TTY.
1400
+
1401
+ `--count` accepts integers `1` through `10000`; outside that range exits 2 with a `ConfigError`.
1402
+
1403
+ Exit codes: `0` success, `2` invalid `--count`.
1404
+
1368
1405
  ## Environment variables
1369
1406
 
1370
1407
  | Variable | Effect |
@@ -0,0 +1,11 @@
1
+ import "./package-BPEXn1Of.mjs";
2
+ import "./command-augment-D9pI9Vbh.mjs";
3
+ import "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./runtime-Dwaw7sqU.mjs";
6
+ import "./parse-id-BqO2IY1b.mjs";
7
+ import "./poll-task-CXSagHdO.mjs";
8
+ import "./poll-DJWznjP9.mjs";
9
+ import { SyncSettingsUpdateResult, add_collection_default, setCollectionRemoteSynced, syncSettingsUpdateView } from "./add-collection-Cvh_24_Q.mjs";
10
+
11
+ export { add_collection_default as default };
@@ -1,7 +1,7 @@
1
- import { renderItem } from "./render-BYWlZPEH.mjs";
2
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
3
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
4
- import { REMOTE_SYNC_PATHS } from "./poll-task-DlcGug4o.mjs";
1
+ import { renderItem } from "./render-D8GOkk4P.mjs";
2
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
3
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
4
+ import { REMOTE_SYNC_PATHS } from "./poll-task-CXSagHdO.mjs";
5
5
  import { z } from "zod";
6
6
 
7
7
  //#region src/commands/sync/add-collection.ts
@@ -6,7 +6,7 @@ var api_key_default = defineCommand({
6
6
  name: "api-key",
7
7
  description: "Manage Metabase API keys"
8
8
  },
9
- subCommands: { create: () => import("./create-D52ykhxx.mjs").then((mod) => mod.default) }
9
+ subCommands: { create: () => import("./create-D5GQ3L7D.mjs").then((mod) => mod.default) }
10
10
  });
11
11
 
12
12
  //#endregion
@@ -1,11 +1,11 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
7
- import { Measure, measureView } from "./measure-B1GKcZxO.mjs";
8
- import { revisionMessageFlag } from "./revision-message-flag-BJiGjb5m.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
+ import { Measure, measureView } from "./measure-jbc7fsCs.mjs";
8
+ import { revisionMessageFlag } from "./revision-message-flag-D4E1lKE5.mjs";
9
9
 
10
10
  //#region src/commands/measure/archive.ts
11
11
  var archive_default = defineMetabaseCommand({
@@ -1,10 +1,10 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
7
- import { Snippet, snippetView } from "./snippet-DRTklDg3.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
+ import { Snippet, snippetView } from "./snippet-CBTV07b-.mjs";
8
8
 
9
9
  //#region src/commands/snippet/archive.ts
10
10
  var archive_default = defineMetabaseCommand({
@@ -1,9 +1,9 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
7
  import { Card, cardView } from "./card-BOGKT258.mjs";
8
8
 
9
9
  //#region src/commands/card/archive.ts
@@ -1,11 +1,11 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
7
- import { revisionMessageFlag } from "./revision-message-flag-BJiGjb5m.mjs";
8
- import { Segment, segmentView } from "./segment-CQ5w3M_W.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
+ import { revisionMessageFlag } from "./revision-message-flag-D4E1lKE5.mjs";
8
+ import { Segment, segmentView } from "./segment-D0XmKSU2.mjs";
9
9
 
10
10
  //#region src/commands/segment/archive.ts
11
11
  var archive_default = defineMetabaseCommand({
@@ -0,0 +1,19 @@
1
+ import { defineCommand } from "citty";
2
+
3
+ //#region src/commands/auth/index.ts
4
+ var auth_default = defineCommand({
5
+ meta: {
6
+ name: "auth",
7
+ description: "Authenticate against a Metabase instance"
8
+ },
9
+ default: "login",
10
+ subCommands: {
11
+ login: () => import("./login-D4a3b52m.mjs").then((m) => m.default),
12
+ status: () => import("./status-g9cjxsHd.mjs").then((m) => m.default),
13
+ list: () => import("./list-BsmGs2Wf.mjs").then((m) => m.default),
14
+ logout: () => import("./logout-BhO5sEm8.mjs").then((m) => m.default)
15
+ }
16
+ });
17
+
18
+ //#endregion
19
+ export { auth_default as default };
@@ -1,6 +1,6 @@
1
- import { ConfigError } from "./errors-C6w1eZ1F.mjs";
2
- import { readInput } from "./input-DMcm_A5s.mjs";
3
- import { parseJson } from "./runtime-BfWVLqFk.mjs";
1
+ import { ConfigError } from "./errors-DqPLKwoK.mjs";
2
+ import { readInput } from "./input-a1VFtFBh.mjs";
3
+ import { parseJson } from "./runtime-Dwaw7sqU.mjs";
4
4
 
5
5
  //#region src/runtime/body.ts
6
6
  async function readBody(sources, schema) {
@@ -1,10 +1,10 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderList } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, listEnvelopeSchema, outputFlags, profileFlag, wrapList } from "./runtime-BfWVLqFk.mjs";
6
- import { REMOTE_SYNC_PATHS } from "./poll-task-DlcGug4o.mjs";
7
- import "./poll-48PVbWIx.mjs";
3
+ import { renderList } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, listEnvelopeSchema, outputFlags, profileFlag, wrapList } from "./runtime-Dwaw7sqU.mjs";
6
+ import { REMOTE_SYNC_PATHS } from "./poll-task-CXSagHdO.mjs";
7
+ import "./poll-DJWznjP9.mjs";
8
8
  import { z } from "zod";
9
9
 
10
10
  //#region src/commands/sync/branches.ts
@@ -1,9 +1,9 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
7
  import { z } from "zod";
8
8
 
9
9
  //#region src/commands/transform/cancel.ts
@@ -1,10 +1,10 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
6
- import { REMOTE_SYNC_PATHS, SyncTask, syncTaskView } from "./poll-task-DlcGug4o.mjs";
7
- import "./poll-48PVbWIx.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
6
+ import { REMOTE_SYNC_PATHS, SyncTask, syncTaskView } from "./poll-task-CXSagHdO.mjs";
7
+ import "./poll-DJWznjP9.mjs";
8
8
 
9
9
  //#region src/commands/sync/cancel-task.ts
10
10
  var cancel_task_default = defineMetabaseCommand({
@@ -0,0 +1,20 @@
1
+ import { defineCommand } from "citty";
2
+
3
+ //#region src/commands/card/index.ts
4
+ var card_default = defineCommand({
5
+ meta: {
6
+ name: "card",
7
+ description: "Manage Metabase cards (questions, models, metrics)"
8
+ },
9
+ subCommands: {
10
+ list: () => import("./list-VIZSxtf3.mjs").then((mod) => mod.default),
11
+ get: () => import("./get-BD7Vyb-k.mjs").then((mod) => mod.default),
12
+ query: () => import("./query-q7b2hzrE.mjs").then((mod) => mod.default),
13
+ create: () => import("./create-oFRJZRJW.mjs").then((mod) => mod.default),
14
+ update: () => import("./update-fRqtvI5G.mjs").then((mod) => mod.default),
15
+ archive: () => import("./archive-O0WoU8LU.mjs").then((mod) => mod.default)
16
+ }
17
+ });
18
+
19
+ //#endregion
20
+ export { card_default as default };
@@ -1,10 +1,10 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderList } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import { connectionFlags, defineMetabaseCommand, listEnvelopeSchema, outputFlags, profileFlag, wrapList } from "./runtime-BfWVLqFk.mjs";
6
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
7
- import { DashboardDetail, DashcardCompact, dashcardView } from "./dashboard-CztCJxke.mjs";
3
+ import { renderList } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import { connectionFlags, defineMetabaseCommand, listEnvelopeSchema, outputFlags, profileFlag, wrapList } from "./runtime-Dwaw7sqU.mjs";
6
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
7
+ import { DashboardDetail, DashcardCompact, dashcardView } from "./dashboard-DyrRSbqQ.mjs";
8
8
 
9
9
  //#region src/commands/dashboard/cards.ts
10
10
  const DashcardListEnvelope = listEnvelopeSchema(DashcardCompact);
package/dist/cli.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { package_default } from "./package-CtkDnX1U.mjs";
2
+ import { package_default } from "./package-BPEXn1Of.mjs";
3
3
  import { getMetabaseAugment } from "./command-augment-D9pI9Vbh.mjs";
4
4
  import { defineCommand, renderUsage, runMain } from "citty";
5
5
 
@@ -11,28 +11,29 @@ const main = defineCommand({
11
11
  description: package_default.description
12
12
  },
13
13
  subCommands: {
14
- auth: () => import("./auth-DHOpcw11.mjs").then((mod) => mod.default),
15
- license: () => import("./license-CHccrjDp.mjs").then((mod) => mod.default),
16
- db: () => import("./db-CBCfAbIZ.mjs").then((mod) => mod.default),
17
- table: () => import("./table-BjX5aZ_b.mjs").then((mod) => mod.default),
18
- field: () => import("./field-DbuCWbv9.mjs").then((mod) => mod.default),
19
- card: () => import("./card-D1JLv6cG.mjs").then((mod) => mod.default),
20
- dashboard: () => import("./dashboard-BLr8iCSU.mjs").then((mod) => mod.default),
21
- collection: () => import("./collection-C2C4HUz_.mjs").then((mod) => mod.default),
22
- transform: () => import("./transform-hfQvOcAS.mjs").then((mod) => mod.default),
23
- "transform-job": () => import("./transform-job-BtJZYt5N.mjs").then((mod) => mod.default),
24
- setting: () => import("./setting-BDbBiriX.mjs").then((mod) => mod.default),
25
- search: () => import("./search-BU6MBJkj.mjs").then((mod) => mod.default),
26
- sync: () => import("./sync-CHqSTijq.mjs").then((mod) => mod.default),
27
- workspace: () => import("./workspace-DvZtoFEM.mjs").then((mod) => mod.default),
28
- setup: () => import("./setup-DfWKuwgQ.mjs").then((mod) => mod.default),
29
- "api-key": () => import("./api-key-BqZV1nLg.mjs").then((mod) => mod.default),
30
- snippet: () => import("./snippet-CbNr7l5W.mjs").then((mod) => mod.default),
31
- segment: () => import("./segment-CYr8A0Qx.mjs").then((mod) => mod.default),
32
- measure: () => import("./measure-CDMN4H2K.mjs").then((mod) => mod.default),
33
- eid: () => import("./eid-AISoTK5d.mjs").then((mod) => mod.default),
34
- query: () => import("./query-BoIeOotH.mjs").then((mod) => mod.default),
35
- __manifest: () => import("./manifest-CdAV6-YB.mjs").then((mod) => mod.createManifestCommand(main))
14
+ auth: () => import("./auth-DCoGwYKi.mjs").then((mod) => mod.default),
15
+ license: () => import("./license-2t70RAE_.mjs").then((mod) => mod.default),
16
+ db: () => import("./db-2G-o2xtr.mjs").then((mod) => mod.default),
17
+ table: () => import("./table-CpsE5VUF.mjs").then((mod) => mod.default),
18
+ field: () => import("./field-CzZEYFp6.mjs").then((mod) => mod.default),
19
+ card: () => import("./card-CtK41cpb.mjs").then((mod) => mod.default),
20
+ dashboard: () => import("./dashboard-GeAXKl0W.mjs").then((mod) => mod.default),
21
+ collection: () => import("./collection-CWYozp35.mjs").then((mod) => mod.default),
22
+ transform: () => import("./transform-CUxV3WSi.mjs").then((mod) => mod.default),
23
+ "transform-job": () => import("./transform-job-Dry0r1Xz.mjs").then((mod) => mod.default),
24
+ setting: () => import("./setting-DWoyNzLC.mjs").then((mod) => mod.default),
25
+ search: () => import("./search-CKie8hjZ.mjs").then((mod) => mod.default),
26
+ sync: () => import("./sync-CcYMBXTo.mjs").then((mod) => mod.default),
27
+ workspace: () => import("./workspace-DAlhADfI.mjs").then((mod) => mod.default),
28
+ setup: () => import("./setup-Cn54kGu2.mjs").then((mod) => mod.default),
29
+ "api-key": () => import("./api-key-d2kBtC3S.mjs").then((mod) => mod.default),
30
+ snippet: () => import("./snippet-TOO4F2a8.mjs").then((mod) => mod.default),
31
+ segment: () => import("./segment-C66MvGDy.mjs").then((mod) => mod.default),
32
+ measure: () => import("./measure-Bagaha3J.mjs").then((mod) => mod.default),
33
+ eid: () => import("./eid-CANLCfwr.mjs").then((mod) => mod.default),
34
+ query: () => import("./query-DR0R8J_B.mjs").then((mod) => mod.default),
35
+ uuid: () => import("./uuid-D9rbiLTK.mjs").then((mod) => mod.default),
36
+ __manifest: () => import("./manifest-DalRNBAy.mjs").then((mod) => mod.createManifestCommand(main))
36
37
  }
37
38
  });
38
39
  var main_default = main;
@@ -0,0 +1,19 @@
1
+ import { defineCommand } from "citty";
2
+
3
+ //#region src/commands/collection/index.ts
4
+ var collection_default = defineCommand({
5
+ meta: {
6
+ name: "collection",
7
+ description: "Browse Metabase collections"
8
+ },
9
+ subCommands: {
10
+ list: () => import("./list-ehmXcC-t.mjs").then((mod) => mod.default),
11
+ get: () => import("./get-Dxyz8B08.mjs").then((mod) => mod.default),
12
+ items: () => import("./items-ZP8yJJTA.mjs").then((mod) => mod.default),
13
+ tree: () => import("./tree-DZNnXYjb.mjs").then((mod) => mod.default),
14
+ create: () => import("./create-lYoy27zG.mjs").then((mod) => mod.default)
15
+ }
16
+ });
17
+
18
+ //#endregion
19
+ export { collection_default as default };
@@ -104,10 +104,10 @@ const CollectionItem = z.object({
104
104
  model: CollectionItemModel,
105
105
  name: z.string(),
106
106
  description: z.string().nullable().optional(),
107
- archived: z.boolean(),
107
+ archived: z.boolean().nullable(),
108
108
  collection_id: CollectionId.nullable().optional(),
109
109
  collection_position: z.number().int().nullable().optional(),
110
- display: z.string().optional(),
110
+ display: z.string().nullable().optional(),
111
111
  location: z.string().nullable().optional(),
112
112
  entity_id: z.string().nullable().optional(),
113
113
  database_id: z.number().int().nullable().optional(),
@@ -1,12 +1,12 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import "./input-DMcm_A5s.mjs";
6
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
7
- import { readBody } from "./body-D_BRIb1g.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./input-a1VFtFBh.mjs";
6
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
7
+ import { readBody } from "./body-C2lo4Axp.mjs";
8
8
  import { bodyInputFlags } from "./body-flags-BK7J6Daz.mjs";
9
- import { Workspace, WorkspaceCreateInput, workspaceView } from "./workspace-D93cDL8-.mjs";
9
+ import { Workspace, WorkspaceCreateInput, workspaceView } from "./workspace-jfsegcq8.mjs";
10
10
 
11
11
  //#region src/commands/workspace/create.ts
12
12
  var create_default = defineMetabaseCommand({
@@ -1,12 +1,12 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import "./input-DMcm_A5s.mjs";
6
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
7
- import { readBody } from "./body-D_BRIb1g.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./input-a1VFtFBh.mjs";
6
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
7
+ import { readBody } from "./body-C2lo4Axp.mjs";
8
8
  import { bodyInputFlags } from "./body-flags-BK7J6Daz.mjs";
9
- import { TransformJob, TransformJobCreateInput, transformJobView } from "./transform-job-DgApCViL.mjs";
9
+ import { TransformJob, TransformJobCreateInput, transformJobView } from "./transform-job-DZ38Xc3k.mjs";
10
10
 
11
11
  //#region src/commands/transform-job/create.ts
12
12
  var create_default = defineMetabaseCommand({
@@ -1,13 +1,13 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import "./input-DMcm_A5s.mjs";
6
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
7
- import { readBody } from "./body-D_BRIb1g.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./input-a1VFtFBh.mjs";
6
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
7
+ import { readBody } from "./body-C2lo4Axp.mjs";
8
8
  import { bodyInputFlags } from "./body-flags-BK7J6Daz.mjs";
9
- import { requireBothOrNeither } from "./flag-pair-Dz-mbq0z.mjs";
10
- import { parseId } from "./parse-id-jvzdqaO1.mjs";
9
+ import { requireBothOrNeither } from "./flag-pair-Byca1x-Q.mjs";
10
+ import { parseId } from "./parse-id-BqO2IY1b.mjs";
11
11
  import { z } from "zod";
12
12
 
13
13
  //#region src/domain/api-key.ts
@@ -1,12 +1,12 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import "./input-DMcm_A5s.mjs";
6
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
7
- import { readBody } from "./body-D_BRIb1g.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./input-a1VFtFBh.mjs";
6
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
7
+ import { readBody } from "./body-C2lo4Axp.mjs";
8
8
  import { bodyInputFlags } from "./body-flags-BK7J6Daz.mjs";
9
- import { Measure, MeasureCreateInput, measureView } from "./measure-B1GKcZxO.mjs";
9
+ import { Measure, MeasureCreateInput, measureView } from "./measure-jbc7fsCs.mjs";
10
10
 
11
11
  //#region src/commands/measure/create.ts
12
12
  var create_default = defineMetabaseCommand({
@@ -1,12 +1,12 @@
1
- import "./package-CtkDnX1U.mjs";
1
+ import "./package-BPEXn1Of.mjs";
2
2
  import "./command-augment-D9pI9Vbh.mjs";
3
- import { renderItem } from "./render-BYWlZPEH.mjs";
4
- import "./errors-C6w1eZ1F.mjs";
5
- import "./input-DMcm_A5s.mjs";
6
- import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-BfWVLqFk.mjs";
7
- import { readBody } from "./body-D_BRIb1g.mjs";
3
+ import { renderItem } from "./render-D8GOkk4P.mjs";
4
+ import "./errors-DqPLKwoK.mjs";
5
+ import "./input-a1VFtFBh.mjs";
6
+ import { connectionFlags, defineMetabaseCommand, outputFlags, profileFlag } from "./runtime-Dwaw7sqU.mjs";
7
+ import { readBody } from "./body-C2lo4Axp.mjs";
8
8
  import { bodyInputFlags } from "./body-flags-BK7J6Daz.mjs";
9
- import { Snippet, SnippetCreateInput, snippetView } from "./snippet-DRTklDg3.mjs";
9
+ import { Snippet, SnippetCreateInput, snippetView } from "./snippet-CBTV07b-.mjs";
10
10
 
11
11
  //#region src/commands/snippet/create.ts
12
12
  var create_default = defineMetabaseCommand({