@vertexvis/api-client-node 0.15.6 → 0.17.1
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/dist/cjs/api.d.ts +647 -248
- package/dist/cjs/api.js +393 -248
- package/dist/cjs/client/helpers/exports.d.ts +15 -0
- package/dist/cjs/client/helpers/exports.js +39 -0
- package/dist/cjs/client/helpers/index.d.ts +1 -0
- package/dist/cjs/client/helpers/index.js +1 -0
- package/dist/cjs/client/version.d.ts +1 -1
- package/dist/cjs/client/version.js +1 -1
- package/dist/cjs/client/vertex-client.d.ts +2 -1
- package/dist/cjs/client/vertex-client.js +1 -0
- package/dist/esm/api.d.ts +647 -248
- package/dist/esm/api.js +386 -245
- package/dist/esm/client/helpers/exports.d.ts +15 -0
- package/dist/esm/client/helpers/exports.js +35 -0
- package/dist/esm/client/helpers/index.d.ts +1 -0
- package/dist/esm/client/helpers/index.js +1 -0
- package/dist/esm/client/version.d.ts +1 -1
- package/dist/esm/client/version.js +1 -1
- package/dist/esm/client/vertex-client.d.ts +2 -1
- package/dist/esm/client/vertex-client.js +2 -1
- package/package.json +1 -1
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { CreateExportRequest, Export } from '../../index';
|
|
2
|
+
import { BaseReq } from '../index';
|
|
3
|
+
/**
|
|
4
|
+
* Create export arguments.
|
|
5
|
+
*/
|
|
6
|
+
export interface CreateExportReq extends BaseReq {
|
|
7
|
+
/** Function returning a {@link CreateExportRequest}. */
|
|
8
|
+
readonly createExportReq: () => CreateExportRequest;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Create an export.
|
|
12
|
+
*
|
|
13
|
+
* @param args - The {@link CreateExportReq}.
|
|
14
|
+
*/
|
|
15
|
+
export declare function createExport({ client, createExportReq, onMsg, verbose, }: CreateExportReq): Promise<Export>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.createExport = void 0;
|
|
13
|
+
const index_1 = require("../index");
|
|
14
|
+
/**
|
|
15
|
+
* Create an export.
|
|
16
|
+
*
|
|
17
|
+
* @param args - The {@link CreateExportReq}.
|
|
18
|
+
*/
|
|
19
|
+
function createExport({ client, createExportReq, onMsg = console.log, verbose, }) {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const res = yield client.exports.createExport({
|
|
22
|
+
createExportRequest: createExportReq(),
|
|
23
|
+
});
|
|
24
|
+
const queuedId = res.data.data.id;
|
|
25
|
+
if (verbose)
|
|
26
|
+
onMsg(`Created export with queued-export ${queuedId}`);
|
|
27
|
+
const pollRes = yield (0, index_1.pollQueuedJob)({
|
|
28
|
+
id: queuedId,
|
|
29
|
+
getQueuedJob: (id) => client.exports.getQueuedExport({ id }),
|
|
30
|
+
polling: { intervalMs: index_1.PollIntervalMs, maxAttempts: index_1.MaxAttempts },
|
|
31
|
+
});
|
|
32
|
+
if ((0, index_1.isPollError)(pollRes.res))
|
|
33
|
+
(0, index_1.throwOnError)(pollRes);
|
|
34
|
+
if (verbose)
|
|
35
|
+
onMsg(`Completed export ${pollRes.res.data.id}`);
|
|
36
|
+
return pollRes.res;
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
exports.createExport = createExport;
|
|
@@ -10,6 +10,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
10
10
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./exports"), exports);
|
|
13
14
|
__exportStar(require("./files"), exports);
|
|
14
15
|
__exportStar(require("./parts"), exports);
|
|
15
16
|
__exportStar(require("./scenes"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.
|
|
1
|
+
export declare const version = "0.17.1";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AxiosInstance, AxiosRequestConfig } from 'axios';
|
|
2
|
-
import { AccountsApi, ApplicationsApi, BatchesApi, Configuration, FilesApi, GeometrySetsApi, HitsApi, Oauth2Api, OAuth2Token, PartRevisionsApi, PartsApi, SceneAlterationsApi, SceneItemOverridesApi, SceneItemsApi, ScenesApi, SceneViewsApi, SceneViewStatesApi, StreamKeysApi, TranslationInspectionsApi, WebhookSubscriptionsApi } from '../index';
|
|
2
|
+
import { AccountsApi, ApplicationsApi, BatchesApi, Configuration, ExportsApi, FilesApi, GeometrySetsApi, HitsApi, Oauth2Api, OAuth2Token, PartRevisionsApi, PartsApi, SceneAlterationsApi, SceneItemOverridesApi, SceneItemsApi, ScenesApi, SceneViewsApi, SceneViewStatesApi, StreamKeysApi, TranslationInspectionsApi, WebhookSubscriptionsApi } from '../index';
|
|
3
3
|
import { BasePath } from './index';
|
|
4
4
|
/**
|
|
5
5
|
* Static `build` function arguments.
|
|
@@ -72,6 +72,7 @@ export declare class VertexClient {
|
|
|
72
72
|
accounts: AccountsApi;
|
|
73
73
|
applications: ApplicationsApi;
|
|
74
74
|
batches: BatchesApi;
|
|
75
|
+
exports: ExportsApi;
|
|
75
76
|
files: FilesApi;
|
|
76
77
|
geometrySets: GeometrySetsApi;
|
|
77
78
|
hits: HitsApi;
|
|
@@ -79,6 +79,7 @@ class VertexClient {
|
|
|
79
79
|
this.accounts = new index_1.AccountsApi(this.config, undefined, axiosInst);
|
|
80
80
|
this.applications = new index_1.ApplicationsApi(this.config, undefined, axiosInst);
|
|
81
81
|
this.batches = new index_1.BatchesApi(this.config, undefined, axiosInst);
|
|
82
|
+
this.exports = new index_1.ExportsApi(this.config, undefined, axiosInst);
|
|
82
83
|
this.files = new index_1.FilesApi(this.config, undefined, axiosInst);
|
|
83
84
|
this.geometrySets = new index_1.GeometrySetsApi(this.config, undefined, axiosInst);
|
|
84
85
|
this.hits = new index_1.HitsApi(this.config, undefined, axiosInst);
|