@nizam-os/operator-sdk 2.5.1 → 2.6.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/dist/Client.d.ts +3 -0
- package/dist/Client.js +8 -4
- package/dist/api/errors/BadGatewayError.d.ts +6 -0
- package/dist/api/errors/BadGatewayError.js +54 -0
- package/dist/api/errors/BadRequestError.d.ts +6 -0
- package/dist/api/errors/BadRequestError.js +54 -0
- package/dist/api/errors/index.d.ts +2 -0
- package/dist/api/errors/index.js +2 -0
- package/dist/api/resources/index.d.ts +1 -0
- package/dist/api/resources/index.js +2 -1
- package/dist/api/resources/positions/client/Client.d.ts +31 -0
- package/dist/api/resources/positions/client/Client.js +114 -0
- package/dist/api/resources/positions/client/index.d.ts +1 -0
- package/dist/api/resources/positions/client/index.js +2 -0
- package/dist/api/resources/positions/exports.d.ts +2 -0
- package/dist/api/resources/positions/exports.js +21 -0
- package/dist/api/resources/positions/index.d.ts +1 -0
- package/dist/api/resources/positions/index.js +17 -0
- package/dist/api/types/BulkJobSubmission.d.ts +15 -0
- package/dist/api/types/BulkJobSubmission.js +10 -0
- package/dist/api/types/HeatmapCell.d.ts +18 -0
- package/dist/api/types/HeatmapCell.js +10 -0
- package/dist/api/types/Job.d.ts +66 -0
- package/dist/api/types/Job.js +24 -0
- package/dist/api/types/JobSubmission.d.ts +14 -0
- package/dist/api/types/JobSubmission.js +10 -0
- package/dist/api/types/ListResponseHeatmapCell.d.ts +27 -0
- package/dist/api/types/ListResponseHeatmapCell.js +11 -0
- package/dist/api/types/ListResponseJob.d.ts +27 -0
- package/dist/api/types/ListResponseJob.js +11 -0
- package/dist/api/types/ListResponseOperatorPosition.d.ts +27 -0
- package/dist/api/types/ListResponseOperatorPosition.js +11 -0
- package/dist/api/types/ListResponsePosition.d.ts +27 -0
- package/dist/api/types/ListResponsePosition.js +11 -0
- package/dist/api/types/MqttToken.d.ts +12 -0
- package/dist/api/types/MqttToken.js +3 -0
- package/dist/api/types/OperatorPosition.d.ts +28 -0
- package/dist/api/types/OperatorPosition.js +10 -0
- package/dist/api/types/Position.d.ts +30 -0
- package/dist/api/types/Position.js +10 -0
- package/dist/api/types/index.d.ts +11 -0
- package/dist/api/types/index.js +11 -0
- package/package.json +1 -1
package/dist/Client.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { InvitesClient } from "./api/resources/invites/client/Client.js";
|
|
2
2
|
import { LookupsClient } from "./api/resources/lookups/client/Client.js";
|
|
3
|
+
import { PositionsClient } from "./api/resources/positions/client/Client.js";
|
|
3
4
|
import { RealtimeClient } from "./api/resources/realtime/client/Client.js";
|
|
4
5
|
import { UsersClient } from "./api/resources/users/client/Client.js";
|
|
5
6
|
import type { BaseClientOptions, BaseRequestOptions } from "./BaseClient.js";
|
|
@@ -15,11 +16,13 @@ export declare class NizamOperatorRuntimeClient {
|
|
|
15
16
|
protected _invites: InvitesClient | undefined;
|
|
16
17
|
protected _lookups: LookupsClient | undefined;
|
|
17
18
|
protected _users: UsersClient | undefined;
|
|
19
|
+
protected _positions: PositionsClient | undefined;
|
|
18
20
|
protected _realtime: RealtimeClient | undefined;
|
|
19
21
|
constructor(options: NizamOperatorRuntimeClient.Options);
|
|
20
22
|
get invites(): InvitesClient;
|
|
21
23
|
get lookups(): LookupsClient;
|
|
22
24
|
get users(): UsersClient;
|
|
25
|
+
get positions(): PositionsClient;
|
|
23
26
|
get realtime(): RealtimeClient;
|
|
24
27
|
/**
|
|
25
28
|
* Make a passthrough request using the SDK's configured auth, retry, logging, etc.
|
package/dist/Client.js
CHANGED
|
@@ -37,8 +37,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
37
37
|
exports.NizamOperatorRuntimeClient = void 0;
|
|
38
38
|
const Client_js_1 = require("./api/resources/invites/client/Client.js");
|
|
39
39
|
const Client_js_2 = require("./api/resources/lookups/client/Client.js");
|
|
40
|
-
const Client_js_3 = require("./api/resources/
|
|
41
|
-
const Client_js_4 = require("./api/resources/
|
|
40
|
+
const Client_js_3 = require("./api/resources/positions/client/Client.js");
|
|
41
|
+
const Client_js_4 = require("./api/resources/realtime/client/Client.js");
|
|
42
|
+
const Client_js_5 = require("./api/resources/users/client/Client.js");
|
|
42
43
|
const BaseClient_js_1 = require("./BaseClient.js");
|
|
43
44
|
const core = __importStar(require("./core/index.js"));
|
|
44
45
|
class NizamOperatorRuntimeClient {
|
|
@@ -52,10 +53,13 @@ class NizamOperatorRuntimeClient {
|
|
|
52
53
|
return (this._lookups ?? (this._lookups = new Client_js_2.LookupsClient(this._options)));
|
|
53
54
|
}
|
|
54
55
|
get users() {
|
|
55
|
-
return (this._users ?? (this._users = new
|
|
56
|
+
return (this._users ?? (this._users = new Client_js_5.UsersClient(this._options)));
|
|
57
|
+
}
|
|
58
|
+
get positions() {
|
|
59
|
+
return (this._positions ?? (this._positions = new Client_js_3.PositionsClient(this._options)));
|
|
56
60
|
}
|
|
57
61
|
get realtime() {
|
|
58
|
-
return (this._realtime ?? (this._realtime = new
|
|
62
|
+
return (this._realtime ?? (this._realtime = new Client_js_4.RealtimeClient(this._options)));
|
|
59
63
|
}
|
|
60
64
|
/**
|
|
61
65
|
* Make a passthrough request using the SDK's configured auth, retry, logging, etc.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type * as core from "../../core/index.js";
|
|
2
|
+
import * as errors from "../../errors/index.js";
|
|
3
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
4
|
+
export declare class BadGatewayError extends errors.NizamOperatorRuntimeError {
|
|
5
|
+
constructor(body: NizamOperatorRuntime.ProblemDetail, rawResponse?: core.RawResponse);
|
|
6
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.BadGatewayError = void 0;
|
|
38
|
+
const errors = __importStar(require("../../errors/index.js"));
|
|
39
|
+
class BadGatewayError extends errors.NizamOperatorRuntimeError {
|
|
40
|
+
constructor(body, rawResponse) {
|
|
41
|
+
super({
|
|
42
|
+
message: "BadGatewayError",
|
|
43
|
+
statusCode: 502,
|
|
44
|
+
body: body,
|
|
45
|
+
rawResponse: rawResponse,
|
|
46
|
+
});
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
exports.BadGatewayError = BadGatewayError;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type * as core from "../../core/index.js";
|
|
2
|
+
import * as errors from "../../errors/index.js";
|
|
3
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
4
|
+
export declare class BadRequestError extends errors.NizamOperatorRuntimeError {
|
|
5
|
+
constructor(body: NizamOperatorRuntime.ProblemDetail, rawResponse?: core.RawResponse);
|
|
6
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.BadRequestError = void 0;
|
|
38
|
+
const errors = __importStar(require("../../errors/index.js"));
|
|
39
|
+
class BadRequestError extends errors.NizamOperatorRuntimeError {
|
|
40
|
+
constructor(body, rawResponse) {
|
|
41
|
+
super({
|
|
42
|
+
message: "BadRequestError",
|
|
43
|
+
statusCode: 400,
|
|
44
|
+
body: body,
|
|
45
|
+
rawResponse: rawResponse,
|
|
46
|
+
});
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
exports.BadRequestError = BadRequestError;
|
package/dist/api/errors/index.js
CHANGED
|
@@ -14,6 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./BadGatewayError.js"), exports);
|
|
18
|
+
__exportStar(require("./BadRequestError.js"), exports);
|
|
17
19
|
__exportStar(require("./ConflictError.js"), exports);
|
|
18
20
|
__exportStar(require("./ForbiddenError.js"), exports);
|
|
19
21
|
__exportStar(require("./GoneError.js"), exports);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export * from "./invites/client/requests/index.js";
|
|
2
2
|
export * as invites from "./invites/index.js";
|
|
3
3
|
export * as lookups from "./lookups/index.js";
|
|
4
|
+
export * as positions from "./positions/index.js";
|
|
4
5
|
export * as realtime from "./realtime/index.js";
|
|
5
6
|
export * as users from "./users/index.js";
|
|
@@ -36,9 +36,10 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
36
36
|
};
|
|
37
37
|
})();
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.users = exports.realtime = exports.lookups = exports.invites = void 0;
|
|
39
|
+
exports.users = exports.realtime = exports.positions = exports.lookups = exports.invites = void 0;
|
|
40
40
|
__exportStar(require("./invites/client/requests/index.js"), exports);
|
|
41
41
|
exports.invites = __importStar(require("./invites/index.js"));
|
|
42
42
|
exports.lookups = __importStar(require("./lookups/index.js"));
|
|
43
|
+
exports.positions = __importStar(require("./positions/index.js"));
|
|
43
44
|
exports.realtime = __importStar(require("./realtime/index.js"));
|
|
44
45
|
exports.users = __importStar(require("./users/index.js"));
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../core/index.js";
|
|
4
|
+
import * as NizamOperatorRuntime from "../../../index.js";
|
|
5
|
+
export declare namespace PositionsClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export declare class PositionsClient {
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<PositionsClient.Options>;
|
|
12
|
+
constructor(options: PositionsClient.Options);
|
|
13
|
+
/**
|
|
14
|
+
* Exchanges the caller's access token for a short-lived MQTT credential (aud=mqtt) scoped to the caller's own operator. Connect to the broker with username = the operator id and password = the returned token, then publish position pings to the returned topic. The credential expires after `expires_in` seconds — re-mint before then (budget: 30/hour).
|
|
15
|
+
*
|
|
16
|
+
* @param {PositionsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
17
|
+
*
|
|
18
|
+
* @throws {@link NizamOperatorRuntime.BadRequestError}
|
|
19
|
+
* @throws {@link NizamOperatorRuntime.UnauthorizedError}
|
|
20
|
+
* @throws {@link NizamOperatorRuntime.ForbiddenError}
|
|
21
|
+
* @throws {@link NizamOperatorRuntime.NotFoundError}
|
|
22
|
+
* @throws {@link NizamOperatorRuntime.TooManyRequestsError}
|
|
23
|
+
* @throws {@link NizamOperatorRuntime.InternalServerError}
|
|
24
|
+
* @throws {@link NizamOperatorRuntime.BadGatewayError}
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* await client.positions.mintMqttToken()
|
|
28
|
+
*/
|
|
29
|
+
mintMqttToken(requestOptions?: PositionsClient.RequestOptions): core.HttpResponsePromise<NizamOperatorRuntime.MqttToken>;
|
|
30
|
+
private __mintMqttToken;
|
|
31
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.PositionsClient = void 0;
|
|
38
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
39
|
+
const headers_js_1 = require("../../../../core/headers.js");
|
|
40
|
+
const core = __importStar(require("../../../../core/index.js"));
|
|
41
|
+
const environments = __importStar(require("../../../../environments.js"));
|
|
42
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
43
|
+
const errors = __importStar(require("../../../../errors/index.js"));
|
|
44
|
+
const NizamOperatorRuntime = __importStar(require("../../../index.js"));
|
|
45
|
+
class PositionsClient {
|
|
46
|
+
constructor(options) {
|
|
47
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Exchanges the caller's access token for a short-lived MQTT credential (aud=mqtt) scoped to the caller's own operator. Connect to the broker with username = the operator id and password = the returned token, then publish position pings to the returned topic. The credential expires after `expires_in` seconds — re-mint before then (budget: 30/hour).
|
|
51
|
+
*
|
|
52
|
+
* @param {PositionsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
53
|
+
*
|
|
54
|
+
* @throws {@link NizamOperatorRuntime.BadRequestError}
|
|
55
|
+
* @throws {@link NizamOperatorRuntime.UnauthorizedError}
|
|
56
|
+
* @throws {@link NizamOperatorRuntime.ForbiddenError}
|
|
57
|
+
* @throws {@link NizamOperatorRuntime.NotFoundError}
|
|
58
|
+
* @throws {@link NizamOperatorRuntime.TooManyRequestsError}
|
|
59
|
+
* @throws {@link NizamOperatorRuntime.InternalServerError}
|
|
60
|
+
* @throws {@link NizamOperatorRuntime.BadGatewayError}
|
|
61
|
+
*
|
|
62
|
+
* @example
|
|
63
|
+
* await client.positions.mintMqttToken()
|
|
64
|
+
*/
|
|
65
|
+
mintMqttToken(requestOptions) {
|
|
66
|
+
return core.HttpResponsePromise.fromPromise(this.__mintMqttToken(requestOptions));
|
|
67
|
+
}
|
|
68
|
+
async __mintMqttToken(requestOptions) {
|
|
69
|
+
const _authRequest = await this._options.authProvider.getAuthRequest();
|
|
70
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, this._options?.headers, requestOptions?.headers);
|
|
71
|
+
const _response = await core.fetcher({
|
|
72
|
+
url: core.url.join((await core.Supplier.get(this._options.baseUrl)) ??
|
|
73
|
+
(await core.Supplier.get(this._options.environment)) ??
|
|
74
|
+
environments.NizamOperatorRuntimeEnvironment.Production, "v1/me/mqtt-token"),
|
|
75
|
+
method: "POST",
|
|
76
|
+
headers: _headers,
|
|
77
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions?.queryParams).build(),
|
|
78
|
+
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
|
|
79
|
+
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
|
|
80
|
+
abortSignal: requestOptions?.abortSignal,
|
|
81
|
+
fetchFn: this._options?.fetch,
|
|
82
|
+
logging: this._options.logging,
|
|
83
|
+
});
|
|
84
|
+
if (_response.ok) {
|
|
85
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
86
|
+
}
|
|
87
|
+
if (_response.error.reason === "status-code") {
|
|
88
|
+
switch (_response.error.statusCode) {
|
|
89
|
+
case 400:
|
|
90
|
+
throw new NizamOperatorRuntime.BadRequestError(_response.error.body, _response.rawResponse);
|
|
91
|
+
case 401:
|
|
92
|
+
throw new NizamOperatorRuntime.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
93
|
+
case 403:
|
|
94
|
+
throw new NizamOperatorRuntime.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
95
|
+
case 404:
|
|
96
|
+
throw new NizamOperatorRuntime.NotFoundError(_response.error.body, _response.rawResponse);
|
|
97
|
+
case 429:
|
|
98
|
+
throw new NizamOperatorRuntime.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
99
|
+
case 500:
|
|
100
|
+
throw new NizamOperatorRuntime.InternalServerError(_response.error.body, _response.rawResponse);
|
|
101
|
+
case 502:
|
|
102
|
+
throw new NizamOperatorRuntime.BadGatewayError(_response.error.body, _response.rawResponse);
|
|
103
|
+
default:
|
|
104
|
+
throw new errors.NizamOperatorRuntimeError({
|
|
105
|
+
statusCode: _response.error.statusCode,
|
|
106
|
+
body: _response.error.body,
|
|
107
|
+
rawResponse: _response.rawResponse,
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/v1/me/mqtt-token");
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
exports.PositionsClient = PositionsClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.PositionsClient = void 0;
|
|
19
|
+
var Client_js_1 = require("./client/Client.js");
|
|
20
|
+
Object.defineProperty(exports, "PositionsClient", { enumerable: true, get: function () { return Client_js_1.PositionsClient; } });
|
|
21
|
+
__exportStar(require("./client/index.js"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Acknowledgement of a bulk admin action that fanned out one job per work item.
|
|
3
|
+
*/
|
|
4
|
+
export interface BulkJobSubmission {
|
|
5
|
+
job_ids?: string[] | undefined;
|
|
6
|
+
/** Number of jobs created (one per matched service account). */
|
|
7
|
+
count?: number | undefined;
|
|
8
|
+
object?: BulkJobSubmission.Object_ | undefined;
|
|
9
|
+
}
|
|
10
|
+
export declare namespace BulkJobSubmission {
|
|
11
|
+
const Object_: {
|
|
12
|
+
readonly BulkJobSubmission: "bulk_job_submission";
|
|
13
|
+
};
|
|
14
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
15
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.BulkJobSubmission = void 0;
|
|
5
|
+
var BulkJobSubmission;
|
|
6
|
+
(function (BulkJobSubmission) {
|
|
7
|
+
BulkJobSubmission.Object_ = {
|
|
8
|
+
BulkJobSubmission: "bulk_job_submission",
|
|
9
|
+
};
|
|
10
|
+
})(BulkJobSubmission || (exports.BulkJobSubmission = BulkJobSubmission = {}));
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Aggregated position count for one H3 hex cell.
|
|
3
|
+
*/
|
|
4
|
+
export interface HeatmapCell {
|
|
5
|
+
/** H3 cell index, lowercase hex (string — H3 indexes exceed the JS safe-integer range). */
|
|
6
|
+
h3_cell?: string | undefined;
|
|
7
|
+
/** H3 resolution of the cell (9 or 11). */
|
|
8
|
+
h3_res?: number | undefined;
|
|
9
|
+
/** Number of positions recorded in the cell over the window. */
|
|
10
|
+
count?: number | undefined;
|
|
11
|
+
object?: HeatmapCell.Object_ | undefined;
|
|
12
|
+
}
|
|
13
|
+
export declare namespace HeatmapCell {
|
|
14
|
+
const Object_: {
|
|
15
|
+
readonly HeatmapCell: "heatmap_cell";
|
|
16
|
+
};
|
|
17
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
18
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.HeatmapCell = void 0;
|
|
5
|
+
var HeatmapCell;
|
|
6
|
+
(function (HeatmapCell) {
|
|
7
|
+
HeatmapCell.Object_ = {
|
|
8
|
+
HeatmapCell: "heatmap_cell",
|
|
9
|
+
};
|
|
10
|
+
})(HeatmapCell || (exports.HeatmapCell = HeatmapCell = {}));
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A long-running, retryable, operator-visible unit of work — bulk imports, exports, backfills, cache rebuilds. The job row is the persistent handle; the executing engine (Temporal workflow or lease worker, declared per kind) reports progress into it. Cancellation is cooperative: already-running work continues until the engine's next checkpoint.
|
|
3
|
+
*/
|
|
4
|
+
export interface Job {
|
|
5
|
+
/** Stable job id. */
|
|
6
|
+
id?: string | undefined;
|
|
7
|
+
/** Owning organization. */
|
|
8
|
+
organization_id?: string | undefined;
|
|
9
|
+
/** What kind of work this job performs; the kind also fixes the executing engine. */
|
|
10
|
+
kind?: Job.Kind | undefined;
|
|
11
|
+
/** Lifecycle status. Terminal states are `completed`, `failed`, `cancelled`. */
|
|
12
|
+
status?: Job.Status | undefined;
|
|
13
|
+
/** User who submitted the job. Null only if that user was since deleted. */
|
|
14
|
+
requested_by_id?: string | undefined;
|
|
15
|
+
/** Input handle the job consumes (kind-specific), e.g. an uploaded import file. */
|
|
16
|
+
source_uri?: string | undefined;
|
|
17
|
+
/** Artifact produced by a completed job (kind-specific), e.g. a result report. */
|
|
18
|
+
report_uri?: string | undefined;
|
|
19
|
+
/** Total work items, once the engine has sized the work. Null while unknown. */
|
|
20
|
+
rows_total?: number | undefined;
|
|
21
|
+
/** Work items processed so far (monotonic). */
|
|
22
|
+
rows_processed?: number | undefined;
|
|
23
|
+
/** Work items that failed so far (monotonic). */
|
|
24
|
+
rows_failed?: number | undefined;
|
|
25
|
+
/** Operator-facing failure reason. Set only when status is `failed`. */
|
|
26
|
+
error_summary?: string | undefined;
|
|
27
|
+
/** Temporal workflow id (Temporal-engine kinds only) — cross-reference into the Temporal UI. */
|
|
28
|
+
workflow_id?: string | undefined;
|
|
29
|
+
/** Temporal run id of the latest attempt (changes across workflow retries). */
|
|
30
|
+
run_id?: string | undefined;
|
|
31
|
+
/** Engine execution attempts spent so far. */
|
|
32
|
+
attempt_count?: number | undefined;
|
|
33
|
+
/** Retry budget: a failed job with attempt_count >= max_attempts is dead-lettered. */
|
|
34
|
+
max_attempts?: number | undefined;
|
|
35
|
+
/** When the first engine attempt started. Null while pending (and for jobs cancelled before starting). */
|
|
36
|
+
started_at?: string | undefined;
|
|
37
|
+
/** When the job reached a terminal status. */
|
|
38
|
+
finished_at?: string | undefined;
|
|
39
|
+
/** Submission time. */
|
|
40
|
+
created_at?: string | undefined;
|
|
41
|
+
/** Last state/progress change. */
|
|
42
|
+
updated_at?: string | undefined;
|
|
43
|
+
object?: Job.Object_ | undefined;
|
|
44
|
+
}
|
|
45
|
+
export declare namespace Job {
|
|
46
|
+
/** What kind of work this job performs; the kind also fixes the executing engine. */
|
|
47
|
+
const Kind: {
|
|
48
|
+
readonly MembershipCacheRebuild: "membership_cache_rebuild";
|
|
49
|
+
readonly ServiceAccountApiKeyRegeneration: "service_account_api_key_regeneration";
|
|
50
|
+
};
|
|
51
|
+
type Kind = (typeof Kind)[keyof typeof Kind];
|
|
52
|
+
/** Lifecycle status. Terminal states are `completed`, `failed`, `cancelled`. */
|
|
53
|
+
const Status: {
|
|
54
|
+
readonly Pending: "pending";
|
|
55
|
+
readonly Running: "running";
|
|
56
|
+
readonly Cancelling: "cancelling";
|
|
57
|
+
readonly Completed: "completed";
|
|
58
|
+
readonly Failed: "failed";
|
|
59
|
+
readonly Cancelled: "cancelled";
|
|
60
|
+
};
|
|
61
|
+
type Status = (typeof Status)[keyof typeof Status];
|
|
62
|
+
const Object_: {
|
|
63
|
+
readonly Job: "job";
|
|
64
|
+
};
|
|
65
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
66
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Job = void 0;
|
|
5
|
+
var Job;
|
|
6
|
+
(function (Job) {
|
|
7
|
+
/** What kind of work this job performs; the kind also fixes the executing engine. */
|
|
8
|
+
Job.Kind = {
|
|
9
|
+
MembershipCacheRebuild: "membership_cache_rebuild",
|
|
10
|
+
ServiceAccountApiKeyRegeneration: "service_account_api_key_regeneration",
|
|
11
|
+
};
|
|
12
|
+
/** Lifecycle status. Terminal states are `completed`, `failed`, `cancelled`. */
|
|
13
|
+
Job.Status = {
|
|
14
|
+
Pending: "pending",
|
|
15
|
+
Running: "running",
|
|
16
|
+
Cancelling: "cancelling",
|
|
17
|
+
Completed: "completed",
|
|
18
|
+
Failed: "failed",
|
|
19
|
+
Cancelled: "cancelled",
|
|
20
|
+
};
|
|
21
|
+
Job.Object_ = {
|
|
22
|
+
Job: "job",
|
|
23
|
+
};
|
|
24
|
+
})(Job || (exports.Job = Job = {}));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Acknowledgement that a job was submitted to its engine.
|
|
3
|
+
*/
|
|
4
|
+
export interface JobSubmission {
|
|
5
|
+
/** The created job — poll/cancel it via /v1/jobs/{id}. */
|
|
6
|
+
job_id?: string | undefined;
|
|
7
|
+
object?: JobSubmission.Object_ | undefined;
|
|
8
|
+
}
|
|
9
|
+
export declare namespace JobSubmission {
|
|
10
|
+
const Object_: {
|
|
11
|
+
readonly JobSubmission: "job_submission";
|
|
12
|
+
};
|
|
13
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
14
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.JobSubmission = void 0;
|
|
5
|
+
var JobSubmission;
|
|
6
|
+
(function (JobSubmission) {
|
|
7
|
+
JobSubmission.Object_ = {
|
|
8
|
+
JobSubmission: "job_submission",
|
|
9
|
+
};
|
|
10
|
+
})(JobSubmission || (exports.JobSubmission = JobSubmission = {}));
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Envelope for paginated list responses (Stripe-style cursor pagination).
|
|
4
|
+
*/
|
|
5
|
+
export interface ListResponseHeatmapCell {
|
|
6
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
7
|
+
object?: ListResponseHeatmapCell.Object_ | undefined;
|
|
8
|
+
/** Page of resources. Empty array when there are no matches. */
|
|
9
|
+
data?: NizamOperatorRuntime.HeatmapCell[] | undefined;
|
|
10
|
+
/** True when more pages exist; pass `next_cursor` as `?starting_after=` to fetch the next page. */
|
|
11
|
+
has_more?: boolean | undefined;
|
|
12
|
+
/** True when earlier pages exist; pass `prev_cursor` as `?ending_before=` to fetch the previous page. */
|
|
13
|
+
has_previous?: boolean | undefined;
|
|
14
|
+
/** Opaque cursor for the next page. `null` on the last page. */
|
|
15
|
+
next_cursor?: string | undefined;
|
|
16
|
+
/** Opaque cursor for the previous page. `null` on the first page. */
|
|
17
|
+
prev_cursor?: string | undefined;
|
|
18
|
+
/** Page size that produced this response. */
|
|
19
|
+
limit?: number | undefined;
|
|
20
|
+
}
|
|
21
|
+
export declare namespace ListResponseHeatmapCell {
|
|
22
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
23
|
+
const Object_: {
|
|
24
|
+
readonly List: "list";
|
|
25
|
+
};
|
|
26
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.ListResponseHeatmapCell = void 0;
|
|
5
|
+
var ListResponseHeatmapCell;
|
|
6
|
+
(function (ListResponseHeatmapCell) {
|
|
7
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
8
|
+
ListResponseHeatmapCell.Object_ = {
|
|
9
|
+
List: "list",
|
|
10
|
+
};
|
|
11
|
+
})(ListResponseHeatmapCell || (exports.ListResponseHeatmapCell = ListResponseHeatmapCell = {}));
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Envelope for paginated list responses (Stripe-style cursor pagination).
|
|
4
|
+
*/
|
|
5
|
+
export interface ListResponseJob {
|
|
6
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
7
|
+
object?: ListResponseJob.Object_ | undefined;
|
|
8
|
+
/** Page of resources. Empty array when there are no matches. */
|
|
9
|
+
data?: NizamOperatorRuntime.Job[] | undefined;
|
|
10
|
+
/** True when more pages exist; pass `next_cursor` as `?starting_after=` to fetch the next page. */
|
|
11
|
+
has_more?: boolean | undefined;
|
|
12
|
+
/** True when earlier pages exist; pass `prev_cursor` as `?ending_before=` to fetch the previous page. */
|
|
13
|
+
has_previous?: boolean | undefined;
|
|
14
|
+
/** Opaque cursor for the next page. `null` on the last page. */
|
|
15
|
+
next_cursor?: string | undefined;
|
|
16
|
+
/** Opaque cursor for the previous page. `null` on the first page. */
|
|
17
|
+
prev_cursor?: string | undefined;
|
|
18
|
+
/** Page size that produced this response. */
|
|
19
|
+
limit?: number | undefined;
|
|
20
|
+
}
|
|
21
|
+
export declare namespace ListResponseJob {
|
|
22
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
23
|
+
const Object_: {
|
|
24
|
+
readonly List: "list";
|
|
25
|
+
};
|
|
26
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.ListResponseJob = void 0;
|
|
5
|
+
var ListResponseJob;
|
|
6
|
+
(function (ListResponseJob) {
|
|
7
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
8
|
+
ListResponseJob.Object_ = {
|
|
9
|
+
List: "list",
|
|
10
|
+
};
|
|
11
|
+
})(ListResponseJob || (exports.ListResponseJob = ListResponseJob = {}));
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Envelope for paginated list responses (Stripe-style cursor pagination).
|
|
4
|
+
*/
|
|
5
|
+
export interface ListResponseOperatorPosition {
|
|
6
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
7
|
+
object?: ListResponseOperatorPosition.Object_ | undefined;
|
|
8
|
+
/** Page of resources. Empty array when there are no matches. */
|
|
9
|
+
data?: NizamOperatorRuntime.OperatorPosition[] | undefined;
|
|
10
|
+
/** True when more pages exist; pass `next_cursor` as `?starting_after=` to fetch the next page. */
|
|
11
|
+
has_more?: boolean | undefined;
|
|
12
|
+
/** True when earlier pages exist; pass `prev_cursor` as `?ending_before=` to fetch the previous page. */
|
|
13
|
+
has_previous?: boolean | undefined;
|
|
14
|
+
/** Opaque cursor for the next page. `null` on the last page. */
|
|
15
|
+
next_cursor?: string | undefined;
|
|
16
|
+
/** Opaque cursor for the previous page. `null` on the first page. */
|
|
17
|
+
prev_cursor?: string | undefined;
|
|
18
|
+
/** Page size that produced this response. */
|
|
19
|
+
limit?: number | undefined;
|
|
20
|
+
}
|
|
21
|
+
export declare namespace ListResponseOperatorPosition {
|
|
22
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
23
|
+
const Object_: {
|
|
24
|
+
readonly List: "list";
|
|
25
|
+
};
|
|
26
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.ListResponseOperatorPosition = void 0;
|
|
5
|
+
var ListResponseOperatorPosition;
|
|
6
|
+
(function (ListResponseOperatorPosition) {
|
|
7
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
8
|
+
ListResponseOperatorPosition.Object_ = {
|
|
9
|
+
List: "list",
|
|
10
|
+
};
|
|
11
|
+
})(ListResponseOperatorPosition || (exports.ListResponseOperatorPosition = ListResponseOperatorPosition = {}));
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type * as NizamOperatorRuntime from "../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Envelope for paginated list responses (Stripe-style cursor pagination).
|
|
4
|
+
*/
|
|
5
|
+
export interface ListResponsePosition {
|
|
6
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
7
|
+
object?: ListResponsePosition.Object_ | undefined;
|
|
8
|
+
/** Page of resources. Empty array when there are no matches. */
|
|
9
|
+
data?: NizamOperatorRuntime.Position[] | undefined;
|
|
10
|
+
/** True when more pages exist; pass `next_cursor` as `?starting_after=` to fetch the next page. */
|
|
11
|
+
has_more?: boolean | undefined;
|
|
12
|
+
/** True when earlier pages exist; pass `prev_cursor` as `?ending_before=` to fetch the previous page. */
|
|
13
|
+
has_previous?: boolean | undefined;
|
|
14
|
+
/** Opaque cursor for the next page. `null` on the last page. */
|
|
15
|
+
next_cursor?: string | undefined;
|
|
16
|
+
/** Opaque cursor for the previous page. `null` on the first page. */
|
|
17
|
+
prev_cursor?: string | undefined;
|
|
18
|
+
/** Page size that produced this response. */
|
|
19
|
+
limit?: number | undefined;
|
|
20
|
+
}
|
|
21
|
+
export declare namespace ListResponsePosition {
|
|
22
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
23
|
+
const Object_: {
|
|
24
|
+
readonly List: "list";
|
|
25
|
+
};
|
|
26
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.ListResponsePosition = void 0;
|
|
5
|
+
var ListResponsePosition;
|
|
6
|
+
(function (ListResponsePosition) {
|
|
7
|
+
/** Object type discriminator (Stripe pattern). Always `list` for this envelope. */
|
|
8
|
+
ListResponsePosition.Object_ = {
|
|
9
|
+
List: "list",
|
|
10
|
+
};
|
|
11
|
+
})(ListResponsePosition || (exports.ListResponsePosition = ListResponsePosition = {}));
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A short-lived MQTT publish credential for the position ingest broker.
|
|
3
|
+
*/
|
|
4
|
+
export interface MqttToken {
|
|
5
|
+
/** JWT to present as the MQTT CONNECT password. The CONNECT username must be the operator id embedded in the token's operator_id claim. */
|
|
6
|
+
token?: string | undefined;
|
|
7
|
+
/** Seconds until the token expires. Re-mint before this elapses to stay connected. */
|
|
8
|
+
expires_in?: number | undefined;
|
|
9
|
+
/** The only topic this credential may publish to: nizam/{organizationId}/operators/{operatorId}/location. */
|
|
10
|
+
topic?: string | undefined;
|
|
11
|
+
object?: string | undefined;
|
|
12
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The current position of one operator.
|
|
3
|
+
*/
|
|
4
|
+
export interface OperatorPosition {
|
|
5
|
+
/** Operator id. */
|
|
6
|
+
operator_id?: string | undefined;
|
|
7
|
+
/** Latitude (WGS84). */
|
|
8
|
+
lat?: number | undefined;
|
|
9
|
+
/** Longitude (WGS84). */
|
|
10
|
+
lng?: number | undefined;
|
|
11
|
+
/** Direction of travel, compass degrees [0,360). */
|
|
12
|
+
heading?: number | undefined;
|
|
13
|
+
/** Course over ground, compass degrees [0,360). */
|
|
14
|
+
bearing?: number | undefined;
|
|
15
|
+
/** Ground speed, km/h. */
|
|
16
|
+
speed?: number | undefined;
|
|
17
|
+
/** Altitude above the WGS84 ellipsoid, metres. */
|
|
18
|
+
altitude?: number | undefined;
|
|
19
|
+
/** Device-time of the fix. */
|
|
20
|
+
captured_at?: string | undefined;
|
|
21
|
+
object?: OperatorPosition.Object_ | undefined;
|
|
22
|
+
}
|
|
23
|
+
export declare namespace OperatorPosition {
|
|
24
|
+
const Object_: {
|
|
25
|
+
readonly OperatorPosition: "operator_position";
|
|
26
|
+
};
|
|
27
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
28
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.OperatorPosition = void 0;
|
|
5
|
+
var OperatorPosition;
|
|
6
|
+
(function (OperatorPosition) {
|
|
7
|
+
OperatorPosition.Object_ = {
|
|
8
|
+
OperatorPosition: "operator_position",
|
|
9
|
+
};
|
|
10
|
+
})(OperatorPosition || (exports.OperatorPosition = OperatorPosition = {}));
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One recorded GPS position of an operator.
|
|
3
|
+
*/
|
|
4
|
+
export interface Position {
|
|
5
|
+
/** Position id. */
|
|
6
|
+
id?: string | undefined;
|
|
7
|
+
/** Operator the fix belongs to. */
|
|
8
|
+
operator_id?: string | undefined;
|
|
9
|
+
/** Latitude (WGS84). */
|
|
10
|
+
lat?: number | undefined;
|
|
11
|
+
/** Longitude (WGS84). */
|
|
12
|
+
lng?: number | undefined;
|
|
13
|
+
/** Direction of travel, compass degrees [0,360). */
|
|
14
|
+
heading?: number | undefined;
|
|
15
|
+
/** Course over ground toward the destination, compass degrees [0,360). */
|
|
16
|
+
bearing?: number | undefined;
|
|
17
|
+
/** Ground speed, km/h. */
|
|
18
|
+
speed?: number | undefined;
|
|
19
|
+
/** Altitude above the WGS84 ellipsoid, metres. */
|
|
20
|
+
altitude?: number | undefined;
|
|
21
|
+
/** Device-time the fix was captured (authoritative). */
|
|
22
|
+
recorded_at?: string | undefined;
|
|
23
|
+
object?: Position.Object_ | undefined;
|
|
24
|
+
}
|
|
25
|
+
export declare namespace Position {
|
|
26
|
+
const Object_: {
|
|
27
|
+
readonly Position: "position";
|
|
28
|
+
};
|
|
29
|
+
type Object_ = (typeof Object_)[keyof typeof Object_];
|
|
30
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Position = void 0;
|
|
5
|
+
var Position;
|
|
6
|
+
(function (Position) {
|
|
7
|
+
Position.Object_ = {
|
|
8
|
+
Position: "position",
|
|
9
|
+
};
|
|
10
|
+
})(Position || (exports.Position = Position = {}));
|
|
@@ -4,6 +4,7 @@ export * from "./ApiFieldError.js";
|
|
|
4
4
|
export * from "./Asset.js";
|
|
5
5
|
export * from "./AssetListItem.js";
|
|
6
6
|
export * from "./Assignment.js";
|
|
7
|
+
export * from "./BulkJobSubmission.js";
|
|
7
8
|
export * from "./BusinessCategory.js";
|
|
8
9
|
export * from "./CloseAssignmentRequest.js";
|
|
9
10
|
export * from "./Country.js";
|
|
@@ -15,26 +16,36 @@ export * from "./CreateOperatorRequest.js";
|
|
|
15
16
|
export * from "./CreateOrganizationRequest.js";
|
|
16
17
|
export * from "./CreateTeleoperatedOperatorRequest.js";
|
|
17
18
|
export * from "./Currency.js";
|
|
19
|
+
export * from "./HeatmapCell.js";
|
|
18
20
|
export * from "./InternalUserUpdateRequest.js";
|
|
19
21
|
export * from "./Invite.js";
|
|
20
22
|
export * from "./InviteUserRequest.js";
|
|
23
|
+
export * from "./Job.js";
|
|
24
|
+
export * from "./JobSubmission.js";
|
|
21
25
|
export * from "./Language.js";
|
|
22
26
|
export * from "./ListResponseActivityResource.js";
|
|
23
27
|
export * from "./ListResponseAssetListItem.js";
|
|
24
28
|
export * from "./ListResponseBusinessCategory.js";
|
|
25
29
|
export * from "./ListResponseCountry.js";
|
|
26
30
|
export * from "./ListResponseCurrency.js";
|
|
31
|
+
export * from "./ListResponseHeatmapCell.js";
|
|
32
|
+
export * from "./ListResponseJob.js";
|
|
27
33
|
export * from "./ListResponseLanguage.js";
|
|
28
34
|
export * from "./ListResponseMembership.js";
|
|
35
|
+
export * from "./ListResponseOperatorPosition.js";
|
|
29
36
|
export * from "./ListResponseOrganization.js";
|
|
37
|
+
export * from "./ListResponsePosition.js";
|
|
30
38
|
export * from "./ListResponseTimezone.js";
|
|
31
39
|
export * from "./ListResponseUserResource.js";
|
|
32
40
|
export * from "./Membership.js";
|
|
33
41
|
export * from "./MembershipChoice.js";
|
|
34
42
|
export * from "./MembershipDriftResponse.js";
|
|
43
|
+
export * from "./MqttToken.js";
|
|
35
44
|
export * from "./OpenAssignmentRequest.js";
|
|
36
45
|
export * from "./Operator.js";
|
|
46
|
+
export * from "./OperatorPosition.js";
|
|
37
47
|
export * from "./Organization.js";
|
|
48
|
+
export * from "./Position.js";
|
|
38
49
|
export * from "./ProblemDetail.js";
|
|
39
50
|
export * from "./RealtimeTicket.js";
|
|
40
51
|
export * from "./ReconcileResponse.js";
|
package/dist/api/types/index.js
CHANGED
|
@@ -20,6 +20,7 @@ __exportStar(require("./ApiFieldError.js"), exports);
|
|
|
20
20
|
__exportStar(require("./Asset.js"), exports);
|
|
21
21
|
__exportStar(require("./AssetListItem.js"), exports);
|
|
22
22
|
__exportStar(require("./Assignment.js"), exports);
|
|
23
|
+
__exportStar(require("./BulkJobSubmission.js"), exports);
|
|
23
24
|
__exportStar(require("./BusinessCategory.js"), exports);
|
|
24
25
|
__exportStar(require("./CloseAssignmentRequest.js"), exports);
|
|
25
26
|
__exportStar(require("./Country.js"), exports);
|
|
@@ -31,26 +32,36 @@ __exportStar(require("./CreateOperatorRequest.js"), exports);
|
|
|
31
32
|
__exportStar(require("./CreateOrganizationRequest.js"), exports);
|
|
32
33
|
__exportStar(require("./CreateTeleoperatedOperatorRequest.js"), exports);
|
|
33
34
|
__exportStar(require("./Currency.js"), exports);
|
|
35
|
+
__exportStar(require("./HeatmapCell.js"), exports);
|
|
34
36
|
__exportStar(require("./InternalUserUpdateRequest.js"), exports);
|
|
35
37
|
__exportStar(require("./Invite.js"), exports);
|
|
36
38
|
__exportStar(require("./InviteUserRequest.js"), exports);
|
|
39
|
+
__exportStar(require("./Job.js"), exports);
|
|
40
|
+
__exportStar(require("./JobSubmission.js"), exports);
|
|
37
41
|
__exportStar(require("./Language.js"), exports);
|
|
38
42
|
__exportStar(require("./ListResponseActivityResource.js"), exports);
|
|
39
43
|
__exportStar(require("./ListResponseAssetListItem.js"), exports);
|
|
40
44
|
__exportStar(require("./ListResponseBusinessCategory.js"), exports);
|
|
41
45
|
__exportStar(require("./ListResponseCountry.js"), exports);
|
|
42
46
|
__exportStar(require("./ListResponseCurrency.js"), exports);
|
|
47
|
+
__exportStar(require("./ListResponseHeatmapCell.js"), exports);
|
|
48
|
+
__exportStar(require("./ListResponseJob.js"), exports);
|
|
43
49
|
__exportStar(require("./ListResponseLanguage.js"), exports);
|
|
44
50
|
__exportStar(require("./ListResponseMembership.js"), exports);
|
|
51
|
+
__exportStar(require("./ListResponseOperatorPosition.js"), exports);
|
|
45
52
|
__exportStar(require("./ListResponseOrganization.js"), exports);
|
|
53
|
+
__exportStar(require("./ListResponsePosition.js"), exports);
|
|
46
54
|
__exportStar(require("./ListResponseTimezone.js"), exports);
|
|
47
55
|
__exportStar(require("./ListResponseUserResource.js"), exports);
|
|
48
56
|
__exportStar(require("./Membership.js"), exports);
|
|
49
57
|
__exportStar(require("./MembershipChoice.js"), exports);
|
|
50
58
|
__exportStar(require("./MembershipDriftResponse.js"), exports);
|
|
59
|
+
__exportStar(require("./MqttToken.js"), exports);
|
|
51
60
|
__exportStar(require("./OpenAssignmentRequest.js"), exports);
|
|
52
61
|
__exportStar(require("./Operator.js"), exports);
|
|
62
|
+
__exportStar(require("./OperatorPosition.js"), exports);
|
|
53
63
|
__exportStar(require("./Organization.js"), exports);
|
|
64
|
+
__exportStar(require("./Position.js"), exports);
|
|
54
65
|
__exportStar(require("./ProblemDetail.js"), exports);
|
|
55
66
|
__exportStar(require("./RealtimeTicket.js"), exports);
|
|
56
67
|
__exportStar(require("./ReconcileResponse.js"), exports);
|