@c8y/client 1017.45.0 → 1017.47.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.
@@ -337,7 +337,7 @@ class ApplicationService extends core_1.Service {
337
337
  return { res, data };
338
338
  }
339
339
  /**
340
- * Dynamic options are stored on the API in a specific config: {} object. They can
340
+ * Dynamic options are stored on the API in a specific `config: {}` object. They can
341
341
  * be used to configure the app dynamically.
342
342
  *
343
343
  * Note: To avoids conflicts with the default Config, it is recommended
@@ -15,6 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./ApplicationService"), exports);
18
+ __exportStar(require("./ApplicationBinaryService"), exports);
18
19
  __exportStar(require("./IApplication"), exports);
19
20
  __exportStar(require("./IApplicationBinary"), exports);
20
21
  __exportStar(require("./IApplicationInstanceDetails"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/application/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC;AACrC,iDAA+B;AAC/B,uDAAqC;AACrC,gEAA8C;AAC9C,0DAAwC;AACxC,oDAAkC;AAClC,gDAA8B;AAC9B,8CAA4B;AAC5B,4DAA0C;AAC1C,8CAA4B;AAC5B,8CAA4B;AAC5B,0DAAwC;AACxC,wDAAsC;AACtC,gEAA8C"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/application/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC;AACrC,6DAA2C;AAC3C,iDAA+B;AAC/B,uDAAqC;AACrC,gEAA8C;AAC9C,0DAAwC;AACxC,oDAAkC;AAClC,gDAA8B;AAC9B,8CAA4B;AAC5B,4DAA0C;AAC1C,8CAA4B;AAC5B,8CAA4B;AAC5B,0DAAwC;AACxC,wDAAsC;AACtC,gEAA8C"}
@@ -57,32 +57,32 @@ class QueriesUtil {
57
57
  * Builds query string from provided query object.
58
58
  *
59
59
  * @param query Object containing filters and sort order for querying managed objects. Supported filters are:
60
- * - **__and** - Specifies conditions, e.g. {__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}.
61
- * - **__or** - Specifies alternative conditions, e.g. {__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}.
62
- * - **__eq** - Specified fragment must be equal to given value, e.g. {'status': 'AVAILABLE'} (no nested object required).
63
- * - **__lt** - Specified fragment must be less then given value, e.g. {'count': {__lt: 10}}.
64
- * - **__gt** - Specified fragment must be greater then given value, e.g. {'count': {__gt: 0}}.
65
- * - **__in** - Specified fragment must be equal to one of values in the list, e.g. {'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}.
66
- * - **__not** - Negates condition, e.g. {__not: {'status': 'AVAILABLE'}}.
67
- * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. {__bygroupid: 10300}.
68
- * - **__has** - Specified fragment must have a value defined, e.g. {__has: 'c8y_IsDevice'}.
69
- * - **__useFilterQueryString** - Gets rid of the '$filter=()… $orderby=…' parts of a query and keeps only what's between the most
60
+ * - **__and** - Specifies conditions, e.g. `{__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}`.
61
+ * - **__or** - Specifies alternative conditions, e.g. `{__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}`.
62
+ * - **__eq** - Specified fragment must be equal to given value, e.g. `{'status': 'AVAILABLE'}` (no nested object required).
63
+ * - **__lt** - Specified fragment must be less then given value, e.g. `{'count': {__lt: 10}}`.
64
+ * - **__gt** - Specified fragment must be greater then given value, e.g. `{'count': {__gt: 0}}`.
65
+ * - **__in** - Specified fragment must be equal to one of values in the list, e.g. `{'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}`.
66
+ * - **__not** - Negates condition, e.g. `{__not: {'status': 'AVAILABLE'}}`.
67
+ * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. `{__bygroupid: 10300}`.
68
+ * - **__has** - Specified fragment must have a value defined, e.g. `{__has: 'c8y_IsDevice'}`.
69
+ * - **__useFilterQueryString** - Gets rid of the `$filter=()… $orderby=…` parts of a query and keeps only what's between the most
70
70
  * exterior parentheses of the $filter.
71
71
  * EXAMPLE: takes a query of the form
72
- * "$filter=(name eq 'RaspPi*') $orderby=name asc"
72
+ * `$filter=(name eq 'RaspPi*') $orderby=name asc`
73
73
  * and turns it into
74
- * "name eq 'RaspPi*'"
74
+ * `name eq 'RaspPi*'`
75
75
  * This is necessary for searching for smart groups, which are identified by their own query
76
76
  * that needs to be passed through.
77
77
  *
78
78
  *
79
79
  * The order is specified by an array of field paths and sort direction (1 for ascending, -1 for descending), e.g.:
80
- * - {__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}
80
+ * - `{__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}`
81
81
  *
82
82
  * @returns {string} Returns a query string ready to be sent in request params to backend.
83
83
  *
84
84
  * **Example**
85
- * <pre>
85
+ * ```typescript
86
86
  * const query = {
87
87
  * __filter: {
88
88
  * 'name': 'My Device*',
@@ -115,7 +115,7 @@ class QueriesUtil {
115
115
  * const params = {
116
116
  * query: queriesUtil.buildQuery(query)
117
117
  * };
118
- * </pre>
118
+ * ```
119
119
  */
