@openeo/js-client 2.8.0 → 2.10.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/README.md +2 -2
- package/openeo.d.ts +105 -63
- package/openeo.js +2710 -168
- package/openeo.min.js +1 -1
- package/package.json +7 -6
- package/src/authprovider.js +12 -4
- package/src/capabilities.js +45 -0
- package/src/connection.js +14 -2
- package/src/oidcprovider.js +12 -1
- package/src/openeo.js +1 -1
- package/src/typedefs.js +17 -0
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@ JavaScript/TypeScript client for the openEO API.
|
|
|
4
4
|
|
|
5
5
|
* [Documentation](https://open-eo.github.io/openeo-js-client/latest/).
|
|
6
6
|
|
|
7
|
-
The version of this client is **2.
|
|
7
|
+
The version of this client is **2.10.0** and supports **openEO API versions 1.x.x**.
|
|
8
8
|
Legacy versions are available as releases.
|
|
9
9
|
See the [CHANGELOG](CHANGELOG.md) for recent changes.
|
|
10
10
|
|
|
@@ -75,7 +75,7 @@ Run tests:
|
|
|
75
75
|
* `npm test browser` (browser tests)
|
|
76
76
|
* `npm test node` (node tests)
|
|
77
77
|
* `npm test builder` (tests only the process builder)
|
|
78
|
-
* `npm test
|
|
78
|
+
* `npm test test-api` (full test suite using the openeo-test-api back-end as server)
|
|
79
79
|
|
|
80
80
|
# Contributions
|
|
81
81
|
|
package/openeo.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import { ProcessRegistry } from '@openeo/js-commons';
|
|
|
5
5
|
import { Readable } from 'stream';
|
|
6
6
|
import axios from 'axios';
|
|
7
7
|
|
|
8
|
-
declare
|
|
8
|
+
declare namespace OpenEO {
|
|
9
9
|
/**
|
|
10
10
|
* The base class for authentication providers such as Basic and OpenID Connect.
|
|
11
11
|
*
|
|
@@ -70,6 +70,8 @@ declare module OpenEO {
|
|
|
70
70
|
* Returns the access token that is used as Bearer Token in API requests.
|
|
71
71
|
*
|
|
72
72
|
* Returns `null` if no access token has been set yet (i.e. not authenticated any longer).
|
|
73
|
+
*
|
|
74
|
+
* Checks whether the server supports the JWT conformance class.
|
|
73
75
|
*
|
|
74
76
|
* @returns {string | null}
|
|
75
77
|
*/
|
|
@@ -124,12 +126,12 @@ declare module OpenEO {
|
|
|
124
126
|
* @protected
|
|
125
127
|
* @type {object.<string, string>}
|
|
126
128
|
*/
|
|
127
|
-
protected apiToClientNames:
|
|
129
|
+
protected apiToClientNames: Record<string, string>;
|
|
128
130
|
/**
|
|
129
131
|
* @protected
|
|
130
132
|
* @type {object.<string, string>}
|
|
131
133
|
*/
|
|
132
|
-
protected clientToApiNames:
|
|
134
|
+
protected clientToApiNames: Record<string, string>;
|
|
133
135
|
/**
|
|
134
136
|
* @protected
|
|
135
137
|
* @type {number}
|
|
@@ -141,20 +143,20 @@ declare module OpenEO {
|
|
|
141
143
|
* @protected
|
|
142
144
|
* @type {object.<string, *>}
|
|
143
145
|
*/
|
|
144
|
-
protected extra:
|
|
146
|
+
protected extra: Record<string, any>;
|
|
145
147
|
/**
|
|
146
148
|
* Returns a JSON serializable representation of the data that is API compliant.
|
|
147
149
|
*
|
|
148
150
|
* @returns {object.<string, *>}
|
|
149
151
|
*/
|
|
150
|
-
toJSON():
|
|
152
|
+
toJSON(): Record<string, any>;
|
|
151
153
|
/**
|
|
152
154
|
* Converts the data from an API response into data suitable for our JS client models.
|
|
153
155
|
*
|
|
154
156
|
* @param {object.<string, *>} metadata - JSON object originating from an API response.
|
|
155
157
|
* @returns {BaseEntity} Returns the object itself.
|
|
156
158
|
*/
|
|
157
|
-
setAll(metadata:
|
|
159
|
+
setAll(metadata: Record<string, any>): BaseEntity;
|
|
158
160
|
/**
|
|
159
161
|
* Returns the age of the data in seconds.
|
|
160
162
|
*
|
|
@@ -166,7 +168,7 @@ declare module OpenEO {
|
|
|
166
168
|
*
|
|
167
169
|
* @returns {object.<string, *>}
|
|
168
170
|
*/
|
|
169
|
-
getAll():
|
|
171
|
+
getAll(): Record<string, any>;
|
|
170
172
|
/**
|
|
171
173
|
* Get a value from the additional data that is not part of the core model, i.e. from proprietary extensions.
|
|
172
174
|
*
|
|
@@ -181,7 +183,7 @@ declare module OpenEO {
|
|
|
181
183
|
* @returns {object.<string, *>}
|
|
182
184
|
* @protected
|
|
183
185
|
*/
|
|
184
|
-
protected _convertToRequest(parameters:
|
|
186
|
+
protected _convertToRequest(parameters: Record<string, any>): Record<string, any>;
|
|
185
187
|
/**
|
|
186
188
|
* Checks whether a features is supported by the API.
|
|
187
189
|
*
|
|
@@ -205,7 +207,7 @@ declare module OpenEO {
|
|
|
205
207
|
* @type {object}
|
|
206
208
|
* @static
|
|
207
209
|
*/
|
|
208
|
-
static axios: axios;
|
|
210
|
+
static axios: typeof axios;
|
|
209
211
|
/**
|
|
210
212
|
* Returns the name of the Environment, `Node` or `Browser`.
|
|
211
213
|
*
|
|
@@ -280,7 +282,7 @@ declare module OpenEO {
|
|
|
280
282
|
* @param {string} targetFolder
|
|
281
283
|
* @throws {Error}
|
|
282
284
|
*/
|
|
283
|
-
static downloadResults(con: Connection, assets: Array<
|
|
285
|
+
static downloadResults(con: Connection, assets: Array<Record<string, any>>, targetFolder: string): Promise<void>;
|
|
284
286
|
/**
|
|
285
287
|
* Streams data into a file (node) or offers data to download (browser).
|
|
286
288
|
*
|
|
@@ -330,7 +332,7 @@ declare module OpenEO {
|
|
|
330
332
|
* @param {object.<string, *>} data - A capabilities response compatible to the API specification for `GET /`.
|
|
331
333
|
* @throws {Error}
|
|
332
334
|
*/
|
|
333
|
-
constructor(data:
|
|
335
|
+
constructor(data: Record<string, any>);
|
|
334
336
|
/**
|
|
335
337
|
* @private
|
|
336
338
|
* @type {object.<string, *>}
|
|
@@ -367,7 +369,7 @@ declare module OpenEO {
|
|
|
367
369
|
*
|
|
368
370
|
* @returns {object.<string, *>} - A reference to the capabilities response.
|
|
369
371
|
*/
|
|
370
|
-
toJSON():
|
|
372
|
+
toJSON(): Record<string, any>;
|
|
371
373
|
/**
|
|
372
374
|
* Returns the openEO API version implemented by the back-end.
|
|
373
375
|
*
|
|
@@ -437,6 +439,15 @@ declare module OpenEO {
|
|
|
437
439
|
* @returns {boolean} `true` if the feature is supported, otherwise `false`.
|
|
438
440
|
*/
|
|
439
441
|
hasFeature(methodName: string): boolean;
|
|
442
|
+
/**
|
|
443
|
+
* Check whether a conformance class is supported by the back-end.
|
|
444
|
+
*
|
|
445
|
+
* Use `*` as a wildcard character for e.g. version numbers.
|
|
446
|
+
*
|
|
447
|
+
* @param {string|Array.<string>} uris - Conformance class URI(s) - any of them must match.
|
|
448
|
+
* @returns {boolean} `true` if any of the conformance classes is supported, otherwise `false`.
|
|
449
|
+
*/
|
|
450
|
+
hasConformance(uris: string | Array<string>): boolean;
|
|
440
451
|
/**
|
|
441
452
|
* Get the billing currency.
|
|
442
453
|
*
|
|
@@ -457,6 +468,8 @@ declare module OpenEO {
|
|
|
457
468
|
* @returns {AxiosResponse}
|
|
458
469
|
*/
|
|
459
470
|
protected migrate(response: AxiosResponse): AxiosResponse;
|
|
471
|
+
|
|
472
|
+
static Conformance: Record<string, string | Array<string>>;
|
|
460
473
|
}
|
|
461
474
|
/**
|
|
462
475
|
* The Authentication Provider for OpenID Connect.
|
|
@@ -495,7 +508,7 @@ declare module OpenEO {
|
|
|
495
508
|
* @throws {Error}
|
|
496
509
|
* @see https://github.com/IdentityModel/oidc-client-js/wiki#other-optional-settings
|
|
497
510
|
*/
|
|
498
|
-
static signinCallback(provider?: OidcProvider, options?:
|
|
511
|
+
static signinCallback(provider?: OidcProvider, options?: Record<string, any>): Promise<User | null>;
|
|
499
512
|
/**
|
|
500
513
|
* Creates a new OidcProvider instance to authenticate using OpenID Connect.
|
|
501
514
|
*
|
|
@@ -595,7 +608,7 @@ declare module OpenEO {
|
|
|
595
608
|
* @see https://github.com/IdentityModel/oidc-client-js/wiki#other-optional-settings
|
|
596
609
|
* @see {OidcProvider#refreshTokenScope}
|
|
597
610
|
*/
|
|
598
|
-
login(options?:
|
|
611
|
+
login(options?: Record<string, any>, requestRefreshToken?: boolean): Promise<void>;
|
|
599
612
|
/**
|
|
600
613
|
* Returns the options for the OIDC client library.
|
|
601
614
|
*
|
|
@@ -607,7 +620,7 @@ declare module OpenEO {
|
|
|
607
620
|
* @returns {object.<string, *>}
|
|
608
621
|
* @see {OidcProvider#refreshTokenScope}
|
|
609
622
|
*/
|
|
610
|
-
protected getOptions(options?:
|
|
623
|
+
protected getOptions(options?: Record<string, any>, requestRefreshToken?: boolean): Record<string, any>;
|
|
611
624
|
/**
|
|
612
625
|
* Get the response_type based on the grant type.
|
|
613
626
|
*
|
|
@@ -687,13 +700,13 @@ declare module OpenEO {
|
|
|
687
700
|
*
|
|
688
701
|
* @returns {object.<string, FileType>}
|
|
689
702
|
*/
|
|
690
|
-
getInputTypes():
|
|
703
|
+
getInputTypes(): Record<string, FileType>;
|
|
691
704
|
/**
|
|
692
705
|
* Returns the output file formats.
|
|
693
706
|
*
|
|
694
707
|
* @returns {object.<string, FileType>}
|
|
695
708
|
*/
|
|
696
|
-
getOutputTypes():
|
|
709
|
+
getOutputTypes(): Record<string, FileType>;
|
|
697
710
|
/**
|
|
698
711
|
* Returns a single input file format for a given identifier.
|
|
699
712
|
*
|
|
@@ -1071,7 +1084,7 @@ declare module OpenEO {
|
|
|
1071
1084
|
* @returns {Promise<object.<string, *>>} The JSON-based response compatible to the API specification, but also including a `costs` property if present in the headers.
|
|
1072
1085
|
* @throws {Error}
|
|
1073
1086
|
*/
|
|
1074
|
-
getResultsAsStac(): Promise<
|
|
1087
|
+
getResultsAsStac(): Promise<Record<string, any>>;
|
|
1075
1088
|
/**
|
|
1076
1089
|
* Retrieves download links.
|
|
1077
1090
|
*
|
|
@@ -1138,14 +1151,14 @@ declare module OpenEO {
|
|
|
1138
1151
|
* @readonly
|
|
1139
1152
|
* @type {?Array.<object.<string, *>>}
|
|
1140
1153
|
*/
|
|
1141
|
-
public readonly parameters: Array<
|
|
1154
|
+
public readonly parameters: Array<Record<string, any>> | null;
|
|
1142
1155
|
/**
|
|
1143
1156
|
* Description of the data that is returned by this process.
|
|
1144
1157
|
* @public
|
|
1145
1158
|
* @readonly
|
|
1146
1159
|
* @type {?object.<string, *>}
|
|
1147
1160
|
*/
|
|
1148
|
-
public readonly returns:
|
|
1161
|
+
public readonly returns: Record<string, any> | null;
|
|
1149
1162
|
/**
|
|
1150
1163
|
* Specifies that the process or parameter is deprecated with the potential to be removed in any of the next versions.
|
|
1151
1164
|
* @public
|
|
@@ -1166,13 +1179,13 @@ declare module OpenEO {
|
|
|
1166
1179
|
* @readonly
|
|
1167
1180
|
* @type {?object.<string, *>}
|
|
1168
1181
|
*/
|
|
1169
|
-
public readonly exceptions:
|
|
1182
|
+
public readonly exceptions: Record<string, any> | null;
|
|
1170
1183
|
/**
|
|
1171
1184
|
* @public
|
|
1172
1185
|
* @readonly
|
|
1173
1186
|
* @type {?Array.<object.<string, *>>}
|
|
1174
1187
|
*/
|
|
1175
|
-
public readonly examples: Array<
|
|
1188
|
+
public readonly examples: Array<Record<string, any>> | null;
|
|
1176
1189
|
/**
|
|
1177
1190
|
* Links related to this process.
|
|
1178
1191
|
* @public
|
|
@@ -1185,7 +1198,7 @@ declare module OpenEO {
|
|
|
1185
1198
|
* @readonly
|
|
1186
1199
|
* @type {?object.<string, *>}
|
|
1187
1200
|
*/
|
|
1188
|
-
public readonly processGraph:
|
|
1201
|
+
public readonly processGraph: Record<string, any> | null;
|
|
1189
1202
|
/**
|
|
1190
1203
|
* Updates the data stored in this object by requesting the process graph metadata from the back-end.
|
|
1191
1204
|
*
|
|
@@ -1283,14 +1296,14 @@ declare module OpenEO {
|
|
|
1283
1296
|
* @readonly
|
|
1284
1297
|
* @type {?object.<string, *>}
|
|
1285
1298
|
*/
|
|
1286
|
-
public readonly configuration:
|
|
1299
|
+
public readonly configuration: Record<string, any> | null;
|
|
1287
1300
|
/**
|
|
1288
1301
|
* Additional attributes of the secondary web service, e.g. available layers for a WMS based on the bands in the underlying GeoTiff.
|
|
1289
1302
|
* @public
|
|
1290
1303
|
* @readonly
|
|
1291
1304
|
* @type {?object.<string, *>}
|
|
1292
1305
|
*/
|
|
1293
|
-
public readonly attributes:
|
|
1306
|
+
public readonly attributes: Record<string, any> | null;
|
|
1294
1307
|
/**
|
|
1295
1308
|
* Date and time of creation, formatted as a RFC 3339 date-time.
|
|
1296
1309
|
* @public
|
|
@@ -1347,7 +1360,7 @@ declare module OpenEO {
|
|
|
1347
1360
|
title: string;
|
|
1348
1361
|
description: string;
|
|
1349
1362
|
enabled: boolean;
|
|
1350
|
-
configuration:
|
|
1363
|
+
configuration: Record<string, any>;
|
|
1351
1364
|
plan: string;
|
|
1352
1365
|
budget: number;
|
|
1353
1366
|
}): Promise<Service>;
|
|
@@ -1430,7 +1443,7 @@ declare module OpenEO {
|
|
|
1430
1443
|
* @param {string} description - A description for the parameter
|
|
1431
1444
|
* @param {*} defaultValue - An optional default Value for the parameter. If set, make the parameter optional. If not set, the parameter is required. Defaults to `undefined`.
|
|
1432
1445
|
*/
|
|
1433
|
-
constructor(name: string, schema?:
|
|
1446
|
+
constructor(name: string, schema?: Record<string, any> | string, description?: string, defaultValue?: any);
|
|
1434
1447
|
name: string;
|
|
1435
1448
|
spec: {
|
|
1436
1449
|
name: string;
|
|
@@ -1442,7 +1455,7 @@ declare module OpenEO {
|
|
|
1442
1455
|
*
|
|
1443
1456
|
* @returns {object.<string, *>}
|
|
1444
1457
|
*/
|
|
1445
|
-
toJSON():
|
|
1458
|
+
toJSON(): Record<string, any>;
|
|
1446
1459
|
/**
|
|
1447
1460
|
* Returns the reference object for this parameter.
|
|
1448
1461
|
*
|
|
@@ -1498,7 +1511,7 @@ declare module OpenEO {
|
|
|
1498
1511
|
/**
|
|
1499
1512
|
* @type {object.<string, *>}
|
|
1500
1513
|
*/
|
|
1501
|
-
tree:
|
|
1514
|
+
tree: Record<string, any>;
|
|
1502
1515
|
/**
|
|
1503
1516
|
* @type {Builder | null}
|
|
1504
1517
|
*/
|
|
@@ -1527,7 +1540,7 @@ declare module OpenEO {
|
|
|
1527
1540
|
* @returns {object.<string, *>}
|
|
1528
1541
|
* @throws {Error}
|
|
1529
1542
|
*/
|
|
1530
|
-
protected parseTree(tree:
|
|
1543
|
+
protected parseTree(tree: Record<string, any>): Record<string, any>;
|
|
1531
1544
|
/**
|
|
1532
1545
|
* Gets the reference for a value, e.g. from_node or from_parameter.
|
|
1533
1546
|
*
|
|
@@ -1545,10 +1558,10 @@ declare module OpenEO {
|
|
|
1545
1558
|
* @returns {BuilderNode}
|
|
1546
1559
|
* @throws {Error}
|
|
1547
1560
|
*/
|
|
1548
|
-
addOperatorProcess(operator: string, left: number |
|
|
1561
|
+
addOperatorProcess(operator: string, left: number | Record<string, any>, right: number | Record<string, any>): BuilderNode;
|
|
1549
1562
|
}
|
|
1550
1563
|
export namespace Formula {
|
|
1551
|
-
let operatorMapping:
|
|
1564
|
+
let operatorMapping: Record<string, string>;
|
|
1552
1565
|
}
|
|
1553
1566
|
/**
|
|
1554
1567
|
* A class that represents a process node and also a result from a process.
|
|
@@ -1563,7 +1576,7 @@ declare module OpenEO {
|
|
|
1563
1576
|
* @param {?string} [processDescription=null]
|
|
1564
1577
|
* @param {?string} [processNamespace=null]
|
|
1565
1578
|
*/
|
|
1566
|
-
constructor(parent: Builder, processId: string, processArgs?:
|
|
1579
|
+
constructor(parent: Builder, processId: string, processArgs?: Record<string, any>, processDescription?: string | null, processNamespace?: string | null);
|
|
1567
1580
|
/**
|
|
1568
1581
|
* The parent builder.
|
|
1569
1582
|
* @type {Builder}
|
|
@@ -1589,7 +1602,7 @@ declare module OpenEO {
|
|
|
1589
1602
|
* The arguments for the process.
|
|
1590
1603
|
* @type {object.<string, *>}
|
|
1591
1604
|
*/
|
|
1592
|
-
arguments:
|
|
1605
|
+
arguments: Record<string, any>;
|
|
1593
1606
|
/**
|
|
1594
1607
|
* @ignore
|
|
1595
1608
|
*/
|
|
@@ -1606,13 +1619,13 @@ declare module OpenEO {
|
|
|
1606
1619
|
* @returns {object.<string, *>}
|
|
1607
1620
|
* @throws {Error}
|
|
1608
1621
|
*/
|
|
1609
|
-
namedArguments(processArgs: Array<
|
|
1622
|
+
namedArguments(processArgs: Array<Record<string, any>>): Record<string, any>;
|
|
1610
1623
|
/**
|
|
1611
1624
|
* Checks the arguments given for parameters and add them to the process.
|
|
1612
1625
|
*
|
|
1613
1626
|
* @param {object.<string, *>|Array} processArgs
|
|
1614
1627
|
*/
|
|
1615
|
-
addParametersToProcess(processArgs:
|
|
1628
|
+
addParametersToProcess(processArgs: Record<string, any> | any[]): void;
|
|
1616
1629
|
/**
|
|
1617
1630
|
* Gets/Sets a description for the node.
|
|
1618
1631
|
*
|
|
@@ -1658,13 +1671,13 @@ declare module OpenEO {
|
|
|
1658
1671
|
* @returns {object.<string, *>}
|
|
1659
1672
|
* @throws {Error}
|
|
1660
1673
|
*/
|
|
1661
|
-
protected exportCallback(arg: Function, name: string):
|
|
1674
|
+
protected exportCallback(arg: Function, name: string): Record<string, any>;
|
|
1662
1675
|
/**
|
|
1663
1676
|
* Returns a JSON serializable representation of the data that is API compliant.
|
|
1664
1677
|
*
|
|
1665
1678
|
* @returns {object.<string, *>}
|
|
1666
1679
|
*/
|
|
1667
|
-
toJSON():
|
|
1680
|
+
toJSON(): Record<string, any>;
|
|
1668
1681
|
/**
|
|
1669
1682
|
* Returns the reference object for this node.
|
|
1670
1683
|
*
|
|
@@ -1839,7 +1852,7 @@ declare module OpenEO {
|
|
|
1839
1852
|
* @returns {Array.<object.<string,*>>}
|
|
1840
1853
|
* @todo Should this also pass callback parameters from parents until root is reached?
|
|
1841
1854
|
*/
|
|
1842
|
-
getParentCallbackParameters(): Array<
|
|
1855
|
+
getParentCallbackParameters(): Array<Record<string, any>>;
|
|
1843
1856
|
/**
|
|
1844
1857
|
* Adds a parameter to the list of process parameters.
|
|
1845
1858
|
*
|
|
@@ -1848,7 +1861,7 @@ declare module OpenEO {
|
|
|
1848
1861
|
* @param {object.<string, *>} parameter - The parameter spec to add, must comply to the API.
|
|
1849
1862
|
* @param {boolean} [root=true] - Adds the parameter to the root process if set to `true`, otherwise to the process constructed by this builder. Usually you want to add it to the root.
|
|
1850
1863
|
*/
|
|
1851
|
-
addParameter(parameter:
|
|
1864
|
+
addParameter(parameter: Record<string, any>, root?: boolean): void;
|
|
1852
1865
|
/**
|
|
1853
1866
|
* Returns the process specification for the given process identifier and namespace (or `null`).
|
|
1854
1867
|
*
|
|
@@ -1884,7 +1897,7 @@ declare module OpenEO {
|
|
|
1884
1897
|
* @param {?string} [description=null] - An optional description for the process call.
|
|
1885
1898
|
* @returns {BuilderNode}
|
|
1886
1899
|
*/
|
|
1887
|
-
process(processId: string, args?:
|
|
1900
|
+
process(processId: string, args?: Record<string, any> | any[], description?: string | null): BuilderNode;
|
|
1888
1901
|
/**
|
|
1889
1902
|
* Returns a JSON serializable representation of the data that is API compliant.
|
|
1890
1903
|
*
|
|
@@ -2109,7 +2122,7 @@ declare module OpenEO {
|
|
|
2109
2122
|
* @protected
|
|
2110
2123
|
* @type {object.<string|Function>}
|
|
2111
2124
|
*/
|
|
2112
|
-
protected listeners:
|
|
2125
|
+
protected listeners: Record<string, Function>;
|
|
2113
2126
|
/**
|
|
2114
2127
|
* Additional options for the connection.
|
|
2115
2128
|
*
|
|
@@ -2167,6 +2180,14 @@ declare module OpenEO {
|
|
|
2167
2180
|
* @throws {Error}
|
|
2168
2181
|
*/
|
|
2169
2182
|
listFileTypes(): Promise<FileTypes>;
|
|
2183
|
+
/**
|
|
2184
|
+
* List the supported output file formats.
|
|
2185
|
+
*
|
|
2186
|
+
* @async
|
|
2187
|
+
* @returns {Promise<ProcessingParameters>} A response compatible to the API specification.
|
|
2188
|
+
* @throws {Error}
|
|
2189
|
+
*/
|
|
2190
|
+
listProcessingParameters(): Promise<ProcessingParameters>;
|
|
2170
2191
|
/**
|
|
2171
2192
|
* List the supported secondary service types.
|
|
2172
2193
|
*
|
|
@@ -2174,7 +2195,7 @@ declare module OpenEO {
|
|
|
2174
2195
|
* @returns {Promise<object.<string, ServiceType>>} A response compatible to the API specification.
|
|
2175
2196
|
* @throws {Error}
|
|
2176
2197
|
*/
|
|
2177
|
-
listServiceTypes(): Promise<
|
|
2198
|
+
listServiceTypes(): Promise<Record<string, ServiceType>>;
|
|
2178
2199
|
/**
|
|
2179
2200
|
* List the supported UDF runtimes.
|
|
2180
2201
|
*
|
|
@@ -2182,7 +2203,7 @@ declare module OpenEO {
|
|
|
2182
2203
|
* @returns {Promise<object.<string, UdfRuntime>>} A response compatible to the API specification.
|
|
2183
2204
|
* @throws {Error}
|
|
2184
2205
|
*/
|
|
2185
|
-
listUdfRuntimes(): Promise<
|
|
2206
|
+
listUdfRuntimes(): Promise<Record<string, UdfRuntime>>;
|
|
2186
2207
|
/**
|
|
2187
2208
|
* List all collections available on the back-end.
|
|
2188
2209
|
*
|
|
@@ -2487,7 +2508,7 @@ declare module OpenEO {
|
|
|
2487
2508
|
* @returns {object.<string, *>}
|
|
2488
2509
|
* @protected
|
|
2489
2510
|
*/
|
|
2490
|
-
protected _normalizeUserProcess(process: UserProcess | BuilderNode |
|
|
2511
|
+
protected _normalizeUserProcess(process: UserProcess | BuilderNode | Record<string, any>, additional?: Record<string, any>): Record<string, any>;
|
|
2491
2512
|
/**
|
|
2492
2513
|
* Validates a user-defined process at the back-end.
|
|
2493
2514
|
*
|
|
@@ -2545,7 +2566,7 @@ declare module OpenEO {
|
|
|
2545
2566
|
* @param {object.<string, *>} [additional={}] - Other parameters to pass for the batch job, e.g. `log_level`.
|
|
2546
2567
|
* @returns {Promise<SyncResult>} - An object with the data and some metadata.
|
|
2547
2568
|
*/
|
|
2548
|
-
computeResult(process: Process, plan?: string | null, budget?: number | null, abortController?: AbortController | null, additional?:
|
|
2569
|
+
computeResult(process: Process, plan?: string | null, budget?: number | null, abortController?: AbortController | null, additional?: Record<string, any>): Promise<SyncResult>;
|
|
2549
2570
|
/**
|
|
2550
2571
|
* Executes a process synchronously and downloads to result the given path.
|
|
2551
2572
|
*
|
|
@@ -2593,7 +2614,7 @@ declare module OpenEO {
|
|
|
2593
2614
|
* @returns {Promise<Job>} The stored batch job.
|
|
2594
2615
|
* @throws {Error}
|
|
2595
2616
|
*/
|
|
2596
|
-
createJob(process: Process, title?: string | null, description?: string | null, plan?: string | null, budget?: number | null, additional?:
|
|
2617
|
+
createJob(process: Process, title?: string | null, description?: string | null, plan?: string | null, budget?: number | null, additional?: Record<string, any>): Promise<Job>;
|
|
2597
2618
|
/**
|
|
2598
2619
|
* Get all information about a batch job.
|
|
2599
2620
|
*
|
|
@@ -2608,10 +2629,10 @@ declare module OpenEO {
|
|
|
2608
2629
|
*
|
|
2609
2630
|
* @async
|
|
2610
2631
|
* @param {Array.<Service>} [oldServices=[]] - A list of existing services to update.
|
|
2611
|
-
* @returns {Promise<ResponseArray.<
|
|
2632
|
+
* @returns {Promise<ResponseArray.<Service>>} A list of services.
|
|
2612
2633
|
* @throws {Error}
|
|
2613
2634
|
*/
|
|
2614
|
-
listServices(oldServices?: Array<Service>): Promise<ResponseArray<
|
|
2635
|
+
listServices(oldServices?: Array<Service>): Promise<ResponseArray<Service>>;
|
|
2615
2636
|
/**
|
|
2616
2637
|
* Paginate through the secondary web services of the authenticated user.
|
|
2617
2638
|
*
|
|
@@ -2635,7 +2656,7 @@ declare module OpenEO {
|
|
|
2635
2656
|
* @returns {Promise<Service>} The stored service.
|
|
2636
2657
|
* @throws {Error}
|
|
2637
2658
|
*/
|
|
2638
|
-
createService(process: Process, type: string, title?: string | null, description?: string | null, enabled?: boolean, configuration?:
|
|
2659
|
+
createService(process: Process, type: string, title?: string | null, description?: string | null, enabled?: boolean, configuration?: Record<string, any>, plan?: string | null, budget?: number | null, additional?: Record<string, any>): Promise<Service>;
|
|
2639
2660
|
/**
|
|
2640
2661
|
* Get all information about a secondary web service.
|
|
2641
2662
|
*
|
|
@@ -2676,7 +2697,7 @@ declare module OpenEO {
|
|
|
2676
2697
|
* @throws {Error}
|
|
2677
2698
|
* @see https://github.com/axios/axios#request-config
|
|
2678
2699
|
*/
|
|
2679
|
-
protected _get(path: string, query:
|
|
2700
|
+
protected _get(path: string, query: Record<string, any>, responseType: string, abortController?: AbortController | null): Promise<AxiosResponse>;
|
|
2680
2701
|
/**
|
|
2681
2702
|
* Sends a POST request.
|
|
2682
2703
|
*
|
|
@@ -2740,7 +2761,7 @@ declare module OpenEO {
|
|
|
2740
2761
|
* @protected
|
|
2741
2762
|
* @returns {object.<string, string>}
|
|
2742
2763
|
*/
|
|
2743
|
-
protected _getAuthHeaders():
|
|
2764
|
+
protected _getAuthHeaders(): Record<string, string>;
|
|
2744
2765
|
/**
|
|
2745
2766
|
* Sends a HTTP request.
|
|
2746
2767
|
*
|
|
@@ -2761,7 +2782,7 @@ declare module OpenEO {
|
|
|
2761
2782
|
* @throws {Error}
|
|
2762
2783
|
* @see https://github.com/axios/axios
|
|
2763
2784
|
*/
|
|
2764
|
-
protected _send(options:
|
|
2785
|
+
protected _send(options: Record<string, any>, abortController?: AbortController | null): Promise<AxiosResponse>;
|
|
2765
2786
|
}
|
|
2766
2787
|
namespace Connection {
|
|
2767
2788
|
export { oidcProviderFactoryFunction, uploadStatusCallback };
|
|
@@ -2857,7 +2878,7 @@ declare module OpenEO {
|
|
|
2857
2878
|
status: number;
|
|
2858
2879
|
statusText: string;
|
|
2859
2880
|
headers: any;
|
|
2860
|
-
config:
|
|
2881
|
+
config: Record<string, any>;
|
|
2861
2882
|
request: any;
|
|
2862
2883
|
};
|
|
2863
2884
|
export type BillingPlan = {
|
|
@@ -2890,22 +2911,22 @@ declare module OpenEO {
|
|
|
2890
2911
|
*/
|
|
2891
2912
|
"federation:missing": Array<string>;
|
|
2892
2913
|
};
|
|
2893
|
-
export type Collection =
|
|
2914
|
+
export type Collection = Record<string, any>;
|
|
2894
2915
|
export type FileTypesAPI = {
|
|
2895
2916
|
/**
|
|
2896
2917
|
* - File types supported to import
|
|
2897
2918
|
*/
|
|
2898
|
-
input:
|
|
2919
|
+
input: Record<string, FileType>;
|
|
2899
2920
|
/**
|
|
2900
2921
|
* - File types supported to export
|
|
2901
2922
|
*/
|
|
2902
|
-
output:
|
|
2923
|
+
output: Record<string, FileType>;
|
|
2903
2924
|
};
|
|
2904
2925
|
export type FileType = {
|
|
2905
2926
|
title: string;
|
|
2906
2927
|
description: string;
|
|
2907
2928
|
gis_data_types: Array<string>;
|
|
2908
|
-
parameters:
|
|
2929
|
+
parameters: Record<string, any>;
|
|
2909
2930
|
links: Array<Link>;
|
|
2910
2931
|
};
|
|
2911
2932
|
/**
|
|
@@ -2926,7 +2947,7 @@ declare module OpenEO {
|
|
|
2926
2947
|
*/
|
|
2927
2948
|
from_parameter: string;
|
|
2928
2949
|
};
|
|
2929
|
-
export type Item =
|
|
2950
|
+
export type Item = Record<string, any>;
|
|
2930
2951
|
export type ItemCollection = {
|
|
2931
2952
|
/**
|
|
2932
2953
|
* - The items in the collection.
|
|
@@ -3000,7 +3021,7 @@ declare module OpenEO {
|
|
|
3000
3021
|
level: string;
|
|
3001
3022
|
message: string;
|
|
3002
3023
|
data: any;
|
|
3003
|
-
path: Array<
|
|
3024
|
+
path: Array<Record<string, string | null>>;
|
|
3004
3025
|
links: Array<Link>;
|
|
3005
3026
|
};
|
|
3006
3027
|
/**
|
|
@@ -3077,7 +3098,28 @@ declare module OpenEO {
|
|
|
3077
3098
|
/**
|
|
3078
3099
|
* An openEO processing chain.
|
|
3079
3100
|
*/
|
|
3080
|
-
export type Process =
|
|
3101
|
+
export type Process = Record<string, any>;
|
|
3102
|
+
/**
|
|
3103
|
+
* A specific processing parameter.
|
|
3104
|
+
*/
|
|
3105
|
+
type ProcessingParameter = object<string, any>;
|
|
3106
|
+
/**
|
|
3107
|
+
* All types of processing parameters.
|
|
3108
|
+
*/
|
|
3109
|
+
type ProcessingParameters = {
|
|
3110
|
+
/**
|
|
3111
|
+
* Processing parameters for batch jobs.
|
|
3112
|
+
*/
|
|
3113
|
+
create_job_parameters: Array<ProcessingParameter>;
|
|
3114
|
+
/**
|
|
3115
|
+
* Processing parameters for secondary web services.
|
|
3116
|
+
*/
|
|
3117
|
+
create_service_parameters: Array<ProcessingParameter>;
|
|
3118
|
+
/**
|
|
3119
|
+
* Processing parameters for synchronous processing.
|
|
3120
|
+
*/
|
|
3121
|
+
create_synchronous_parameters: Array<ProcessingParameter>;
|
|
3122
|
+
};
|
|
3081
3123
|
/**
|
|
3082
3124
|
* A back-end in the federation.
|
|
3083
3125
|
*/
|
|
@@ -3125,7 +3167,7 @@ declare module OpenEO {
|
|
|
3125
3167
|
* Adds two properties: `links` and `federation:missing`.
|
|
3126
3168
|
*/
|
|
3127
3169
|
export type ResponseArray = any;
|
|
3128
|
-
export type ServiceType =
|
|
3170
|
+
export type ServiceType = Record<string, any>;
|
|
3129
3171
|
export type SyncResult = {
|
|
3130
3172
|
/**
|
|
3131
3173
|
* The data as `Stream` in NodeJS environments or as `Blob` in browsers.
|
|
@@ -3144,7 +3186,7 @@ declare module OpenEO {
|
|
|
3144
3186
|
*/
|
|
3145
3187
|
logs: Array<Log>;
|
|
3146
3188
|
};
|
|
3147
|
-
export type UdfRuntime =
|
|
3189
|
+
export type UdfRuntime = Record<string, any>;
|
|
3148
3190
|
export type UserAccountStorage = {
|
|
3149
3191
|
/**
|
|
3150
3192
|
* in bytes as integer
|