@distilled.cloud/axiom 0.0.0 → 0.12.7
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/README.md +61 -6
- package/lib/category.d.ts +5 -0
- package/lib/category.d.ts.map +1 -0
- package/lib/category.js +5 -0
- package/lib/category.js.map +1 -0
- package/lib/client.d.ts +10 -0
- package/lib/client.d.ts.map +1 -0
- package/lib/client.js +102 -0
- package/lib/client.js.map +1 -0
- package/lib/credentials.d.ts +30 -0
- package/lib/credentials.d.ts.map +1 -0
- package/lib/credentials.js +31 -0
- package/lib/credentials.js.map +1 -0
- package/lib/errors.d.ts +31 -0
- package/lib/errors.d.ts.map +1 -0
- package/lib/errors.js +23 -0
- package/lib/errors.js.map +1 -0
- package/lib/index.d.ts +16 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +16 -0
- package/lib/index.js.map +1 -0
- package/lib/operations/index.d.ts +4 -0
- package/lib/operations/index.d.ts.map +1 -0
- package/lib/operations/index.js +4 -0
- package/lib/operations/index.js.map +1 -0
- package/lib/operations/v1-edge-ingest/index.d.ts +2 -0
- package/lib/operations/v1-edge-ingest/index.d.ts.map +1 -0
- package/lib/operations/v1-edge-ingest/index.js +2 -0
- package/lib/operations/v1-edge-ingest/index.js.map +1 -0
- package/lib/operations/v1-edge-ingest/ingestToDataset.d.ts +46 -0
- package/lib/operations/v1-edge-ingest/ingestToDataset.d.ts.map +1 -0
- package/lib/operations/v1-edge-ingest/ingestToDataset.js +38 -0
- package/lib/operations/v1-edge-ingest/ingestToDataset.js.map +1 -0
- package/lib/operations/v1-edge-query/index.d.ts +2 -0
- package/lib/operations/v1-edge-query/index.d.ts.map +1 -0
- package/lib/operations/v1-edge-query/index.js +2 -0
- package/lib/operations/v1-edge-query/index.js.map +1 -0
- package/lib/operations/v1-edge-query/queryApl.d.ts +124 -0
- package/lib/operations/v1-edge-query/queryApl.d.ts.map +1 -0
- package/lib/operations/v1-edge-query/queryApl.js +74 -0
- package/lib/operations/v1-edge-query/queryApl.js.map +1 -0
- package/lib/operations/v2/createAPIToken.d.ts +165 -0
- package/lib/operations/v2/createAPIToken.d.ts.map +1 -0
- package/lib/operations/v2/createAPIToken.js +91 -0
- package/lib/operations/v2/createAPIToken.js.map +1 -0
- package/lib/operations/v2/createAnnotation.d.ts +45 -0
- package/lib/operations/v2/createAnnotation.d.ts.map +1 -0
- package/lib/operations/v2/createAnnotation.js +35 -0
- package/lib/operations/v2/createAnnotation.js.map +1 -0
- package/lib/operations/v2/createDashboard.d.ts +147 -0
- package/lib/operations/v2/createDashboard.d.ts.map +1 -0
- package/lib/operations/v2/createDashboard.js +115 -0
- package/lib/operations/v2/createDashboard.js.map +1 -0
- package/lib/operations/v2/createDataset.d.ts +55 -0
- package/lib/operations/v2/createDataset.d.ts.map +1 -0
- package/lib/operations/v2/createDataset.js +51 -0
- package/lib/operations/v2/createDataset.js.map +1 -0
- package/lib/operations/v2/createGroup.d.ts +39 -0
- package/lib/operations/v2/createGroup.d.ts.map +1 -0
- package/lib/operations/v2/createGroup.js +33 -0
- package/lib/operations/v2/createGroup.js.map +1 -0
- package/lib/operations/v2/createMapField.d.ts +18 -0
- package/lib/operations/v2/createMapField.d.ts.map +1 -0
- package/lib/operations/v2/createMapField.js +20 -0
- package/lib/operations/v2/createMapField.js.map +1 -0
- package/lib/operations/v2/createMonitor.d.ts +117 -0
- package/lib/operations/v2/createMonitor.d.ts.map +1 -0
- package/lib/operations/v2/createMonitor.js +83 -0
- package/lib/operations/v2/createMonitor.js.map +1 -0
- package/lib/operations/v2/createNotifier.d.ts +181 -0
- package/lib/operations/v2/createNotifier.d.ts.map +1 -0
- package/lib/operations/v2/createNotifier.js +100 -0
- package/lib/operations/v2/createNotifier.js.map +1 -0
- package/lib/operations/v2/createOrg.d.ts +101 -0
- package/lib/operations/v2/createOrg.d.ts.map +1 -0
- package/lib/operations/v2/createOrg.js +77 -0
- package/lib/operations/v2/createOrg.js.map +1 -0
- package/lib/operations/v2/createRole.d.ts +163 -0
- package/lib/operations/v2/createRole.d.ts.map +1 -0
- package/lib/operations/v2/createRole.js +91 -0
- package/lib/operations/v2/createRole.js.map +1 -0
- package/lib/operations/v2/createStarred.d.ts +166 -0
- package/lib/operations/v2/createStarred.d.ts.map +1 -0
- package/lib/operations/v2/createStarred.js +102 -0
- package/lib/operations/v2/createStarred.js.map +1 -0
- package/lib/operations/v2/createUser.d.ts +35 -0
- package/lib/operations/v2/createUser.d.ts.map +1 -0
- package/lib/operations/v2/createUser.js +30 -0
- package/lib/operations/v2/createUser.js.map +1 -0
- package/lib/operations/v2/createView.d.ts +36 -0
- package/lib/operations/v2/createView.d.ts.map +1 -0
- package/lib/operations/v2/createView.js +29 -0
- package/lib/operations/v2/createView.js.map +1 -0
- package/lib/operations/v2/createVirtualField.d.ts +38 -0
- package/lib/operations/v2/createVirtualField.d.ts.map +1 -0
- package/lib/operations/v2/createVirtualField.js +32 -0
- package/lib/operations/v2/createVirtualField.js.map +1 -0
- package/lib/operations/v2/deleteAPIToken.d.ts +15 -0
- package/lib/operations/v2/deleteAPIToken.d.ts.map +1 -0
- package/lib/operations/v2/deleteAPIToken.js +20 -0
- package/lib/operations/v2/deleteAPIToken.js.map +1 -0
- package/lib/operations/v2/deleteAnnotation.d.ts +17 -0
- package/lib/operations/v2/deleteAnnotation.d.ts.map +1 -0
- package/lib/operations/v2/deleteAnnotation.js +22 -0
- package/lib/operations/v2/deleteAnnotation.js.map +1 -0
- package/lib/operations/v2/deleteDashboard.d.ts +17 -0
- package/lib/operations/v2/deleteDashboard.d.ts.map +1 -0
- package/lib/operations/v2/deleteDashboard.js +22 -0
- package/lib/operations/v2/deleteDashboard.js.map +1 -0
- package/lib/operations/v2/deleteDataset.d.ts +15 -0
- package/lib/operations/v2/deleteDataset.d.ts.map +1 -0
- package/lib/operations/v2/deleteDataset.js +20 -0
- package/lib/operations/v2/deleteDataset.js.map +1 -0
- package/lib/operations/v2/deleteGroup.d.ts +19 -0
- package/lib/operations/v2/deleteGroup.d.ts.map +1 -0
- package/lib/operations/v2/deleteGroup.js +24 -0
- package/lib/operations/v2/deleteGroup.js.map +1 -0
- package/lib/operations/v2/deleteMapField.d.ts +14 -0
- package/lib/operations/v2/deleteMapField.d.ts.map +1 -0
- package/lib/operations/v2/deleteMapField.js +21 -0
- package/lib/operations/v2/deleteMapField.js.map +1 -0
- package/lib/operations/v2/deleteMonitor.d.ts +15 -0
- package/lib/operations/v2/deleteMonitor.d.ts.map +1 -0
- package/lib/operations/v2/deleteMonitor.js +20 -0
- package/lib/operations/v2/deleteMonitor.js.map +1 -0
- package/lib/operations/v2/deleteNotifier.d.ts +15 -0
- package/lib/operations/v2/deleteNotifier.d.ts.map +1 -0
- package/lib/operations/v2/deleteNotifier.js +20 -0
- package/lib/operations/v2/deleteNotifier.js.map +1 -0
- package/lib/operations/v2/deleteRole.d.ts +19 -0
- package/lib/operations/v2/deleteRole.d.ts.map +1 -0
- package/lib/operations/v2/deleteRole.js +24 -0
- package/lib/operations/v2/deleteRole.js.map +1 -0
- package/lib/operations/v2/deleteStarred.d.ts +12 -0
- package/lib/operations/v2/deleteStarred.d.ts.map +1 -0
- package/lib/operations/v2/deleteStarred.js +17 -0
- package/lib/operations/v2/deleteStarred.js.map +1 -0
- package/lib/operations/v2/deleteView.d.ts +12 -0
- package/lib/operations/v2/deleteView.d.ts.map +1 -0
- package/lib/operations/v2/deleteView.js +17 -0
- package/lib/operations/v2/deleteView.js.map +1 -0
- package/lib/operations/v2/deleteVirtualField.d.ts +12 -0
- package/lib/operations/v2/deleteVirtualField.d.ts.map +1 -0
- package/lib/operations/v2/deleteVirtualField.js +18 -0
- package/lib/operations/v2/deleteVirtualField.js.map +1 -0
- package/lib/operations/v2/getAPIToken.d.ts +93 -0
- package/lib/operations/v2/getAPIToken.d.ts.map +1 -0
- package/lib/operations/v2/getAPIToken.js +57 -0
- package/lib/operations/v2/getAPIToken.js.map +1 -0
- package/lib/operations/v2/getAPITokens.d.ts +88 -0
- package/lib/operations/v2/getAPITokens.d.ts.map +1 -0
- package/lib/operations/v2/getAPITokens.js +53 -0
- package/lib/operations/v2/getAPITokens.js.map +1 -0
- package/lib/operations/v2/getAnnotation.d.ts +35 -0
- package/lib/operations/v2/getAnnotation.d.ts.map +1 -0
- package/lib/operations/v2/getAnnotation.js +31 -0
- package/lib/operations/v2/getAnnotation.js.map +1 -0
- package/lib/operations/v2/getAnnotations.d.ts +40 -0
- package/lib/operations/v2/getAnnotations.d.ts.map +1 -0
- package/lib/operations/v2/getAnnotations.js +33 -0
- package/lib/operations/v2/getAnnotations.js.map +1 -0
- package/lib/operations/v2/getCurrentUser.d.ts +26 -0
- package/lib/operations/v2/getCurrentUser.d.ts.map +1 -0
- package/lib/operations/v2/getCurrentUser.js +24 -0
- package/lib/operations/v2/getCurrentUser.js.map +1 -0
- package/lib/operations/v2/getDashboard.d.ts +83 -0
- package/lib/operations/v2/getDashboard.d.ts.map +1 -0
- package/lib/operations/v2/getDashboard.js +69 -0
- package/lib/operations/v2/getDashboard.js.map +1 -0
- package/lib/operations/v2/getDataset.d.ts +41 -0
- package/lib/operations/v2/getDataset.d.ts.map +1 -0
- package/lib/operations/v2/getDataset.js +38 -0
- package/lib/operations/v2/getDataset.js.map +1 -0
- package/lib/operations/v2/getDatasets.d.ts +37 -0
- package/lib/operations/v2/getDatasets.d.ts.map +1 -0
- package/lib/operations/v2/getDatasets.js +36 -0
- package/lib/operations/v2/getDatasets.js.map +1 -0
- package/lib/operations/v2/getFieldForDataset.d.ts +26 -0
- package/lib/operations/v2/getFieldForDataset.d.ts.map +1 -0
- package/lib/operations/v2/getFieldForDataset.js +29 -0
- package/lib/operations/v2/getFieldForDataset.js.map +1 -0
- package/lib/operations/v2/getFieldsForDataset.d.ts +24 -0
- package/lib/operations/v2/getFieldsForDataset.d.ts.map +1 -0
- package/lib/operations/v2/getFieldsForDataset.js +25 -0
- package/lib/operations/v2/getFieldsForDataset.js.map +1 -0
- package/lib/operations/v2/getGroupById.d.ts +33 -0
- package/lib/operations/v2/getGroupById.d.ts.map +1 -0
- package/lib/operations/v2/getGroupById.js +31 -0
- package/lib/operations/v2/getGroupById.js.map +1 -0
- package/lib/operations/v2/getMapFields.d.ts +12 -0
- package/lib/operations/v2/getMapFields.d.ts.map +1 -0
- package/lib/operations/v2/getMapFields.js +17 -0
- package/lib/operations/v2/getMapFields.js.map +1 -0
- package/lib/operations/v2/getMonitor.d.ts +71 -0
- package/lib/operations/v2/getMonitor.d.ts.map +1 -0
- package/lib/operations/v2/getMonitor.js +55 -0
- package/lib/operations/v2/getMonitor.js.map +1 -0
- package/lib/operations/v2/getMonitorHistory.d.ts +32 -0
- package/lib/operations/v2/getMonitorHistory.d.ts.map +1 -0
- package/lib/operations/v2/getMonitorHistory.js +30 -0
- package/lib/operations/v2/getMonitorHistory.js.map +1 -0
- package/lib/operations/v2/getMonitors.d.ts +64 -0
- package/lib/operations/v2/getMonitors.d.ts.map +1 -0
- package/lib/operations/v2/getMonitors.js +49 -0
- package/lib/operations/v2/getMonitors.js.map +1 -0
- package/lib/operations/v2/getNotifier.d.ts +103 -0
- package/lib/operations/v2/getNotifier.d.ts.map +1 -0
- package/lib/operations/v2/getNotifier.js +64 -0
- package/lib/operations/v2/getNotifier.js.map +1 -0
- package/lib/operations/v2/getNotifiers.d.ts +96 -0
- package/lib/operations/v2/getNotifiers.d.ts.map +1 -0
- package/lib/operations/v2/getNotifiers.js +58 -0
- package/lib/operations/v2/getNotifiers.js.map +1 -0
- package/lib/operations/v2/getOrg.d.ts +100 -0
- package/lib/operations/v2/getOrg.d.ts.map +1 -0
- package/lib/operations/v2/getOrg.js +78 -0
- package/lib/operations/v2/getOrg.js.map +1 -0
- package/lib/operations/v2/getOrgs.d.ts +95 -0
- package/lib/operations/v2/getOrgs.d.ts.map +1 -0
- package/lib/operations/v2/getOrgs.js +74 -0
- package/lib/operations/v2/getOrgs.js.map +1 -0
- package/lib/operations/v2/getRoleById.d.ts +95 -0
- package/lib/operations/v2/getRoleById.d.ts.map +1 -0
- package/lib/operations/v2/getRoleById.js +60 -0
- package/lib/operations/v2/getRoleById.js.map +1 -0
- package/lib/operations/v2/getStarred.d.ts +92 -0
- package/lib/operations/v2/getStarred.d.ts.map +1 -0
- package/lib/operations/v2/getStarred.js +61 -0
- package/lib/operations/v2/getStarred.js.map +1 -0
- package/lib/operations/v2/getStarredQueries.d.ts +106 -0
- package/lib/operations/v2/getStarredQueries.d.ts.map +1 -0
- package/lib/operations/v2/getStarredQueries.js +70 -0
- package/lib/operations/v2/getStarredQueries.js.map +1 -0
- package/lib/operations/v2/getUser.d.ts +31 -0
- package/lib/operations/v2/getUser.d.ts.map +1 -0
- package/lib/operations/v2/getUser.js +28 -0
- package/lib/operations/v2/getUser.js.map +1 -0
- package/lib/operations/v2/getUsers.d.ts +26 -0
- package/lib/operations/v2/getUsers.d.ts.map +1 -0
- package/lib/operations/v2/getUsers.js +24 -0
- package/lib/operations/v2/getUsers.js.map +1 -0
- package/lib/operations/v2/getView.d.ts +26 -0
- package/lib/operations/v2/getView.d.ts.map +1 -0
- package/lib/operations/v2/getView.js +24 -0
- package/lib/operations/v2/getView.js.map +1 -0
- package/lib/operations/v2/getViews.d.ts +21 -0
- package/lib/operations/v2/getViews.d.ts.map +1 -0
- package/lib/operations/v2/getViews.js +20 -0
- package/lib/operations/v2/getViews.js.map +1 -0
- package/lib/operations/v2/getVirtualField.d.ts +28 -0
- package/lib/operations/v2/getVirtualField.d.ts.map +1 -0
- package/lib/operations/v2/getVirtualField.js +25 -0
- package/lib/operations/v2/getVirtualField.js.map +1 -0
- package/lib/operations/v2/getVirtualFields.d.ts +27 -0
- package/lib/operations/v2/getVirtualFields.d.ts.map +1 -0
- package/lib/operations/v2/getVirtualFields.js +23 -0
- package/lib/operations/v2/getVirtualFields.js.map +1 -0
- package/lib/operations/v2/index.d.ts +77 -0
- package/lib/operations/v2/index.d.ts.map +1 -0
- package/lib/operations/v2/index.js +77 -0
- package/lib/operations/v2/index.js.map +1 -0
- package/lib/operations/v2/listDashboards.d.ts +84 -0
- package/lib/operations/v2/listDashboards.d.ts.map +1 -0
- package/lib/operations/v2/listDashboards.js +68 -0
- package/lib/operations/v2/listDashboards.js.map +1 -0
- package/lib/operations/v2/listGroups.d.ts +26 -0
- package/lib/operations/v2/listGroups.d.ts.map +1 -0
- package/lib/operations/v2/listGroups.js +25 -0
- package/lib/operations/v2/listGroups.js.map +1 -0
- package/lib/operations/v2/listRoles.d.ts +88 -0
- package/lib/operations/v2/listRoles.d.ts.map +1 -0
- package/lib/operations/v2/listRoles.js +54 -0
- package/lib/operations/v2/listRoles.js.map +1 -0
- package/lib/operations/v2/regenerateAPIToken.d.ts +175 -0
- package/lib/operations/v2/regenerateAPIToken.d.ts.map +1 -0
- package/lib/operations/v2/regenerateAPIToken.js +98 -0
- package/lib/operations/v2/regenerateAPIToken.js.map +1 -0
- package/lib/operations/v2/removeUserFromOrg.d.ts +15 -0
- package/lib/operations/v2/removeUserFromOrg.d.ts.map +1 -0
- package/lib/operations/v2/removeUserFromOrg.js +20 -0
- package/lib/operations/v2/removeUserFromOrg.js.map +1 -0
- package/lib/operations/v2/trimDataset.d.ts +19 -0
- package/lib/operations/v2/trimDataset.d.ts.map +1 -0
- package/lib/operations/v2/trimDataset.js +23 -0
- package/lib/operations/v2/trimDataset.js.map +1 -0
- package/lib/operations/v2/updateAnnotation.d.ts +49 -0
- package/lib/operations/v2/updateAnnotation.d.ts.map +1 -0
- package/lib/operations/v2/updateAnnotation.js +38 -0
- package/lib/operations/v2/updateAnnotation.js.map +1 -0
- package/lib/operations/v2/updateCurrentUser.d.ts +30 -0
- package/lib/operations/v2/updateCurrentUser.d.ts.map +1 -0
- package/lib/operations/v2/updateCurrentUser.js +27 -0
- package/lib/operations/v2/updateCurrentUser.js.map +1 -0
- package/lib/operations/v2/updateDashboard.d.ts +147 -0
- package/lib/operations/v2/updateDashboard.d.ts.map +1 -0
- package/lib/operations/v2/updateDashboard.js +115 -0
- package/lib/operations/v2/updateDashboard.js.map +1 -0
- package/lib/operations/v2/updateDataset.d.ts +47 -0
- package/lib/operations/v2/updateDataset.d.ts.map +1 -0
- package/lib/operations/v2/updateDataset.js +41 -0
- package/lib/operations/v2/updateDataset.js.map +1 -0
- package/lib/operations/v2/updateFieldForDataset.d.ts +36 -0
- package/lib/operations/v2/updateFieldForDataset.d.ts.map +1 -0
- package/lib/operations/v2/updateFieldForDataset.js +34 -0
- package/lib/operations/v2/updateFieldForDataset.js.map +1 -0
- package/lib/operations/v2/updateGroup.d.ts +43 -0
- package/lib/operations/v2/updateGroup.d.ts.map +1 -0
- package/lib/operations/v2/updateGroup.js +36 -0
- package/lib/operations/v2/updateGroup.js.map +1 -0
- package/lib/operations/v2/updateMapFields.d.ts +12 -0
- package/lib/operations/v2/updateMapFields.d.ts.map +1 -0
- package/lib/operations/v2/updateMapFields.js +17 -0
- package/lib/operations/v2/updateMapFields.js.map +1 -0
- package/lib/operations/v2/updateMonitor.d.ts +119 -0
- package/lib/operations/v2/updateMonitor.d.ts.map +1 -0
- package/lib/operations/v2/updateMonitor.js +84 -0
- package/lib/operations/v2/updateMonitor.js.map +1 -0
- package/lib/operations/v2/updateNotifier.d.ts +183 -0
- package/lib/operations/v2/updateNotifier.d.ts.map +1 -0
- package/lib/operations/v2/updateNotifier.js +101 -0
- package/lib/operations/v2/updateNotifier.js.map +1 -0
- package/lib/operations/v2/updateOrg.d.ts +102 -0
- package/lib/operations/v2/updateOrg.d.ts.map +1 -0
- package/lib/operations/v2/updateOrg.js +79 -0
- package/lib/operations/v2/updateOrg.js.map +1 -0
- package/lib/operations/v2/updateRole.d.ts +167 -0
- package/lib/operations/v2/updateRole.d.ts.map +1 -0
- package/lib/operations/v2/updateRole.js +94 -0
- package/lib/operations/v2/updateRole.js.map +1 -0
- package/lib/operations/v2/updateStarred.d.ts +168 -0
- package/lib/operations/v2/updateStarred.d.ts.map +1 -0
- package/lib/operations/v2/updateStarred.js +103 -0
- package/lib/operations/v2/updateStarred.js.map +1 -0
- package/lib/operations/v2/updateUserRole.d.ts +33 -0
- package/lib/operations/v2/updateUserRole.d.ts.map +1 -0
- package/lib/operations/v2/updateUserRole.js +29 -0
- package/lib/operations/v2/updateUserRole.js.map +1 -0
- package/lib/operations/v2/updateView.d.ts +38 -0
- package/lib/operations/v2/updateView.d.ts.map +1 -0
- package/lib/operations/v2/updateView.js +30 -0
- package/lib/operations/v2/updateView.js.map +1 -0
- package/lib/operations/v2/updateVirtualField.d.ts +40 -0
- package/lib/operations/v2/updateVirtualField.d.ts.map +1 -0
- package/lib/operations/v2/updateVirtualField.js +33 -0
- package/lib/operations/v2/updateVirtualField.js.map +1 -0
- package/lib/operations/v2/vacuumDataset.d.ts +11 -0
- package/lib/operations/v2/vacuumDataset.d.ts.map +1 -0
- package/lib/operations/v2/vacuumDataset.js +15 -0
- package/lib/operations/v2/vacuumDataset.js.map +1 -0
- package/lib/retry.d.ts +22 -0
- package/lib/retry.d.ts.map +1 -0
- package/lib/retry.js +21 -0
- package/lib/retry.js.map +1 -0
- package/lib/sensitive.d.ts +5 -0
- package/lib/sensitive.d.ts.map +1 -0
- package/lib/sensitive.js +5 -0
- package/lib/sensitive.js.map +1 -0
- package/lib/traits.d.ts +5 -0
- package/lib/traits.d.ts.map +1 -0
- package/lib/traits.js +5 -0
- package/lib/traits.js.map +1 -0
- package/package.json +80 -7
- package/src/category.ts +4 -0
- package/src/client.ts +112 -0
- package/src/credentials.ts +51 -0
- package/src/errors.ts +47 -0
- package/src/index.ts +15 -0
- package/src/operations/index.ts +3 -0
- package/src/operations/v1-edge-ingest/index.ts +1 -0
- package/src/operations/v1-edge-ingest/ingestToDataset.ts +46 -0
- package/src/operations/v1-edge-query/index.ts +1 -0
- package/src/operations/v1-edge-query/queryApl.ts +84 -0
- package/src/operations/v2/createAPIToken.ts +185 -0
- package/src/operations/v2/createAnnotation.ts +41 -0
- package/src/operations/v2/createDashboard.ts +127 -0
- package/src/operations/v2/createDataset.ts +57 -0
- package/src/operations/v2/createGroup.ts +37 -0
- package/src/operations/v2/createMapField.ts +26 -0
- package/src/operations/v2/createMonitor.ts +91 -0
- package/src/operations/v2/createNotifier.ts +144 -0
- package/src/operations/v2/createOrg.ts +81 -0
- package/src/operations/v2/createRole.ts +191 -0
- package/src/operations/v2/createStarred.ts +130 -0
- package/src/operations/v2/createUser.ts +36 -0
- package/src/operations/v2/createView.ts +33 -0
- package/src/operations/v2/createVirtualField.ts +36 -0
- package/src/operations/v2/deleteAPIToken.ts +24 -0
- package/src/operations/v2/deleteAnnotation.ts +26 -0
- package/src/operations/v2/deleteDashboard.ts +26 -0
- package/src/operations/v2/deleteDataset.ts +24 -0
- package/src/operations/v2/deleteGroup.ts +28 -0
- package/src/operations/v2/deleteMapField.ts +27 -0
- package/src/operations/v2/deleteMonitor.ts +24 -0
- package/src/operations/v2/deleteNotifier.ts +24 -0
- package/src/operations/v2/deleteRole.ts +28 -0
- package/src/operations/v2/deleteStarred.ts +21 -0
- package/src/operations/v2/deleteView.ts +21 -0
- package/src/operations/v2/deleteVirtualField.ts +22 -0
- package/src/operations/v2/getAPIToken.ts +103 -0
- package/src/operations/v2/getAPITokens.ts +105 -0
- package/src/operations/v2/getAnnotation.ts +35 -0
- package/src/operations/v2/getAnnotations.ts +39 -0
- package/src/operations/v2/getCurrentUser.ts +32 -0
- package/src/operations/v2/getDashboard.ts +77 -0
- package/src/operations/v2/getDataset.ts +42 -0
- package/src/operations/v2/getDatasets.ts +44 -0
- package/src/operations/v2/getFieldForDataset.ts +35 -0
- package/src/operations/v2/getFieldsForDataset.ts +31 -0
- package/src/operations/v2/getGroupById.ts +35 -0
- package/src/operations/v2/getMapFields.ts +23 -0
- package/src/operations/v2/getMonitor.ts +61 -0
- package/src/operations/v2/getMonitorHistory.ts +38 -0
- package/src/operations/v2/getMonitors.ts +59 -0
- package/src/operations/v2/getNotifier.ts +88 -0
- package/src/operations/v2/getNotifiers.ts +86 -0
- package/src/operations/v2/getOrg.ts +82 -0
- package/src/operations/v2/getOrgs.ts +82 -0
- package/src/operations/v2/getRoleById.ts +112 -0
- package/src/operations/v2/getStarred.ts +77 -0
- package/src/operations/v2/getStarredQueries.ts +92 -0
- package/src/operations/v2/getUser.ts +34 -0
- package/src/operations/v2/getUsers.ts +34 -0
- package/src/operations/v2/getView.ts +28 -0
- package/src/operations/v2/getViews.ts +28 -0
- package/src/operations/v2/getVirtualField.ts +29 -0
- package/src/operations/v2/getVirtualFields.ts +29 -0
- package/src/operations/v2/index.ts +76 -0
- package/src/operations/v2/listDashboards.ts +78 -0
- package/src/operations/v2/listGroups.ts +33 -0
- package/src/operations/v2/listRoles.ts +114 -0
- package/src/operations/v2/regenerateAPIToken.ts +228 -0
- package/src/operations/v2/removeUserFromOrg.ts +26 -0
- package/src/operations/v2/trimDataset.ts +27 -0
- package/src/operations/v2/updateAnnotation.ts +44 -0
- package/src/operations/v2/updateCurrentUser.ts +35 -0
- package/src/operations/v2/updateDashboard.ts +127 -0
- package/src/operations/v2/updateDataset.ts +45 -0
- package/src/operations/v2/updateFieldForDataset.ts +43 -0
- package/src/operations/v2/updateGroup.ts +40 -0
- package/src/operations/v2/updateMapFields.ts +23 -0
- package/src/operations/v2/updateMonitor.ts +92 -0
- package/src/operations/v2/updateNotifier.ts +145 -0
- package/src/operations/v2/updateOrg.ts +83 -0
- package/src/operations/v2/updateRole.ts +194 -0
- package/src/operations/v2/updateStarred.ts +131 -0
- package/src/operations/v2/updateUserRole.ts +35 -0
- package/src/operations/v2/updateView.ts +34 -0
- package/src/operations/v2/updateVirtualField.ts +37 -0
- package/src/operations/v2/vacuumDataset.ts +19 -0
- package/src/retry.ts +35 -0
- package/src/sensitive.ts +4 -0
- package/src/traits.ts +4 -0
- package/bun.lock +0 -26
- package/index.ts +0 -1
- package/tsconfig.json +0 -29
package/lib/traits.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"traits.d.ts","sourceRoot":"","sources":["../src/traits.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,8BAA8B,CAAC"}
|
package/lib/traits.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"traits.js","sourceRoot":"","sources":["../src/traits.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,8BAA8B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,15 +1,88 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@distilled.cloud/axiom",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
3
|
+
"version": "0.12.7",
|
|
4
|
+
"repository": {
|
|
5
|
+
"type": "git",
|
|
6
|
+
"url": "https://github.com/alchemy-run/distilled",
|
|
7
|
+
"directory": "packages/axiom"
|
|
8
|
+
},
|
|
5
9
|
"type": "module",
|
|
10
|
+
"sideEffects": false,
|
|
11
|
+
"module": "src/index.ts",
|
|
12
|
+
"files": [
|
|
13
|
+
"lib",
|
|
14
|
+
"src"
|
|
15
|
+
],
|
|
16
|
+
"exports": {
|
|
17
|
+
".": {
|
|
18
|
+
"types": "./lib/index.d.ts",
|
|
19
|
+
"bun": "./src/index.ts",
|
|
20
|
+
"default": "./lib/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./Category": {
|
|
23
|
+
"types": "./lib/category.d.ts",
|
|
24
|
+
"bun": "./src/category.ts",
|
|
25
|
+
"default": "./lib/category.js"
|
|
26
|
+
},
|
|
27
|
+
"./Client": {
|
|
28
|
+
"types": "./lib/client.d.ts",
|
|
29
|
+
"bun": "./src/client.ts",
|
|
30
|
+
"default": "./lib/client.js"
|
|
31
|
+
},
|
|
32
|
+
"./Credentials": {
|
|
33
|
+
"types": "./lib/credentials.d.ts",
|
|
34
|
+
"bun": "./src/credentials.ts",
|
|
35
|
+
"default": "./lib/credentials.js"
|
|
36
|
+
},
|
|
37
|
+
"./Errors": {
|
|
38
|
+
"types": "./lib/errors.d.ts",
|
|
39
|
+
"bun": "./src/errors.ts",
|
|
40
|
+
"default": "./lib/errors.js"
|
|
41
|
+
},
|
|
42
|
+
"./Operations": {
|
|
43
|
+
"types": "./lib/operations/index.d.ts",
|
|
44
|
+
"bun": "./src/operations/index.ts",
|
|
45
|
+
"default": "./lib/operations/index.js"
|
|
46
|
+
},
|
|
47
|
+
"./Retry": {
|
|
48
|
+
"types": "./lib/retry.d.ts",
|
|
49
|
+
"bun": "./src/retry.ts",
|
|
50
|
+
"default": "./lib/retry.js"
|
|
51
|
+
},
|
|
52
|
+
"./Sensitive": {
|
|
53
|
+
"types": "./lib/sensitive.d.ts",
|
|
54
|
+
"bun": "./src/sensitive.ts",
|
|
55
|
+
"default": "./lib/sensitive.js"
|
|
56
|
+
},
|
|
57
|
+
"./Traits": {
|
|
58
|
+
"types": "./lib/traits.d.ts",
|
|
59
|
+
"bun": "./src/traits.ts",
|
|
60
|
+
"default": "./lib/traits.js"
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
"scripts": {
|
|
64
|
+
"typecheck": "tsgo",
|
|
65
|
+
"build": "tsgo -b",
|
|
66
|
+
"fmt": "oxfmt --write src",
|
|
67
|
+
"lint": "oxlint --fix src",
|
|
68
|
+
"check": "tsgo && oxlint src && oxfmt --check src",
|
|
69
|
+
"test": "bunx vitest run test",
|
|
70
|
+
"publish:npm": "bun run build && bun publish --access public",
|
|
71
|
+
"generate": "bun run scripts/generate.ts && oxlint --fix src && oxfmt --write src && oxfmt --write src",
|
|
72
|
+
"specs:fetch": "git submodule update --force --init --recursive --depth=1 specs/docs && git -C specs/docs checkout -- .",
|
|
73
|
+
"specs:update": "git -C specs/docs fetch && git -C specs/docs checkout main && git -C specs/docs pull"
|
|
74
|
+
},
|
|
75
|
+
"dependencies": {
|
|
76
|
+
"@distilled.cloud/core": "0.12.7",
|
|
77
|
+
"effect": "4.0.0-beta.48"
|
|
78
|
+
},
|
|
6
79
|
"devDependencies": {
|
|
7
|
-
"@types/bun": "
|
|
80
|
+
"@types/bun": "^1.3.0",
|
|
81
|
+
"@types/node": "^25.3.5",
|
|
82
|
+
"dotenv": "^16.5.0",
|
|
83
|
+
"vitest": "^3.2.3"
|
|
8
84
|
},
|
|
9
85
|
"peerDependencies": {
|
|
10
|
-
"
|
|
11
|
-
},
|
|
12
|
-
"repository": {
|
|
13
|
-
"type": "git"
|
|
86
|
+
"effect": "4.0.0-beta.48"
|
|
14
87
|
}
|
|
15
88
|
}
|
package/src/category.ts
ADDED
package/src/client.ts
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Axiom API Client.
|
|
3
|
+
*
|
|
4
|
+
* Wraps the shared REST client from sdk-core with Axiom-specific
|
|
5
|
+
* error matching and credential handling.
|
|
6
|
+
*/
|
|
7
|
+
import * as Effect from "effect/Effect";
|
|
8
|
+
import * as Redacted from "effect/Redacted";
|
|
9
|
+
import * as Schema from "effect/Schema";
|
|
10
|
+
import { makeAPI } from "@distilled.cloud/core/client";
|
|
11
|
+
import {
|
|
12
|
+
HTTP_STATUS_MAP,
|
|
13
|
+
UnknownAxiomError,
|
|
14
|
+
AxiomParseError,
|
|
15
|
+
} from "./errors.ts";
|
|
16
|
+
|
|
17
|
+
// Re-export for backwards compatibility
|
|
18
|
+
export { UnknownAxiomError } from "./errors.ts";
|
|
19
|
+
import { Credentials } from "./credentials.ts";
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Axiom returns two error envelope shapes:
|
|
23
|
+
* - control-plane / edge-ingest: `{ "code": "...", "message": "..." }`
|
|
24
|
+
* - edge-query: `{ "error": "...", "message": "..." }`
|
|
25
|
+
* Plus some endpoints return plain `{ message: "..." }`.
|
|
26
|
+
* We accept all of them and extract a unified `message`/`code` pair.
|
|
27
|
+
*/
|
|
28
|
+
const ApiErrorResponse = Schema.Struct({
|
|
29
|
+
code: Schema.optional(Schema.Union([Schema.String, Schema.Number])),
|
|
30
|
+
error: Schema.optional(Schema.String),
|
|
31
|
+
message: Schema.optional(Schema.String),
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Match an Axiom API error response to the appropriate error class based on
|
|
36
|
+
* HTTP status.
|
|
37
|
+
*
|
|
38
|
+
* Strategy: HTTP status is the authoritative signal. We always try status-based
|
|
39
|
+
* matching first, then enrich with a message parsed from the body if we can.
|
|
40
|
+
* Non-JSON responses (plain text "Forbidden", empty bodies, HTML error pages)
|
|
41
|
+
* still map to the correct typed error via status code.
|
|
42
|
+
*/
|
|
43
|
+
const matchError = (
|
|
44
|
+
status: number,
|
|
45
|
+
errorBody: unknown,
|
|
46
|
+
): Effect.Effect<never, unknown> => {
|
|
47
|
+
const ErrorClass = (HTTP_STATUS_MAP as any)[status];
|
|
48
|
+
let message = "";
|
|
49
|
+
let code: string | number | undefined;
|
|
50
|
+
try {
|
|
51
|
+
const parsed = Schema.decodeUnknownSync(ApiErrorResponse)(errorBody);
|
|
52
|
+
message = parsed.message ?? parsed.error ?? "";
|
|
53
|
+
code = parsed.code ?? parsed.error;
|
|
54
|
+
} catch {
|
|
55
|
+
if (typeof errorBody === "string") {
|
|
56
|
+
message = errorBody;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
if (ErrorClass) {
|
|
60
|
+
return Effect.fail(new ErrorClass({ message }));
|
|
61
|
+
}
|
|
62
|
+
return Effect.fail(
|
|
63
|
+
new UnknownAxiomError({
|
|
64
|
+
code: typeof code === "number" ? String(code) : code,
|
|
65
|
+
message,
|
|
66
|
+
body: errorBody,
|
|
67
|
+
}),
|
|
68
|
+
);
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Axiom's backend (Go) serializes nil slices and omitted optional fields as
|
|
73
|
+
* JSON `null`. The generated output schemas model these as `Schema.optional(…)`
|
|
74
|
+
* which accepts only the value or `undefined`, so `null` trips decoding.
|
|
75
|
+
*
|
|
76
|
+
* Recursively drop explicit `null` properties before decoding so optional
|
|
77
|
+
* fields simply get treated as absent. Keys that are genuinely nullable in
|
|
78
|
+
* the API should be patched to `Schema.NullOr(…)` in the spec — this hook
|
|
79
|
+
* exists for the far more common "Go nil slice" case.
|
|
80
|
+
*/
|
|
81
|
+
const stripNulls = (value: unknown): unknown => {
|
|
82
|
+
if (Array.isArray(value)) return value.map(stripNulls);
|
|
83
|
+
if (value && typeof value === "object") {
|
|
84
|
+
const out: Record<string, unknown> = {};
|
|
85
|
+
for (const [k, v] of Object.entries(value as Record<string, unknown>)) {
|
|
86
|
+
if (v === null) continue;
|
|
87
|
+
out[k] = stripNulls(v);
|
|
88
|
+
}
|
|
89
|
+
return out;
|
|
90
|
+
}
|
|
91
|
+
return value;
|
|
92
|
+
};
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* Axiom API client.
|
|
96
|
+
*/
|
|
97
|
+
export const API = makeAPI({
|
|
98
|
+
credentials: Credentials as any,
|
|
99
|
+
getBaseUrl: (creds: any) => creds.apiBaseUrl,
|
|
100
|
+
getAuthHeaders: (creds: any) => {
|
|
101
|
+
const headers: Record<string, string> = {
|
|
102
|
+
Authorization: `Bearer ${Redacted.value(creds.apiKey)}`,
|
|
103
|
+
};
|
|
104
|
+
if (creds.orgId) {
|
|
105
|
+
headers["X-Axiom-Org-ID"] = creds.orgId;
|
|
106
|
+
}
|
|
107
|
+
return headers;
|
|
108
|
+
},
|
|
109
|
+
matchError,
|
|
110
|
+
ParseError: AxiomParseError as any,
|
|
111
|
+
transformResponse: stripNulls,
|
|
112
|
+
});
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect";
|
|
2
|
+
import * as Layer from "effect/Layer";
|
|
3
|
+
import * as Redacted from "effect/Redacted";
|
|
4
|
+
import * as Context from "effect/Context";
|
|
5
|
+
import { ConfigError } from "@distilled.cloud/core/errors";
|
|
6
|
+
|
|
7
|
+
/** Default base URL for Axiom Cloud. Self-hosted users can override via AXIOM_URL. */
|
|
8
|
+
export const DEFAULT_API_BASE_URL = "https://api.axiom.co";
|
|
9
|
+
|
|
10
|
+
export interface Config {
|
|
11
|
+
readonly apiKey: Redacted.Redacted<string>;
|
|
12
|
+
readonly apiBaseUrl: string;
|
|
13
|
+
/**
|
|
14
|
+
* Optional organization ID. Required when authenticating with a Personal
|
|
15
|
+
* Access Token (PAT); optional for API tokens scoped to a single org.
|
|
16
|
+
* Sent on every request as the `X-Axiom-Org-ID` header when set.
|
|
17
|
+
*/
|
|
18
|
+
readonly orgId?: string;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export class Credentials extends Context.Service<Credentials, Config>()(
|
|
22
|
+
"AxiomCredentials",
|
|
23
|
+
) {}
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Build {@link Credentials} from environment variables.
|
|
27
|
+
*
|
|
28
|
+
* - `AXIOM_TOKEN` or `AXIOM_API_KEY` (required) — Axiom API token or PAT.
|
|
29
|
+
* - `AXIOM_URL` (optional) — override the API base URL (for self-hosted or
|
|
30
|
+
* regional edge deployments). Defaults to `https://api.axiom.co`.
|
|
31
|
+
* - `AXIOM_ORG_ID` (optional) — organization ID, required for PATs.
|
|
32
|
+
*/
|
|
33
|
+
export const CredentialsFromEnv = Layer.effect(
|
|
34
|
+
Credentials,
|
|
35
|
+
Effect.gen(function* () {
|
|
36
|
+
const apiKey = process.env.AXIOM_TOKEN ?? process.env.AXIOM_API_KEY;
|
|
37
|
+
|
|
38
|
+
if (!apiKey) {
|
|
39
|
+
return yield* new ConfigError({
|
|
40
|
+
message:
|
|
41
|
+
"AXIOM_TOKEN (or AXIOM_API_KEY) environment variable is required",
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
return {
|
|
46
|
+
apiKey: Redacted.make(apiKey),
|
|
47
|
+
apiBaseUrl: process.env.AXIOM_URL ?? DEFAULT_API_BASE_URL,
|
|
48
|
+
orgId: process.env.AXIOM_ORG_ID,
|
|
49
|
+
};
|
|
50
|
+
}),
|
|
51
|
+
);
|
package/src/errors.ts
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Axiom-specific error types.
|
|
3
|
+
*
|
|
4
|
+
* Re-exports common HTTP errors from sdk-core and adds Axiom-specific
|
|
5
|
+
* error matching and API error types.
|
|
6
|
+
*/
|
|
7
|
+
export {
|
|
8
|
+
BadGateway,
|
|
9
|
+
BadRequest,
|
|
10
|
+
Conflict,
|
|
11
|
+
ConfigError,
|
|
12
|
+
Forbidden,
|
|
13
|
+
GatewayTimeout,
|
|
14
|
+
InternalServerError,
|
|
15
|
+
Locked,
|
|
16
|
+
NotFound,
|
|
17
|
+
ServiceUnavailable,
|
|
18
|
+
TooManyRequests,
|
|
19
|
+
Unauthorized,
|
|
20
|
+
UnprocessableEntity,
|
|
21
|
+
HTTP_STATUS_MAP,
|
|
22
|
+
DEFAULT_ERRORS,
|
|
23
|
+
API_ERRORS,
|
|
24
|
+
} from "@distilled.cloud/core/errors";
|
|
25
|
+
export type { DefaultErrors } from "@distilled.cloud/core/errors";
|
|
26
|
+
|
|
27
|
+
import * as Schema from "effect/Schema";
|
|
28
|
+
import * as Category from "@distilled.cloud/core/category";
|
|
29
|
+
|
|
30
|
+
// Unknown Axiom error - returned when an error code is not recognized
|
|
31
|
+
export class UnknownAxiomError extends Schema.TaggedErrorClass<UnknownAxiomError>()(
|
|
32
|
+
"UnknownAxiomError",
|
|
33
|
+
{
|
|
34
|
+
code: Schema.optional(Schema.String),
|
|
35
|
+
message: Schema.optional(Schema.String),
|
|
36
|
+
body: Schema.Unknown,
|
|
37
|
+
},
|
|
38
|
+
).pipe(Category.withServerError) {}
|
|
39
|
+
|
|
40
|
+
// Schema parse error wrapper
|
|
41
|
+
export class AxiomParseError extends Schema.TaggedErrorClass<AxiomParseError>()(
|
|
42
|
+
"AxiomParseError",
|
|
43
|
+
{
|
|
44
|
+
body: Schema.Unknown,
|
|
45
|
+
cause: Schema.Unknown,
|
|
46
|
+
},
|
|
47
|
+
).pipe(Category.withParseError) {}
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Axiom SDK for Effect
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* \`\`\`ts
|
|
6
|
+
* import * as Axiom from "@distilled.cloud/axiom";
|
|
7
|
+
* \`\`\`
|
|
8
|
+
*/
|
|
9
|
+
export * from "./credentials.ts";
|
|
10
|
+
export * as Category from "./category.ts";
|
|
11
|
+
export * as T from "./traits.ts";
|
|
12
|
+
export * as Retry from "./retry.ts";
|
|
13
|
+
export { API } from "./client.ts";
|
|
14
|
+
export * from "./errors.ts";
|
|
15
|
+
export { SensitiveString, SensitiveNullableString } from "./sensitive.ts";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./ingestToDataset";
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../../client";
|
|
3
|
+
import * as T from "../../traits";
|
|
4
|
+
import { BadRequest, NotFound, UnprocessableEntity } from "../../errors";
|
|
5
|
+
|
|
6
|
+
// Input Schema
|
|
7
|
+
export const IngestToDatasetInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
"dataset-id": Schema.String.pipe(T.PathParam()),
|
|
9
|
+
"timestamp-field": Schema.optional(Schema.String),
|
|
10
|
+
"timestamp-format": Schema.optional(Schema.String),
|
|
11
|
+
"csv-delimiter": Schema.optional(Schema.String),
|
|
12
|
+
}).pipe(T.Http({ method: "POST", path: "/v1/datasets/{dataset-id}/ingest" }));
|
|
13
|
+
export type IngestToDatasetInput = typeof IngestToDatasetInput.Type;
|
|
14
|
+
|
|
15
|
+
// Output Schema
|
|
16
|
+
export const IngestToDatasetOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
17
|
+
blocksCreated: Schema.Number,
|
|
18
|
+
failed: Schema.Number,
|
|
19
|
+
failures: Schema.optional(
|
|
20
|
+
Schema.Array(
|
|
21
|
+
Schema.Struct({
|
|
22
|
+
error: Schema.String,
|
|
23
|
+
timestamp: Schema.String,
|
|
24
|
+
}),
|
|
25
|
+
),
|
|
26
|
+
),
|
|
27
|
+
ingested: Schema.Number,
|
|
28
|
+
processedBytes: Schema.Number,
|
|
29
|
+
walLength: Schema.Number,
|
|
30
|
+
});
|
|
31
|
+
export type IngestToDatasetOutput = typeof IngestToDatasetOutput.Type;
|
|
32
|
+
|
|
33
|
+
// The operation
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @param timestamp-field - The name of the field to use as the timestamp. If not specified, the timestamp will be the time the event was received by Axiom.
|
|
37
|
+
* @param timestamp-format - The date-time format of the timestamp field. The reference time is `Mon Jan 2 15:04:05 -0700 MST 2006`, as specified in https://pkg.go.dev/time/?tab=doc#Parse
|
|
38
|
+
* @param csv-delimiter - The delimiter to use when parsing CSV data. If not specified, the default delimiter is `,`.
|
|
39
|
+
* @param X-Axiom-CSV-Fields - A list of optional comma separated fields to use for CSV ingestion. If not specified, the first line of the CSV will be used as the field names.
|
|
40
|
+
* @param X-Axiom-Event-Labels - An optional JSON encoded object with additional labels to add to all events in the request
|
|
41
|
+
*/
|
|
42
|
+
export const ingestToDataset = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
43
|
+
inputSchema: IngestToDatasetInput,
|
|
44
|
+
outputSchema: IngestToDatasetOutput,
|
|
45
|
+
errors: [BadRequest, NotFound, UnprocessableEntity] as const,
|
|
46
|
+
}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./queryApl";
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../../client";
|
|
3
|
+
import * as T from "../../traits";
|
|
4
|
+
|
|
5
|
+
// Input Schema
|
|
6
|
+
export const QueryAplInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
7
|
+
format: Schema.Literals(["legacy", "tabular", "tabular-rows"]),
|
|
8
|
+
nocache: Schema.optional(Schema.Boolean),
|
|
9
|
+
saveAsKind: Schema.optional(Schema.String),
|
|
10
|
+
id: Schema.optional(Schema.String),
|
|
11
|
+
"streaming-duration": Schema.optional(Schema.String),
|
|
12
|
+
"apl-source": Schema.optional(Schema.String),
|
|
13
|
+
"apl-source-id": Schema.optional(Schema.String),
|
|
14
|
+
totals: Schema.optional(Schema.Boolean),
|
|
15
|
+
apl: Schema.String,
|
|
16
|
+
cursor: Schema.optional(Schema.String),
|
|
17
|
+
defaultLimit: Schema.optional(Schema.Number),
|
|
18
|
+
defaultOrder: Schema.optional(
|
|
19
|
+
Schema.Array(
|
|
20
|
+
Schema.Struct({
|
|
21
|
+
desc: Schema.optional(Schema.Boolean),
|
|
22
|
+
field: Schema.optional(Schema.String),
|
|
23
|
+
}),
|
|
24
|
+
),
|
|
25
|
+
),
|
|
26
|
+
endTime: Schema.optional(Schema.String),
|
|
27
|
+
includeCursor: Schema.optional(Schema.Boolean),
|
|
28
|
+
includeCursorField: Schema.optional(Schema.Boolean),
|
|
29
|
+
libraries: Schema.optional(Schema.Array(Schema.String)),
|
|
30
|
+
maxBinAutoGroups: Schema.optional(Schema.Number),
|
|
31
|
+
queryEdgeDeployment: Schema.optional(Schema.String),
|
|
32
|
+
queryOptions: Schema.optional(
|
|
33
|
+
Schema.Struct({
|
|
34
|
+
against: Schema.optional(Schema.String),
|
|
35
|
+
againstStart: Schema.optional(Schema.String),
|
|
36
|
+
againstTimestamp: Schema.optional(Schema.String),
|
|
37
|
+
aggChartOpts: Schema.optional(Schema.String),
|
|
38
|
+
caseSensitive: Schema.optional(Schema.String),
|
|
39
|
+
containsTimeFilter: Schema.optional(Schema.String),
|
|
40
|
+
datasets: Schema.optional(Schema.String),
|
|
41
|
+
displayNull: Schema.optional(Schema.String),
|
|
42
|
+
editorContent: Schema.optional(Schema.String),
|
|
43
|
+
endColumn: Schema.optional(Schema.String),
|
|
44
|
+
endLineNumber: Schema.optional(Schema.String),
|
|
45
|
+
endTime: Schema.optional(Schema.String),
|
|
46
|
+
integrationsFilter: Schema.optional(Schema.String),
|
|
47
|
+
nanosecondPrecision: Schema.optional(Schema.String),
|
|
48
|
+
openIntervals: Schema.optional(Schema.String),
|
|
49
|
+
overlayCharts: Schema.optional(Schema.String),
|
|
50
|
+
queryObject: Schema.optional(Schema.String),
|
|
51
|
+
quickRange: Schema.optional(Schema.String),
|
|
52
|
+
resolution: Schema.optional(Schema.String),
|
|
53
|
+
resultsHistogram: Schema.optional(Schema.String),
|
|
54
|
+
selection: Schema.optional(Schema.String),
|
|
55
|
+
shownColumns: Schema.optional(Schema.String),
|
|
56
|
+
startColumn: Schema.optional(Schema.String),
|
|
57
|
+
startLineNumber: Schema.optional(Schema.String),
|
|
58
|
+
startTime: Schema.optional(Schema.String),
|
|
59
|
+
timeSeriesVariant: Schema.optional(Schema.String),
|
|
60
|
+
timeSeriesView: Schema.optional(Schema.String),
|
|
61
|
+
}),
|
|
62
|
+
),
|
|
63
|
+
queryRegion: Schema.optional(Schema.String),
|
|
64
|
+
startTime: Schema.optional(Schema.String),
|
|
65
|
+
variables: Schema.optional(Schema.Record(Schema.String, Schema.Unknown)),
|
|
66
|
+
}).pipe(T.Http({ method: "POST", path: "/v1/datasets/_apl?format=tabular" }));
|
|
67
|
+
export type QueryAplInput = typeof QueryAplInput.Type;
|
|
68
|
+
|
|
69
|
+
// Output Schema
|
|
70
|
+
export const QueryAplOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Unknown;
|
|
71
|
+
export type QueryAplOutput = typeof QueryAplOutput.Type;
|
|
72
|
+
|
|
73
|
+
// The operation
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
* @param id - when saveAsKind is true, this parameter indicates the id of the associated dataset
|
|
77
|
+
* @param apl-source - contains the source of the APL query (for example console, dashboard, etc.)
|
|
78
|
+
* @param apl-source-id - contains the id of the source, for example dashboard_id
|
|
79
|
+
* @param totals - Include a totals table (only supported in MetricsDB)
|
|
80
|
+
*/
|
|
81
|
+
export const queryApl = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
82
|
+
inputSchema: QueryAplInput,
|
|
83
|
+
outputSchema: QueryAplOutput,
|
|
84
|
+
}));
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
import * as Schema from "effect/Schema";
|
|
2
|
+
import { API } from "../../client";
|
|
3
|
+
import * as T from "../../traits";
|
|
4
|
+
import { UnprocessableEntity } from "../../errors";
|
|
5
|
+
|
|
6
|
+
// Input Schema
|
|
7
|
+
export const CreateAPITokenInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
8
|
+
datasetCapabilities: Schema.optional(
|
|
9
|
+
Schema.Record(
|
|
10
|
+
Schema.String,
|
|
11
|
+
Schema.Struct({
|
|
12
|
+
data: Schema.optional(Schema.Array(Schema.Literals(["delete"]))),
|
|
13
|
+
ingest: Schema.optional(Schema.Array(Schema.Literals(["create"]))),
|
|
14
|
+
query: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
15
|
+
share: Schema.optional(
|
|
16
|
+
Schema.Array(Schema.Literals(["create", "read", "delete"])),
|
|
17
|
+
),
|
|
18
|
+
starredQueries: Schema.optional(
|
|
19
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
20
|
+
),
|
|
21
|
+
trim: Schema.optional(Schema.Array(Schema.Literals(["update"]))),
|
|
22
|
+
vacuum: Schema.optional(Schema.Array(Schema.Literals(["update"]))),
|
|
23
|
+
virtualFields: Schema.optional(
|
|
24
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
25
|
+
),
|
|
26
|
+
}),
|
|
27
|
+
),
|
|
28
|
+
),
|
|
29
|
+
description: Schema.optional(Schema.String),
|
|
30
|
+
expiresAt: Schema.optional(Schema.NullOr(Schema.String)),
|
|
31
|
+
name: Schema.String,
|
|
32
|
+
orgCapabilities: Schema.optional(
|
|
33
|
+
Schema.Struct({
|
|
34
|
+
annotations: Schema.optional(
|
|
35
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
36
|
+
),
|
|
37
|
+
apiTokens: Schema.optional(
|
|
38
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
39
|
+
),
|
|
40
|
+
auditLog: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
41
|
+
billing: Schema.optional(
|
|
42
|
+
Schema.Array(Schema.Literals(["read", "update"])),
|
|
43
|
+
),
|
|
44
|
+
dashboards: Schema.optional(
|
|
45
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
46
|
+
),
|
|
47
|
+
datasets: Schema.optional(
|
|
48
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
49
|
+
),
|
|
50
|
+
endpoints: Schema.optional(
|
|
51
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
52
|
+
),
|
|
53
|
+
flows: Schema.optional(
|
|
54
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
55
|
+
),
|
|
56
|
+
integrations: Schema.optional(
|
|
57
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
58
|
+
),
|
|
59
|
+
monitors: Schema.optional(
|
|
60
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
61
|
+
),
|
|
62
|
+
notifiers: Schema.optional(
|
|
63
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
64
|
+
),
|
|
65
|
+
rbac: Schema.optional(
|
|
66
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
67
|
+
),
|
|
68
|
+
sharedAccessKeys: Schema.optional(
|
|
69
|
+
Schema.Array(Schema.Literals(["read", "update"])),
|
|
70
|
+
),
|
|
71
|
+
users: Schema.optional(
|
|
72
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
73
|
+
),
|
|
74
|
+
views: Schema.optional(
|
|
75
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
76
|
+
),
|
|
77
|
+
}),
|
|
78
|
+
),
|
|
79
|
+
viewCapabilities: Schema.optional(
|
|
80
|
+
Schema.Record(
|
|
81
|
+
Schema.String,
|
|
82
|
+
Schema.Struct({
|
|
83
|
+
query: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
84
|
+
share: Schema.optional(
|
|
85
|
+
Schema.Array(Schema.Literals(["create", "read", "delete"])),
|
|
86
|
+
),
|
|
87
|
+
}),
|
|
88
|
+
),
|
|
89
|
+
),
|
|
90
|
+
}).pipe(T.Http({ method: "POST", path: "/v2/tokens" }));
|
|
91
|
+
export type CreateAPITokenInput = typeof CreateAPITokenInput.Type;
|
|
92
|
+
|
|
93
|
+
// Output Schema
|
|
94
|
+
export const CreateAPITokenOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
|
|
95
|
+
datasetCapabilities: Schema.Record(
|
|
96
|
+
Schema.String,
|
|
97
|
+
Schema.Struct({
|
|
98
|
+
data: Schema.optional(Schema.Array(Schema.Literals(["delete"]))),
|
|
99
|
+
ingest: Schema.optional(Schema.Array(Schema.Literals(["create"]))),
|
|
100
|
+
query: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
101
|
+
share: Schema.optional(
|
|
102
|
+
Schema.Array(Schema.Literals(["create", "read", "delete"])),
|
|
103
|
+
),
|
|
104
|
+
starredQueries: Schema.optional(
|
|
105
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
106
|
+
),
|
|
107
|
+
trim: Schema.optional(Schema.Array(Schema.Literals(["update"]))),
|
|
108
|
+
vacuum: Schema.optional(Schema.Array(Schema.Literals(["update"]))),
|
|
109
|
+
virtualFields: Schema.optional(
|
|
110
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
111
|
+
),
|
|
112
|
+
}),
|
|
113
|
+
),
|
|
114
|
+
description: Schema.optional(Schema.String),
|
|
115
|
+
expiresAt: Schema.optional(Schema.NullOr(Schema.String)),
|
|
116
|
+
id: Schema.String,
|
|
117
|
+
name: Schema.String,
|
|
118
|
+
orgCapabilities: Schema.Struct({
|
|
119
|
+
annotations: Schema.optional(
|
|
120
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
121
|
+
),
|
|
122
|
+
apiTokens: Schema.optional(
|
|
123
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
124
|
+
),
|
|
125
|
+
auditLog: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
126
|
+
billing: Schema.optional(Schema.Array(Schema.Literals(["read", "update"]))),
|
|
127
|
+
dashboards: Schema.optional(
|
|
128
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
129
|
+
),
|
|
130
|
+
datasets: Schema.optional(
|
|
131
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
132
|
+
),
|
|
133
|
+
endpoints: Schema.optional(
|
|
134
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
135
|
+
),
|
|
136
|
+
flows: Schema.optional(
|
|
137
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
138
|
+
),
|
|
139
|
+
integrations: Schema.optional(
|
|
140
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
141
|
+
),
|
|
142
|
+
monitors: Schema.optional(
|
|
143
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
144
|
+
),
|
|
145
|
+
notifiers: Schema.optional(
|
|
146
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
147
|
+
),
|
|
148
|
+
rbac: Schema.optional(
|
|
149
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
150
|
+
),
|
|
151
|
+
sharedAccessKeys: Schema.optional(
|
|
152
|
+
Schema.Array(Schema.Literals(["read", "update"])),
|
|
153
|
+
),
|
|
154
|
+
users: Schema.optional(
|
|
155
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
156
|
+
),
|
|
157
|
+
views: Schema.optional(
|
|
158
|
+
Schema.Array(Schema.Literals(["create", "read", "update", "delete"])),
|
|
159
|
+
),
|
|
160
|
+
}),
|
|
161
|
+
samlAuthenticated: Schema.optional(Schema.Boolean),
|
|
162
|
+
viewCapabilities: Schema.optional(
|
|
163
|
+
Schema.Record(
|
|
164
|
+
Schema.String,
|
|
165
|
+
Schema.Struct({
|
|
166
|
+
query: Schema.optional(Schema.Array(Schema.Literals(["read"]))),
|
|
167
|
+
share: Schema.optional(
|
|
168
|
+
Schema.Array(Schema.Literals(["create", "read", "delete"])),
|
|
169
|
+
),
|
|
170
|
+
}),
|
|
171
|
+
),
|
|
172
|
+
),
|
|
173
|
+
token: Schema.optional(Schema.String),
|
|
174
|
+
});
|
|
175
|
+
export type CreateAPITokenOutput = typeof CreateAPITokenOutput.Type;
|
|
176
|
+
|
|
177
|
+
// The operation
|
|
178
|
+
/**
|
|
179
|
+
* Create API token
|
|
180
|
+
*/
|
|
181
|
+
export const createAPIToken = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
|
|
182
|
+
inputSchema: CreateAPITokenInput,
|
|
183
|
+
outputSchema: CreateAPITokenOutput,
|
|
184
|
+
errors: [UnprocessableEntity] as const,
|
|
185
|
+
}));
|