Weaver CLI and Client

Once Weaver package is installed (see Installation), it provides a command line interface (CLI) as well as a Python weaver.cli.WeaverClient to allow simplified interactions through shell calls or Python scripts.

This offers to the user methods to use file references (e.g.: local CWL Application Package definition) to rapidly operate with functionalities such as Deploy, Describe, Execute and any other operation described in Managing processes included in Weaver ADES/EMS section.

Note

Technically, any OGC API - Processes implementation could be supported using the provided CLI and weaver.cli.WeaverClient. There are however some operations such as Uploading File to the Vault feature (and any utility that makes use of it) that are applicable only for Weaver instances.

Please refer to following sections for more details.

Python Client Commands

For details about using the Python weaver.cli.WeaverClient, please refer directly to its class documentation and its underlying methods.

Shell CLI Commands

Following are the detail for the shell CLI which provides the same features.

Run Weaver operations.

usage: weaver [-h] [--stdout] [--log LOG]
              [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
              [--version]
              {deploy,undeploy,register,unregister,capabilities,processes,describe,execute,jobs,monitor,dismiss,status,logs,exceptions,errors,statistics,stats,results,upload}
              ...

Optional Arguments

--version, -V

Display the version of the package.

Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Operations

Name of the operation to run.

operation

Possible choices: deploy, undeploy, register, unregister, capabilities, processes, describe, execute, jobs, monitor, dismiss, status, logs, exceptions, errors, statistics, stats, results, upload

Sub-commands:

deploy

Deploy a process.

weaver deploy [--stdout] [--log LOG]
              [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
              [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
              [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
              [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
              [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
              [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] [-p PROCESS_ID]
              [-b BODY] [--cwl CWL | --wps WPS] [-T TOKEN] [-U USERNAME]
              [-P PASSWORD] [-D]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-p, --id, --process

Process identifier for deployment. If no --body is provided, this is required. Otherwise, provided value overrides the corresponding ID in the body.

-b, --body

Deployment body directly provided. Allows both JSON and YAML format when using file reference. If provided in combination with process ID or CWL, they will override the corresponding content. Can be provided either with a local file, an URL or literal string contents formatted as JSON.

--cwl

Application Package of the process defined using Common Workflow Language (CWL) as JSON or YAML format when provided by file reference. File reference can be a local file or URL location. Can also be provided as literal string contents formatted as JSON. Provided contents will be inserted into an automatically generated request deploy body if none was specified with --body option (note: --process must be specified instead in that case). Otherwise, it will override the appropriate execution unit section within the provided deploy body.

--wps

Reference URL to a specific process under a Web Processing Service (WPS) to package as OGC-API Process.

-D, --delete, --undeploy

Perform undeploy step as applicable prior to deployment to avoid conflict with exiting process.

Default: False

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

Docker Authentication Arguments

Parameters to obtain access to a protected Docker registry to retrieve the referenced image.

-T, --token

Authentication token to retrieve a Docker image reference from a protected registry during execution.

-U, --username

Username to compute the authentication token for Docker image retrieval from a protected registry.

-P, --password

Password to compute the authentication token for Docker image retrieval from a protected registry.

undeploy

Undeploy an existing process.

weaver undeploy [--stdout] [--log LOG]
                [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
                [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] -p PROCESS_ID
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-p, --id, --process

Identifier of the process to run undeploy operation.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

register

Register a remote provider.

weaver register [--stdout] [--log LOG]
                [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
                [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] -pI PROVIDER_ID
                -pU PROVIDER_URL
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-pI, --provider

Identifier of a remote provider under which the referred process can be found to run register operation.

-pU, --provider-url

Endpoint URL of the remote provider to register.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

unregister

Unregister a remote provider.

weaver unregister [--stdout] [--log LOG]
                  [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                  [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
                  [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                  [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                  [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                  [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] -pI
                  PROVIDER_ID
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-pI, --provider

Identifier of a remote provider under which the referred process can be found to run unregister operation.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

capabilities (processes)

List available processes.

weaver capabilities [--stdout] [--log LOG]
                    [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                    [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
                    [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                    [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                    [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                    [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] [-P PAGE]
                    [-N LIMIT] [-D]
                    [-O {identifier,version,id,process,created}] [-nP | -wP]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-P, --page

Specify the paging index for process listing.

-N, --number, --limit

Specify the amount of process to list per page.

-D, --detail

Obtain detailed process descriptions instead of only their ID (default: False).

Default: False

-O, --order, --sort

Possible choices: identifier, version, id, process, created

Sorting field to list process. Name must be one of the fields supported by process objects.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

Remote Provider Arguments

Parameters related to remote providers reporting.

-nP, --no-providers

Omit “providers” listing from returned result body (default).

Default: False

-wP, --with-providers

Include “providers” listing in returned result body along with local processes.

Default: False

describe

Obtain an existing process description.

weaver describe [--stdout] [--log LOG]
                [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
                [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] -p PROCESS_ID
                [-pI PROVIDER_ID] [-S {OGC,WPS,OLD}]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-p, --id, --process

Identifier of the process to run describe operation.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-pI, --provider

Identifier of a remote provider under which the referred process can be found to run describe operation.

-S, --schema

Possible choices: OGC, WPS, OLD

Representation schema of the returned process description (default: OGC, case-insensitive).

Default: OGC

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

execute

Submit a job execution for an existing process.

weaver execute [--stdout] [--log LOG]
               [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
               [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
               [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
               [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
               [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
               [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] -p PROCESS_ID
               [-pI PROVIDER_ID] -I INPUTS [-R REFERENCE] [-M] [-T TIMEOUT]
               [-W INTERVAL]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-p, --id, --process

Identifier of the process to run execute operation.

-I, --inputs

Literal input definitions, or a file path or URL reference to JSON or YAML contents defining job inputs with OGC-API or CWL schema. This parameter is required.

To provide inputs using a file reference, refer to relevant CWL Job schema or API request schema for selected format. Both mapping and listing formats are supported.

To execute a process without any inputs (e.g.: using its defaults), supply an explicit empty input (i.e.: -I "" or loaded from JSON/YAML file as {}).

To provide inputs using literal command-line definitions, inputs should be specified using <id>=<value> convention, with distinct -I options for each applicable input value.

Values that require other type than string to be converted for job submission can include the data type following the ID using a colon separator (i.e.: <id>:<type>=<value>). For example, an integer could be specified as follows: number:int=1 while a floating point number would be: number:float=1.23.

File references (href) should be specified using File as the type (i.e.: input:File=http://...). Note that File in this case is expected to be an URL location where the file can be download from. When a local file is supplied, Weaver will automatically convert it to a remote Vault File in order to upload it at the specified URL location and make it available for the remote process.

Inputs with multiplicity (maxOccurs > 1) can be specified using semicolon (;) separated values after a single input ID. Note that this is not the same as an single-value array-like input, which should use comma (,) separated values instead. The type of an element-wise item of this input can also be provided (i.e.: multiInput:int=1;2;3). Alternatively, the same input ID can be repeated over many -I options each providing an element of the multi-value input to be formed (i.e.: -I multiInput=1 -I multiInput=2 -I multiInput=3).

Additional parameters can be specified following any <value> using any amount of @<param>=<info> specifiers. Those will be added to the inputs body submitted for execution. This can be used, amongst other things, to provide a file’s mediaType or encoding details. When using multi-value inputs, each item value can take @ parameters independently with distinct properties.

Any value that contains special separator characters (:;@) to be used as literal entries must be URL-encoded (%XX) to avoid invalid parsing.

Example: -I message='Hello Weaver' -I value:int=1234 -I file:File=data.xml@mediaType=text/xml

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-pI, --provider

Identifier of a remote provider under which the referred process can be found to run execute operation.

-R, --ref, --reference

Indicates which outputs by ID to be returned as HTTP Link header reference instead of body content value. This defines the output transmission mode when submitting the execution request.

With reference transmission mode, outputs that contain literal data will be linked by text/plain file containing the data. Outputs that refer to a file reference will simply contain that URL reference as link.

With value transmission mode (default behavior when outputs are not specified in this list), outputs are returned as direct values (literal or href) within the response content body.

When requesting any output to be returned by reference, option -H/--headers should be considered as well to return the provided Link headers for these outputs on the command line.

Example: -R output-one -R output-two

-M, --monitor

Automatically perform the monitoring operation following job submission to retrieve final results. If not requested, the created job status location is directly returned.

Default: False

-T, --timeout, --exec-timeout

Wait timeout (seconds) of the maximum monitoring duration of the job execution (default: 60s). If this timeout is reached but job is still running, another call directly to the monitoring operation can be done to resume monitoring. The job execution itself will not stop in case of timeout.

Default: 60

-W, --wait, --interval

Wait interval (seconds) between each job status polling during monitoring (default: 5s).

Default: 5

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

jobs

Obtain listing of registered jobs.

weaver jobs [--stdout] [--log LOG]
            [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
            [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
            [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
            [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
            [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
            [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] [-P PAGE] [-N LIMIT]
            [-D] [-O {finished,status,user,service,process,created}]
            [-S {paused,dismissed,started,unknown,successful,failed,succeeded,accepted,exception,running} [{paused,dismissed,started,unknown,successful,failed,succeeded,accepted,exception,running} ...]]
            [-G] [-fP PROCESS] [-fS PROVIDER] [-fT TAGS [TAGS ...]]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-P, --page

Specify the paging index for job listing.

-N, --number, --limit

Specify the amount of job to list per page.

-D, --detail

Obtain detailed job descriptions instead of only their ID (default: False).

Default: False

-O, --order, --sort

Possible choices: finished, status, user, service, process, created

Sorting field to list job. Name must be one of the fields supported by job objects.

-S, --status

Possible choices: paused, dismissed, started, unknown, successful, failed, succeeded, accepted, exception, running

Filter job listing only to matching status. If multiple are provided, must match one of them.

-G, --groups

Obtain grouped representation of jobs per provider and process categories.

Default: False

-fP, --process

Filter job listing only to matching process (local and/or remote whether combined with ‘-fS’).

-fS, --provider, --service

Filter job listing only to matching remote service provider.

-fT, --tags

Filter job listing only to matching tags. Jobs must match all tags simultaneously, not one of them.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

monitor

Monitor a pending or running job execution until completion or up to a maximum wait time.

weaver monitor [--stdout] [--log LOG]
               [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
               [-h] [-u URL] -j JOB_REFERENCE [-T TIMEOUT] [-W INTERVAL]
               [-nL | -wL] [-nH | -wH] [-H HEADER]
               [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
               [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
               [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
               [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Required Arguments
-j, --job

Job URL or UUID to run monitor operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-T, --timeout, --exec-timeout

Wait timeout (seconds) of the maximum monitoring duration of the job execution (default: 60s). If this timeout is reached but job is still running, another call directly to the monitoring operation can be done to resume monitoring. The job execution itself will not stop in case of timeout.

Default: 60

-W, --wait, --interval

Wait interval (seconds) between each job status polling during monitoring (default: 5s).

Default: 5

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

dismiss

Dismiss a pending or running job, or wipe any finished job results.

weaver dismiss [--stdout] [--log LOG]
               [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
               [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH]
               [-H HEADER]
               [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
               [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
               [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
               [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run dismiss operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

status

Obtain the status of a job using a reference UUID or URL. This is equivalent to doing a single-shot ‘monitor’ operation without any pooling or retries.

weaver status [--stdout] [--log LOG]
              [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
              [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH]
              [-H HEADER]
              [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
              [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
              [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
              [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run status operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

logs

Obtain the logs of a job using a reference UUID or URL. Only guaranteed by Weaver instances. Pure ‘OGC API - Processes’ servers might not implement this feature.

weaver logs [--stdout] [--log LOG]
            [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
            [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH] [-H HEADER]
            [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
            [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
            [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
            [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run logs operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

exceptions (errors)

Obtain the exceptions and error details of a failed job using a reference UUID or URL. If the job is not marked with failed status, this will return an error. Only guaranteed by Weaver instances. Pure ‘OGC API - Processes’ servers might not implement this feature.

weaver exceptions [--stdout] [--log LOG]
                  [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                  [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH]
                  [-H HEADER]
                  [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                  [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                  [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                  [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run exceptions operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

statistics (stats)

Obtain the computation statistics details of a successful job using a reference UUID or URL. If the job is not marked with succeeded status, this will return an error. Only guaranteed by Weaver instances. Pure ‘OGC API - Processes’ servers might not implement this feature.

weaver statistics [--stdout] [--log LOG]
                  [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
                  [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH]
                  [-H HEADER]
                  [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
                  [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
                  [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
                  [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run statistics operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

results

Obtain the output results from a job successfully executed. This operation can also download them from the remote server if requested.

weaver results [--stdout] [--log LOG]
               [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
               [-h] [-u URL] -j JOB_REFERENCE [-nL | -wL] [-nH | -wH]
               [-H HEADER]
               [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
               [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
               [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
               [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] [-D] [-O OUT_DIR]
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-j, --job

Job URL or UUID to run results operation. If full Job URL is provided, the instance --url parameter can be omitted.

Optional Arguments
-u, --url

URL of the instance to run operations.

-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-D, --download

Download all found job results file references to output location. If not requested, the operation simply displays the job results (default: False).

Default: False

-O, --outdir

Output directory where to store downloaded files from job results if requested (default: ${CURDIR}/{JobID}/<outputs.files>).

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

upload

Upload a local file to the remote server vault for reference in process execution inputs. This operation is accomplished automatically for all execution inputs submitted using local files. [note: feature only available for Weaver instances]

weaver upload [--stdout] [--log LOG]
              [--quiet | --debug | --verbose | --log-level {DEBUG,ERROR,INFO,WARN}]
              [-h] -u URL [-nL | -wL] [-nH | -wH] [-H HEADER]
              [-F {JSON,JSON+RAW,JSON+STR,TEXT,TXT,XML,XML+RAW,XML+STR,YAML,YML}]
              [-rT REQUEST_TIMEOUT] [-rR REQUEST_RETRIES]
              [-aC AUTH_HANDLER_CLASS] [-aI IDENTITY] [-aP PASSWORD]
              [-aU AUTH_URL] [-aM HTTP_METHOD] [-aH HEADER] [-c CONTENT_TYPE]
              -f FILE
Logging Arguments

Options that configure output logging.

--stdout

Enforce logging to stdout for display in console.

Default: False

--log, --log-file

Output file to write generated logs.

--quiet, -q

Do not output anything else than error.

Default: False

--debug, -d

Enable extra debug logging.

Default: False

--verbose, -v

Output informative logging details.

Default: False

--log-level, -l

Possible choices: DEBUG, ERROR, INFO, WARN

Explicit log level to employ (default: None, case-insensitive).

Required Arguments
-u, --url

URL of the instance to run operations.

-f, --file

Local file path to upload to the vault.

Optional Arguments
-nL, --no-links

Remove “links” section from returned result body.

Default: True

-wL, --with-links

Preserve “links” section from returned result body (default).

Default: True

-nH, --no-headers

Omit response headers, only returning the result body (default).

Default: False

-wH, --with-headers

Return response headers additionally to the result body.

Default: False

-H, --header

Additional headers to apply for sending requests toward the service. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed. Note that overridden headers expected by requests and the service could break some functionalities.

-F, --format

Possible choices: JSON, JSON+RAW, JSON+STR, TEXT, TXT, XML, XML+RAW, XML+STR, YAML, YML

Select an alternative output representation (default: JSON+STR, case-insensitive).

JSON: Representation as JSON (object), which can still be manipulated in code.

JSON+RAW: Representation as JSON content formatted as raw string without any indentation or newlines.

JSON+STR: Representation as JSON content formatted as string with indentation and newlines.

TEXT: Representation as plain text content without any specific reformatting or validation.

TXT: Representation as plain text content without any specific reformatting or validation.

XML: Representation as XML content formatted as serialized string.

XML+RAW: Representation as XML content formatted as raw string without indentation or newlines.

XML+STR: Representation as XML content formatted as string with indentation and newlines.

YAML: Representation as YAML content formatted as string with indentation and newlines.

YML: Alias to YAML.

-c, --content-type

Content-Type of the file to apply. This should be an IANA Media-Type, optionally with additional parameters such as charset. If not provided, attempts to guess it based on the file extension.

Request Arguments

Parameters to control specific options related to HTTP request handling.

-rT, --request-timeout

Maximum timout duration (seconds) to wait for a response when performing HTTP requests (default: 5s).

Default: 5

-rR, --request-retries

Amount of attempt to retry HTTP requests in case of failure (default: no retry).

Service Authentication Arguments

Parameters to obtain access to a protected service using a request authentication handler.

-aC, --auth-class, --auth-handler

Script or module path reference to class implementation to handle inline request authentication. Format [path/to/script.py:module.AuthHandlerClass] or [installed.module.AuthHandlerClass] is expected.

Utility definitions are available as:

weaver.cli.BasicAuthHandler weaver.cli.BearerAuthHandler weaver.cli.CookieAuthHandler

Custom implementations are allowed for more advanced use cases.

-aI, --auth-identity, --auth-username

Authentication identity (or username) to be passed down to the specified Authentication Handler.

-aP, --auth-password

Authentication password to be passed down to the specified Authentication Handler.

-aU, --auth-url

Authentication URL to be passed down to the specified Authentication Handler.

-aM, --auth-method

Possible choices: GET, HEAD, POST, PUT, DELETE

Authentication HTTP request method to be passed down to the specified Authentication Handler (default: GET, case-insensitive).

Default: GET

-aH, --auth-header

Additional headers to apply for sending requests when using the authentication handler. This option can be provided multiple times, each with a value formatted as:

‘Header-Name: value’

Header names are case-insensitive. Quotes can be used in the <value> portion to delimit it. Surrounding spaces are trimmed.

CLI and Client Examples

Following sections present different typical usage of the Shell CLI Commands and Python Client Commands. Operations are equivalent between the CLI and Python client.

Note

Much more operations and option parameters are available. They are not all necessarily represented in below examples. Explore available arguments using weaver <operation> --help or using the above documentation for Python Client Commands and cli_commands.

For each of the following examples, the client is created as follows:

Python
client = WeaverClient(url="{WEAVER_URL}")

Authentication Example

For any operation that requires authentication/authorization to access a protected service targeted by {WEAVER_URL}, it is possible to either provide the auth parameter during initialization of the weaver.cli.WeaverClient itself (the specific weaver.cli.AuthHandler is reused for all operations), or as argument to individual methods when calling the respective operation (handler only used for that step).

Any class implementation that derives from weaver.cli.AuthHandler or requests.auth.AuthBase can be used for the auth argument. This class must implement the __call__ method taking a single request``argument and returning the adjusted ``request instance. The call should apply any relevant modifications to grant the necessary authentication/authorization details. This __call__ will be performed inline prior to sending the actual request toward the service.

Note

There are multiple predefined handlers available for use:

When using the Shell CLI Commands, the specific weaver.cli.AuthHandler implementation to employ must be provided using the --auth-handler/--auth-class (-aC) argument. This can be an importable (installed) class module reference or a plain Python script path separated with a : character followed by the class name definition. Other --auth prefixed arguments can also be supplied, but their actual use depend on the targeted authentication handler implementation.

Below are examples of possible commands:

Command Line
weaver capabilities -u {WEAVER_URL} -aH requests_magpie.MagpieAuth -aU ${MAGPIE_URL} -aI <username> -aP <password>

When using the Python Interface, the desired implementation can be specified directly.

client.capabilities(auth=requests_magpie.MagpieAuth("${MAGPIE_URL]", "<username>", "<password>"))

Deploy Example

Accomplishes the Deployment request in order to subscribe a new Process in the service. Requires a Weaver or OGC API - Processes - Part 2: Deploy, Replace, Undeploy compliant instance.

The Process can correspond to an Application Package using CWL (i.e.: a script, a Docker application, etc.) or a Remote Provider using an external WPS (XML, JSON) or another OGC API - Processes instance. A Workflow of multiple Process references (possibly of distinct nature) can also be deployed.

See also

Chapter Type of Processes covers supported definitions and further explain each type.

Note

If the Application Package being deployed employs a protected Docker repository reference, access can be provided using the corresponding parameters. Those will be required for later execution of the application in order to retrieve the referenced Docker image.

Note

Content definitions for CWL Application Package and/or the literal Process body can be submitted using either a local file reference, an URL, or a literal string formatted as JSON or :temr:`YAML`. With the Python Interface, the definition can also be provided with a dict directly.

Below is a sample Process deployment using a basic Python script wrapped in a Docker image to ensure all requirements are met. The CWL definition provides all necessary inputs and outputs definition to run the desired Application Package. The contents of below URL definition is also available in Sample CWL definition of a Python script.

Command Line
weaver deploy -u {WEAVER_URL} \
    -p docker-python-script-report \
    --cwl https://raw.githubusercontent.com/crim-ca/weaver/master/docs/examples/docker-python-script-report.cwl
Python
client.deploy(
    process_id="docker-python-script-report",
    cwl="https://raw.githubusercontent.com/crim-ca/weaver/master/docs/examples/docker-python-script-report.cwl",
)

Sample Output:

{
  "description": "Process successfully deployed.",
  "processSummary": {
    "id": "docker-python-script-report",
    "mutable": true,
    "keywords": [
      "application"
    ],
    "metadata": [],
    "jobControlOptions": [
      "async-execute",
      "sync-execute"
    ],
    "outputTransmission": [
      "reference",
      "value"
    ],
    "processDescriptionURL": "http://schema-example.com/processes/docker-python-script-report",
    "executeEndpoint": "http://schema-example.com/processes/docker-python-script-report/jobs"
  },
  "deploymentDone": true
}

Undeploy Example

Accomplishes the Undeployment request to remove a previously Deployed Process from the service. Requires a Weaver or OGC API - Processes - Part 2: Deploy, Replace, Undeploy compliant instance.

Command Line
weaver undeploy -u {WEAVER_URL} -p docker-python-script-report
Python
client.undeploy("docker-python-script-report")

Sample Output:

{
  "description": "Process successfully undeployed.",
  "identifier": "docker-python-script-report",
  "undeploymentDone": true
}

GetCapabilities Example

Accomplishes the GetCapabilities request to obtain a list of available Process.

Command Line
weaver capabilities -u {WEAVER_URL}
Python
client.capabilities()

Sample Output:

{
  "description": "Listing of available processes successful.",
  "processes": [
    "docker-demo-cat",
    "docker-python-script",
    "Echo",
    "file_index_selector",
    "file2string_array",
    "image-utils",
    "jsonarray2netcdf",
    "las2tif",
    "metalink2netcdf",
    "sleep"
  ],
  "page": 0,
  "total": 25
}

DescribeProcess Example

Accomplishes the DescribeProcess request to obtain the Process definition.

Command Line
weaver describe -u {WEAVER_URL} -p jsonarray2netcdf
Python
client.describe("jsonarray2netcdf")

Sample Output:

{
  "id": "jsonarray2netcdf",
  "title": "JSON array to NetCDF",
  "version": "1.1",
  "abstract": "Extracts and fetches NetCDF files from a JSON file containing an URL string array, and provides them on the output directory.",
  "keywords": [],
  "metadata": [],
  "inputs": {
    "input": {
      "title": "input",
      "formats": [
        {
          "mimeType": "application/json",
          "default": true
        }
      ],
      "minOccurs": "1",
      "maxOccurs": "1"
    }
  },
  "outputs": {
    "output": {
      "title": "output",
      "formats": [
        {
          "mimeType": "application/x-netcdf",
          "default": true
        }
      ]
    }
  },
  "visibility": "public",
  "processEndpointWPS1": "http://schema-example.com/wps",
  "processDescriptionURL": "http://schema-example.com/processes/jsonarray2netcdf/jobs",
  "executeEndpoint": "http://schema-example.com/processes/jsonarray2netcdf/jobs",
  "links": [
    {
      "type": "application/json",
      "title": "Process description.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/jsonarray2netcdf",
      "rel": "self"
    },
    {
      "type": "application/json",
      "title": "Process description.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/jsonarray2netcdf",
      "rel": "process-desc"
    },
    {
      "type": "application/json",
      "title": "Process execution endpoint for job submission.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/jsonarray2netcdf/execution",
      "rel": "execute"
    },
    {
      "type": "application/json",
      "title": "List of registered processes.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes",
      "rel": "collection"
    },
    {
      "type": "application/xml",
      "title": "Service definition.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/ows/wps?service=WPS&request=GetCapabilities",
      "rel": "service-desc"
    }
  ]
}

Execute Example

Accomplishes the Execute request to launch a Job execution with the specified Process and provided inputs. Execution can also take multiple execution control parameters such as requesting outputs by reference, selecting the (a)synchronous mode to be employed and much more.

See also

Please refer to weaver.cli.WeaverClient.execute() arguments, CLI execute operation and chapter Execute documentation for more details regarding all implications of Job execution. File reference types, request contents, execution modes and other advanced use cases are covered in greater extent.

Note

Parameters available for Status Monitoring can also be provided directly during this operation. This has the effect of executing the Job and immediately monitor the obtained status until the completed status is obtained, or timeout is reached, whichever occurs first.

Note

Any valid local file path given as input for the Job execution will be automatically uploaded toward the service (Weaver required) in order to make it available for the underlying application defined by the Process. The same procedure as the Manual Upload operation is employed to temporarily place the file(s) in the Vault and make it accessible only for the submitted Job. The file(s) submitted this way will be deleted once retrieved by the Process for execution.

In order to use the Shell CLI Commands, the Job inputs definition has been made extremely versatile. Arguments can be provided using literal string entries by repeating -I options followed by their desired KVP definitions. Additional properties can also be supplied in order to specify precisely what needs to be submitted to the Process. Please refer to CLI execute help message for more explanations.

Command Line
weaver execute -u {WEAVER_URL} -p Echo \
    -I "message='Hello World!'" \
    -I value:int=123456 \
    -I array:float=1.23,4.56 \
    -I multi:File=http://example.com/data.json;=http://other.com/catalog.json \
    -I multi:File=http://another.com/data.json \
    -I single:File=/workspace/data.xml@mediaType=text/xml

Inputs can also be provided using a JSON or YAML Job document (as when running CWL) or using a JSON document matching the schema normally submitted by HTTP request for OGC APi - Processes execution.

When using the Python Interface, the inputs can be provided in the same manner as for the above CLI variations, but it is usually more intuitive to use a Python dict directly.

Python
client.execute("Echo", {
    "message": "Hello World!",
    "value": 123456,
    "array": [1.23, 4.56],
    "multi": [
        {"href": "http://example.com/data.json"},
        {"href": "http://other.com/catalog.json"},
        {"href": "http://another.com/data.json"},
    ],
    "single": {
        "href": "/workspace/data.xml@mediaType",  # note: uploaded to vault automatically before execution
        "type": "text/xml",
    }
})

Sample Output:

{
  "description": "Job successfully submitted to processing queue. Execution should begin when resources are available.",
  "jobID": "797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
  "processID": "Echo",
  "status": "accepted",
  "location": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8"
}

Dismiss Example

Accomplishes the Job dismiss request to either cancel an accepted or running Job or to remove any stored results from a successful execution.

Command Line
weaver dismiss -u {WEAVER_URL} -j "29af3a33-0a3e-477d-863e-efccc97e0b02"
Python
client.dismiss("29af3a33-0a3e-477d-863e-efccc97e0b02")

Sample Output:

GetStatus Example

Accomplishes the GetStatus operation to request the current status of a Job.

Command Line
weaver status -u {WEAVER_URL} -j "797c0c5e-9bc2-4bf3-ab73-5f3df32044a8"
Python
client.status("797c0c5e-9bc2-4bf3-ab73-5f3df32044a8")

Sample Output:

{
  "jobID": "797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
  "processID": "Echo",
  "providerID": null,
  "type": "process",
  "status": "succeeded",
  "message": "Job succeeded.",
  "created": "2022-06-03T23:46:45.049000+00:00",
  "started": "2022-06-03T23:46:45.077000+00:00",
  "finished": "2022-06-03T23:46:48.134000+00:00",
  "updated": "2022-06-03T23:46:48.135000+00:00",
  "duration": "00:00:03",
  "runningDuration": "PT03S",
  "runningSeconds": 3.057,
  "percentCompleted": 100,
  "progress": 100,
  "links": [
    {
      "title": "Job status.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
      "type": "application/json",
      "rel": "status"
    },
    {
      "title": "Job monitoring location.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
      "type": "application/json",
      "rel": "monitor"
    },
    {
      "title": "Job status generic endpoint.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
      "type": "application/json",
      "rel": "alternate"
    },
    {
      "title": "List of submitted jobs.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/jobs",
      "type": "application/json",
      "rel": "collection"
    },
    {
      "title": "List of submitted jobs.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/jobs",
      "type": "application/json",
      "rel": "http://www.opengis.net/def/rel/ogc/1.0/job-list"
    },
    {
      "title": "New job submission endpoint for the corresponding process.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/execution",
      "type": "application/json",
      "rel": "http://www.opengis.net/def/rel/ogc/1.0/execute"
    },
    {
      "title": "Submitted job inputs for process execution.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8/inputs",
      "type": "application/json",
      "rel": "inputs"
    },
    {
      "title": "Job outputs of successful process execution (extended outputs with metadata).",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8/outputs",
      "type": "application/json",
      "rel": "outputs"
    },
    {
      "title": "Job results of successful process execution (direct output values mapping).",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8/results",
      "type": "application/json",
      "rel": "http://www.opengis.net/def/rel/ogc/1.0/results"
    },
    {
      "title": "Job statistics collected following process execution.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8/statistics",
      "type": "application/json",
      "rel": "statistics"
    },
    {
      "title": "List of collected job logs during process execution.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8/logs",
      "type": "application/json",
      "rel": "logs"
    },
    {
      "title": "Job status.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
      "type": "application/json",
      "rel": "self"
    },
    {
      "title": "Job status details.",
      "hreflang": "en-CA",
      "href": "http://schema-example.com/processes/Echo/jobs/797c0c5e-9bc2-4bf3-ab73-5f3df32044a8",
      "type": "application/json",
      "rel": "up"
    }
  ]
}

Jobs Example

Accomplishes the Job listing request to obtain known Job definitions using filter search queries.

Command Line
weaver jobs -u {WEAVER_URL} -nL
Python
client.jobs(with_links=False)

Note

Option -nL and argument with_links are used to omit links section in sample output.

Sample Output:

Monitor Example

If a Job was summited for execution, it is possible to perform Status Monitoring of this Job until completion or until the specified timeout is reached. This can be performed at any moment on a pending or running Job.

See also

It is possible to directly perform monitoring when calling the Job Execution operation. Simply provide the relevant arguments and options applicable to the monitoring step during the execute call.

Command Line
# assuming job is 'running'
weaver monitor -u {WEAVER_URL} -j "14c68477-c3ed-4784-9c0f-a4c9e1344db5"
Python
client.results("14c68477-c3ed-4784-9c0f-a4c9e1344db5")

Monitor output should be in as similar format as GetStatus Example with the latest Job status retrieved.

Results Example

Retrieves the Job Results from a successful Job execution.

Note

It is possible to employ the download argument to retrieve File outputs from a Job. If this is enabled, files will be downloaded using the URL references specified in the Job results and store them in the specified local output directory.

Command Line
weaver results -u {WEAVER_URL} -j "14c68477-c3ed-4784-9c0f-a4c9e1344db5"
Python
client.results("14c68477-c3ed-4784-9c0f-a4c9e1344db5")

Sample Output:

{
  "output": {
    "href": "http://schema-example.com/wpsoutputs/14c68477-c3ed-4784-9c0f-a4c9e1344db5/output.txt",
    "format": {
      "mediaType": "text/plain"
    }
  }
}

Upload Example

This operation allows manual upload of a local file to the Vault.

Note

When running the execute operation, any detected local file reference will be automatically uploaded as Vault file in order to make it available for the remote Weaver server for Process execution.

See also

File Vault Inputs and Uploading File to the Vault provide more details about this feature.

Command Line
weaver upload -u {WEAVER_URL} -f /path/to/file.txt
Python
client.upload("/path/to/file.txt")

Sample Output:

{
  "description": "File successfully uploaded to vault.",
  "access_token": "<ACCESS_TOKEN>",
  "file_id": "e337a830-dbd6-4915-90ef-bfd46e237a3e",
  "file_href": "vault://e337a830-dbd6-4915-90ef-bfd46e237a3e"
}