@vizzly/api-client 0.0.69 → 0.0.70

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.
@@ -2,7 +2,7 @@ import { Api } from './Api';
2
2
  import { Authentication } from './Authentication';
3
3
  import { nVizzlyQueryEngine, Request, extraHeaders, CreateDashboardParams, UpdateDashboardParams, UpdateGlobalLibraryParams, GlobalLibrary, CreateGlobalLibraryParams, GlobalLibraryPermissionFromAPI, RequestParams, DataOptimiser } from '../types';
4
4
  import { nSemanticLayer } from '@vizzly/semantic-layer-public';
5
- import { SQLSchema } from '@vizzly/sqlbuilder-public';
5
+ import { HighLevelSQLSchema, SQLSchema } from '@vizzly/sqlbuilder-public';
6
6
  export declare class VizzlyQueryEngineApi extends Api {
7
7
  constructor(auth: Authentication, host: string, extraHeaders?: extraHeaders);
8
8
  buildCreateDashboardRequest(params: RequestParams<CreateDashboardParams>): Request<CreateDashboardParams & {
@@ -29,6 +29,15 @@ export declare class VizzlyQueryEngineApi extends Api {
29
29
  results: Array<nSemanticLayer.Result>;
30
30
  }>>;
31
31
  private buildCreateResultsRequest;
32
+ collectTableSchema(params: RequestParams<nVizzlyQueryEngine.CollectTableSchemaParams>): Promise<import("../types").Response<{
33
+ tableSchemaByConnection: {
34
+ [connectionId: string]: {
35
+ /** ID of the connection */
36
+ id: string;
37
+ } & HighLevelSQLSchema;
38
+ };
39
+ }>>;
40
+ private buildCollectTableSchemaRequest;
32
41
  collectSchema(params: RequestParams<nVizzlyQueryEngine.CollectSchemaParams>): Promise<import("../types").Response<{
33
42
  schemaByConnection: {
34
43
  [connectionId: string]: {
@@ -110,6 +110,23 @@ class VizzlyQueryEngineApi extends Api_1.Api {
110
110
  acceptedAuthParams: ['queryEngineApiKey', 'dashboardAccessToken'],
111
111
  };
112
112
  }
113
+ collectTableSchema(params) {
114
+ return __awaiter(this, void 0, void 0, function* () {
115
+ return yield this.execute(this.buildCollectTableSchemaRequest(params));
116
+ });
117
+ }
118
+ buildCollectTableSchemaRequest(params) {
119
+ return {
120
+ path: `/api/v1/schema/tables`,
121
+ method: 'post',
122
+ abortSignal: params.abortSignal,
123
+ body: {
124
+ allowedConfigOrigins: params.allowedConfigOrigins,
125
+ dynamicConfig: params.dynamicConfig
126
+ },
127
+ acceptedAuthParams: ['queryEngineApiKey'],
128
+ };
129
+ }
113
130
  collectSchema(params) {
114
131
  return __awaiter(this, void 0, void 0, function* () {
115
132
  return yield this.execute(this.buildCollectSchemaRequest(params));
package/dist/types.d.ts CHANGED
@@ -113,6 +113,10 @@ export declare namespace nVizzlyQueryEngine {
113
113
  dynamicConfig?: nSemanticLayer.Config;
114
114
  secureFilters?: DataAccessConfig['secureFilters'];
115
115
  };
116
+ type CollectTableSchemaParams = {
117
+ allowedConfigOrigins: OriginId[];
118
+ dynamicConfig?: nSemanticLayer.Config;
119
+ };
116
120
  type CollectSchemaParams = {
117
121
  allowedConfigOrigins: OriginId[];
118
122
  dynamicConfig?: nSemanticLayer.Config;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vizzly/api-client",
3
- "version": "0.0.69",
3
+ "version": "0.0.70",
4
4
  "private": false,
5
5
  "license": "NONE",
6
6
  "source": "src/index.ts",
@@ -34,7 +34,7 @@
34
34
  },
35
35
  "dependencies": {
36
36
  "@vizzly/semantic-layer-public": ">=0.0.231",
37
- "@vizzly/sqlbuilder-public": ">=0.1.41",
37
+ "@vizzly/sqlbuilder-public": ">=0.1.62",
38
38
  "cross-fetch": "^4.0.0"
39
39
  }
40
40
  }