120
120
  buildQuery(query) {
121
121
  const q = [];
@@ -389,7 +389,7 @@ export class ApplicationService extends Service {
389
389
  });
390
390
  }
391
391
  /**
392
- * Dynamic options are stored on the API in a specific config: {} object. They can
392
+ * Dynamic options are stored on the API in a specific `config: {}` object. They can
393
393
  * be used to configure the app dynamically.
394
394
  *
395
395
  * Note: To avoids conflicts with the default Config, it is recommended
@@ -1,4 +1,5 @@
1
1
  export * from './ApplicationService';
2
+ export * from './ApplicationBinaryService';
2
3
  export * from './IApplication';
3
4
  export * from './IApplicationBinary';
4
5
  export * from './IApplicationInstanceDetails';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/application/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yBAAyB,CAAC;AACxC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,+BAA+B,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/application/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yBAAyB,CAAC;AACxC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,+BAA+B,CAAC"}
@@ -55,32 +55,32 @@ export class QueriesUtil {
55
55
  * Builds query string from provided query object.
56
56
  *
57
57
  * @param query Object containing filters and sort order for querying managed objects. Supported filters are:
58
- * - **__and** - Specifies conditions, e.g. {__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}.
59
- * - **__or** - Specifies alternative conditions, e.g. {__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}.
60
- * - **__eq** - Specified fragment must be equal to given value, e.g. {'status': 'AVAILABLE'} (no nested object required).
61
- * - **__lt** - Specified fragment must be less then given value, e.g. {'count': {__lt: 10}}.
62
- * - **__gt** - Specified fragment must be greater then given value, e.g. {'count': {__gt: 0}}.
63
- * - **__in** - Specified fragment must be equal to one of values in the list, e.g. {'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}.
64
- * - **__not** - Negates condition, e.g. {__not: {'status': 'AVAILABLE'}}.
65
- * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. {__bygroupid: 10300}.
66
- * - **__has** - Specified fragment must have a value defined, e.g. {__has: 'c8y_IsDevice'}.
67
- * - **__useFilterQueryString** - Gets rid of the '$filter=()… $orderby=…' parts of a query and keeps only what's between the most
58
+ * - **__and** - Specifies conditions, e.g. `{__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}`.
59
+ * - **__or** - Specifies alternative conditions, e.g. `{__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}`.
60
+ * - **__eq** - Specified fragment must be equal to given value, e.g. `{'status': 'AVAILABLE'}` (no nested object required).
61
+ * - **__lt** - Specified fragment must be less then given value, e.g. `{'count': {__lt: 10}}`.
62
+ * - **__gt** - Specified fragment must be greater then given value, e.g. `{'count': {__gt: 0}}`.
63
+ * - **__in** - Specified fragment must be equal to one of values in the list, e.g. `{'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}`.
64
+ * - **__not** - Negates condition, e.g. `{__not: {'status': 'AVAILABLE'}}`.
65
+ * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. `{__bygroupid: 10300}`.
66
+ * - **__has** - Specified fragment must have a value defined, e.g. `{__has: 'c8y_IsDevice'}`.
67
+ * - **__useFilterQueryString** - Gets rid of the `$filter=()… $orderby=…` parts of a query and keeps only what's between the most
68
68
  * exterior parentheses of the $filter.
69
69
  * EXAMPLE: takes a query of the form
70
- * "$filter=(name eq 'RaspPi*') $orderby=name asc"
70
+ * `$filter=(name eq 'RaspPi*') $orderby=name asc`
71
71
  * and turns it into
72
- * "name eq 'RaspPi*'"
72
+ * `name eq 'RaspPi*'`
73
73
  * This is necessary for searching for smart groups, which are identified by their own query
74
74
  * that needs to be passed through.
75
75
  *
76
76
  *
77
77
  * The order is specified by an array of field paths and sort direction (1 for ascending, -1 for descending), e.g.:
78
- * - {__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}
78
+ * - `{__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}`
79
79
  *
80
80
  * @returns {string} Returns a query string ready to be sent in request params to backend.
81
81
  *
82
82
  * **Example**
83
- * <pre>
83
+ * ```typescript
84
84
  * const query = {
85
85
  * __filter: {
86
86
  * 'name': 'My Device*',
@@ -113,7 +113,7 @@ export class QueriesUtil {
113
113
  * const params = {
114
114
  * query: queriesUtil.buildQuery(query)
115
115
  * };
116
- * </pre>
116
+ * ```
117
117
  */
