Methods
(static) clientVersion() → {string}
Returns the version number of the client.
Not to confuse with the API version(s) supported by the client.
Returns:
Version number (according to SemVer).
- Type
- string
(async, static) connect(url, authTypeopt, authOptionsopt) → {Connection}
Connect to a back-end with version discovery (recommended).
Includes version discovery (request to `GET /well-known/openeo`) and connects to the most suitable version compatible to this JS client version.
Requests the capabilities and authenticates where required.
Parameters:
| Name | Type | Attributes | Default | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
url |
string | The server URL to connect to. | ||||||||||||||||||||||
authType |
string |
<optional> |
null | Authentication type, either `basic` for HTTP Basic, `oidc` for OpenID Connect (Browser only) or `null` to disable authentication. | ||||||||||||||||||||
authOptions |
object |
<optional> |
{} | Object with authentication options.
Properties
|
Throws:
Error
Returns:
- Type
- Connection
(async, static) connectDirect(url, authTypeopt, authOptionsopt) → {Connection}
Connects directly to a back-end instance, without version discovery (NOT recommended).
Doesn't do version discovery, therefore a URL of a versioned API must be specified. Requests the capabilities and authenticates where required.
Parameters:
| Name | Type | Attributes | Default | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
url |
string | The server URL to connect to. | ||||||||||||||||||||||
authType |
string |
<optional> |
null | Authentication type, either `basic` for HTTP Basic, `oidc` for OpenID Connect (Browser only) or `null` to disable authentication. | ||||||||||||||||||||
authOptions |
object |
<optional> |
{} | Object with authentication options.
Properties
|
Throws:
Error
Returns:
- Type
- Connection