@keboola/api-client 36.0.0 → 40.0.0
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.
- package/AGENTS.md +133 -103
- package/API-SURFACE.md +36 -2
- package/CHANGELOG.md +194 -0
- package/README.md +22 -20
- package/dist/{ManagementClientAuthError-DD4u0EU7.cjs → ManagementClientAuthError-DE7lNGZQ.cjs} +3 -2
- package/dist/{ManagementClientAuthError-DD4u0EU7.cjs.map → ManagementClientAuthError-DE7lNGZQ.cjs.map} +1 -1
- package/dist/{ManagementClientAuthError-ey-f03vy.js → ManagementClientAuthError-H30lti_Q.js} +3 -2
- package/dist/{ManagementClientAuthError-ey-f03vy.js.map → ManagementClientAuthError-H30lti_Q.js.map} +1 -1
- package/dist/{ValidationError-CLVJCCwH.cjs → ValidationError-D65QU0uq.cjs} +10 -16
- package/dist/ValidationError-D65QU0uq.cjs.map +1 -0
- package/dist/ValidationError-DjhtNMfZ.js +42 -0
- package/dist/ValidationError-DjhtNMfZ.js.map +1 -0
- package/dist/ai/index.cjs +2 -2
- package/dist/ai/index.d.cts +2 -2
- package/dist/ai/index.d.ts +2 -2
- package/dist/ai/index.js +2 -2
- package/dist/ai/types.d.cts +1 -1
- package/dist/ai/types.d.ts +1 -1
- package/dist/{appLogs-BjfUoWzs.cjs → appLogs-B9zFJIuy.cjs} +2 -2
- package/dist/{appLogs-BjfUoWzs.cjs.map → appLogs-B9zFJIuy.cjs.map} +1 -1
- package/dist/{appLogs-xsVkTriU.js → appLogs-BBkkUOW1.js} +2 -2
- package/dist/{appLogs-xsVkTriU.js.map → appLogs-BBkkUOW1.js.map} +1 -1
- package/dist/{appLogs-Ch7DYpzx.d.ts → appLogs-BS6ViVGR.d.ts} +2 -2
- package/dist/{appLogs-D5A13Y0y.d.cts → appLogs-C9YlJ2g8.d.cts} +2 -2
- package/dist/apps/index.cjs +30 -56
- package/dist/apps/index.cjs.map +1 -1
- package/dist/apps/index.d.cts +8 -13
- package/dist/apps/index.d.ts +8 -13
- package/dist/apps/index.js +30 -56
- package/dist/apps/index.js.map +1 -1
- package/dist/apps/types.d.cts +2 -2
- package/dist/apps/types.d.ts +2 -2
- package/dist/assets/index.cjs +1 -1
- package/dist/assets/index.d.cts +1 -1
- package/dist/assets/index.d.ts +1 -1
- package/dist/assets/index.js +1 -1
- package/dist/auth/index.cjs +8 -4
- package/dist/auth/index.d.cts +2 -2
- package/dist/auth/index.d.ts +2 -2
- package/dist/auth/index.js +2 -2
- package/dist/auth/types.d.cts +2 -2
- package/dist/auth/types.d.ts +2 -2
- package/dist/{auth-JQ33o3nU.cjs → auth-Dm0F2rOh.cjs} +2 -2
- package/dist/{auth-JQ33o3nU.cjs.map → auth-Dm0F2rOh.cjs.map} +1 -1
- package/dist/{auth-aItmDu45.js → auth-DworfoPy.js} +2 -2
- package/dist/{auth-aItmDu45.js.map → auth-DworfoPy.js.map} +1 -1
- package/dist/{authClient-_PpvGgZJ.cjs → authClient-BmuUo0J4.cjs} +141 -48
- package/dist/authClient-BmuUo0J4.cjs.map +1 -0
- package/dist/{authClient-D8i3JTM-.d.ts → authClient-CHXWJ9x3.d.ts} +109 -76
- package/dist/{authClient-D7W9vWPR.js → authClient-CgcDGd30.js} +108 -39
- package/dist/authClient-CgcDGd30.js.map +1 -0
- package/dist/{authClient-CTHNs6Tq.d.cts → authClient-vEt_7_uk.d.cts} +109 -76
- package/dist/billing/index.cjs +2 -2
- package/dist/billing/index.d.cts +1 -1
- package/dist/billing/index.d.ts +1 -1
- package/dist/billing/index.js +2 -2
- package/dist/billing/types.d.cts +1 -1
- package/dist/billing/types.d.ts +1 -1
- package/dist/businessWorkspaceApi/index.cjs +3 -0
- package/dist/businessWorkspaceApi/index.d.cts +2 -0
- package/dist/businessWorkspaceApi/index.d.ts +2 -0
- package/dist/businessWorkspaceApi/index.js +2 -0
- package/dist/businessWorkspaceApi/types.cjs +0 -0
- package/dist/businessWorkspaceApi/types.d.cts +2 -0
- package/dist/businessWorkspaceApi/types.d.ts +2 -0
- package/dist/businessWorkspaceApi/types.js +1 -0
- package/dist/businessWorkspaceApi-6tCDdpnY.cjs +66 -0
- package/dist/businessWorkspaceApi-6tCDdpnY.cjs.map +1 -0
- package/dist/businessWorkspaceApi-BLUdefRF.js +61 -0
- package/dist/businessWorkspaceApi-BLUdefRF.js.map +1 -0
- package/dist/businessWorkspaceApiClient-BHDJlHFo.d.cts +529 -0
- package/dist/businessWorkspaceApiClient-DI-z1VIH.d.ts +529 -0
- package/dist/chat/index.cjs +9 -5
- package/dist/chat/index.cjs.map +1 -1
- package/dist/chat/index.d.cts +3 -3
- package/dist/chat/index.d.ts +3 -3
- package/dist/chat/index.js +9 -5
- package/dist/chat/index.js.map +1 -1
- package/dist/chat/types.cjs +1 -3
- package/dist/chat/types.cjs.map +1 -1
- package/dist/chat/types.d.cts +2 -2
- package/dist/chat/types.d.ts +2 -2
- package/dist/chat/types.js +1 -3
- package/dist/chat/types.js.map +1 -1
- package/dist/{componentId-DkyQ8PM0.cjs → componentId-57vjsa2i.cjs} +4 -2
- package/dist/{componentId-DkyQ8PM0.cjs.map → componentId-57vjsa2i.cjs.map} +1 -1
- package/dist/{componentId-vJz-kWs6.js → componentId-C6WZa_R1.js} +4 -2
- package/dist/{componentId-vJz-kWs6.js.map → componentId-C6WZa_R1.js.map} +1 -1
- package/dist/{concurrent-CH9fbNr3.js → concurrent-BacWxPwi.js} +5 -7
- package/dist/concurrent-BacWxPwi.js.map +1 -0
- package/dist/{concurrent-tbiIa0UL.cjs → concurrent-CdVfR1N5.cjs} +5 -7
- package/dist/concurrent-CdVfR1N5.cjs.map +1 -0
- package/dist/{configurations-VtNE0nrT.js → configurations-BPKGGy-M.js} +14 -22
- package/dist/configurations-BPKGGy-M.js.map +1 -0
- package/dist/{configurations-CyFF9Dtu.cjs → configurations-BTRHVSRq.cjs} +20 -53
- package/dist/configurations-BTRHVSRq.cjs.map +1 -0
- package/dist/{configurations-BVvcimzo.js → configurations-Chg_JwJ1.js} +20 -53
- package/dist/configurations-Chg_JwJ1.js.map +1 -0
- package/dist/{configurations-zkNjr73Q.cjs → configurations-IYyOvhI3.cjs} +14 -22
- package/dist/configurations-IYyOvhI3.cjs.map +1 -0
- package/dist/constants/index.cjs +2 -2
- package/dist/constants/index.d.cts +2 -2
- package/dist/constants/index.d.ts +2 -2
- package/dist/constants/index.js +2 -2
- package/dist/{constants-wfbFsqqN.js → constants-C2tYAJSj.js} +10 -1
- package/dist/constants-C2tYAJSj.js.map +1 -0
- package/dist/{constants-C4DlsF_M.cjs → constants-C6xku_Vx.cjs} +10 -1
- package/dist/constants-C6xku_Vx.cjs.map +1 -0
- package/dist/{createFetchClient-DgMiqTJ8.cjs → createFetchClient-Cwp8max9.cjs} +24 -5
- package/dist/createFetchClient-Cwp8max9.cjs.map +1 -0
- package/dist/{createFetchClient-U-ZrwPl2.js → createFetchClient-DXHQK63w.js} +24 -5
- package/dist/createFetchClient-DXHQK63w.js.map +1 -0
- package/dist/{createGenericFetchClient-rxvUUbap.js → createGenericFetchClient-Dg1rgzmG.js} +2 -2
- package/dist/{createGenericFetchClient-rxvUUbap.js.map → createGenericFetchClient-Dg1rgzmG.js.map} +1 -1
- package/dist/{createGenericFetchClient-o3cPJeRn.cjs → createGenericFetchClient-Dl9cqTvR.cjs} +2 -2
- package/dist/{createGenericFetchClient-o3cPJeRn.cjs.map → createGenericFetchClient-Dl9cqTvR.cjs.map} +1 -1
- package/dist/{createOpenapiFetchClient-DhUU3M1W.cjs → createOpenapiFetchClient-BYqW-9tm.cjs} +2 -2
- package/dist/{createOpenapiFetchClient-DhUU3M1W.cjs.map → createOpenapiFetchClient-BYqW-9tm.cjs.map} +1 -1
- package/dist/{createOpenapiFetchClient-BVSc9ibR.js → createOpenapiFetchClient-DZUOVupy.js} +2 -2
- package/dist/{createOpenapiFetchClient-BVSc9ibR.js.map → createOpenapiFetchClient-DZUOVupy.js.map} +1 -1
- package/dist/dataScience/index.cjs +2 -2
- package/dist/dataScience/index.d.cts +2 -2
- package/dist/dataScience/index.d.ts +2 -2
- package/dist/dataScience/index.js +2 -2
- package/dist/dataScience/types.d.cts +2 -2
- package/dist/dataScience/types.d.ts +2 -2
- package/dist/{dataScience-0Rl_EuV_.cjs → dataScience-B5QxZnvW.cjs} +5 -5
- package/dist/{dataScience-0Rl_EuV_.cjs.map → dataScience-B5QxZnvW.cjs.map} +1 -1
- package/dist/{dataScience-C1gO5zUn.js → dataScience-OXcwdk1p.js} +5 -5
- package/dist/{dataScience-C1gO5zUn.js.map → dataScience-OXcwdk1p.js.map} +1 -1
- package/dist/dedupe-Cky1gSUu.js +21 -0
- package/dist/dedupe-Cky1gSUu.js.map +1 -0
- package/dist/dedupe-OSnnst2u.cjs +26 -0
- package/dist/dedupe-OSnnst2u.cjs.map +1 -0
- package/dist/developerPortal/index.cjs +1 -1
- package/dist/developerPortal/index.d.cts +2 -2
- package/dist/developerPortal/index.d.ts +2 -2
- package/dist/developerPortal/index.js +1 -1
- package/dist/developerPortal/types.d.cts +1 -1
- package/dist/developerPortal/types.d.ts +1 -1
- package/dist/{developerPortalClient-C_48z8BN.js → developerPortalClient-B1QZ1rYi.js} +6 -8
- package/dist/{developerPortalClient-C_48z8BN.js.map → developerPortalClient-B1QZ1rYi.js.map} +1 -1
- package/dist/{developerPortalClient-ki0XS_OD.cjs → developerPortalClient-CLPpBksD.cjs} +6 -8
- package/dist/{developerPortalClient-ki0XS_OD.cjs.map → developerPortalClient-CLPpBksD.cjs.map} +1 -1
- package/dist/domain/permissions/index.cjs +9 -30
- package/dist/domain/permissions/index.cjs.map +1 -1
- package/dist/domain/permissions/index.d.cts +29 -102
- package/dist/domain/permissions/index.d.ts +29 -102
- package/dist/domain/permissions/index.js +9 -30
- package/dist/domain/permissions/index.js.map +1 -1
- package/dist/domain/storageTable/index.d.cts +1 -1
- package/dist/domain/storageTable/index.d.ts +1 -1
- package/dist/editor/index.cjs +2 -2
- package/dist/editor/index.cjs.map +1 -1
- package/dist/editor/index.d.cts +2 -2
- package/dist/editor/index.d.ts +2 -2
- package/dist/editor/index.js +2 -2
- package/dist/editor/index.js.map +1 -1
- package/dist/editor/types.d.cts +1 -1
- package/dist/editor/types.d.ts +1 -1
- package/dist/encryption/index.cjs +2 -22
- package/dist/encryption/index.cjs.map +1 -1
- package/dist/encryption/index.d.cts +1 -1
- package/dist/encryption/index.d.ts +1 -1
- package/dist/encryption/index.js +2 -22
- package/dist/encryption/index.js.map +1 -1
- package/dist/encryption/types.d.cts +1 -1
- package/dist/encryption/types.d.ts +1 -1
- package/dist/import/index.cjs +1 -1
- package/dist/import/index.d.cts +3 -3
- package/dist/import/index.d.ts +3 -3
- package/dist/import/index.js +1 -1
- package/dist/{import-C83w7BKz.cjs → import-CNk89mqy.cjs} +3 -3
- package/dist/{import-C83w7BKz.cjs.map → import-CNk89mqy.cjs.map} +1 -1
- package/dist/{import-CROEK82b.js → import-DiMQCzLa.js} +3 -3
- package/dist/{import-CROEK82b.js.map → import-DiMQCzLa.js.map} +1 -1
- package/dist/{index-DR4QqItd.d.cts → index--ZpnE3YT.d.cts} +3 -3
- package/dist/{index-C77vTm2K.d.ts → index-BDZvaRud.d.ts} +6 -6
- package/dist/{index-KuQ79Mnz.d.ts → index-BVhHt5lx.d.cts} +18 -26
- package/dist/{index-NC1dXRTD.d.ts → index-BfqkgPGI.d.cts} +7 -13
- package/dist/{index-NC1dXRTD.d.cts → index-BfqkgPGI.d.ts} +7 -13
- package/dist/{index-V7XKUQm9.d.cts → index-BgR5zcjJ.d.ts} +18 -26
- package/dist/{index-2JM0gyAf.d.ts → index-BkqackZf.d.ts} +439 -289
- package/dist/{index-BDG-LKXj.d.cts → index-ByRpNVcs.d.cts} +88 -18
- package/dist/{index-pXN4LWUX.d.ts → index-C11JSxBY.d.ts} +8 -11
- package/dist/{index-GjcJTCbz.d.cts → index-C4TNAA8-.d.cts} +8 -11
- package/dist/{index-NaYLwG_h.d.cts → index-C8gRRWHL.d.cts} +11 -1
- package/dist/{index-NaYLwG_h.d.ts → index-C8gRRWHL.d.ts} +11 -1
- package/dist/{index-3LUk2rpD.d.ts → index-CPu4Nezo.d.cts} +34 -9
- package/dist/{index-BMqLPS6S.d.ts → index-CXcWpZQ2.d.cts} +4 -12
- package/dist/{index-BMqLPS6S.d.cts → index-CXcWpZQ2.d.ts} +4 -12
- package/dist/{index-Dx52hNLP.d.cts → index-CcMHJcuP.d.cts} +3 -3
- package/dist/{index-BgLnWTZU.d.cts → index-Cvbjp3jx.d.cts} +6 -6
- package/dist/{index-DppA4k3b.d.cts → index-Cz0MXhzs.d.cts} +5 -5
- package/dist/{index-6Xe81qN3.d.ts → index-D-VMgpGc.d.ts} +5 -5
- package/dist/{index-D8rcUbnk.d.ts → index-D7-o-oGa.d.ts} +3 -3
- package/dist/{index-BXF-bs2d.d.ts → index-DCRKjihs.d.ts} +88 -18
- package/dist/{kaiAgentClient-DhTaM3GC.d.cts → index-DNThyEej.d.cts} +19 -5
- package/dist/{index-DXSmFkol.d.cts → index-DOAZmWvh.d.cts} +6 -6
- package/dist/{index-DIAyi-EZ.d.cts → index-DXYASsPP.d.cts} +439 -289
- package/dist/{index-BuegqrS1.d.ts → index-D_-4uQF8.d.ts} +3 -3
- package/dist/{index-CW3Pj7DY.d.cts → index-Dazy-meb.d.ts} +34 -9
- package/dist/{index-CqgtL2NU.d.ts → index-DnQTuc6t.d.ts} +6 -6
- package/dist/{kaiAgentClient-BJj_2aqt.d.ts → index-Qb7X6-ph.d.ts} +19 -5
- package/dist/index.cjs +1503 -895
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +1501 -896
- package/dist/index.js.map +1 -1
- package/dist/isLoginPageRedirect-XPwAOKK3.js +14 -0
- package/dist/isLoginPageRedirect-XPwAOKK3.js.map +1 -0
- package/dist/isLoginPageRedirect-jQHiLrG7.cjs +19 -0
- package/dist/isLoginPageRedirect-jQHiLrG7.cjs.map +1 -0
- package/dist/{jobStatus-0_Y3Sr4i.cjs → jobStatus-BMlsyXWI.cjs} +19 -45
- package/dist/jobStatus-BMlsyXWI.cjs.map +1 -0
- package/dist/{jobStatus-PSZJMTiA.js → jobStatus-CfRtsIpv.js} +19 -45
- package/dist/jobStatus-CfRtsIpv.js.map +1 -0
- package/dist/kaiAgent/index.cjs +1 -1
- package/dist/kaiAgent/index.d.cts +3 -2
- package/dist/kaiAgent/index.d.ts +3 -2
- package/dist/kaiAgent/index.js +1 -1
- package/dist/kaiAgent/types.d.cts +2 -2
- package/dist/kaiAgent/types.d.ts +2 -2
- package/dist/{kaiAgent-8LNzGhZc.js → kaiAgent-Dp20HLTh.js} +63 -7
- package/dist/kaiAgent-Dp20HLTh.js.map +1 -0
- package/dist/{kaiAgent-B_TaUPRt.cjs → kaiAgent-QNoeVKPs.cjs} +63 -7
- package/dist/kaiAgent-QNoeVKPs.cjs.map +1 -0
- package/dist/kaiMemory-CClSPInt.cjs +289 -0
- package/dist/kaiMemory-CClSPInt.cjs.map +1 -0
- package/dist/kaiMemory-D0Y_16U4.js +260 -0
- package/dist/kaiMemory-D0Y_16U4.js.map +1 -0
- package/dist/management/index.cjs +1 -1
- package/dist/management/index.d.cts +2 -2
- package/dist/management/index.d.ts +2 -2
- package/dist/management/index.js +1 -1
- package/dist/management/types.d.cts +2 -2
- package/dist/management/types.d.ts +2 -2
- package/dist/{management-BoxlRNg2.cjs → management-CCY0IYnq.cjs} +93 -25
- package/dist/management-CCY0IYnq.cjs.map +1 -0
- package/dist/{management-Bp440RsV.js → management-DvmPiG64.js} +93 -25
- package/dist/management-DvmPiG64.js.map +1 -0
- package/dist/metastore/index.cjs +1 -1
- package/dist/metastore/index.d.cts +1 -1
- package/dist/metastore/index.d.ts +1 -1
- package/dist/metastore/index.js +1 -1
- package/dist/metastore/types.d.cts +2 -2
- package/dist/metastore/types.d.ts +2 -2
- package/dist/{metastore-VCDRVhUT.js → metastore-BycJxe7A.js} +14 -8
- package/dist/metastore-BycJxe7A.js.map +1 -0
- package/dist/{metastore-BYYWTb3m.cjs → metastore-XtWciCZT.cjs} +14 -8
- package/dist/metastore-XtWciCZT.cjs.map +1 -0
- package/dist/microsoftGraph/index.cjs +2 -2
- package/dist/microsoftGraph/index.d.cts +2 -2
- package/dist/microsoftGraph/index.d.ts +2 -2
- package/dist/microsoftGraph/index.js +2 -2
- package/dist/microsoftGraph/types.d.cts +1 -1
- package/dist/microsoftGraph/types.d.ts +1 -1
- package/dist/middleware-CBwrtgQd.js +34 -0
- package/dist/middleware-CBwrtgQd.js.map +1 -0
- package/dist/middleware-IjYx3d5u.cjs +45 -0
- package/dist/middleware-IjYx3d5u.cjs.map +1 -0
- package/dist/notifications/index.cjs +4 -4
- package/dist/notifications/index.d.cts +2 -2
- package/dist/notifications/index.d.ts +2 -2
- package/dist/notifications/index.js +4 -4
- package/dist/notifications/types.d.cts +1 -1
- package/dist/notifications/types.d.ts +1 -1
- package/dist/oauth/index.cjs +1 -1
- package/dist/oauth/index.d.cts +2 -2
- package/dist/oauth/index.d.ts +2 -2
- package/dist/oauth/index.js +1 -1
- package/dist/oauth/types.d.cts +1 -1
- package/dist/oauth/types.d.ts +1 -1
- package/dist/{oauth-B8yqG6Sy.cjs → oauth--2p8jkJf.cjs} +5 -5
- package/dist/{oauth-B8yqG6Sy.cjs.map → oauth--2p8jkJf.cjs.map} +1 -1
- package/dist/{oauth--asfePw-.js → oauth-l5zE39cD.js} +5 -5
- package/dist/{oauth--asfePw-.js.map → oauth-l5zE39cD.js.map} +1 -1
- package/dist/omnisearch/index.cjs +6 -14
- package/dist/omnisearch/index.cjs.map +1 -1
- package/dist/omnisearch/index.d.cts +6 -14
- package/dist/omnisearch/index.d.ts +6 -14
- package/dist/omnisearch/index.js +6 -14
- package/dist/omnisearch/index.js.map +1 -1
- package/dist/omnisearch/types.d.cts +1 -1
- package/dist/omnisearch/types.d.ts +1 -1
- package/dist/{project-C2wvX0xZ.d.ts → project-B15gStbM.d.ts} +2 -2
- package/dist/{project-hePfzUY0.d.cts → project-cHKuGvqJ.d.cts} +2 -2
- package/dist/queryService/index.cjs +1 -1
- package/dist/queryService/index.d.cts +1 -1
- package/dist/queryService/index.d.ts +1 -1
- package/dist/queryService/index.js +1 -1
- package/dist/queryService/types.d.cts +1 -1
- package/dist/queryService/types.d.ts +1 -1
- package/dist/{queryService-Ca65E5KH.js → queryService-CCOYbRbw.js} +6 -6
- package/dist/{queryService-Ca65E5KH.js.map → queryService-CCOYbRbw.js.map} +1 -1
- package/dist/{queryService-BVtjkXy1.cjs → queryService-CQzclHdL.cjs} +6 -6
- package/dist/{queryService-BVtjkXy1.cjs.map → queryService-CQzclHdL.cjs.map} +1 -1
- package/dist/queue/index.cjs +1 -1
- package/dist/queue/index.d.cts +3 -3
- package/dist/queue/index.d.ts +3 -3
- package/dist/queue/index.js +1 -1
- package/dist/queue/types.d.cts +1 -1
- package/dist/queue/types.d.ts +1 -1
- package/dist/{queue-DyotLFJi.js → queue-Cowbg6bR.js} +8 -11
- package/dist/queue-Cowbg6bR.js.map +1 -0
- package/dist/{queue-OJJUUqc2.cjs → queue-UG_BWKIC.cjs} +8 -11
- package/dist/queue-UG_BWKIC.cjs.map +1 -0
- package/dist/scheduler/index.cjs +4 -4
- package/dist/scheduler/index.d.cts +2 -2
- package/dist/scheduler/index.d.ts +2 -2
- package/dist/scheduler/index.js +4 -4
- package/dist/scheduler/types.d.cts +1 -1
- package/dist/scheduler/types.d.ts +1 -1
- package/dist/sdk/configurations/index.cjs +1 -1
- package/dist/sdk/configurations/index.d.cts +11 -11
- package/dist/sdk/configurations/index.d.ts +11 -11
- package/dist/sdk/configurations/index.js +1 -1
- package/dist/sdk/developerPortal/index.cjs +10 -18
- package/dist/sdk/developerPortal/index.cjs.map +1 -1
- package/dist/sdk/developerPortal/index.d.cts +7 -15
- package/dist/sdk/developerPortal/index.d.ts +7 -15
- package/dist/sdk/developerPortal/index.js +7 -15
- package/dist/sdk/developerPortal/index.js.map +1 -1
- package/dist/sdk/kaiMemory/index.cjs +7 -0
- package/dist/sdk/kaiMemory/index.d.cts +41 -0
- package/dist/sdk/kaiMemory/index.d.ts +41 -0
- package/dist/sdk/kaiMemory/index.js +2 -0
- package/dist/sdk/kaiMemory/types.cjs +0 -0
- package/dist/sdk/kaiMemory/types.d.cts +2 -0
- package/dist/sdk/kaiMemory/types.d.ts +2 -0
- package/dist/sdk/kaiMemory/types.js +1 -0
- package/dist/sdk/queryService/index.cjs +2 -2
- package/dist/sdk/queryService/index.d.cts +1 -1
- package/dist/sdk/queryService/index.d.ts +1 -1
- package/dist/sdk/queryService/index.js +2 -2
- package/dist/sdk/semanticLayer/index.cjs +1 -1
- package/dist/sdk/semanticLayer/index.d.cts +16 -40
- package/dist/sdk/semanticLayer/index.d.ts +16 -40
- package/dist/sdk/semanticLayer/index.js +1 -1
- package/dist/sdk/semanticLayer/types.d.cts +1 -1
- package/dist/sdk/semanticLayer/types.d.ts +1 -1
- package/dist/sdk/storage/index.cjs +0 -5
- package/dist/sdk/storage/index.cjs.map +1 -1
- package/dist/sdk/storage/index.d.cts +2 -2
- package/dist/sdk/storage/index.d.ts +2 -2
- package/dist/sdk/storage/index.js +1 -5
- package/dist/sdk/storage/index.js.map +1 -1
- package/dist/sdk/tag/index.cjs +1 -1
- package/dist/sdk/tag/index.d.cts +3 -3
- package/dist/sdk/tag/index.d.ts +3 -3
- package/dist/sdk/tag/index.js +1 -1
- package/dist/sdk/tag/types.d.cts +1 -1
- package/dist/sdk/tag/types.d.ts +1 -1
- package/dist/sdk/vault/index.cjs +1 -1
- package/dist/sdk/vault/index.d.cts +1 -1
- package/dist/sdk/vault/index.d.ts +1 -1
- package/dist/sdk/vault/index.js +1 -1
- package/dist/{semanticLayer-E0Vilu8u.cjs → semanticLayer-CKDVkU56.cjs} +78 -166
- package/dist/semanticLayer-CKDVkU56.cjs.map +1 -0
- package/dist/{semanticLayer-CSqmtHRo.js → semanticLayer-pYy082Ju.js} +78 -166
- package/dist/semanticLayer-pYy082Ju.js.map +1 -0
- package/dist/{serviceIds-DRcoTnSd.d.cts → serviceIds-DC-H6ZD9.d.cts} +2 -1
- package/dist/{serviceIds-DRcoTnSd.d.ts → serviceIds-DC-H6ZD9.d.ts} +2 -1
- package/dist/status/index.cjs +1 -1
- package/dist/status/index.d.cts +1 -1
- package/dist/status/index.d.ts +1 -1
- package/dist/status/index.js +1 -1
- package/dist/storage/index.cjs +6 -5
- package/dist/storage/index.d.cts +3 -3
- package/dist/storage/index.d.ts +3 -3
- package/dist/storage/index.js +6 -6
- package/dist/storage/types.d.cts +3 -3
- package/dist/storage/types.d.ts +3 -3
- package/dist/{storage-LYwFQPNO.js → storage-CZQHZcXG.js} +127 -289
- package/dist/storage-CZQHZcXG.js.map +1 -0
- package/dist/{storage-BKm7cztt.cjs → storage-JinL1y1s.cjs} +132 -288
- package/dist/storage-JinL1y1s.cjs.map +1 -0
- package/dist/stream/index.cjs +3 -3
- package/dist/stream/index.d.cts +2 -2
- package/dist/stream/index.d.ts +2 -2
- package/dist/stream/index.js +3 -3
- package/dist/stream/types.d.cts +1 -1
- package/dist/stream/types.d.ts +1 -1
- package/dist/syncActions/index.cjs +1 -1
- package/dist/syncActions/index.d.cts +1 -1
- package/dist/syncActions/index.d.ts +1 -1
- package/dist/syncActions/index.js +1 -1
- package/dist/syncActions/types.d.cts +2 -2
- package/dist/syncActions/types.d.ts +2 -2
- package/dist/{syncActions-QeBhIVhG.js → syncActions-BmmoqZO_.js} +130 -111
- package/dist/syncActions-BmmoqZO_.js.map +1 -0
- package/dist/{syncActions-OEZdVffK.cjs → syncActions-CtcLGQiy.cjs} +130 -111
- package/dist/syncActions-CtcLGQiy.cjs.map +1 -0
- package/dist/{tag-CsoOZWB_.cjs → tag-DHS_soa7.cjs} +2 -2
- package/dist/{tag-CsoOZWB_.cjs.map → tag-DHS_soa7.cjs.map} +1 -1
- package/dist/{tag-DCsoewjL.js → tag-hh-1nhNr.js} +2 -2
- package/dist/{tag-DCsoewjL.js.map → tag-hh-1nhNr.js.map} +1 -1
- package/dist/telemetry/index.cjs +7 -11
- package/dist/telemetry/index.cjs.map +1 -1
- package/dist/telemetry/index.d.cts +5 -9
- package/dist/telemetry/index.d.ts +5 -9
- package/dist/telemetry/index.js +7 -11
- package/dist/telemetry/index.js.map +1 -1
- package/dist/telemetry/types.d.cts +1 -1
- package/dist/telemetry/types.d.ts +1 -1
- package/dist/{types-DqxIx9Pi.d.cts → types-6kuMW4JW.d.cts} +2 -2
- package/dist/{types-Ct0YPy2w.d.ts → types-B2w2TtSA.d.ts} +3 -3
- package/dist/{types-M46WuBSm.d.cts → types-B61aCifg.d.cts} +2 -2
- package/dist/{types-COL1kVEB.d.cts → types-B8N_k79M.d.cts} +2 -2
- package/dist/{types-Jw10xuOW.d.cts → types-BIECJYun.d.ts} +171 -44
- package/dist/{types-DZk3XHiN.d.cts → types-BLNB882w.d.cts} +3 -3
- package/dist/{types-BEe50G2r.d.cts → types-BPy5Ozee.d.cts} +2 -2
- package/dist/{types-DBOSvWtD.d.ts → types-BS4jwuMi.d.ts} +8 -15
- package/dist/{types-BrYkBQo4.d.ts → types-BTK7Bv3n.d.cts} +171 -44
- package/dist/{types-CW6lCqrC.d.cts → types-BYM9Ptz5.d.ts} +93 -43
- package/dist/{types-D6UmMa6E.d.ts → types-BZDV8DZk.d.ts} +3 -3
- package/dist/{types-Cz83RiVu.d.cts → types-B_iLJlp4.d.ts} +255 -12
- package/dist/{types-DjrRmQUe.d.cts → types-BiMahEK8.d.cts} +92 -238
- package/dist/{types-BH5LLeJy.d.ts → types-Bl03Cg2n.d.cts} +255 -12
- package/dist/{types-bGQb4Jtl.d.cts → types-ByLH46Dt.d.cts} +13 -8
- package/dist/{types-g3vU7hcg.d.cts → types-Bydx6ga_.d.cts} +2 -2
- package/dist/{types-DYzJ6K2e.d.ts → types-CFeZCQ9p.d.cts} +93 -43
- package/dist/{types-DEc55spK.d.ts → types-CKmTZSPG.d.ts} +92 -238
- package/dist/{types-CaYtinmA.d.cts → types-CMzQSHAQ.d.cts} +3 -3
- package/dist/{types-N3EChotg.d.cts → types-CP_LBmw3.d.cts} +2 -2
- package/dist/{types-zZBxJ0P-.d.ts → types-CWyXTMwy.d.ts} +2 -2
- package/dist/{types-CPB-eF82.d.ts → types-CZJlLCbA.d.ts} +2 -2
- package/dist/{types-l9o4gFsI.d.ts → types-CZXPu3gn.d.ts} +2 -2
- package/dist/{types-BztF4HeB.d.ts → types-CaOtNjSZ.d.ts} +6 -13
- package/dist/{types-BTWIPEiU.d.ts → types-CfwqVkEA.d.ts} +2 -2
- package/dist/types-Cg14ncdV.d.ts +63 -0
- package/dist/{types-Bxhh2SJr.d.ts → types-CoJVrRAD.d.ts} +2 -2
- package/dist/{types-CKiW3n6v.d.ts → types-D3wcs4tp.d.ts} +2 -2
- package/dist/{types-DPS8nwkV.d.cts → types-DDOa07rU.d.cts} +8 -15
- package/dist/{types-BW2BXUB4.d.cts → types-DE9hgr7i.d.cts} +2 -2
- package/dist/{types-BOqD3Hqy.d.cts → types-DEzW1CfI.d.cts} +3 -3
- package/dist/{types-OaD-cbbl.d.ts → types-DIiOMV-t.d.ts} +3 -3
- package/dist/{types-BuqxXXYP.d.ts → types-DKc1gmd9.d.ts} +949 -190
- package/dist/{types-BQsOHNI0.d.ts → types-DRCMBt89.d.ts} +3 -3
- package/dist/{types-BQvv4RaI.d.cts → types-DUMal2E-.d.cts} +5 -8
- package/dist/types-DWiLcrxt.d.cts +63 -0
- package/dist/{types-DNxOHnZI.d.cts → types-Dd31Lw4S.d.cts} +2 -2
- package/dist/{types-Dmu-8g4O.d.ts → types-DekYAlA-.d.ts} +3 -3
- package/dist/{types-B2U9cFcx.d.ts → types-DgJeO9Nd.d.ts} +2 -2
- package/dist/{types-nrviNdzZ.d.ts → types-DicSaNwq.d.ts} +2 -2
- package/dist/{types-f8W_j6qD.d.cts → types-DinIJ1D_.d.cts} +688 -201
- package/dist/{types-DhDNS-5B.d.ts → types-DlQw6FCi.d.ts} +13 -8
- package/dist/{types-_RhBCj4_.d.cts → types-DoZtE9tz.d.cts} +3 -3
- package/dist/{types-BsxLGDoC.d.cts → types-DrvKfXXd.d.cts} +2 -2
- package/dist/{types-CzsnuPFh.d.cts → types-Dtuvhm3K.d.cts} +949 -190
- package/dist/{types-CcrvrAJX.d.ts → types-DwVSj-Da.d.ts} +5 -8
- package/dist/{types-C2vefB4D.d.ts → types-FwRmjsNN.d.ts} +10 -34
- package/dist/{types-C0_2KZ-A.d.ts → types-RbrfiY8T.d.ts} +2 -2
- package/dist/{types-DfvdbRPL.d.ts → types-WZBztugL.d.ts} +2 -2
- package/dist/{types-52irAt99.d.cts → types-YHUEArkR.d.cts} +2 -2
- package/dist/{types-fX4gbxfV.d.cts → types-bc-4z_gc.d.cts} +10 -34
- package/dist/{types-3eUgOA7I.d.cts → types-ePSqbXRr.d.cts} +6 -13
- package/dist/{types-BupPADSm.d.ts → types-n4PTnLii.d.ts} +688 -201
- package/dist/{types-DXskkNp8.d.cts → types-pvQzbgNE.d.cts} +3 -3
- package/dist/{types-DajzGOKB.d.ts → types-q-1r_9d1.d.ts} +2 -2
- package/dist/{types-D8Rrz51O.d.cts → types-tKkeLa2B.d.cts} +2 -2
- package/dist/{validateConnectionStatus-olE2sQ3U.js → validateConnectionStatus-BEGu8wXT.js} +7 -10
- package/dist/validateConnectionStatus-BEGu8wXT.js.map +1 -0
- package/dist/{validateConnectionStatus-CsvYmCOI.cjs → validateConnectionStatus-BEYkQpu9.cjs} +7 -10
- package/dist/validateConnectionStatus-BEYkQpu9.cjs.map +1 -0
- package/dist/vault/index.cjs +4 -4
- package/dist/vault/index.d.cts +1 -1
- package/dist/vault/index.d.ts +1 -1
- package/dist/vault/index.js +4 -4
- package/dist/vault/types.d.cts +1 -1
- package/dist/vault/types.d.ts +1 -1
- package/package.json +58 -4
- package/surface/apps.md +3 -3
- package/surface/auth.md +13 -6
- package/surface/businessWorkspaceApi.md +12 -0
- package/surface/chat.md +7 -7
- package/surface/kaiAgent.md +13 -9
- package/surface/management.md +18 -5
- package/surface/metastore.md +2 -2
- package/surface/queue.md +3 -3
- package/surface/sdk.md +13 -3
- package/surface/storage.md +6 -6
- package/surface/syncActions.md +9 -0
- package/dist/ValidationError-BekhphAq.js +0 -48
- package/dist/ValidationError-BekhphAq.js.map +0 -1
- package/dist/ValidationError-CLVJCCwH.cjs.map +0 -1
- package/dist/authClient-D7W9vWPR.js.map +0 -1
- package/dist/authClient-_PpvGgZJ.cjs.map +0 -1
- package/dist/concurrent-CH9fbNr3.js.map +0 -1
- package/dist/concurrent-tbiIa0UL.cjs.map +0 -1
- package/dist/configurations-BVvcimzo.js.map +0 -1
- package/dist/configurations-CyFF9Dtu.cjs.map +0 -1
- package/dist/configurations-VtNE0nrT.js.map +0 -1
- package/dist/configurations-zkNjr73Q.cjs.map +0 -1
- package/dist/constants-C4DlsF_M.cjs.map +0 -1
- package/dist/constants-wfbFsqqN.js.map +0 -1
- package/dist/createFetchClient-DgMiqTJ8.cjs.map +0 -1
- package/dist/createFetchClient-U-ZrwPl2.js.map +0 -1
- package/dist/credential-CihSf_xs.js +0 -36
- package/dist/credential-CihSf_xs.js.map +0 -1
- package/dist/credential-DVWvJFJs.cjs +0 -47
- package/dist/credential-DVWvJFJs.cjs.map +0 -1
- package/dist/dedupe-CiskLkGR.cjs +0 -30
- package/dist/dedupe-CiskLkGR.cjs.map +0 -1
- package/dist/dedupe-DYIHgZoG.js +0 -25
- package/dist/dedupe-DYIHgZoG.js.map +0 -1
- package/dist/isLoginPageRedirect-B0EmRsHr.cjs +0 -25
- package/dist/isLoginPageRedirect-B0EmRsHr.cjs.map +0 -1
- package/dist/isLoginPageRedirect-BTTAedW-.js +0 -20
- package/dist/isLoginPageRedirect-BTTAedW-.js.map +0 -1
- package/dist/jobStatus-0_Y3Sr4i.cjs.map +0 -1
- package/dist/jobStatus-PSZJMTiA.js.map +0 -1
- package/dist/kaiAgent-8LNzGhZc.js.map +0 -1
- package/dist/kaiAgent-B_TaUPRt.cjs.map +0 -1
- package/dist/management-BoxlRNg2.cjs.map +0 -1
- package/dist/management-Bp440RsV.js.map +0 -1
- package/dist/metastore-BYYWTb3m.cjs.map +0 -1
- package/dist/metastore-VCDRVhUT.js.map +0 -1
- package/dist/queue-DyotLFJi.js.map +0 -1
- package/dist/queue-OJJUUqc2.cjs.map +0 -1
- package/dist/semanticLayer-CSqmtHRo.js.map +0 -1
- package/dist/semanticLayer-E0Vilu8u.cjs.map +0 -1
- package/dist/storage-BKm7cztt.cjs.map +0 -1
- package/dist/storage-LYwFQPNO.js.map +0 -1
- package/dist/syncActions-OEZdVffK.cjs.map +0 -1
- package/dist/syncActions-QeBhIVhG.js.map +0 -1
- package/dist/validateConnectionStatus-CsvYmCOI.cjs.map +0 -1
- package/dist/validateConnectionStatus-olE2sQ3U.js.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { a as poller, t as jobStatus } from "./jobStatus-
|
|
2
|
-
import { t as concurrent } from "./concurrent-
|
|
3
|
-
import { h as KeboolaHttpHeader, r as isApiError, s as HttpHeader } from "./createFetchClient-
|
|
4
|
-
import { t as validateConnectionStatus } from "./validateConnectionStatus-
|
|
5
|
-
import { t as createGenericFetchClient } from "./createGenericFetchClient-
|
|
6
|
-
import { t as createOpenapiFetchClient } from "./createOpenapiFetchClient-
|
|
7
|
-
import { t as createAuthHeaders } from "./auth-
|
|
1
|
+
import { a as poller, t as jobStatus } from "./jobStatus-CfRtsIpv.js";
|
|
2
|
+
import { t as concurrent } from "./concurrent-BacWxPwi.js";
|
|
3
|
+
import { g as ApiError, h as KeboolaHttpHeader, r as isApiError, s as HttpHeader } from "./createFetchClient-DXHQK63w.js";
|
|
4
|
+
import { t as validateConnectionStatus } from "./validateConnectionStatus-BEGu8wXT.js";
|
|
5
|
+
import { t as createGenericFetchClient } from "./createGenericFetchClient-Dg1rgzmG.js";
|
|
6
|
+
import { t as createOpenapiFetchClient } from "./createOpenapiFetchClient-DZUOVupy.js";
|
|
7
|
+
import { t as createAuthHeaders } from "./auth-DworfoPy.js";
|
|
8
8
|
//#region src/utils/async/series.ts
|
|
9
9
|
/**
|
|
10
10
|
* Executes a callback function on an array of items in series (one at a time).
|
|
@@ -17,6 +17,28 @@ const series = async (options) => concurrent({
|
|
|
17
17
|
concurrency: 1
|
|
18
18
|
});
|
|
19
19
|
//#endregion
|
|
20
|
+
//#region src/errors/readableReason.ts
|
|
21
|
+
const isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
22
|
+
/**
|
|
23
|
+
* Whether this error's `message` is a status line rather than a sentence.
|
|
24
|
+
*
|
|
25
|
+
* - Only the base `ApiError`: its subclasses carry reader-facing wording that must be kept.
|
|
26
|
+
*/
|
|
27
|
+
const carriesStatusLine = (error) => error.constructor === ApiError;
|
|
28
|
+
/**
|
|
29
|
+
* The part of a failure worth putting in front of a reader, or `undefined` when there is none.
|
|
30
|
+
*
|
|
31
|
+
* - A plain `ApiError`: the service's message from the body, never the status line.
|
|
32
|
+
* - Any other error: its `message` as-is.
|
|
33
|
+
* - `undefined` means render your own wording; don't test for an empty `message` instead.
|
|
34
|
+
*/
|
|
35
|
+
const readableReason = (error) => {
|
|
36
|
+
if (!(error instanceof Error)) return void 0;
|
|
37
|
+
if (!carriesStatusLine(error)) return error.message === "" ? void 0 : error.message;
|
|
38
|
+
const message = isRecord(error.data) ? error.data.message : void 0;
|
|
39
|
+
return typeof message === "string" && message !== "" ? message : void 0;
|
|
40
|
+
};
|
|
41
|
+
//#endregion
|
|
20
42
|
//#region src/errors/ServiceUnavailableError.ts
|
|
21
43
|
var ServiceUnavailableError = class ServiceUnavailableError extends Error {
|
|
22
44
|
constructor(serviceId, path, clientName) {
|
|
@@ -103,12 +125,11 @@ const createMergeRequests = (client) => {
|
|
|
103
125
|
//#endregion
|
|
104
126
|
//#region src/clients/storage/branches/branches.ts
|
|
105
127
|
/**
|
|
106
|
-
*
|
|
128
|
+
* Dev-branches client; the spec has three defects.
|
|
107
129
|
*
|
|
108
|
-
* - `creatorToken` is a bare `object`, so `DevBranch` re-types it and
|
|
109
|
-
* -
|
|
110
|
-
*
|
|
111
|
-
* - Duplicate: the create is also declared on `/dev-branches/` (trailing slash); drop it.
|
|
130
|
+
* - `creatorToken` is a bare `object`, so `DevBranch` re-types it and reads are asserted.
|
|
131
|
+
* - Create and delete answer a flat `JobResponse`, not the `Job<T>` union, so jobs are asserted.
|
|
132
|
+
* - The create is also declared on `/dev-branches/` (trailing slash); drop it.
|
|
112
133
|
*/
|
|
113
134
|
const createBranches = (client, poller) => {
|
|
114
135
|
/**
|
|
@@ -119,8 +140,6 @@ const createBranches = (client, poller) => {
|
|
|
119
140
|
return data;
|
|
120
141
|
};
|
|
121
142
|
/**
|
|
122
|
-
* Creates a development branch. Async — returns a job to poll.
|
|
123
|
-
*
|
|
124
143
|
* @link https://api.keboola.com/?service=storage#storage/tag/dev-branches/POST/v2/storage/dev-branches
|
|
125
144
|
*/
|
|
126
145
|
const createDevBranchAsync = async (body) => {
|
|
@@ -128,16 +147,12 @@ const createBranches = (client, poller) => {
|
|
|
128
147
|
return data;
|
|
129
148
|
};
|
|
130
149
|
/**
|
|
131
|
-
* Creates a development branch and waits for the job to finish.
|
|
132
|
-
*
|
|
133
150
|
* @link https://api.keboola.com/?service=storage#storage/tag/dev-branches/POST/v2/storage/dev-branches
|
|
134
151
|
*/
|
|
135
152
|
const createDevBranchAndWait = async (body, options) => {
|
|
136
153
|
return poller(await createDevBranchAsync(body), options).start();
|
|
137
154
|
};
|
|
138
155
|
/**
|
|
139
|
-
* Renames a development branch or changes its description.
|
|
140
|
-
*
|
|
141
156
|
* @link https://api.keboola.com/?service=storage#storage/tag/dev-branches/PUT/v2/storage/dev-branches/{id}
|
|
142
157
|
*/
|
|
143
158
|
const updateDevBranch = async ({ id, name, description }) => {
|
|
@@ -151,8 +166,6 @@ const createBranches = (client, poller) => {
|
|
|
151
166
|
return data;
|
|
152
167
|
};
|
|
153
168
|
/**
|
|
154
|
-
* Deletes a development branch. Async — returns a job to poll.
|
|
155
|
-
*
|
|
156
169
|
* @link https://api.keboola.com/?service=storage#storage/tag/dev-branches/DELETE/v2/storage/dev-branches/{id}
|
|
157
170
|
*/
|
|
158
171
|
const deleteDevBranchAsync = async (id) => {
|
|
@@ -160,12 +173,9 @@ const createBranches = (client, poller) => {
|
|
|
160
173
|
return data;
|
|
161
174
|
};
|
|
162
175
|
/**
|
|
163
|
-
*
|
|
164
|
-
*
|
|
165
|
-
* -
|
|
166
|
-
* `devBranchDelete` job.
|
|
167
|
-
* - A job that ended as `error` is a `done` wait carrying a failed job — it finished. `timedOut`,
|
|
168
|
-
* `exhausted`, `aborted` and `errored` are the endings with no job to read.
|
|
176
|
+
* - Never throws; resolves with how the wait ended.
|
|
177
|
+
* - `done` carries the finished job, even one that ended as `error`.
|
|
178
|
+
* - `timedOut`, `exhausted`, `aborted` and `errored` carry no job.
|
|
169
179
|
*
|
|
170
180
|
* @link https://api.keboola.com/?service=storage#storage/tag/dev-branches/DELETE/v2/storage/dev-branches/{id}
|
|
171
181
|
*/
|
|
@@ -173,8 +183,7 @@ const createBranches = (client, poller) => {
|
|
|
173
183
|
return poller(await deleteDevBranchAsync(id), options).start();
|
|
174
184
|
};
|
|
175
185
|
/**
|
|
176
|
-
*
|
|
177
|
-
* thing being addressed rather than the branch a request is scoped to.
|
|
186
|
+
* `branchId` is the branch the metadata is on, not a request scope.
|
|
178
187
|
*
|
|
179
188
|
* @link https://api.keboola.com/?service=storage#storage/tag/metadata/GET/v2/storage/branch/{branchId}/metadata
|
|
180
189
|
*/
|
|
@@ -183,8 +192,6 @@ const createBranches = (client, poller) => {
|
|
|
183
192
|
return data;
|
|
184
193
|
};
|
|
185
194
|
/**
|
|
186
|
-
* Adds or updates metadata on a branch.
|
|
187
|
-
*
|
|
188
195
|
* @link https://api.keboola.com/?service=storage#storage/tag/metadata/POST/v2/storage/branch/{branchId}/metadata
|
|
189
196
|
*/
|
|
190
197
|
const saveDevBranchMetadata = async ({ branchId, metadata }, signal) => {
|
|
@@ -195,8 +202,6 @@ const createBranches = (client, poller) => {
|
|
|
195
202
|
return data;
|
|
196
203
|
};
|
|
197
204
|
/**
|
|
198
|
-
* Deletes a single metadata entry from a branch.
|
|
199
|
-
*
|
|
200
205
|
* @link https://api.keboola.com/?service=storage#storage/tag/metadata/DELETE/v2/storage/branch/{branchId}/metadata/{metadataId}
|
|
201
206
|
*/
|
|
202
207
|
const deleteDevBranchMetadata = async ({ branchId, metadataId }, signal) => {
|
|
@@ -220,31 +225,14 @@ const createBranches = (client, poller) => {
|
|
|
220
225
|
//#endregion
|
|
221
226
|
//#region src/clients/storage/bucketExternal/bucketExternal.ts
|
|
222
227
|
/**
|
|
223
|
-
*
|
|
224
|
-
* BigQuery) rather than one Keboola created. Registering it is what makes the rest of this namespace
|
|
225
|
-
* apply: only an external bucket needs its table metadata refreshed, manually or on a cron.
|
|
228
|
+
* External buckets wrap a schema that already exists in the backend (Snowflake or BigQuery).
|
|
226
229
|
*
|
|
227
|
-
*
|
|
228
|
-
* -
|
|
229
|
-
*
|
|
230
|
-
* the operation declares a `JobResponse` or no body at all.
|
|
231
|
-
* - **`async` query** — `registerBucketAsync` is invoked with `async: true` but declares
|
|
232
|
-
* `query: never`.
|
|
233
|
-
*
|
|
234
|
-
* What the Storage spec needs, per operation:
|
|
235
|
-
*
|
|
236
|
-
* - `POST /buckets/register` (`BucketRegisterAction`)
|
|
237
|
-
* - query: `never` → really accepts `async`
|
|
238
|
-
* - response: contentless `default` → really a `bucketRegister` job
|
|
239
|
-
* - `PUT /buckets/{bucketId}/refresh` (`BucketRefreshAction`)
|
|
240
|
-
* - response: 202 `JobResponse` → really a `bucketRefresh` job
|
|
241
|
-
* `GET /buckets/register-guide` and the scheduled-task create are the operations whose spec is
|
|
242
|
-
* already right — their bodies, queries and responses are generated, not asserted.
|
|
230
|
+
* - Only they need table metadata refreshed, manually or on a cron.
|
|
231
|
+
* - Job returns are asserted: the spec's flat `JobResponse` is not the `Job<T>` union.
|
|
232
|
+
* - The `POST /buckets/register` spec lacks the `async` query and the `bucketRegister` job response.
|
|
243
233
|
*/
|
|
244
234
|
const createBucketExternal = (client) => {
|
|
245
235
|
/**
|
|
246
|
-
* Registers an external bucket. Async — returns a job to poll.
|
|
247
|
-
*
|
|
248
236
|
* @link https://api.keboola.com/?service=storage#storage/POST/v2/storage/buckets/register
|
|
249
237
|
*/
|
|
250
238
|
const registerBucketAsync = async (body, signal) => {
|
|
@@ -255,7 +243,7 @@ const createBucketExternal = (client) => {
|
|
|
255
243
|
return data;
|
|
256
244
|
};
|
|
257
245
|
/**
|
|
258
|
-
* Returns
|
|
246
|
+
* Returns markdown.
|
|
259
247
|
*
|
|
260
248
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/GET/v2/storage/buckets/register-guide
|
|
261
249
|
*/
|
|
@@ -267,8 +255,6 @@ const createBucketExternal = (client) => {
|
|
|
267
255
|
return data;
|
|
268
256
|
};
|
|
269
257
|
/**
|
|
270
|
-
* Refreshes an external bucket's table metadata. Async — returns a job to poll.
|
|
271
|
-
*
|
|
272
258
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/PUT/v2/storage/buckets/{bucketId}/refresh
|
|
273
259
|
*/
|
|
274
260
|
const refreshExternalBucketAsync = async ({ bucketId, ...query }, signal) => {
|
|
@@ -302,10 +288,7 @@ const createBucketExternal = (client) => {
|
|
|
302
288
|
//#endregion
|
|
303
289
|
//#region src/clients/storage/bucketListings/utils.ts
|
|
304
290
|
/**
|
|
305
|
-
*
|
|
306
|
-
* spec documents as "prefixed with `user:` or `group:`". The write path uses `toBackendSubscribers`;
|
|
307
|
-
* reads hand back the raw `string[]`, so a consumer that renders or edits subscribers decodes with
|
|
308
|
-
* `fromBackendSubscribers` rather than re-deriving the prefix rule.
|
|
291
|
+
* Encodes subscribers as GCP IAM principals (`user:`/`group:`); `fromBackendSubscribers` decodes.
|
|
309
292
|
*/
|
|
310
293
|
const toBackendSubscribers = (subscribers) => subscribers.map((s) => `${s.type}:${s.email}`);
|
|
311
294
|
const fromBackendSubscribers = (raw) => {
|
|
@@ -327,17 +310,9 @@ const fromBackendSubscribers = (raw) => {
|
|
|
327
310
|
/**
|
|
328
311
|
* Builds the PATCH body for a listing update.
|
|
329
312
|
*
|
|
330
|
-
*
|
|
331
|
-
*
|
|
332
|
-
*
|
|
333
|
-
* `null` and silently clear it.
|
|
334
|
-
*
|
|
335
|
-
* Throws when nothing was supplied: the backend answers an empty PATCH with a job that lands in
|
|
336
|
-
* `success` without changing anything, so a caller would poll it and report a save that never
|
|
337
|
-
* happened. Gate the call on the form's "dirty" state rather than relying on this.
|
|
338
|
-
*
|
|
339
|
-
* Do not "normalize" the `exposure*` names without coordinating with the bucket-listing backend
|
|
340
|
-
* owner.
|
|
313
|
+
* - Copies only supplied fields: `description` absent keeps it, `null` clears it, a string sets it.
|
|
314
|
+
* - Throws when nothing was supplied: an empty PATCH yields a `success` job that changed nothing.
|
|
315
|
+
* - Keep the `exposure*` names unless the bucket-listing backend owner agrees.
|
|
341
316
|
*/
|
|
342
317
|
const toUpdateListingBody = (input) => {
|
|
343
318
|
const body = {};
|
|
@@ -350,26 +325,17 @@ const toUpdateListingBody = (input) => {
|
|
|
350
325
|
//#endregion
|
|
351
326
|
//#region src/clients/storage/bucketListings/bucketListings.ts
|
|
352
327
|
/**
|
|
353
|
-
*
|
|
354
|
-
* only backend today, which is why every write carries a `bigquery` key.
|
|
355
|
-
*
|
|
356
|
-
* What the Storage spec needs, per operation:
|
|
357
|
-
*
|
|
358
|
-
* - `POST` / `PATCH` / `DELETE /buckets/{bucketId}/listing`
|
|
359
|
-
* - response: 202 `JobResponse` → really `bucketListingCreate` / `bucketListingUpdate` /
|
|
360
|
-
* `bucketListingDelete` jobs. The spec's `JobResponse` is a flat shape with `status: string`,
|
|
361
|
-
* while `Job<T>` is a discriminated union over `status` carrying typed `results`, so each is
|
|
362
|
-
* asserted.
|
|
328
|
+
* Bucket listings (exposures) publish a bucket to a marketplace.
|
|
363
329
|
*
|
|
364
|
-
*
|
|
365
|
-
*
|
|
330
|
+
* - BigQuery Analytics Hub is the only backend, hence the `bigquery` key on every write.
|
|
331
|
+
* - Write jobs are asserted: the spec's flat `JobResponse` is not the `Job<T>` union.
|
|
366
332
|
*/
|
|
367
333
|
const createBucketListings = (openApiClient) => {
|
|
368
334
|
/**
|
|
369
|
-
*
|
|
370
|
-
*
|
|
371
|
-
* present only for a BigQuery bucket
|
|
372
|
-
* raw `user:`/`group
|
|
335
|
+
* Returns `null` on 404: no bucket or no listing.
|
|
336
|
+
*
|
|
337
|
+
* - `bigquery` is present only for a BigQuery bucket.
|
|
338
|
+
* - Its `subscribers` are raw `user:`/`group:` principals; decode with `fromBackendSubscribers`.
|
|
373
339
|
*/
|
|
374
340
|
const getListing = async (bucketId, signal) => {
|
|
375
341
|
try {
|
|
@@ -395,11 +361,7 @@ const createBucketListings = (openApiClient) => {
|
|
|
395
361
|
return data;
|
|
396
362
|
};
|
|
397
363
|
/**
|
|
398
|
-
*
|
|
399
|
-
* `subscribers` must be provided — the SDK throws synchronously if all three
|
|
400
|
-
* are absent, since the backend would otherwise no-op a PATCH with an empty
|
|
401
|
-
* body and we'd return a job that's already in `success` with no actual
|
|
402
|
-
* change. Callers should gate the call against the form's "dirty" state.
|
|
364
|
+
* Rejects when `name`, `description` and `subscribers` are all absent; gate on the form's dirty state.
|
|
403
365
|
*/
|
|
404
366
|
const updateListingAsync = async ({ bucketId, ...input }, signal) => {
|
|
405
367
|
const { data } = await openApiClient.patch("/v2/storage/buckets/{bucketId}/listing", {
|
|
@@ -428,29 +390,11 @@ const createBucketListings = (openApiClient) => {
|
|
|
428
390
|
//#endregion
|
|
429
391
|
//#region src/clients/storage/buckets/buckets.ts
|
|
430
392
|
/**
|
|
431
|
-
*
|
|
432
|
-
*
|
|
433
|
-
*
|
|
434
|
-
*
|
|
435
|
-
|
|
436
|
-
* One mismatch recurs: the spec's `JobResponse` is a flat shape with `status: string`, while `Job<T>`
|
|
437
|
-
* is a discriminated union over `status` carrying typed `results`, so every job return is asserted.
|
|
438
|
-
*
|
|
439
|
-
* What the Storage spec needs, per operation:
|
|
440
|
-
*
|
|
441
|
-
* - `PUT /buckets/{bucketId}` — **operation missing entirely**; really takes `UpdateBucketBody`
|
|
442
|
-
* (`displayName` / `description` / `color`) and answers a bucket detail
|
|
443
|
-
* - `GET /branch/{branchId}/buckets` (`BucketsListAction`)
|
|
444
|
-
* - query: `include` is a `string` → really a repeatable list, sent comma-joined
|
|
445
|
-
* - response: `BucketCreateResponse[]` → really `Bucket[]` (a listing row, not a create result)
|
|
446
|
-
* - `POST /buckets` (`BucketCreateAction`)
|
|
447
|
-
* - response: 201 `BucketCreateResponse` → really a bucket detail
|
|
448
|
-
* - `DELETE /buckets/{bucketId}` (`BucketDeleteAction`)
|
|
449
|
-
* - response: 204 wins over the 202 `JobResponse` in success-code precedence, so the async variant's
|
|
450
|
-
* job is asserted
|
|
451
|
-
* - `POST /buckets/{bucketId}/owner` (`BucketOwnerUpdateAction`)
|
|
452
|
-
* - body: `BucketOwnerUpdateRequest` is stubbed → really `{ email } | { id }`
|
|
453
|
-
* */
|
|
393
|
+
* Spec mismatches behind the assertions below:
|
|
394
|
+
* - Job returns: the spec's flat `JobResponse` vs the `Job<T>` union; on delete, 204 shadows the 202.
|
|
395
|
+
* - List/create responses are really `Bucket[]` / a bucket detail; list `include` is comma-joined.
|
|
396
|
+
* - Owner-update body is stubbed; really `{ email } | { id }`.
|
|
397
|
+
*/
|
|
454
398
|
const createBuckets = (openApiClient, client) => {
|
|
455
399
|
const getBuckets = async ({ branchId, ...query }, signal) => {
|
|
456
400
|
const { data } = await openApiClient.get("/v2/storage/branch/{branchId}/buckets", {
|
|
@@ -492,8 +436,8 @@ const createBuckets = (openApiClient, client) => {
|
|
|
492
436
|
/**
|
|
493
437
|
* Deletes a bucket synchronously.
|
|
494
438
|
*
|
|
495
|
-
* Refused
|
|
496
|
-
*
|
|
439
|
+
* - Refused on the stacks we test against (`400 storage.buckets.syncDeleteDisabled`); prefer
|
|
440
|
+
* `deleteBucketAsync`.
|
|
497
441
|
*
|
|
498
442
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/DELETE/v2/storage/buckets/{bucketId}
|
|
499
443
|
*/
|
|
@@ -501,10 +445,7 @@ const createBuckets = (openApiClient, client) => {
|
|
|
501
445
|
await openApiClient.delete("/v2/storage/buckets/{bucketId}", { path: { bucketId: id } });
|
|
502
446
|
};
|
|
503
447
|
/**
|
|
504
|
-
* Deletes a bucket asynchronously and returns a job to poll.
|
|
505
|
-
* Required on GCP stacks where synchronous bucket deletion is not supported.
|
|
506
|
-
*
|
|
507
|
-
* `force` deletes all tables inside the bucket before removing it.
|
|
448
|
+
* Deletes a bucket asynchronously and returns a job to poll. Required on GCP stacks.
|
|
508
449
|
*
|
|
509
450
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/DELETE/v2/storage/buckets/{bucketId}
|
|
510
451
|
*/
|
|
@@ -521,9 +462,8 @@ const createBuckets = (openApiClient, client) => {
|
|
|
521
462
|
/**
|
|
522
463
|
* Returns the owner of a bucket in the given branch.
|
|
523
464
|
*
|
|
524
|
-
* A bucket
|
|
525
|
-
*
|
|
526
|
-
* "unassigned" rather than as a missing bucket).
|
|
465
|
+
* - A bucket without an assigned owner answers `404 storage.bucket.ownerNotFound`, not a missing
|
|
466
|
+
* bucket.
|
|
527
467
|
*
|
|
528
468
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/GET/v2/storage/branch/{branchId}/buckets/{bucketId}/owner
|
|
529
469
|
*/
|
|
@@ -588,36 +528,11 @@ const createBuckets = (openApiClient, client) => {
|
|
|
588
528
|
//#endregion
|
|
589
529
|
//#region src/clients/storage/bucketSharing/bucketSharing.ts
|
|
590
530
|
/**
|
|
591
|
-
*
|
|
592
|
-
* -
|
|
593
|
-
*
|
|
594
|
-
*
|
|
595
|
-
* -
|
|
596
|
-
* `query: never`.
|
|
597
|
-
*
|
|
598
|
-
* What the Storage spec needs, per operation:
|
|
599
|
-
*
|
|
600
|
-
* - `POST /branch/{branchId}/buckets/{bucketId}/share-organization` / `-organization-project`
|
|
601
|
-
* - query: `never` → really accepts `async`
|
|
602
|
-
* - response: `BucketShareOrganizationResponse` / `…ProjectResponse` → really share jobs
|
|
603
|
-
* - `POST /branch/{branchId}/buckets/{bucketId}/share-to-projects` / `-to-users`
|
|
604
|
-
* - query: `never` → really accepts `async`
|
|
605
|
-
* - body: `CreateBucketSharingToProjectsRequest` / `…ToUsersRequest` are stubbed
|
|
606
|
-
* (`Record<string, never>`) → really `{ targetProjectIds }` / `{ targetUsers }`
|
|
607
|
-
* - response: contentless `default` → really `bucketShareToProjects` / `bucketShareToAdmins` jobs
|
|
608
|
-
* - `DELETE /branch/{branchId}/buckets/{bucketId}/share` (`BucketShareDeleteAction`)
|
|
609
|
-
* - query: `never` → really accepts `async`
|
|
610
|
-
* - response: `BucketShareDeleteResponse` → really a `bucketRemoveShare` job
|
|
611
|
-
* - `DELETE /branch/{branchId}/buckets/{bucketId}/links/{linkedProjectId}` (`BucketForceUnlinkAction`)
|
|
612
|
-
* - query: `never` → really accepts `async`
|
|
613
|
-
* - path: `linkedProjectId` is a `number` → really a string
|
|
614
|
-
* - response: 202 `JobResponse` → really a `bucketForceUnlink` job
|
|
615
|
-
* - `POST /buckets` (`BucketCreateAction`) — the link half of a create-or-link endpoint
|
|
616
|
-
* - response: the 201 "created or linked synchronously" wins over the 202 in success-code
|
|
617
|
-
* precedence, so the async variant's `bucketLink` job is asserted
|
|
618
|
-
* - `GET /shared-buckets` (`SharedBucketsListAction`)
|
|
619
|
-
* - response: `Record<string, never>[]` → really a shared-bucket listing. This one is *not*
|
|
620
|
-
* asserted, so `SharedBuckets` is currently an empty-object array and callers get nothing useful.
|
|
531
|
+
* Spec mismatches behind the assertions below:
|
|
532
|
+
* - Job returns: the spec's flat `JobResponse` (or no body) vs the `Job<T>` union.
|
|
533
|
+
* - Share/unshare declare `query: never`, but accept `async`.
|
|
534
|
+
* - Share-to-projects/users bodies are stubbed; force-unlink `linkedProjectId` is really a string.
|
|
535
|
+
* - `sharedBuckets` is not asserted, so it returns the spec's `Record<string, never>[]`.
|
|
621
536
|
*/
|
|
622
537
|
const createBucketSharing = (openApiClient) => {
|
|
623
538
|
/**
|
|
@@ -749,24 +664,10 @@ const createBucketSharing = (openApiClient) => {
|
|
|
749
664
|
//#endregion
|
|
750
665
|
//#region src/clients/storage/columns/columns.ts
|
|
751
666
|
/**
|
|
752
|
-
*
|
|
753
|
-
*
|
|
754
|
-
*
|
|
755
|
-
*
|
|
756
|
-
*
|
|
757
|
-
* - `POST /branch/{branchId}/tables/{id}/columns` (`ColumnCreateAction`)
|
|
758
|
-
* - body: none of `ColumnCreateRequest` / `SnowflakeAddColumnToTableRequest` /
|
|
759
|
-
* `BigqueryAddColumnToTableRequest` declares `basetype`, and they type `definition.length` as a
|
|
760
|
-
* `number` → really a string (a decimal length is sent as `'38,0'`)
|
|
761
|
-
* - response: 202 is contentless → really a `tableColumnAdd` job
|
|
762
|
-
* - `DELETE /branch/{branchId}/tables/{tableId}/columns/{columnName}` (`ColumnDeleteAction`)
|
|
763
|
-
* - response: 202 declares `JobResponse` → really a `tableColumnDelete` job
|
|
764
|
-
* - `POST /branch/{branchId}/tables/{tableId}/primary-key` (`PrimaryKeyCreateAction`)
|
|
765
|
-
* - body: `CreatePrimaryKeyRequest.skipDuplicatesCheck` is required → really optional (it has a
|
|
766
|
-
* documented `@default false`, so a caller omitting it is valid)
|
|
767
|
-
* - response: 202 is contentless → really a `tablePrimaryKeyAdd` job
|
|
768
|
-
* - `DELETE /branch/{branchId}/tables/{tableId}/primary-key` (`PrimaryKeyDeleteAction`)
|
|
769
|
-
* - response: 202 declares `JobResponse` → really a `tablePrimaryKeyDelete` job
|
|
667
|
+
* Spec mismatches behind the assertions below:
|
|
668
|
+
* - Job returns: the spec's flat `JobResponse` (or no body) vs the `Job<T>` union.
|
|
669
|
+
* - Add-column body lacks `basetype`; `definition.length` is really a string (`'38,0'`).
|
|
670
|
+
* - Primary-key `skipDuplicatesCheck` is really optional (defaults to `false`).
|
|
770
671
|
*/
|
|
771
672
|
const createColumns = (client) => {
|
|
772
673
|
/**
|
|
@@ -1032,17 +933,12 @@ const createConfigurationRows = (client) => {
|
|
|
1032
933
|
//#endregion
|
|
1033
934
|
//#region src/clients/storage/configurations/utils.ts
|
|
1034
935
|
/**
|
|
1035
|
-
* `expectedVersion`
|
|
1036
|
-
* `If-Match` header so the write is conditional on nothing having changed since. What Storage does
|
|
1037
|
-
* with it:
|
|
936
|
+
* Sends `expectedVersion` as `If-Match`. Storage answers:
|
|
1038
937
|
*
|
|
1039
|
-
* 1.
|
|
1040
|
-
*
|
|
1041
|
-
*
|
|
1042
|
-
*
|
|
1043
|
-
* 3. Version moved on since it was read — 412, and nothing is written.
|
|
1044
|
-
* 4. Value unusable — 400. Storage wants a strong entity tag, so the quotes are part of the value;
|
|
1045
|
-
* a bare number, a weak validator or a tag list are all rejected.
|
|
938
|
+
* 1. Omitted — no precondition (except `purgeConfiguration`: 428).
|
|
939
|
+
* 2. Current — the write applies.
|
|
940
|
+
* 3. Moved on — 412, nothing written.
|
|
941
|
+
* 4. Not a strong quoted entity tag — 400.
|
|
1046
942
|
*/
|
|
1047
943
|
const createVersionPrecondition = (expectedVersion) => expectedVersion === void 0 ? {} : { [HttpHeader.IF_MATCH]: `"${expectedVersion}"` };
|
|
1048
944
|
/**
|
|
@@ -1061,10 +957,8 @@ const parseSyncJobId = (headers) => {
|
|
|
1061
957
|
/**
|
|
1062
958
|
* Every configuration read is bridged to `ComponentConfig<T>` with `as unknown as`.
|
|
1063
959
|
*
|
|
1064
|
-
* - `BaseComponentConfig` re-tightens
|
|
1065
|
-
*
|
|
1066
|
-
* - `ComponentConfig<T>` is a conditional over an unresolved `T`, which TypeScript will not check a
|
|
1067
|
-
* direct conversion against either.
|
|
960
|
+
* - `BaseComponentConfig` re-tightens and re-types spec fields, so the shapes never fully overlap.
|
|
961
|
+
* - `ComponentConfig<T>` is a conditional over an unresolved `T`, which TS won't convert against.
|
|
1068
962
|
*/
|
|
1069
963
|
const createConfigurations = (client) => {
|
|
1070
964
|
const getConfiguration = async ({ componentId, configId, branchId }, signal) => {
|
|
@@ -1095,11 +989,10 @@ const createConfigurations = (client) => {
|
|
|
1095
989
|
return data;
|
|
1096
990
|
};
|
|
1097
991
|
/**
|
|
1098
|
-
* Resolve a merge conflict by deleting the configuration
|
|
1099
|
-
*
|
|
1100
|
-
*
|
|
1101
|
-
* `version
|
|
1102
|
-
* the deleted configuration.
|
|
992
|
+
* Resolve a merge conflict by deleting the configuration.
|
|
993
|
+
*
|
|
994
|
+
* - Same rebase endpoint as `rebaseConfiguration`, with an empty `diff` envelope.
|
|
995
|
+
* - Re-anchors onto the default-branch `version`; the head version becomes a tombstone.
|
|
1103
996
|
*/
|
|
1104
997
|
const rebaseConfigurationToDeleted = async ({ branchId, componentId, configId, version }) => {
|
|
1105
998
|
const { data } = await client.post("/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}/rebase", {
|
|
@@ -1126,14 +1019,10 @@ const createConfigurations = (client) => {
|
|
|
1126
1019
|
return data;
|
|
1127
1020
|
};
|
|
1128
1021
|
/**
|
|
1129
|
-
*
|
|
1022
|
+
* Sends only the fields provided.
|
|
1130
1023
|
*
|
|
1131
|
-
* -
|
|
1132
|
-
* -
|
|
1133
|
-
* saved configuration. That part runs as a job: poll `syncJobId` through `jobs.getJob` when it
|
|
1134
|
-
* has to land before the caller reports success.
|
|
1135
|
-
* - A `workspaceId` not linked to this component and configuration is rejected with 400, before
|
|
1136
|
-
* the configuration is written.
|
|
1024
|
+
* - `workspaceId` also enqueues an output-mapping sync job; poll `syncJobId` via `jobs.getJob`.
|
|
1025
|
+
* - A `workspaceId` not linked to this configuration is rejected with 400, before any write.
|
|
1137
1026
|
*
|
|
1138
1027
|
* @link https://api.keboola.com/?service=storage#storage/tag/component-configurations/PUT/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}
|
|
1139
1028
|
*/
|
|
@@ -1171,9 +1060,8 @@ const createConfigurations = (client) => {
|
|
|
1171
1060
|
return data;
|
|
1172
1061
|
};
|
|
1173
1062
|
/**
|
|
1174
|
-
* Move a configuration to the trash — or
|
|
1175
|
-
*
|
|
1176
|
-
* prefer `purgeConfiguration` when the permanent removal is the intent.
|
|
1063
|
+
* Move a configuration to the trash — or purge it if it is already trashed.
|
|
1064
|
+
* Prefer `purgeConfiguration` when permanent removal is the intent.
|
|
1177
1065
|
*/
|
|
1178
1066
|
const deleteConfiguration = async ({ branchId, componentId, configId, expectedVersion }) => {
|
|
1179
1067
|
await client.delete("/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}", { path: {
|
|
@@ -1184,9 +1072,9 @@ const createConfigurations = (client) => {
|
|
|
1184
1072
|
};
|
|
1185
1073
|
/**
|
|
1186
1074
|
* Permanently remove a trashed configuration, including its versions, rows and metadata.
|
|
1187
|
-
*
|
|
1188
|
-
* live configuration is rejected (400 `notInTrash`)
|
|
1189
|
-
* only
|
|
1075
|
+
*
|
|
1076
|
+
* - Purging a live configuration is rejected (400 `notInTrash`), never soft-deleted.
|
|
1077
|
+
* - Default branch only; the token needs `canPurgeTrash`.
|
|
1190
1078
|
*/
|
|
1191
1079
|
const purgeConfiguration = async ({ branchId, componentId, configId, expectedVersion }) => {
|
|
1192
1080
|
await client.post("/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}/purge", { path: {
|
|
@@ -1196,13 +1084,10 @@ const createConfigurations = (client) => {
|
|
|
1196
1084
|
} }, { headers: { ...createVersionPrecondition(expectedVersion) } });
|
|
1197
1085
|
};
|
|
1198
1086
|
/**
|
|
1199
|
-
* Purge configurations across components in one bounded fan-out.
|
|
1200
|
-
* it stops at the first rejection, and here that is a case to plan for rather than an edge: a
|
|
1201
|
-
* stale `expectedVersion` (412) abandons the rest of the queue, so re-read the trash before
|
|
1202
|
-
* offering another attempt.
|
|
1087
|
+
* Purge configurations across components in one bounded fan-out.
|
|
1203
1088
|
*
|
|
1204
|
-
*
|
|
1205
|
-
*
|
|
1089
|
+
* - Stops at the first rejection: a stale `expectedVersion` (412) abandons the rest of the queue,
|
|
1090
|
+
* so re-read the trash before retrying.
|
|
1206
1091
|
*/
|
|
1207
1092
|
const purgeConfigurations = async ({ branchId, configs }) => {
|
|
1208
1093
|
await concurrent({
|
|
@@ -1214,7 +1099,6 @@ const createConfigurations = (client) => {
|
|
|
1214
1099
|
})
|
|
1215
1100
|
});
|
|
1216
1101
|
};
|
|
1217
|
-
/** Restore a trashed configuration. */
|
|
1218
1102
|
const restoreConfiguration = async ({ branchId, componentId, configId }) => {
|
|
1219
1103
|
const { data } = await client.post("/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}/restore", { path: {
|
|
1220
1104
|
branchId,
|
|
@@ -1226,12 +1110,8 @@ const createConfigurations = (client) => {
|
|
|
1226
1110
|
/**
|
|
1227
1111
|
* Reset a dev-branch configuration back to its default-branch (production) version.
|
|
1228
1112
|
*
|
|
1229
|
-
*
|
|
1230
|
-
*
|
|
1231
|
-
* resolving to the configuration, so every caller reading a field off the result was reading
|
|
1232
|
-
* `undefined`. Re-read the configuration to observe the reset.
|
|
1233
|
-
*
|
|
1234
|
-
* Dev-branch only — the API answers 501 on `default`.
|
|
1113
|
+
* - Resolves with an empty body; re-read the configuration to observe the reset.
|
|
1114
|
+
* - Dev-branch only — the API answers 501 on `default`.
|
|
1235
1115
|
*/
|
|
1236
1116
|
const resetConfigurationToDefault = async ({ branchId, componentId, configId }) => {
|
|
1237
1117
|
await client.post("/v2/storage/branch/{branchId}/components/{componentId}/configs/{configurationId}/reset-to-default", { path: {
|
|
@@ -1667,18 +1547,11 @@ const createRefreshTokenMiddlware = ({ accessToken, onRefresh }) => {
|
|
|
1667
1547
|
//#endregion
|
|
1668
1548
|
//#region src/clients/storage/search/search.ts
|
|
1669
1549
|
/**
|
|
1670
|
-
*
|
|
1550
|
+
* Search endpoints.
|
|
1671
1551
|
*
|
|
1672
|
-
* -
|
|
1673
|
-
*
|
|
1674
|
-
*
|
|
1675
|
-
* `Table[]`
|
|
1676
|
-
*
|
|
1677
|
-
* Both query casts are type-only, so each query object reaches the wire exactly as the caller wrote
|
|
1678
|
-
* it. That matters for `global-search`: the spec names its repeatable filters `types[]` / `projectIds[]`
|
|
1679
|
-
* / `branchTypes[]` / `branchIds[]`, but this endpoint has always been called with the bare names,
|
|
1680
|
-
* which `qs` serializes as `types[0]=bucket&types[1]=table` — also an array to the backend. Renaming
|
|
1681
|
-
* the fields to satisfy the document would change what Storage receives, and no test would catch it.
|
|
1552
|
+
* - Both responses are asserted in: the spec stubs them.
|
|
1553
|
+
* - Query casts are type-only: `global-search` filters go out with bare names (`types`, not
|
|
1554
|
+
* `types[]`); renaming them to match the spec would change what Storage receives.
|
|
1682
1555
|
*/
|
|
1683
1556
|
const createSearch = (client) => {
|
|
1684
1557
|
/**
|
|
@@ -1728,8 +1601,7 @@ const createSnapshots = (client) => {
|
|
|
1728
1601
|
/**
|
|
1729
1602
|
* Reads a single snapshot. Not branch-scoped — a snapshot id is unique across branches.
|
|
1730
1603
|
*
|
|
1731
|
-
*
|
|
1732
|
-
* `created`, so the shape is still asserted in. It is the same `Snapshot` the table listing returns.
|
|
1604
|
+
* Asserted in: the spec names the timestamp `createdTime`, the API returns `created`.
|
|
1733
1605
|
*
|
|
1734
1606
|
* @link https://api.keboola.com/?service=storage#storage/GET/v2/storage/snapshots/{snapshotId}
|
|
1735
1607
|
*/
|
|
@@ -1738,13 +1610,9 @@ const createSnapshots = (client) => {
|
|
|
1738
1610
|
return data;
|
|
1739
1611
|
};
|
|
1740
1612
|
/**
|
|
1741
|
-
* Deletes a snapshot
|
|
1742
|
-
* with no content). The endpoint is not branch-scoped — a snapshot id is unique across branches, so
|
|
1743
|
-
* there is no `/branch/{branchId}/snapshots/{snapshotId}` variant.
|
|
1613
|
+
* Deletes a snapshot; returns its storage job, or `null` on no content. Not branch-scoped.
|
|
1744
1614
|
*
|
|
1745
|
-
*
|
|
1746
|
-
* discriminated union over `status`, and says nothing about the no-content answer, so both are
|
|
1747
|
-
* asserted in.
|
|
1615
|
+
* Asserted in: the spec's flat `JobResponse` is not the discriminated `Job`, and omits no-content.
|
|
1748
1616
|
*
|
|
1749
1617
|
* @link https://api.keboola.com/?service=storage#storage/DELETE/v2/storage/snapshots/{snapshotId}
|
|
1750
1618
|
*/
|
|
@@ -1797,10 +1665,8 @@ const createStats = (client) => {
|
|
|
1797
1665
|
//#region src/clients/storage/tables/tables.ts
|
|
1798
1666
|
const createTables = (client, genericClient) => {
|
|
1799
1667
|
/**
|
|
1800
|
-
* Returns every table in the given branch. Filter client-side
|
|
1801
|
-
*
|
|
1802
|
-
* `{bucketId}.` prefix in `table.id` (IDs use `{bucketId}.{tableName}`,
|
|
1803
|
-
* e.g. `in.c-main.users`).
|
|
1668
|
+
* Returns every table in the given branch. Filter by bucket client-side: `table.bucket?.id`
|
|
1669
|
+
* (needs `include: ['buckets']`) or the `{bucketId}.` prefix of `table.id`.
|
|
1804
1670
|
*
|
|
1805
1671
|
* @link https://api.keboola.com/?service=storage#storage/GET/v2/storage/branch/{branchId}/tables
|
|
1806
1672
|
*/
|
|
@@ -1868,9 +1734,7 @@ const createTables = (client, genericClient) => {
|
|
|
1868
1734
|
/**
|
|
1869
1735
|
* Returns the first rows of a table in the given branch.
|
|
1870
1736
|
*
|
|
1871
|
-
* The
|
|
1872
|
-
* `orderBy` / `fulltextSearch`, all of which the endpoint accepts — hence the hand-authored
|
|
1873
|
-
* `GetDataPreviewQuery` and the asserted query.
|
|
1737
|
+
* The spec declares `query?: never`, so the query is the hand-written `GetDataPreviewQuery`.
|
|
1874
1738
|
*
|
|
1875
1739
|
* @link https://api.keboola.com/?service=storage#storage/tag/tables/GET/v2/storage/branch/{branchId}/tables/{tableId}/data-preview
|
|
1876
1740
|
*/
|
|
@@ -1890,11 +1754,7 @@ const createTables = (client, genericClient) => {
|
|
|
1890
1754
|
/**
|
|
1891
1755
|
* Exports a table to a file. Async — returns a job.
|
|
1892
1756
|
*
|
|
1893
|
-
* Unbranched, though
|
|
1894
|
-
* `/v2/storage/branch/{branchId}/tables/{tableId}/export-async`: export was outside the scope of
|
|
1895
|
-
* the table migration (UT-4785), so switching it would change behaviour for a flow that migration
|
|
1896
|
-
* did not touch. It is the one remaining branch-capable method here that does not take a
|
|
1897
|
-
* `branchId`, and moving it is a clean follow-up.
|
|
1757
|
+
* Unbranched, though a branch-scoped `export-async` exists.
|
|
1898
1758
|
*
|
|
1899
1759
|
* @link https://api.keboola.com/?service=storage#storage/tag/tables/POST/v2/storage/tables/{tableId}/export-async
|
|
1900
1760
|
*/
|
|
@@ -1917,7 +1777,7 @@ const createTables = (client, genericClient) => {
|
|
|
1917
1777
|
};
|
|
1918
1778
|
/**
|
|
1919
1779
|
* Creates a typed table from an explicit column definition (no data) in the given bucket.
|
|
1920
|
-
*
|
|
1780
|
+
* Async — returns a `tableDefinitionCreate` job.
|
|
1921
1781
|
*
|
|
1922
1782
|
* @link https://api.keboola.com/?service=storage#storage/tag/buckets/POST/v2/storage/branch/{branchId}/buckets/{bucketId}/tables-definition
|
|
1923
1783
|
*/
|
|
@@ -1942,14 +1802,10 @@ const createTables = (client, genericClient) => {
|
|
|
1942
1802
|
return data;
|
|
1943
1803
|
};
|
|
1944
1804
|
/**
|
|
1945
|
-
* Updates a table's definition in place — `
|
|
1946
|
-
* `isDescriptionSystemManaged`, and per-column
|
|
1947
|
-
* `length`/`nullable`/`default`/`description`. The endpoint is async: it
|
|
1948
|
-
* returns a `tableDefinitionUpdate` storage job that the caller can poll.
|
|
1805
|
+
* Updates a table's definition in place. Async — returns a `tableDefinitionUpdate` job.
|
|
1949
1806
|
*
|
|
1950
|
-
* Send only the fields
|
|
1951
|
-
* patches
|
|
1952
|
-
* neither `displayName` nor `columns`.
|
|
1807
|
+
* - Send only the changed fields; at least one is required.
|
|
1808
|
+
* - Description patches work on non-typed tables too.
|
|
1953
1809
|
*
|
|
1954
1810
|
* @link https://api.keboola.com/?service=storage#storage/tag/tables/PUT/v2/storage/branch/{branchId}/tables/{tableId}/definition
|
|
1955
1811
|
*/
|
|
@@ -1964,20 +1820,11 @@ const createTables = (client, genericClient) => {
|
|
|
1964
1820
|
return data;
|
|
1965
1821
|
};
|
|
1966
1822
|
/**
|
|
1967
|
-
* Updates a table's display name (synchronous).
|
|
1968
|
-
* `updateTableDefinition` instead.
|
|
1969
|
-
*
|
|
1970
|
-
* On the generic client and unbranched, unlike its siblings — but only because of where the
|
|
1971
|
-
* endpoint lives, not because of what it supports. It is still `Storage_TablesController::putAction`
|
|
1972
|
-
* in connection's legacy Zend app, and the Storage document is generated from the `#[OA\...]`
|
|
1973
|
-
* attributes on the migrated Symfony controllers, so no annotation fix closes this gap; the
|
|
1974
|
-
* controller has to move first. The action does take a `DevBranch`, and `put` is in the
|
|
1975
|
-
* branch-implemented route list, so `/branch/{branchId}/tables/{id}` works — there is simply no
|
|
1976
|
-
* `paths` entry to derive it from, and the branch prefix is left to the caller's middleware.
|
|
1823
|
+
* Updates a table's display name (synchronous). Use `updateTableDefinition` for typed tables.
|
|
1977
1824
|
*
|
|
1978
|
-
*
|
|
1979
|
-
*
|
|
1980
|
-
*
|
|
1825
|
+
* - Generic client, unbranched: the spec has no path for it; the caller's middleware adds the
|
|
1826
|
+
* branch prefix.
|
|
1827
|
+
* - The synchronous form is deprecated backend-side; `?async=true` returns a `tableUpdate` job.
|
|
1981
1828
|
*
|
|
1982
1829
|
* @link https://api.keboola.com/?service=storage#storage/tag/tables
|
|
1983
1830
|
*/
|
|
@@ -1991,9 +1838,7 @@ const createTables = (client, genericClient) => {
|
|
|
1991
1838
|
/**
|
|
1992
1839
|
* Pulls a table from the default branch into the given dev branch.
|
|
1993
1840
|
*
|
|
1994
|
-
*
|
|
1995
|
-
* absent from the Storage document and 404s for every table (the live nightly caught it), because
|
|
1996
|
-
* nothing in it says which branch to pull into.
|
|
1841
|
+
* Branch-scoped: the unbranched `/v2/storage/tables/{id}/pull` 404s.
|
|
1997
1842
|
*
|
|
1998
1843
|
* @link https://api.keboola.com/?service=storage#storage/tag/tables
|
|
1999
1844
|
*/
|
|
@@ -2231,16 +2076,12 @@ const createTriggers = (client) => {
|
|
|
2231
2076
|
//#endregion
|
|
2232
2077
|
//#region src/clients/storage/workspaces/workspaces.ts
|
|
2233
2078
|
/**
|
|
2234
|
-
* Paths, queries and bodies come from the spec; only the returns are asserted
|
|
2079
|
+
* Paths, queries and bodies come from the spec; only the returns are asserted.
|
|
2235
2080
|
*
|
|
2236
|
-
* - `
|
|
2237
|
-
* hand-authored (see `./types`) — that covers the list, detail and public-key returns.
|
|
2081
|
+
* - `Workspace` is corrected in `./types`: the spec's connection is narrower than callers get.
|
|
2238
2082
|
* - The password, SSO and delete operations answer a contentless `default`.
|
|
2239
|
-
* - `
|
|
2240
|
-
*
|
|
2241
|
-
*
|
|
2242
|
-
* `workspaceId` is a `number` in every input; the operations whose spec segment is a `string` take
|
|
2243
|
-
* `String(workspaceId)` here rather than pushing the spec's inconsistency onto callers.
|
|
2083
|
+
* - `Job<T>` is a union over `status` with typed `results`; the spec's `JobResponse` is flat.
|
|
2084
|
+
* - `workspaceId` is a `number` in every input, stringified where the spec wants a string.
|
|
2244
2085
|
*/
|
|
2245
2086
|
const createWorkspaces = (client) => {
|
|
2246
2087
|
const getWorkspaces = async (path, signal) => {
|
|
@@ -2289,9 +2130,7 @@ const createWorkspaces = (client) => {
|
|
|
2289
2130
|
return data;
|
|
2290
2131
|
};
|
|
2291
2132
|
/**
|
|
2292
|
-
*
|
|
2293
|
-
* Supported only on Snowflake.
|
|
2294
|
-
* When called, either a new key is created, or the older one is replaced.
|
|
2133
|
+
* Sets or replaces the workspace user's public key, migrating off password auth. Snowflake only.
|
|
2295
2134
|
*/
|
|
2296
2135
|
const setWorkspacePublicKey = async ({ branchId, workspaceId, ...body }) => {
|
|
2297
2136
|
const { data } = await client.post("/v2/storage/branch/{branchId}/workspaces/{workspaceId}/public-key", {
|
|
@@ -2328,10 +2167,9 @@ const createWorkspaces = (client) => {
|
|
|
2328
2167
|
return data;
|
|
2329
2168
|
};
|
|
2330
2169
|
/**
|
|
2331
|
-
*
|
|
2332
|
-
*
|
|
2333
|
-
*
|
|
2334
|
-
* `backend` argument, then the project default.
|
|
2170
|
+
* Previews the resolved load types for an input-mapping config, without a workspace or job.
|
|
2171
|
+
*
|
|
2172
|
+
* - Backend order: the item's `backend`, then the `backend` argument, then the project default.
|
|
2335
2173
|
*/
|
|
2336
2174
|
const inputMappingLoadPreview = async ({ branchId, body, backend }, signal) => {
|
|
2337
2175
|
const { data } = await client.post("/v2/storage/branch/{branchId}/input-mapping-load/preview", {
|
|
@@ -2416,6 +2254,6 @@ const createStorageClient = ({ baseUrl, auth, middlewares = [], onRefreshToken }
|
|
|
2416
2254
|
};
|
|
2417
2255
|
};
|
|
2418
2256
|
//#endregion
|
|
2419
|
-
export {
|
|
2257
|
+
export { readableReason as a, ServiceUnavailableError as i, fromBackendSubscribers as n, series as o, toBackendSubscribers as r, createStorageClient as t };
|
|
2420
2258
|
|
|
2421
|
-
//# sourceMappingURL=storage-
|
|
2259
|
+
//# sourceMappingURL=storage-CZQHZcXG.js.map
|