118
118
  buildQuery(query) {
119
119
  const q = [];
@@ -226,7 +226,7 @@ export declare class ApplicationService extends Service<IApplication> {
226
226
  */
227
227
  getInstanceLog(entityOrId: string | number | IApplication, instanceName: string, params?: IApplicationInstanceLogRequestParams): Promise<IResult<IApplicationInstanceLog>>;
228
228
  /**
229
- * Dynamic options are stored on the API in a specific config: {} object. They can
229
+ * Dynamic options are stored on the API in a specific `config: {}` object. They can
230
230
  * be used to configure the app dynamically.
231
231
  *
232
232
  * Note: To avoids conflicts with the default Config, it is recommended
@@ -1,4 +1,5 @@
1
1
  export * from './ApplicationService';
2
+ export * from './ApplicationBinaryService';
2
3
  export * from './IApplication';
3
4
  export * from './IApplicationBinary';
4
5
  export * from './IApplicationInstanceDetails';
@@ -17,32 +17,32 @@ export declare class QueriesUtil {
17
17
  * Builds query string from provided query object.
18
18
  *
19
19
  * @param query Object containing filters and sort order for querying managed objects. Supported filters are:
20
- * - **__and** - Specifies conditions, e.g. {__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}.
21
- * - **__or** - Specifies alternative conditions, e.g. {__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}.
22
- * - **__eq** - Specified fragment must be equal to given value, e.g. {'status': 'AVAILABLE'} (no nested object required).
23
- * - **__lt** - Specified fragment must be less then given value, e.g. {'count': {__lt: 10}}.
24
- * - **__gt** - Specified fragment must be greater then given value, e.g. {'count': {__gt: 0}}.
25
- * - **__in** - Specified fragment must be equal to one of values in the list, e.g. {'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}.
26
- * - **__not** - Negates condition, e.g. {__not: {'status': 'AVAILABLE'}}.
27
- * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. {__bygroupid: 10300}.
28
- * - **__has** - Specified fragment must have a value defined, e.g. {__has: 'c8y_IsDevice'}.
29
- * - **__useFilterQueryString** - Gets rid of the '$filter=()… $orderby=…' parts of a query and keeps only what's between the most
20
+ * - **__and** - Specifies conditions, e.g. `{__and: [{__has: 'c8y_IsDevice'}, {'count': {__gt: 0}}]}`.
21
+ * - **__or** - Specifies alternative conditions, e.g. `{__or: [{__bygroupid: 10300}, {__bygroupid: 10400}]}`.
22
+ * - **__eq** - Specified fragment must be equal to given value, e.g. `{'status': 'AVAILABLE'}` (no nested object required).
23
+ * - **__lt** - Specified fragment must be less then given value, e.g. `{'count': {__lt: 10}}`.
24
+ * - **__gt** - Specified fragment must be greater then given value, e.g. `{'count': {__gt: 0}}`.
25
+ * - **__in** - Specified fragment must be equal to one of values in the list, e.g. `{'status': {__in: ['AVAILABLE', 'UNAVAILABLE']}}`.
26
+ * - **__not** - Negates condition, e.g. `{__not: {'status': 'AVAILABLE'}}`.
27
+ * - **__bygroupid** - True if filtered managed object is assigned to given group, e.g. `{__bygroupid: 10300}`.
28
+ * - **__has** - Specified fragment must have a value defined, e.g. `{__has: 'c8y_IsDevice'}`.
29
+ * - **__useFilterQueryString** - Gets rid of the `$filter=()… $orderby=…` parts of a query and keeps only what's between the most
30
30
  * exterior parentheses of the $filter.
31
31
  * EXAMPLE: takes a query of the form
32
- * "$filter=(name eq 'RaspPi*') $orderby=name asc"
32
+ * `$filter=(name eq 'RaspPi*') $orderby=name asc`
33
33
  * and turns it into
34
- * "name eq 'RaspPi*'"
34
+ * `name eq 'RaspPi*'`
35
35
  * This is necessary for searching for smart groups, which are identified by their own query
36
36
  * that needs to be passed through.
37
37
  *
38
38
  *
39
39
  * The order is specified by an array of field paths and sort direction (1 for ascending, -1 for descending), e.g.:
40
- * - {__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}
40
+ * - `{__orderby: [{'creationTime': -1}, {'name': 1}], __filter: {...}}`
41
41
  *
42
42
  * @returns {string} Returns a query string ready to be sent in request params to backend.
43
43
  *
44
44
  * **Example**
45
- * <pre>
45
+ * ```typescript
46
46
  * const query = {
47
47
  * __filter: {
48
48
  * 'name': 'My Device*',
@@ -75,7 +75,7 @@ export declare class QueriesUtil {
75
75
  * const params = {
76
76
  * query: queriesUtil.buildQuery(query)
77
77
  * };
78
- * </pre>
78
+ * ```
79
79
  */
80
80
  buildQuery(query: any): string;
81
81
  buildQueryFilter(queryFilter: any, _queryKey?: any, _glueType?: any): string;
@@ -8,7 +8,7 @@ import { IDeviceCredentials } from './IDeviceCredentials';
8
8
  export interface IDeviceBootstrapOptions {
9
9
  /**
10
10
  * If already logged in it is accessible via
11
- * client.auth.getHeader, see [[BasicAuth.getHeader]]
11
+ * client.auth.getFetchOptions, see [[BasicAuth.getFetchOptions]]
12
12
  *
13
13
  * **Example**
14
14
  * ``` typescript
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c8y/client",
3
- "version": "1017.45.0",
3
+ "version": "1017.47.0",
4
4
  "license": "Apache-2.0",
5
5
  "author": "Cumulocity",
6
6
  "description": "Client application programming interface to access the Cumulocity IoT-Platform REST services.",
@@ -9,8 +9,8 @@
9
9
  "build:cjs": "tsc -p . --module commonjs --outDir lib/cjs",
10
10
  "build:esm2015": "tsc -p . --target es2015 --outDir lib/esm2015",
11
11
  "build:typings": "tsc -p . --emitDeclarationOnly true --declaration true --declarationDir lib",
12
- "build:rollup": "rollup -c",
13
- "docs": "typedoc ./src",
12
+ "build:rollup": "rollup -c --bundleConfigAsCjs",
13
+ "docs": "typedoc ./index.ts",
14
14
  "lint": "tslint --project tsconfig.json",
15
15
  "prepare": "rimraf lib && yarn build",
16
16
  "test:coverage": "jest --coverage",
@@ -46,19 +46,19 @@
46
46
  "isomorphic-cometd": "1.1.0"
47
47
  },
48
48
  "devDependencies": {
49
- "@types/fs-extra": "5.0.1",
49
+ "@types/fs-extra": "11.0.1",
50
50
  "@types/jest": "^26.0.22",
51
- "fs-extra": "5.0.0",
51
+ "fs-extra": "11.1.0",
52
52
  "ncp": "2.0.0",
53
53
  "rimraf": "2.6.2",
54
- "rollup": "^0.57.1",
55
- "rollup-plugin-commonjs": "9.2.2",
56
- "rollup-plugin-node-resolve": "^3.3.0",
54
+ "rollup": "^3.12.0",
55
+ "rollup-plugin-commonjs": "10.1.0",
56
+ "rollup-plugin-node-resolve": "^5.2.0",
57
57
  "rollup-plugin-sourcemaps": "^0.6.3",
58
- "rollup-plugin-uglify": "3.0.0",
58
+ "rollup-plugin-uglify": "6.0.4",
59
59
  "ts-jest": "^28.0.7",
60
60
  "tslint": "^5.9.1",
61
- "typedoc": "0.11.1",
61
+ "typedoc": "0.23.24",
62
62
  "typescript": "4.7.4"
63
63
  }
64
64
  }
package/typedoc.json ADDED
@@ -0,0 +1,18 @@
1
+ {
2
+ "$schema": "https://typedoc.org/schema.json",
3
+ "name": "Cumulocity Web SDK",
4
+ "out": "./docs",
5
+ "exclude": ["**/*.spec.ts"],
6
+ "theme": "default",
7
+ "includeVersion": true,
8
+ "hideGenerator": true,
9
+ "excludeProtected": true,
10
+ "excludePrivate": true,
11
+ "excludeInternal": true,
12
+ "compilerOptions": {
13
+ "target": "ES6",
14
+ "module": "commonjs",
15
+ "suppressExcessPropertyErrors": true,
16
+ "suppressImplicitAnyIndexErrors": true,
17
+ }
18
+ }