From 04541cfc94e0fb52228dadfdea410c548b1d0198 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 11:17:06 -0400 Subject: [PATCH 01/11] adjust docs generation settings --- docs/_extensions/doc_redirect.py | 119 +++++++++++++++++++++++++++++ docs/_static/.gitignore | 3 + docs/_templates/autoapi/module.rst | 15 ++++ docs/api.json | 1 + docs/source/conf.py | 72 ++++++++++++++--- requirements-docs.txt | 12 ++- weaver/wps_restapi/api.py | 45 +++++++---- 7 files changed, 240 insertions(+), 27 deletions(-) create mode 100644 docs/_extensions/doc_redirect.py create mode 100644 docs/_static/.gitignore create mode 100644 docs/_templates/autoapi/module.rst create mode 100644 docs/api.json diff --git a/docs/_extensions/doc_redirect.py b/docs/_extensions/doc_redirect.py new file mode 100644 index 000000000..6cf85465d --- /dev/null +++ b/docs/_extensions/doc_redirect.py @@ -0,0 +1,119 @@ +# Inspired by following extension but used locally as there are not pypi package. +# source: https://github.com/sphinx-contrib/redirects + +import os + +from sphinx.builders import html as builders +from sphinx.util import logging + +LOGGER = logging.getLogger(__name__) + +TEMPLATE = """ + + +""" + + +def generate_redirects(app): + """ + This extension allows to fake a link to the HTML page actually generated by an RST file which contains a literal. + + *reference* to another RST file. + + For example, suppose we have two RST (ie: ``file1.rst`` and ``file2.rst`` ). Within ``file1.rst`` we got: + + .. code-block:: rst + + see `file2`_ details + + .. _file2: ./docs/file2.rst + + Normally, the generated HTML will have an hyperlink named ``file2`` with a *literal* reference to ``file2.rst``. + This will result in HTTP Not Found (404) as it doesn't correspond to the generated ``file2.html``. Normally, this + can be fixed using the following directive: + + .. code-block:: rst + + :doc:`./docs/file2.rst` + + But then, rendering on GitHub becomes literally this string with an hyperlink reference that doesn't lead to the + desired ``file2.rst`` (for quick documentation locally within the GitHub repository). + + With this extension, if configuration is specified as follows, the HTML link is resolved by redirecting the literal + ``./file2.rst`` reference in the output HTML build directory to the desired ``file2.html`` generated (as required). + + .. code-block:: python + + doc_redirect_map = { + # mapping of: => + "file2.rst": "file2.rst" + } + + In other words, when ``file1.rst`` is viewed from GitHub, the literal relative path is used an the file is found, + while on ``Readthedocs`` (or when viewing locally in a browser), ``file1.html`` will contain a raw relative path to + where the pointed ``file2.html`` *should* be using corresponding base directories. This is demonstrated below: + + .. code-block:: text + + '/docs/file1.rst' ===> '/file1.html' (ref [file2]) ---> (raw '/docs/file2.rst') + | + | + '/docs/file2.rst' ===> '/file2.html' <------------------------------ + + .. note:: + + Literal RST file references must be relative to package root in other to be rendered correctly on GitHub. + """ + + if not isinstance(app.builder, builders.StandaloneHTMLBuilder): + ext = os.path.split(__file__)[-1].split(".")[0] + LOGGER.warning("Extension '{}' is only supported by the 'html' builder. Skipping...".format(ext)) + return + if not isinstance(app.config.doc_redirect_map, dict) and len(app.config.doc_redirect_map): + LOGGER.info("Could not find doc redirect map") + return + in_suffix = None + if isinstance(app.config.source_suffix, list): + in_suffix = app.config.source_suffix[0] + elif isinstance(app.config.source_suffix, dict): + in_suffix = list(app.config.source_suffix.items())[0][0] + elif app.config.source_suffix: + in_suffix = app.config.source_suffix + if not in_suffix: + in_suffix = ".rst" + + for from_path, to_path in app.config.doc_redirect_map.items(): + LOGGER.debug("Redirecting [%s] -> [%s]" % (from_path, to_path)) + + rst_path = from_path + if not rst_path.endswith(in_suffix): + rst_path = rst_path + in_suffix + html_path = from_path.replace(in_suffix, ".html") + to_path_prefix = "..%s" % os.path.sep * ( + len(html_path.split(os.path.sep)) - 1) + to_path = to_path_prefix + to_path.replace(in_suffix, ".html") + if not to_path.endswith(".html"): + to_path = to_path + ".html" + LOGGER.debug("RST [%s] -> [%s]" % (rst_path, to_path)) + LOGGER.debug("HTML [%s] -> [%s]" % (html_path, to_path)) + + redirected_rst_file = os.path.join(app.builder.outdir, rst_path) + redirected_html_file = os.path.join(app.builder.outdir, html_path) + redirected_directory = os.path.dirname(redirected_html_file) + if not os.path.exists(redirected_directory): + os.makedirs(redirected_directory) + + # create unless it already exists (eg: same directory level, config map is redundant) + if not os.path.exists(redirected_html_file): + # if using a direct call with .html extension, it will still work as if calling the .rst + with open(redirected_html_file, "w") as f: + f.write(TEMPLATE % to_path) + if not os.path.exists(redirected_rst_file): + # point to the .rst that would be reach by clicking the literal reference + # by faking an .html file redirect + os.symlink(redirected_html_file, redirected_rst_file) + + +def setup(app): + app.add_config_value("doc_redirect_map", {}, "env", dict) + app.connect("builder-inited", generate_redirects) diff --git a/docs/_static/.gitignore b/docs/_static/.gitignore new file mode 100644 index 000000000..d5a737218 --- /dev/null +++ b/docs/_static/.gitignore @@ -0,0 +1,3 @@ +# make this directory available as it is referenced by some extensions +*.* +!.gitignore diff --git a/docs/_templates/autoapi/module.rst b/docs/_templates/autoapi/module.rst new file mode 100644 index 000000000..ef9db0074 --- /dev/null +++ b/docs/_templates/autoapi/module.rst @@ -0,0 +1,15 @@ +.. see original here: https://github.com/readthedocs/sphinx-autoapi/blob/master/autoapi/templates/index.rst + +Source Code +============= + +This page contains reference documentation of the source code. + +.. toctree:: + :titlesonly: + + {% for page in pages %} + {% if page.top_level_object and page.display %} + {{ page.include_path }} + {% endif %} + {% endfor %} diff --git a/docs/api.json b/docs/api.json new file mode 100644 index 000000000..e4636af0e --- /dev/null +++ b/docs/api.json @@ -0,0 +1 @@ +{"schemes": ["https"], "host": "example", "swagger": "2.0", "info": {"title": "Weaver REST API", "version": "1.10.1"}, "basePath": "/", "tags": [{"name": "API"}, {"name": "Processes"}, {"name": "GetCapabilities"}, {"name": "Deploy"}, {"name": "DescribeProcess"}, {"name": "Visibility"}, {"name": "Jobs"}, {"name": "Execute"}, {"name": "Status"}, {"name": "Dismiss"}, {"name": "Billing & Quoting"}, {"name": "Results"}, {"name": "Exceptions"}, {"name": "Logs"}, {"name": "Providers"}, {"name": "Provider Processes"}], "paths": {"/": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "FrontpageSchema", "properties": {"message": {"type": "string", "title": "Message", "default": "Weaver Information", "example": "Weaver Information"}, "configuration": {"type": "string", "title": "Configuration", "default": "default", "example": "default"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Param", "properties": {"name": {"type": "string", "title": "Name", "example": "api"}, "enabled": {"type": "boolean", "title": "Enabled", "example": true}, "url": {"type": "string", "title": "Url", "example": "https://weaver-host"}, "doc": {"type": "string", "title": "Doc", "example": "https://weaver-host/api"}}, "required": ["name", "enabled"]}}}, "required": ["message", "configuration", "parameters"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Frontpage of weaver.", "tags": ["API"]}}, "/api": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "text/html", "example": "text/html"}}, "schema": {"type": "object", "title": "SwaggerUISpecSchema", "description": "Swagger UI of weaver API."}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "summary": "weaver REST API swagger-ui schema documentation (this page).", "tags": ["API"]}}, "/json": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "SwaggerJSONSpecSchema", "description": "Swagger JSON of weaver API."}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "weaver REST API schema generation in JSON format.", "tags": ["API"]}}, "/versions": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "VersionsSchema", "properties": {"versions": {"type": "array", "title": "Versions", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name", "description": "Identification name of the current item.", "example": "weaver"}, "type": {"type": "string", "title": "Type", "description": "Identification type of the current item.", "example": "api"}, "version": {"type": "string", "title": "Version", "description": "Version of the current item.", "example": "0.1.0"}}, "required": ["name", "type", "version"]}}}, "required": ["versions"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Weaver versions information.", "tags": ["API"]}}, "/conformance": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ConformanceSchema", "properties": {"conformsTo": {"type": "array", "title": "Conformsto", "items": {"type": "string", "title": "Item", "description": "Conformance specification link.", "example": "http://www.opengis.net/spec/wfs-1/3.0/req/core"}}}, "required": ["conformsTo"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Weaver specification conformance information.", "tags": ["API"]}}, "/processes": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessCollection", "properties": {"processes": {"type": "array", "title": "Processes", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "version": {"type": "string", "title": "Version"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "processDescriptionURL": {"type": "string", "title": "Processdescriptionurl"}}, "required": ["id"]}}}, "required": ["processes"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during processes listing."}}, "produces": ["application/json"], "parameters": [{"name": "providers", "in": "query", "required": false, "description": "List local processes as well as all sub-processes of all registered providers. Applicable only for weaver in EMS mode, false otherwise.", "type": "boolean", "default": false, "example": true}, {"name": "detail", "in": "query", "required": false, "description": "Return summary details about each process, or simply their IDs.", "default": true, "type": "boolean", "example": true}], "summary": "\nList registered processes (GetCapabilities). Optionally list both local and provider processes.\n", "tags": ["Processes", "GetCapabilities"]}, "post": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "OkPostProcessDeployBodySchema", "properties": {"deploymentDone": {"type": "boolean", "title": "Deploymentdone", "description": "Indicates if the process was successfully deployed.", "default": false, "example": true}, "processSummary": {"type": "object", "title": "Processsummary", "description": "Deployed process summary if successful.", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "version": {"type": "string", "title": "Version"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "processDescriptionURL": {"type": "string", "title": "Processdescriptionurl"}}, "required": ["id"]}, "failureReason": {"type": "string", "title": "Failurereason", "description": "Description of deploy failure if applicable."}}, "required": ["deploymentDone"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process deployment."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Deploy", "in": "body", "required": true, "schema": {"type": "object", "title": "Deploy", "properties": {"processDescription": {"type": "object", "title": "Processdescription"}, "immediateDeployment": {"type": "boolean", "title": "Immediatedeployment", "default": true}, "executionUnit": {"type": "array", "title": "Executionunit", "items": {"type": "object", "title": "Item"}}, "deploymentProfileName": {"type": "string", "title": "Deploymentprofilename"}, "owsContext": {"type": "object", "title": "Owscontext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}}, "required": ["processDescription", "executionUnit"]}}], "summary": "\nRegister a local process.\n", "tags": ["Processes", "Deploy"]}}, "/processes/{process_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessOffering", "properties": {"process": {"type": "object", "title": "Process", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "executeEndpoint": {"type": "string", "title": "Executeendpoint"}}, "required": ["id"]}, "processVersion": {"type": "string", "title": "Processversion"}, "processEndpointWPS1": {"type": "string", "title": "Processendpointwps1"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}}, "required": ["process"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process information (DescribeProcess).\n", "tags": ["Processes", "DescribeProcess"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "OkDeleteProcessUndeployBodySchema", "properties": {"deploymentDone": {"type": "boolean", "title": "Deploymentdone", "description": "Indicates if the process was successfully undeployed.", "default": false, "example": true}, "identifier": {"type": "string", "title": "Identifier", "example": "workflow"}, "failureReason": {"type": "string", "title": "Failurereason", "description": "Description of undeploy failure if applicable."}}, "required": ["deploymentDone", "identifier"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process deletion."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nUnregister a local process.\n", "tags": ["Processes", "Deploy"]}}, "/processes/{process_id}/package": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process package description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process package definition.\n", "tags": ["Processes", "DescribeProcess"]}}, "/processes/{process_id}/payload": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process payload description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process payload definition.\n", "tags": ["Processes", "DescribeProcess"]}}, "/processes/{process_id}/visibility": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessVisibilityResponseBodySchema", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process visibility retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet the visibility of a registered local process.\n", "tags": ["Processes", "Visibility"]}, "put": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessVisibilityResponseBodySchema", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process visibility update."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Visibility", "in": "body", "required": true, "schema": {"type": "object", "title": "Visibility", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}], "summary": "\nSet the visibility of a registered local process.\n", "tags": ["Processes", "Visibility"]}}, "/processes/{process_id}/jobs": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Processes", "Jobs"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}}, "required": ["status", "location", "jobID"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process job submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Accept-Language", "in": "header", "required": false, "type": "string"}, {"name": "Execute", "in": "body", "required": true, "schema": {"type": "object", "title": "Execute", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}}], "summary": "\nExecute a local process.\n", "tags": ["Processes", "Execute", "Jobs"]}}, "/processes/{process_id}/jobs/{job_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Processes", "Jobs", "Status"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Processes", "Jobs", "Dismiss"]}}, "/processes/{process_id}/quotations": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "QuoteProcessParametersSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "QuoteProcessParametersSchema", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "mode": {"type": "string", "title": "mode", "default": "auto", "example": "async", "enum": ["sync", "async", "auto"]}, "response": {"type": "string", "title": "response", "default": "raw", "example": "raw", "enum": ["raw", "document"]}}}}], "summary": "\nRequest a quotation for a process.\n", "tags": ["Billing & Quoting", "Processes"]}, "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuotationListSchema", "properties": {"quotations": {"type": "array", "title": "Quotations", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["quotations"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet list of quotes IDs.\n", "tags": ["Billing & Quoting", "Processes"]}}, "/processes/{process_id}/quotations/{quote_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "quote_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet quote information.\n", "tags": ["Billing & Quoting", "Processes"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedQuotedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "bill": {"type": "string", "title": "Bill", "description": "ID of the created bill.", "example": "d88fda5c-52cc-440b-9309-f2cd20bcd6a2"}}, "required": ["status", "location", "jobID", "bill"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote job execution."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "MappingSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}], "summary": "\nExecute a quoted process.\n", "tags": ["Billing & Quoting", "Execute", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/result": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/exceptions": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/logs": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs", "Processes"]}}, "/providers": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ProvidersSchema", "items": {"type": "object", "title": "Providers Service", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "title", "abstract", "public"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during providers listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nLists registered providers.\n", "tags": ["Providers"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProviderSummarySchema", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "title", "abstract", "public"]}}, "400": {"description": "Parameter value is missing"}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process registration."}, "501": {"description": "Provider registration not supported using referenced storage."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "CreateProviderRequestBody", "in": "body", "required": true, "schema": {"type": "object", "title": "CreateProviderRequestBody", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "public"]}}], "summary": "\nAdd a provider.\n", "tags": ["Providers"]}}, "/providers/{provider_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}], "delete": {"responses": {"204": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider removal."}, "501": {"description": "Provider removal not supported using referenced storage."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRemove a provider.\n", "tags": ["Providers"]}, "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProviderCapabilitiesSchema", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "contact": {"type": "string", "title": "Contact"}, "type": {"type": "string", "title": "Type"}}, "required": ["id", "url", "title", "abstract", "contact", "type"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider capabilities request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a provider definition (GetCapabilities).\n", "tags": ["Providers"]}}, "/providers/{provider_id}/processes": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ProcessesSchema", "items": {"type": "object", "title": "Provider Processes Service", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "executeEndpoint": {"type": "string", "title": "Executeendpoint"}}, "required": ["id"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider processes listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve available provider processes (GetCapabilities).\n", "tags": ["Provider Processes", "Providers", "GetCapabilities"]}}, "/providers/{provider_id}/processes/{process_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessDescriptionBodySchema", "properties": {"process": {"type": "object", "title": "Process", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "properties": {"dataType": {"type": "string", "title": "Datatype"}, "defaultValue": {"type": "object", "title": "Defaultvalue"}, "id": {"type": "string", "title": "Id"}, "abstract": {"type": "string", "title": "Abstract"}, "title": {"type": "string", "title": "Title"}}, "required": ["dataType", "defaultValue", "id", "abstract", "title"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "properties": {"minOccurs": {"type": "integer", "title": "Minoccurs"}, "maxOccurs": {"type": "integer", "title": "Maxoccurs"}, "title": {"type": "string", "title": "Title"}, "dataType": {"type": "string", "title": "Datatype"}, "abstract": {"type": "string", "title": "Abstract"}, "id": {"type": "string", "title": "Id"}, "defaultValue": {"type": "array", "title": "Defaultvalue", "items": {"type": "object"}}, "supportedValues": {"type": "array", "title": "Supportedvalues", "items": {"type": "object"}}}, "required": ["minOccurs", "maxOccurs", "title", "dataType", "abstract", "id", "defaultValue", "supportedValues"]}}, "description": {"type": "string", "title": "Description"}, "id": {"type": "string", "title": "Id"}, "label": {"type": "string", "title": "Label"}}, "required": ["outputs", "inputs", "description", "id", "label"]}}, "required": ["process"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve a process description (DescribeProcess).\n", "tags": ["Provider Processes", "Providers", "DescribeProcess"]}}, "/jobs": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Jobs"]}}, "/providers/{provider_id}/processes/{process_id}/jobs": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Jobs", "Providers"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}}, "required": ["status", "location", "jobID"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process job submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma separated tags that can be used to filter jobs later", "type": "string", "default": null}, {"name": "Execute", "in": "body", "required": true, "schema": {"type": "object", "title": "Execute", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}}], "summary": "\nExecute a provider process.\n", "tags": ["Provider Processes", "Providers", "Execute", "Jobs"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Jobs", "Status", "Providers"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Jobs", "Dismiss", "Providers"]}}, "/jobs/{job_id}": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Jobs", "Status"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Jobs", "Dismiss"]}}, "/quotations": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuotationListSchema", "properties": {"quotations": {"type": "array", "title": "Quotations", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["quotations"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "id", "type": "string", "example": "process", "enum": ["id", "price", "process", "created"]}], "summary": "\nGet list of quotes IDs.\n", "tags": ["Billing & Quoting"]}}, "/quotations/{quote_id}": {"parameters": [{"name": "quote_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet quote information.\n", "tags": ["Billing & Quoting"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedQuotedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "bill": {"type": "string", "title": "Bill", "description": "ID of the created bill.", "example": "d88fda5c-52cc-440b-9309-f2cd20bcd6a2"}}, "required": ["status", "location", "jobID", "bill"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote job execution."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "MappingSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}], "summary": "\nExecute a quoted process.\n", "tags": ["Billing & Quoting", "Execute"]}}, "/bills": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "BillListSchema", "properties": {"bills": {"type": "array", "title": "Bills", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["bills"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during bill listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet list of bills IDs.\n", "tags": ["Billing & Quoting"]}}, "/bill/{bill_id}": {"parameters": [{"name": "bill_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "BillSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Bill ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the bill."}, "description": {"type": "string", "title": "Description"}, "price": {"type": "number", "title": "Price", "description": "Price associated to the bill."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the bill in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "quotationId": {"type": "string", "title": "Quotationid", "description": "Corresponding quote ID."}}, "required": ["id", "title", "price", "currency", "created", "userId"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during bill retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet bill information.\n", "tags": ["Billing & Quoting"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/result": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results", "Providers"]}}, "/jobs/{job_id}/result": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/exceptions": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions", "Providers"]}}, "/jobs/{job_id}/exceptions": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/logs": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs", "Providers"]}}, "/jobs/{job_id}/logs": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs"]}}}} \ No newline at end of file diff --git a/docs/source/conf.py b/docs/source/conf.py index 986bcd62b..946c120a9 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -16,37 +16,89 @@ # as they refer to valid setting names defined by sphinx # pylint: disable=C0103 +import json import os +import re import sys # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.insert(0, os.path.abspath("..")) -sys.path.insert(0, os.path.abspath("../..")) -sys.path.insert(0, os.path.abspath("../../..")) +DOC_SRC_ROOT = os.path.abspath(os.path.dirname(__file__)) +DOC_DIR_ROOT = os.path.abspath(os.path.dirname(DOC_SRC_ROOT)) +DOC_PRJ_ROOT = os.path.abspath(os.path.dirname(DOC_DIR_ROOT)) +sys.path.insert(0, os.path.abspath(DOC_SRC_ROOT)) +sys.path.insert(0, os.path.abspath(DOC_DIR_ROOT)) +sys.path.insert(0, os.path.abspath(DOC_PRJ_ROOT)) from weaver import __meta__ # isort:skip # noqa: E402 # pylint: disable=C0413 -# -- General configuration ------------------------------------------------ +# for api generation +from weaver.wps_restapi.api import get_swagger_json # isort:skip # noqa: E402 +from pyramid.config import Configurator # isort:skip # noqa: E402 + +# -- General configuration --------------------------------------------- # If your documentation needs a minimal Sphinx version, state it here. -needs_sphinx = "1.6" +# needs_sphinx = "1.0" # Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom -# ones. +# extensions coming with Sphinx (named "sphinx.ext.*") or your custom ones. +sys.path.append(os.path.abspath(os.path.join(DOC_DIR_ROOT, "_extensions"))) extensions = [ + "doc_redirect", + "sphinxcontrib.redoc", "sphinx.ext.autodoc", - "sphinx.ext.intersphinx", "sphinx.ext.todo", "sphinx.ext.viewcode", - "sphinx.ext.napoleon", + "sphinx.ext.intersphinx", + "autoapi.extension", "sphinx_autodoc_typehints", "pywps.ext_autodoc", - "autoapi.extension", + "sphinx_paramlinks", +] + +# note: see custom extension documentation +doc_redirect_ignores = [ + re.compile(r"weaver\..*"), # autoapi generated files + re.compile(r"index.*"), ] + +def doc_redirect_include(file_path): + return file_path.endswith(".rst") and not any(re.match(regex, file_path) for regex in doc_redirect_ignores) + + +doc_redirect_map = { + "docs/{}".format(file_name): file_name + for file_name in os.listdir(DOC_DIR_ROOT) + if doc_redirect_include(file_name) +} +doc_redirect_map.update({ + file_name: file_name + for file_name in os.listdir(DOC_PRJ_ROOT) + if doc_redirect_include(file_name) +}) + +# generate openapi +config = Configurator(settings={"weaver.wps": False, "weaver.wps_restapi": True}) +config.include("weaver") # need to include package to apply decorators and parse routes +api_spec_file = os.path.join(DOC_DIR_ROOT, "api.json") +api_spec_json = get_swagger_json(http_host="example", http_scheme="https") +with open(api_spec_file, "w") as f: + json.dump(api_spec_json, f) + +redoc = [{ + "name": __meta__.__title__, + "page": "api", # rendered under '{root}/api.html' + "spec": api_spec_file, + "embed": True, + "opts": { + "lazy-rendering": True, + "hide-hostname": True + } +}] + autoapi_type = "python" autoapi_dirs = ["../../weaver"] autoapi_file_pattern = "*.py" diff --git a/requirements-docs.txt b/requirements-docs.txt index 43e2fa074..bcd62e8e4 100644 --- a/requirements-docs.txt +++ b/requirements-docs.txt @@ -1,7 +1,13 @@ +# these are doc-only requirements +# we actually need to install all requirements during docs build because of OpenAPI generation +# (see 'docs/conf.py') +pycodestyle pycodestyle # required for pywps.ext_autodoc pywps -# FIXME: bug when using 1.2 (https://github.com/readthedocs/sphinx-autoapi/issues/186) -sphinx-autoapi<1.2 -sphinx>=1.6 +sphinx-autoapi>=1.3.0 +sphinx-paramlinks>=0.4.1 +sphinx>=2.4 +# adds redoc OpenAPI directly served on readthedocs +sphinxcontrib-redoc>=1.6.0 sphinx_autodoc_typehints[type_comments] diff --git a/weaver/wps_restapi/api.py b/weaver/wps_restapi/api.py index e7acc496a..c448af137 100644 --- a/weaver/wps_restapi/api.py +++ b/weaver/wps_restapi/api.py @@ -123,33 +123,50 @@ def api_conformance(request): # noqa: F811 return HTTPOk(json=conformance) -@sd.api_swagger_json_service.get(tags=[sd.TAG_API], renderer=OUTPUT_FORMAT_JSON, - schema=sd.SwaggerJSONEndpoint(), response_schemas=sd.get_api_swagger_json_responses) -def api_swagger_json(request, use_docstring_summary=True): - # type: (Request, bool) -> dict - """weaver REST API schema generation in JSON format.""" +def get_swagger_json(http_scheme="http", http_host="localhost", base_url=None, use_docstring_summary=True): + # type: (AnyStr, AnyStr, Optional[AnyStr], bool) -> dict + """Obtains the JSON schema of weaver API from request and response views schemas. + + :param http_scheme: Protocol scheme to use for building the API base if not provided by base URL parameter. + :param http_host: Hostname to use for building the API base if not provided by base URL parameter. + :param base_url: Explicit base URL to employ of as API base instead of HTTP scheme/host parameters. + :param use_docstring_summary: + Setting that controls if function docstring should be used to auto-generate the summary field of responses. + + .. seealso:: + - :mod:`weaver.wps_restapi.swagger_definitions` + """ CorniceSwagger.type_converter = CustomTypeConversionDispatcher swagger = CorniceSwagger(get_services()) # function docstrings are used to create the route's summary in Swagger-UI swagger.summary_docstrings = use_docstring_summary - swagger_base_spec = {"schemes": [request.scheme]} + swagger_base_spec = {"schemes": [http_scheme]} - # obtain 'server' host and api-base-path, which doesn't correspond necessarily to the app's host and path - # ex: 'server' adds '/weaver' with proxy redirect before API routes - weaver_server_url = get_weaver_url(request) - LOGGER.debug("Request app URL: [%s]", request.url) - LOGGER.debug("Weaver config URL: [%s]", weaver_server_url) - if weaver_server_url: - weaver_parsed_url = urlparse(weaver_server_url) + if base_url: + weaver_parsed_url = urlparse(base_url) swagger_base_spec["host"] = weaver_parsed_url.netloc swagger_base_path = weaver_parsed_url.path else: - swagger_base_spec["host"] = request.host + swagger_base_spec["host"] = http_host swagger_base_path = sd.api_frontpage_uri swagger.swagger = swagger_base_spec return swagger.generate(title=sd.API_TITLE, version=weaver_version, base_path=swagger_base_path) +@sd.api_swagger_json_service.get(tags=[sd.TAG_API], renderer=OUTPUT_FORMAT_JSON, + schema=sd.SwaggerJSONEndpoint(), response_schemas=sd.get_api_swagger_json_responses) +def api_swagger_json(request): # noqa: F811 + # type: (Request) -> dict + """weaver REST API schema generation in JSON format.""" + # obtain 'server' host and api-base-path, which doesn't correspond necessarily to the app's host and path + # ex: 'server' adds '/weaver' with proxy redirect before API routes + weaver_server_url = get_weaver_url(request) + LOGGER.debug("Request app URL: [%s]", request.url) + LOGGER.debug("Weaver config URL: [%s]", weaver_server_url) + # http_scheme=request.scheme, http_host=request.host + return get_swagger_json(base_url=weaver_server_url, use_docstring_summary=True) + + @sd.api_swagger_ui_service.get(tags=[sd.TAG_API], schema=sd.SwaggerUIEndpoint(), response_schemas=sd.get_api_swagger_ui_responses) def api_swagger_ui(request): From a1f8e58323f567b56f801f103438563856183230 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 14:08:49 -0400 Subject: [PATCH 02/11] adjust docs generation with extensions and openapi generation --- .readthedocs.yml | 2 +- CHANGES.rst | 2 +- docs/Makefile | 38 ++++++++++++++++++++++++-------------- docs/api.json | 1 - docs/{source => }/conf.py | 26 +++++++++++++++++--------- 5 files changed, 43 insertions(+), 26 deletions(-) delete mode 100644 docs/api.json rename docs/{source => }/conf.py (95%) diff --git a/.readthedocs.yml b/.readthedocs.yml index f1ca28b64..fd0492b54 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -1,7 +1,7 @@ # configuration to setup readthedocs version: 2 sphinx: - configuration: docs/source/conf.py + configuration: docs/conf.py formats: all python: version: 3.7 diff --git a/CHANGES.rst b/CHANGES.rst index 4cddfa2d9..bc4b4d7a6 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -8,7 +8,7 @@ Changes Changes: -------- -- No change. +- Generate Weaver OpenAPI specification for readthedocs publication. Fixes: ------ diff --git a/docs/Makefile b/docs/Makefile index 75a6c1c2f..c32f8e9d0 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -1,5 +1,8 @@ # Makefile for Sphinx documentation # +MAKEFILE_NAME := $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)) +-include Makefile.config # Include custom config if it is available +CUR_DIR := $(abspath $(lastword $(MAKEFILE_NAME))/..) # You can set these variables from the command line. SPHINXOPTS = @@ -7,22 +10,26 @@ SPHINXBUILD = sphinx-build PAPER = BUILDDIR = build -# User-friendly check for sphinx-build -ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) -$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/) -endif - # Internal variables. PAPEROPT_a4 = -D latex_paper_size=a4 PAPEROPT_letter = -D latex_paper_size=letter -ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source +ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source -c $(CUR_DIR) # the i18n builder cannot share the environment and doctrees with the others -I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source +I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source -c $(CUR_DIR) + +# User-friendly check for sphinx-build +ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) +$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD \ + environment variable to point to the full path of the '$(SPHINXBUILD)' executable. \ + Alternatively you can add the directory with the executable to your PATH. If you do not have Sphinx installed, grab \ + it from 'http://sphinx-doc.org/' \ +) +endif .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest coverage gettext help: - @echo "Please use \`make ' where is one of" + @echo "Please use 'make ' where is one of" @echo " html to make standalone HTML files" @echo " dirhtml to make HTML files named index.html in directories" @echo " singlehtml to make a single large HTML file" @@ -79,12 +86,14 @@ json: htmlhelp: $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp @echo - @echo "Build finished; now you can run HTML Help Workshop with the" ".hhp project file in $(BUILDDIR)/htmlhelp." + @echo "Build finished; now you can run HTML Help Workshop with the \ + .hhp project file in $(BUILDDIR)/htmlhelp." qthelp: $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp @echo - @echo "Build finished; now you can run "qcollectiongenerator" with the" ".qhcp project file in $(BUILDDIR)/qthelp, like this:" + @echo "Build finished; now you can run "qcollectiongenerator" with the \ + .qhcp project file in $(BUILDDIR)/qthelp, like this:" @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/weaver.qhcp" @echo "To view the help file:" @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/weaver.qhc" @@ -93,16 +102,17 @@ applehelp: $(SPHINXBUILD) -b applehelp $(ALLSPHINXOPTS) $(BUILDDIR)/applehelp @echo @echo "Build finished. The help book is in $(BUILDDIR)/applehelp." - @echo "N.B. You won't be able to view it unless you put it in" "~/Library/Documentation/Help or install it in your application" "bundle." + @echo "N.B. You won't be able to view it unless you put it in \ + ~/Library/Documentation/Help or install it in your application bundle." devhelp: $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp @echo @echo "Build finished." @echo "To view the help file:" - @echo "# mkdir -p $$HOME/.local/share/devhelp/weaver" - @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/weaver" - @echo "# devhelp" + @echo "\# mkdir -p $$HOME/.local/share/devhelp/weaver" + @echo "\# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/weaver" + @echo "\# devhelp" epub: $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub diff --git a/docs/api.json b/docs/api.json deleted file mode 100644 index e4636af0e..000000000 --- a/docs/api.json +++ /dev/null @@ -1 +0,0 @@ -{"schemes": ["https"], "host": "example", "swagger": "2.0", "info": {"title": "Weaver REST API", "version": "1.10.1"}, "basePath": "/", "tags": [{"name": "API"}, {"name": "Processes"}, {"name": "GetCapabilities"}, {"name": "Deploy"}, {"name": "DescribeProcess"}, {"name": "Visibility"}, {"name": "Jobs"}, {"name": "Execute"}, {"name": "Status"}, {"name": "Dismiss"}, {"name": "Billing & Quoting"}, {"name": "Results"}, {"name": "Exceptions"}, {"name": "Logs"}, {"name": "Providers"}, {"name": "Provider Processes"}], "paths": {"/": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "FrontpageSchema", "properties": {"message": {"type": "string", "title": "Message", "default": "Weaver Information", "example": "Weaver Information"}, "configuration": {"type": "string", "title": "Configuration", "default": "default", "example": "default"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Param", "properties": {"name": {"type": "string", "title": "Name", "example": "api"}, "enabled": {"type": "boolean", "title": "Enabled", "example": true}, "url": {"type": "string", "title": "Url", "example": "https://weaver-host"}, "doc": {"type": "string", "title": "Doc", "example": "https://weaver-host/api"}}, "required": ["name", "enabled"]}}}, "required": ["message", "configuration", "parameters"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Frontpage of weaver.", "tags": ["API"]}}, "/api": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "text/html", "example": "text/html"}}, "schema": {"type": "object", "title": "SwaggerUISpecSchema", "description": "Swagger UI of weaver API."}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "summary": "weaver REST API swagger-ui schema documentation (this page).", "tags": ["API"]}}, "/json": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "SwaggerJSONSpecSchema", "description": "Swagger JSON of weaver API."}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "weaver REST API schema generation in JSON format.", "tags": ["API"]}}, "/versions": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "VersionsSchema", "properties": {"versions": {"type": "array", "title": "Versions", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name", "description": "Identification name of the current item.", "example": "weaver"}, "type": {"type": "string", "title": "Type", "description": "Identification type of the current item.", "example": "api"}, "version": {"type": "string", "title": "Version", "description": "Version of the current item.", "example": "0.1.0"}}, "required": ["name", "type", "version"]}}}, "required": ["versions"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Weaver versions information.", "tags": ["API"]}}, "/conformance": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ConformanceSchema", "properties": {"conformsTo": {"type": "array", "title": "Conformsto", "items": {"type": "string", "title": "Item", "description": "Conformance specification link.", "example": "http://www.opengis.net/spec/wfs-1/3.0/req/core"}}}, "required": ["conformsTo"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "Weaver specification conformance information.", "tags": ["API"]}}, "/processes": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessCollection", "properties": {"processes": {"type": "array", "title": "Processes", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "version": {"type": "string", "title": "Version"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "processDescriptionURL": {"type": "string", "title": "Processdescriptionurl"}}, "required": ["id"]}}}, "required": ["processes"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during processes listing."}}, "produces": ["application/json"], "parameters": [{"name": "providers", "in": "query", "required": false, "description": "List local processes as well as all sub-processes of all registered providers. Applicable only for weaver in EMS mode, false otherwise.", "type": "boolean", "default": false, "example": true}, {"name": "detail", "in": "query", "required": false, "description": "Return summary details about each process, or simply their IDs.", "default": true, "type": "boolean", "example": true}], "summary": "\nList registered processes (GetCapabilities). Optionally list both local and provider processes.\n", "tags": ["Processes", "GetCapabilities"]}, "post": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "OkPostProcessDeployBodySchema", "properties": {"deploymentDone": {"type": "boolean", "title": "Deploymentdone", "description": "Indicates if the process was successfully deployed.", "default": false, "example": true}, "processSummary": {"type": "object", "title": "Processsummary", "description": "Deployed process summary if successful.", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "version": {"type": "string", "title": "Version"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "processDescriptionURL": {"type": "string", "title": "Processdescriptionurl"}}, "required": ["id"]}, "failureReason": {"type": "string", "title": "Failurereason", "description": "Description of deploy failure if applicable."}}, "required": ["deploymentDone"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process deployment."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Deploy", "in": "body", "required": true, "schema": {"type": "object", "title": "Deploy", "properties": {"processDescription": {"type": "object", "title": "Processdescription"}, "immediateDeployment": {"type": "boolean", "title": "Immediatedeployment", "default": true}, "executionUnit": {"type": "array", "title": "Executionunit", "items": {"type": "object", "title": "Item"}}, "deploymentProfileName": {"type": "string", "title": "Deploymentprofilename"}, "owsContext": {"type": "object", "title": "Owscontext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}}, "required": ["processDescription", "executionUnit"]}}], "summary": "\nRegister a local process.\n", "tags": ["Processes", "Deploy"]}}, "/processes/{process_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessOffering", "properties": {"process": {"type": "object", "title": "Process", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "executeEndpoint": {"type": "string", "title": "Executeendpoint"}}, "required": ["id"]}, "processVersion": {"type": "string", "title": "Processversion"}, "processEndpointWPS1": {"type": "string", "title": "Processendpointwps1"}, "jobControlOptions": {"type": "array", "title": "Jobcontroloptions", "items": {"type": "string", "title": "jobControlOptions", "default": "async-execute", "example": "async-execute", "enum": ["async-execute", "sync-execute"]}}, "outputTransmission": {"type": "array", "title": "Outputtransmission", "items": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}}, "required": ["process"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process information (DescribeProcess).\n", "tags": ["Processes", "DescribeProcess"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "OkDeleteProcessUndeployBodySchema", "properties": {"deploymentDone": {"type": "boolean", "title": "Deploymentdone", "description": "Indicates if the process was successfully undeployed.", "default": false, "example": true}, "identifier": {"type": "string", "title": "Identifier", "example": "workflow"}, "failureReason": {"type": "string", "title": "Failurereason", "description": "Description of undeploy failure if applicable."}}, "required": ["deploymentDone", "identifier"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process deletion."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nUnregister a local process.\n", "tags": ["Processes", "Deploy"]}}, "/processes/{process_id}/package": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process package description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process package definition.\n", "tags": ["Processes", "DescribeProcess"]}}, "/processes/{process_id}/payload": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process payload description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a registered local process payload definition.\n", "tags": ["Processes", "DescribeProcess"]}}, "/processes/{process_id}/visibility": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessVisibilityResponseBodySchema", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process visibility retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet the visibility of a registered local process.\n", "tags": ["Processes", "Visibility"]}, "put": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessVisibilityResponseBodySchema", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process visibility update."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Visibility", "in": "body", "required": true, "schema": {"type": "object", "title": "Visibility", "properties": {"value": {"type": "string", "title": "Value", "example": "public", "enum": ["public", "private"]}}, "required": ["value"]}}], "summary": "\nSet the visibility of a registered local process.\n", "tags": ["Processes", "Visibility"]}}, "/processes/{process_id}/jobs": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Processes", "Jobs"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}}, "required": ["status", "location", "jobID"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process job submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "Accept-Language", "in": "header", "required": false, "type": "string"}, {"name": "Execute", "in": "body", "required": true, "schema": {"type": "object", "title": "Execute", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}}], "summary": "\nExecute a local process.\n", "tags": ["Processes", "Execute", "Jobs"]}}, "/processes/{process_id}/jobs/{job_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Processes", "Jobs", "Status"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Processes", "Jobs", "Dismiss"]}}, "/processes/{process_id}/quotations": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}], "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "QuoteProcessParametersSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "QuoteProcessParametersSchema", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "mode": {"type": "string", "title": "mode", "default": "auto", "example": "async", "enum": ["sync", "async", "auto"]}, "response": {"type": "string", "title": "response", "default": "raw", "example": "raw", "enum": ["raw", "document"]}}}}], "summary": "\nRequest a quotation for a process.\n", "tags": ["Billing & Quoting", "Processes"]}, "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuotationListSchema", "properties": {"quotations": {"type": "array", "title": "Quotations", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["quotations"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet list of quotes IDs.\n", "tags": ["Billing & Quoting", "Processes"]}}, "/processes/{process_id}/quotations/{quote_id}": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "quote_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet quote information.\n", "tags": ["Billing & Quoting", "Processes"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedQuotedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "bill": {"type": "string", "title": "Bill", "description": "ID of the created bill.", "example": "d88fda5c-52cc-440b-9309-f2cd20bcd6a2"}}, "required": ["status", "location", "jobID", "bill"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote job execution."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "MappingSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}], "summary": "\nExecute a quoted process.\n", "tags": ["Billing & Quoting", "Execute", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/result": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/exceptions": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions", "Processes"]}}, "/processes/{process_id}/jobs/{job_id}/logs": {"parameters": [{"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs", "Processes"]}}, "/providers": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ProvidersSchema", "items": {"type": "object", "title": "Providers Service", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "title", "abstract", "public"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during providers listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nLists registered providers.\n", "tags": ["Providers"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProviderSummarySchema", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "title", "abstract", "public"]}}, "400": {"description": "Parameter value is missing"}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process registration."}, "501": {"description": "Provider registration not supported using referenced storage."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "CreateProviderRequestBody", "in": "body", "required": true, "schema": {"type": "object", "title": "CreateProviderRequestBody", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "public": {"type": "boolean", "title": "Public"}}, "required": ["id", "url", "public"]}}], "summary": "\nAdd a provider.\n", "tags": ["Providers"]}}, "/providers/{provider_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}], "delete": {"responses": {"204": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider removal."}, "501": {"description": "Provider removal not supported using referenced storage."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRemove a provider.\n", "tags": ["Providers"]}, "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProviderCapabilitiesSchema", "properties": {"id": {"type": "string", "title": "Id"}, "url": {"type": "string", "title": "Url"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "contact": {"type": "string", "title": "Contact"}, "type": {"type": "string", "title": "Type"}}, "required": ["id", "url", "title", "abstract", "contact", "type"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider capabilities request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet a provider definition (GetCapabilities).\n", "tags": ["Providers"]}}, "/providers/{provider_id}/processes": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ProcessesSchema", "items": {"type": "object", "title": "Provider Processes Service", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Input"}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}, "title": {"type": "string", "title": "Title"}, "abstract": {"type": "string", "title": "Abstract"}, "keywords": {"type": "array", "title": "Keywords", "items": {"type": "string", "title": "Keyword"}}, "owsContext": {"type": "object", "title": "owsContext", "properties": {"offering": {"type": "object", "title": "offering", "properties": {"code": {"type": "string", "title": "Code", "description": "Descriptor of represented information in 'content'."}, "content": {"type": "object", "title": "content", "properties": {"href": {"type": "string", "title": "href", "description": "URL to CWL file.", "example": "http://some.host/applications/cwl/multisensor_ndvi.cwl"}}, "required": ["href"]}}}}, "required": ["offering"]}, "metadata": {"type": "array", "title": "Metadata", "items": {"type": "object", "title": "Item"}}, "additionalParameters": {"type": "array", "title": "additionalParameters", "items": {"type": "object", "title": "Additionalparameter", "properties": {"role": {"type": "string", "title": "Role"}, "parameters": {"type": "array", "title": "Parameters", "items": {"type": "object", "title": "Item", "properties": {"name": {"type": "string", "title": "Name"}, "values": {"type": "array", "title": "Values", "items": {"type": "string", "title": "Values"}}}, "required": ["name", "values"]}}}}}, "links": {"type": "array", "title": "links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["id"]}}, "executeEndpoint": {"type": "string", "title": "Executeendpoint"}}, "required": ["id"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider processes listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve available provider processes (GetCapabilities).\n", "tags": ["Provider Processes", "Providers", "GetCapabilities"]}}, "/providers/{provider_id}/processes/{process_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ProcessDescriptionBodySchema", "properties": {"process": {"type": "object", "title": "Process", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "properties": {"dataType": {"type": "string", "title": "Datatype"}, "defaultValue": {"type": "object", "title": "Defaultvalue"}, "id": {"type": "string", "title": "Id"}, "abstract": {"type": "string", "title": "Abstract"}, "title": {"type": "string", "title": "Title"}}, "required": ["dataType", "defaultValue", "id", "abstract", "title"]}}, "inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "properties": {"minOccurs": {"type": "integer", "title": "Minoccurs"}, "maxOccurs": {"type": "integer", "title": "Maxoccurs"}, "title": {"type": "string", "title": "Title"}, "dataType": {"type": "string", "title": "Datatype"}, "abstract": {"type": "string", "title": "Abstract"}, "id": {"type": "string", "title": "Id"}, "defaultValue": {"type": "array", "title": "Defaultvalue", "items": {"type": "object"}}, "supportedValues": {"type": "array", "title": "Supportedvalues", "items": {"type": "object"}}}, "required": ["minOccurs", "maxOccurs", "title", "dataType", "abstract", "id", "defaultValue", "supportedValues"]}}, "description": {"type": "string", "title": "Description"}, "id": {"type": "string", "title": "Id"}, "label": {"type": "string", "title": "Label"}}, "required": ["outputs", "inputs", "description", "id", "label"]}}, "required": ["process"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve a process description (DescribeProcess).\n", "tags": ["Provider Processes", "Providers", "DescribeProcess"]}}, "/jobs": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Jobs"]}}, "/providers/{provider_id}/processes/{process_id}/jobs": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "GetQueriedJobsSchema", "properties": {"total": {"type": "integer", "title": "Total", "description": "Total number of matched jobs regardless of grouping or paging result."}}, "required": ["total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during jobs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "detail", "in": "query", "required": false, "description": "Provide job details instead of IDs.", "type": "boolean", "default": false, "example": true}, {"name": "groups", "in": "query", "required": false, "description": "Comma-separated list of grouping fields with which to list jobs.", "type": "string", "default": false, "example": "process,service"}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "status", "in": "query", "required": false, "type": "string", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "provider", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "created", "type": "string", "example": "created", "enum": ["finished", "service", "status", "user", "created", "process"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma-separated values of tags assigned to jobs", "type": "string", "default": null}], "summary": "\nRetrieve the list of jobs which can be filtered, sorted, paged and categorized using query parameters.\n", "tags": ["Jobs", "Providers"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}}, "required": ["status", "location", "jobID"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during process job submission."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "tags", "in": "query", "required": false, "description": "Comma separated tags that can be used to filter jobs later", "type": "string", "default": null}, {"name": "Execute", "in": "body", "required": true, "schema": {"type": "object", "title": "Execute", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}}], "summary": "\nExecute a provider process.\n", "tags": ["Provider Processes", "Providers", "Execute", "Jobs"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Jobs", "Status", "Providers"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Jobs", "Dismiss", "Providers"]}}, "/jobs/{job_id}": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "JobStatusInfo", "properties": {"jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "message": {"type": "string", "title": "Message"}, "logs": {"type": "string", "title": "Logs"}, "result": {"type": "string", "title": "Result"}, "exceptions": {"type": "string", "title": "Exceptions"}, "expirationDate": {"type": "string", "title": "Expirationdate", "format": "date-time"}, "estimatedCompletion": {"type": "string", "title": "Estimatedcompletion", "format": "date-time"}, "duration": {"type": "string", "title": "Duration", "description": "Duration of the process execution."}, "nextPoll": {"type": "string", "title": "Nextpoll", "format": "date-time"}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0, "maximum": 100, "minimum": 0}}, "required": ["jobID", "status", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during provider process description."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the status of a job.\n", "tags": ["Jobs", "Status"]}, "delete": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "DismissedJobSchema", "properties": {"status": {"type": "string", "title": "Status", "default": null, "example": "accepted", "enum": ["failed", "succeeded", "accepted", "running"]}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "message": {"type": "string", "title": "Message", "example": "Job dismissed."}, "percentCompleted": {"type": "integer", "title": "Percentcompleted", "example": 0}}, "required": ["status", "jobID", "message", "percentCompleted"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job dismiss request."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nDismiss a job.\n\nNote: Will only stop tracking this particular process (WPS 1.0 doesn't allow to stop a process)\n", "tags": ["Jobs", "Dismiss"]}}, "/quotations": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuotationListSchema", "properties": {"quotations": {"type": "array", "title": "Quotations", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["quotations"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "page", "in": "query", "required": false, "type": "integer", "default": 0}, {"name": "limit", "in": "query", "required": false, "default": 10, "type": "integer"}, {"name": "process", "in": "query", "required": false, "type": "string", "default": null}, {"name": "sort", "in": "query", "required": false, "default": "id", "type": "string", "example": "process", "enum": ["id", "price", "process", "created"]}], "summary": "\nGet list of quotes IDs.\n", "tags": ["Billing & Quoting"]}}, "/quotations/{quote_id}": {"parameters": [{"name": "quote_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "QuoteSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "process": {"type": "string", "title": "Process", "description": "Corresponding process ID."}, "steps": {"type": "array", "title": "Steps", "description": "Child processes and prices.", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "processId": {"type": "string", "title": "Processid", "description": "Corresponding process ID."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}, "processParameters": {"type": "object", "title": "Processparameters", "properties": {"inputs": {"type": "array", "title": "Inputs", "items": {"type": "object", "title": "Item", "properties": {"id": {"type": "string", "title": "Id"}}, "required": ["id"]}}, "outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}, "transmissionMode": {"type": "string", "title": "transmissionMode", "default": "reference", "example": "reference", "enum": ["reference", "value"]}}, "required": ["id"]}}, "mode": {"type": "string", "title": "Mode", "enum": ["sync", "async", "auto"]}, "notification_email": {"type": "string", "title": "Notification Email", "description": "Optionally send a notification email when the job is done."}, "response": {"type": "string", "title": "Response", "enum": ["raw", "document"]}}, "required": ["outputs", "mode", "response"]}, "alternativeQuotations": {"type": "array", "title": "Alternativequotations", "items": {"type": "object", "title": "Step", "description": "Quote of a workflow step process.", "properties": {"id": {"type": "string", "title": "Id", "description": "Quote ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the quotation."}, "description": {"type": "string", "title": "Description", "description": "Description of the quotation."}, "price": {"type": "number", "title": "Price", "description": "Process execution price."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "expire": {"type": "string", "title": "Expire", "description": "Expiration date and time of the quote in ISO-8601 format.", "format": "date-time"}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the quote in ISO-8601 format.", "format": "date-time"}, "details": {"type": "string", "title": "Details", "description": "Details of the quotation."}, "estimatedTime": {"type": "string", "title": "Estimatedtime", "description": "Estimated duration of the process execution."}}, "required": ["id", "price", "currency", "expire", "created"]}}}, "required": ["id", "processId", "price", "currency", "expire", "created", "userId", "processParameters"]}}, "total": {"type": "number", "title": "Total", "description": "Total of the quote including step processes."}}, "required": ["id", "process", "steps", "total"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet quote information.\n", "tags": ["Billing & Quoting"]}, "post": {"responses": {"201": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "CreatedQuotedJobStatusSchema", "properties": {"status": {"type": "string", "title": "Status", "example": "accepted"}, "location": {"type": "string", "title": "Location", "example": "http://{host}/weaver/processes/{my-process-id}/jobs/{my-job-id}"}, "jobID": {"type": "string", "title": "Jobid", "description": "ID of the created job.", "example": "a9d14bf4-84e0-449a-bac8-16e598efe807"}, "bill": {"type": "string", "title": "Bill", "description": "ID of the created bill.", "example": "d88fda5c-52cc-440b-9309-f2cd20bcd6a2"}}, "required": ["status", "location", "jobID", "bill"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during quote job execution."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}, {"name": "MappingSchema", "in": "body", "required": true, "schema": {"type": "object", "title": "MappingSchema", "default": {}}}], "summary": "\nExecute a quoted process.\n", "tags": ["Billing & Quoting", "Execute"]}}, "/bills": {"get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "BillListSchema", "properties": {"bills": {"type": "array", "title": "Bills", "items": {"type": "string", "title": "Item", "description": "Bill ID."}}}, "required": ["bills"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during bill listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet list of bills IDs.\n", "tags": ["Billing & Quoting"]}}, "/bill/{bill_id}": {"parameters": [{"name": "bill_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "BillSchema", "properties": {"id": {"type": "string", "title": "Id", "description": "Bill ID."}, "title": {"type": "string", "title": "Title", "description": "Name of the bill."}, "description": {"type": "string", "title": "Description"}, "price": {"type": "number", "title": "Price", "description": "Price associated to the bill."}, "currency": {"type": "string", "title": "Currency", "description": "Currency code in ISO-4217 format."}, "created": {"type": "string", "title": "Created", "description": "Creation date and time of the bill in ISO-8601 format.", "format": "date-time"}, "userId": {"type": "string", "title": "Userid", "description": "User id that requested the quote."}, "quotationId": {"type": "string", "title": "Quotationid", "description": "Corresponding quote ID."}}, "required": ["id", "title", "price", "currency", "created", "userId"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during bill retrieval."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nGet bill information.\n", "tags": ["Billing & Quoting"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/result": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results", "Providers"]}}, "/jobs/{job_id}/result": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "Result", "properties": {"outputs": {"type": "array", "title": "Outputs", "items": {"type": "object", "title": "Output", "properties": {"id": {"type": "string", "title": "Id"}, "format": {"type": "object", "title": "Format", "properties": {"mimeType": {"type": "string", "title": "Mimetype", "default": "text/plain"}, "schema": {"type": "string", "title": "Schema"}, "encoding": {"type": "string", "title": "Encoding"}}, "required": ["mimeType"]}}, "required": ["id"]}}, "links": {"type": "array", "title": "Links", "items": {"type": "object", "title": "Item", "properties": {"href": {"type": "string", "title": "Href", "description": "Reference URL."}, "rel": {"type": "string", "title": "Rel", "description": "Relationship of the contained link respective to the current element."}, "type": {"type": "string", "title": "Type"}, "hreflang": {"type": "string", "title": "Hreflang"}, "title": {"type": "string", "title": "Title"}}, "required": ["href", "rel"]}}}, "required": ["outputs"]}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job results listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the results of a job.\n", "tags": ["Jobs", "Results"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/exceptions": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions", "Providers"]}}, "/jobs/{job_id}/exceptions": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "array", "title": "ExceptionsOutputSchema", "items": {"type": "object", "title": "Exceptions", "properties": {"Code": {"type": "string", "title": "Code"}, "Locator": {"type": "string", "title": "Locator"}, "Text": {"type": "array", "title": "Text", "items": {"type": "string", "title": "Text"}}}, "required": ["Code", "Locator", "Text"]}}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job exceptions listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the exceptions of a job.\n", "tags": ["Jobs", "Exceptions"]}}, "/providers/{provider_id}/processes/{process_id}/jobs/{job_id}/logs": {"parameters": [{"name": "provider_id", "in": "path", "required": true, "type": "string"}, {"name": "process_id", "in": "path", "required": true, "type": "string"}, {"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs", "Providers"]}}, "/jobs/{job_id}/logs": {"parameters": [{"name": "job_id", "in": "path", "required": true, "type": "string"}], "get": {"responses": {"200": {"description": "success", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "LogsOutputSchema"}}, "401": {"description": "unauthorized", "headers": {"Content-Type": {"type": "string", "default": "application/json", "example": "application/json"}}, "schema": {"type": "object", "title": "ErrorJsonResponseBodySchema", "properties": {"code": {"type": "string", "title": "Code", "example": "NoApplicableCode"}, "description": {"type": "string", "title": "Description", "example": "Not authorized to access this resource."}}, "required": ["code", "description"]}}, "500": {"description": "Unhandled error occurred during job logs listing."}}, "produces": ["application/json"], "parameters": [{"name": "Accept", "in": "header", "required": false, "default": "application/json", "type": "string", "enum": ["application/json", "application/xml", "text/html"]}], "summary": "\nRetrieve the logs of a job.\n", "tags": ["Jobs", "Logs"]}}}} \ No newline at end of file diff --git a/docs/source/conf.py b/docs/conf.py similarity index 95% rename from docs/source/conf.py rename to docs/conf.py index 946c120a9..96d3e0cd8 100644 --- a/docs/source/conf.py +++ b/docs/conf.py @@ -24,9 +24,11 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -DOC_SRC_ROOT = os.path.abspath(os.path.dirname(__file__)) -DOC_DIR_ROOT = os.path.abspath(os.path.dirname(DOC_SRC_ROOT)) +DOC_DIR_ROOT = os.path.abspath(os.path.dirname(__file__)) DOC_PRJ_ROOT = os.path.abspath(os.path.dirname(DOC_DIR_ROOT)) +DOC_SRC_ROOT = os.path.join(DOC_DIR_ROOT, "source") +DOC_BLD_ROOT = os.path.join(DOC_DIR_ROOT, "build") +DOC_PKG_ROOT = os.path.join(DOC_PRJ_ROOT, "weaver") sys.path.insert(0, os.path.abspath(DOC_SRC_ROOT)) sys.path.insert(0, os.path.abspath(DOC_DIR_ROOT)) sys.path.insert(0, os.path.abspath(DOC_PRJ_ROOT)) @@ -40,11 +42,11 @@ # -- General configuration --------------------------------------------- # If your documentation needs a minimal Sphinx version, state it here. -# needs_sphinx = "1.0" +needs_sphinx = "2.4" # see requirements-docs.txt # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named "sphinx.ext.*") or your custom ones. -sys.path.append(os.path.abspath(os.path.join(DOC_DIR_ROOT, "_extensions"))) +sys.path.append(os.path.join(DOC_DIR_ROOT, "_extensions")) extensions = [ "doc_redirect", "sphinxcontrib.redoc", @@ -83,8 +85,10 @@ def doc_redirect_include(file_path): # generate openapi config = Configurator(settings={"weaver.wps": False, "weaver.wps_restapi": True}) config.include("weaver") # need to include package to apply decorators and parse routes -api_spec_file = os.path.join(DOC_DIR_ROOT, "api.json") +api_spec_file = os.path.join(DOC_BLD_ROOT, "api.json") api_spec_json = get_swagger_json(http_host="example", http_scheme="https") +if not os.path.isdir(DOC_BLD_ROOT): + os.makedirs(DOC_BLD_ROOT) with open(api_spec_file, "w") as f: json.dump(api_spec_json, f) @@ -100,7 +104,7 @@ def doc_redirect_include(file_path): }] autoapi_type = "python" -autoapi_dirs = ["../../weaver"] +autoapi_dirs = [DOC_PKG_ROOT] autoapi_file_pattern = "*.py" autoapi_options = ["members", "undoc-members", "private-members"] autoapi_python_class_content = "both" # class|both|init @@ -188,7 +192,8 @@ def doc_redirect_include(file_path): # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = "alabaster" +# html_theme = "alabaster" +html_theme = "nature" # otherwise, readthedocs.org uses their theme by default, so no need to specify it @@ -220,7 +225,7 @@ def doc_redirect_include(file_path): # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = [ - # "_static" + "_static" ] # Add any extra paths that contain custom files (such as robots.txt or @@ -237,7 +242,10 @@ def doc_redirect_include(file_path): # html_use_smartypants = True # Custom sidebar templates, maps document names to template names. -# html_sidebars = {} +html_sidebars = { + # add full TOC of the doc + "**": ["globaltoc.html", "relations.html", "sourcelink.html", "searchbox.html"] +} # Additional templates that should be rendered to pages, maps page names to # template names. From 6958ece28c189adc5ec1d00c114cc40f36dd824f Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 15:04:40 -0400 Subject: [PATCH 03/11] add sections for docs (#61) --- .codacy.yml | 2 +- .readthedocs.yml | 2 +- CHANGES.rst | 1 + README.rst | 12 ++++--- docs/Makefile | 7 ++-- docs/{ => source}/conf.py | 0 docs/source/configuration.rst | 8 +++++ docs/source/index.rst | 2 ++ docs/source/package.rst | 53 ++++++++++++++++++++++++++++ docs/source/processes.rst | 66 +++++++++++++++++++++++++++++++++++ docs/source/tutorial.rst | 43 +++++++++++++---------- requirements-docs.txt | 2 +- 12 files changed, 167 insertions(+), 31 deletions(-) rename docs/{ => source}/conf.py (100%) create mode 100644 docs/source/package.rst create mode 100644 docs/source/processes.rst diff --git a/.codacy.yml b/.codacy.yml index a772a1bf1..ae678bab3 100644 --- a/.codacy.yml +++ b/.codacy.yml @@ -1,4 +1,4 @@ --- exclude_paths: - 'tests/**' - - 'docs/conf.py' + - 'docs/source/conf.py' diff --git a/.readthedocs.yml b/.readthedocs.yml index fd0492b54..f1ca28b64 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -1,7 +1,7 @@ # configuration to setup readthedocs version: 2 sphinx: - configuration: docs/conf.py + configuration: docs/source/conf.py formats: all python: version: 3.7 diff --git a/CHANGES.rst b/CHANGES.rst index bc4b4d7a6..3cdd792f8 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -9,6 +9,7 @@ Changes Changes: -------- - Generate Weaver OpenAPI specification for readthedocs publication. +- Add some sections for documentation (`#61 `_). Fixes: ------ diff --git a/README.rst b/README.rst index b2e417f90..e453fae4e 100644 --- a/README.rst +++ b/README.rst @@ -97,7 +97,7 @@ For more details, see `Configuration`_ and `Documentation`_ sections. Links ---------------- -Docker image repositories: +Docker image repositories: - CRIM registry: `ogc/weaver `_ - OGC processes: `ogc-public `_ @@ -140,13 +140,15 @@ For more configuration details, please refer to Documentation_. Documentation ---------------- -The REST API documentation is auto-generated and served under ``{WEAVER_URL}/api/`` using -Swagger-UI with tag ``latest``. +The REST API documentation is auto-generated and served under any running `Weaver` application on route +``{WEAVER_URL}/api/``. This documentation will correspond to the version of the executed `Weaver` application. +For the latest documentation, you can refer to the `OpenAPI Specification `_ served directly on `readthedocs`_. -More ample details about installation, configuration and usage are provided on `readthedocs`_. -These are generated from corresponding information provided in `docs`_. +More ample details about installation, configuration and usage are also provided on `readthedocs`_. +These are generated from corresponding information provided in `docs`_ source directory. .. _readthedocs: https://pavics-weaver.readthedocs.io +.. _rtd_oas: https://pavics-weaver.readthedocs.io/en/latest/api.html .. _docs: ./docs ---------------- diff --git a/docs/Makefile b/docs/Makefile index c32f8e9d0..6ec261442 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -1,8 +1,5 @@ # Makefile for Sphinx documentation # -MAKEFILE_NAME := $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)) --include Makefile.config # Include custom config if it is available -CUR_DIR := $(abspath $(lastword $(MAKEFILE_NAME))/..) # You can set these variables from the command line. SPHINXOPTS = @@ -13,9 +10,9 @@ BUILDDIR = build # Internal variables. PAPEROPT_a4 = -D latex_paper_size=a4 PAPEROPT_letter = -D latex_paper_size=letter -ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source -c $(CUR_DIR) +ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source # the i18n builder cannot share the environment and doctrees with the others -I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source -c $(CUR_DIR) +I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source # User-friendly check for sphinx-build ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) diff --git a/docs/conf.py b/docs/source/conf.py similarity index 100% rename from docs/conf.py rename to docs/source/conf.py diff --git a/docs/source/configuration.rst b/docs/source/configuration.rst index e7bd58e97..b21c56904 100644 --- a/docs/source/configuration.rst +++ b/docs/source/configuration.rst @@ -37,6 +37,13 @@ Configuration of WPS Processes `wps_processes.yml.example`_ +Configuration of Request Options +======================================= + +.. todo:: complete docs + + +`request_options.yml.example`_ Starting the Application ======================================= @@ -53,5 +60,6 @@ Starting the Application .. _weaver.ini.example: ../../../config/weaver.ini.example .. _data_sources.json.example: ../../../config/data_sources.json.example .. _wps_processes.yml.example: ../../../config/wps_processes.yml.example +.. _request_options.yml.example: ../../../config/request_options.yml.example .. _Dockerfile-manager: ../../../docker/Dockerfile-manager .. _Dockerfile-worker: ../../../docker/Dockerfile-worker diff --git a/docs/source/index.rst b/docs/source/index.rst index 9781cc40a..fd877ff58 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -7,5 +7,7 @@ configuration running tutorial + processes + package changes appendix diff --git a/docs/source/package.rst b/docs/source/package.rst new file mode 100644 index 000000000..7a739a6ad --- /dev/null +++ b/docs/source/package.rst @@ -0,0 +1,53 @@ +.. package + +************************* +Application Package (CWL) +************************* + +.. todo:: demo docs + +Based on `Common Workflow Language `_ (CWL) `specification `_. + + + +.. _CWL: https://www.commonwl.org/ +.. _cwl_spec: https://www.commonwl.org/#Specification + + +Typical CWL Package Definition +=========================================== + +.. todo:: CommandLineTool + +Correspondance between CWL and WPS fields +=========================================== + +.. todo:: demo docs + + +Correspondance between CWL and WPS fields +=========================================== + +Input / Outputs +----------------------- + +.. todo:: mapping with 'id' +.. todo:: CWL Lit. <-> WPS Literal +.. todo:: CWL File <-> WPS Complex + +File Format +----------------------- + +.. todo:: demo docs + +Allowed Values +----------------------- + + +.. todo:: cwl enum vs allowed/supported WPS + + +Multiple Values +----------------------- + +.. todo:: minOccurs/maxOccurs + array + WPS repeats IDs vs CWL as list diff --git a/docs/source/processes.rst b/docs/source/processes.rst new file mode 100644 index 000000000..3d4ce2f08 --- /dev/null +++ b/docs/source/processes.rst @@ -0,0 +1,66 @@ +.. _processes: + +********** +Processes +********** + +Type of Processes +===================== + +- Builtin +- WPS-1/2 +- WPS-3 (WPS-REST) +- ESGF-CWT +- Workflow +- Remote Provider + + + + +Managing processes included in Weaver ADES/EMS +================================================== + +Following steps represent the typical steps applied to deploy a process, execute it and retrieve the results. + +Register a new process (Deploy) +----------------------------------------- + +.. todo:: complete demo docs + + +Access registered process(es) (GetCapabilities, DescribeProcess) +------------------------------------------------------------------------ + +.. todo:: complete demo docs, stuff about process visibility + + +Execution of a process (Execute, Job) +--------------------------------------------------------------------- + +.. todo:: + +Monitoring of a process (GetStatus) +--------------------------------------------------------------------- + +.. todo:: + +Obtaining output results, logs or errors (GetStatus) +--------------------------------------------------------------------- + +.. todo:: + + + +Special Weaver EMS use-cases +================================================== + +OpenSearch data source +-------------------------------------- + +.. todo:: EOImage with AOI/TOI/CollectionId for OpenSearch + +Workflow (Chaining Step Processes) +-------------------------------------- + +.. todo:: reference IDs of steps + diff --git a/docs/source/tutorial.rst b/docs/source/tutorial.rst index 8e27d9896..dab39f626 100644 --- a/docs/source/tutorial.rst +++ b/docs/source/tutorial.rst @@ -12,15 +12,26 @@ Tutorial Using the WPS application included in Weaver ============================================== -Install Weaver (see: :ref:`installation`) and make sure all required components +Install `Weaver` (see: :ref:`installation`) and make sure all required components are started and running (see: :ref:`configuration`). -Then, execute the desired `WPS`_ request according to desired operation mode and version. +Then, execute the desired `WPS`_ or `WPS-REST`_ request according to desired operation mode and version. For all following examples, ``${WEAVER_URL}`` is used to specify your application URL endpoint configuration. By default, this value should be ``localhost:4001``. -.. _`WPS`: https://www.opengeospatial.org/standards/wps +.. _WPS: https://www.opengeospatial.org/standards/wps +.. _WPS-REST: https://github.com/opengeospatial/wps-rest-binding + +.. note:: + This tutorial section is a minimal introduction to available requests and endpoints. Please refer to + `processes`_ for further details, such as detailed request payload contents, types of processes and additional + operations that compose a typical process execution workflow. Similarly, refer to + `Application Package `_ for further details about the definition of the reference application executed + by the deployed processes. + +.. _processes: ./processes.rst +.. _package: ./package.rst WPS-1/2 requests -------------------- @@ -61,6 +72,10 @@ Then, run the WPS-1/WPS-2 ``Execute`` request (built-in process ``jsonarray2netc The execution of the process should read the JSON list with our dummy NetCDF file and make it available (as a copy) on the output parameter named ``output`` with a path matching the configured output WPS path of the application. +.. note:: + All above WPS-1/2 requests suppose that configuration setting ``weaver.wps_path /ows/wps`` (default value). + The request URL have to be adjusted accordingly if this parameter is modified. + WPS-3 requests -------------- @@ -101,19 +116,11 @@ For all available operations and specific details about them, please refer to th rendered on route ``${WEAVER_URL}/api`` when running `Weaver` application. -Managing WPS processes included in Weaver ADES/EMS -================================================== - -Register a new WPS process --------------------------- - -.. todo:: complete demo docs - - -Access a registered process ---------------------------- - -.. todo:: complete demo docs, stuff about process visibility - - +Endpoint Content-Type +------------------------ +.. todo:: wps-1/2 xml default, json supported wps-2 +.. todo:: + wps-rest json only (for now, xml also if implemented) + https://github.com/crim-ca/weaver/issues/125 + https://github.com/crim-ca/weaver/issues/126 diff --git a/requirements-docs.txt b/requirements-docs.txt index bcd62e8e4..73e3c6c94 100644 --- a/requirements-docs.txt +++ b/requirements-docs.txt @@ -1,6 +1,6 @@ # these are doc-only requirements # we actually need to install all requirements during docs build because of OpenAPI generation -# (see 'docs/conf.py') +# (see 'docs/source/conf.py') pycodestyle pycodestyle # required for pywps.ext_autodoc From 58954ef3c1ecd6a70b9a88d916f37204be77f96e Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 15:27:31 -0400 Subject: [PATCH 04/11] update ogc tb14 tb15 and tb16 references --- README.rst | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index e453fae4e..9377b0f41 100644 --- a/README.rst +++ b/README.rst @@ -151,19 +151,33 @@ These are generated from corresponding information provided in `docs`_ source di .. _rtd_oas: https://pavics-weaver.readthedocs.io/en/latest/api.html .. _docs: ./docs ----------------- -Extra Details ----------------- +------------------------- +Extra Details & Sponsors +------------------------- -The project is developed upon *OGC Testbed-14 – ESA Sponsored Threads – Exploitation Platform* findings and +The project was initially developed upon *OGC Testbed-14 – ESA Sponsored Threads – Exploitation Platform* findings and following improvements. It is also advanced with sponsorship of *U.S. Department of Energy* to support common -API of the *Earth System Grid Federation* (`ESGF`_). +API of the *Earth System Grid Federation* (`ESGF`_). The findings are reported on the +`OGC Testbed-14 `_ thread, and more explicitly in the +`ADES & EMS Results and Best Practices Engineering Report `_. + +The project as been employed for `OGC Testbed-15 - ML Thread `_ to demonstrate the use of Machine Learning +interactions with OGC web standards in the context of natural resources applications. The advancements are reported +through the `OGC Testbed-15: Machine Learning Engineering Report `_. + +Developments are continued in `OGC Testbed-16 `_ to improve methodologies in order to provide better +interoperable geospatial data processing in the areas of Earth Observation Application Packages. The project is furthermore developed through the *Data Analytics for Canadian Climate Services* (`DACCS`_) initiative. Weaver is a **prototype** implemented in Python with the `Pyramid`_ web framework. It is part of `PAVICS`_ and `Birdhouse`_ ecosystems. +.. _ogc-tb14: https://www.ogc.org/projects/initiatives/testbed14 +.. _ogc-tb14-platform-er: http://docs.opengeospatial.org/per/18-050r1.html +.. _ogc-tb15-ml: https://www.ogc.org/projects/initiatives/testbed15#MachineLearning +.. _ogc-tb15-ml-er: http://docs.opengeospatial.org/per/19-027r2.html +.. _ogc-tb16: https://www.ogc.org/projects/initiatives/t-16 .. _PAVICS: https://ouranosinc.github.io/pavics-sdi/index.html .. _Birdhouse: http://bird-house.github.io/ .. _ESGF: https://esgf.llnl.gov/ From bad12e2b17814e1d9002a797f648b1598f331543 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 17:09:40 -0400 Subject: [PATCH 05/11] remove argcomplete requirement --- requirements.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index 85390ba38..12cd4eff0 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,4 @@ alembic -argcomplete backports.tempfile; python_version < "3" # celery 5 to be released in near future # celery >=4.4.3 breaks on 'future.utils' import From 6f385024e240a75991cee3e7875e564b6d76f077 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 17:22:42 -0400 Subject: [PATCH 06/11] pin pylint due to error multiprocessing (https://github.com/PyCQA/pylint/issues/3524) --- requirements-dev.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements-dev.txt b/requirements-dev.txt index 1f5bf9030..f6d30fcc5 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -10,7 +10,7 @@ isort>=4.3.21,<5 mock pluggy>=0.7 pytest -pylint>=2.5 +pylint>=2.4,<2.5 pylint_quotes responses # typing extension required for TypedDict From abeb5c9702c96ceb1b7be4ee3b8115a2a50da37e Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 19:50:39 -0400 Subject: [PATCH 07/11] explore docs linkcheck/importlib_metadata/celery-kombu issue --- docs/Makefile | 4 ++-- requirements-docs.txt | 4 ++-- weaver/processes/wps_workflow.py | 3 ++- weaver/typedefs.py | 2 +- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/docs/Makefile b/docs/Makefile index 6ec261442..296d28b36 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -169,11 +169,11 @@ changes: linkcheck: $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck @echo - @echo "Link check complete; look for any errors in the above output " "or in $(BUILDDIR)/linkcheck/output.txt." + @echo "Link check complete; look for any errors in the above output or in $(BUILDDIR)/linkcheck/output.txt." doctest: $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest - @echo "Testing of doctests in the sources finished, look at the " "results in $(BUILDDIR)/doctest/output.txt." + @echo "Testing of doctests in the sources finished, look at the results in $(BUILDDIR)/doctest/output.txt." coverage: $(SPHINXBUILD) -b coverage $(ALLSPHINXOPTS) $(BUILDDIR)/coverage diff --git a/requirements-docs.txt b/requirements-docs.txt index 73e3c6c94..6a0f42000 100644 --- a/requirements-docs.txt +++ b/requirements-docs.txt @@ -1,13 +1,13 @@ # these are doc-only requirements # we actually need to install all requirements during docs build because of OpenAPI generation # (see 'docs/source/conf.py') -pycodestyle +-r requirements.txt pycodestyle # required for pywps.ext_autodoc pywps +sphinx>=2.4 sphinx-autoapi>=1.3.0 sphinx-paramlinks>=0.4.1 -sphinx>=2.4 # adds redoc OpenAPI directly served on readthedocs sphinxcontrib-redoc>=1.6.0 sphinx_autodoc_typehints[type_comments] diff --git a/weaver/processes/wps_workflow.py b/weaver/processes/wps_workflow.py index 2e2cee98e..93f9fb8d8 100644 --- a/weaver/processes/wps_workflow.py +++ b/weaver/processes/wps_workflow.py @@ -1,3 +1,4 @@ +import collections.abc import hashlib import json import locale @@ -68,7 +69,7 @@ def default_make_tool(toolpath_object, # type: ToolPathObjectType loading_context, # type: LoadingContext get_job_process_definition, # type: GetJobProcessDefinitionFunction ): # type: (...) -> ProcessCWL - if not isinstance(toolpath_object, MutableMapping): # pylint: disable=W1116 # typing alias mapped to real type + if not isinstance(toolpath_object, collections.abc.MutableMapping): raise WorkflowException(u"Not a dict: '%s'" % toolpath_object) if "class" in toolpath_object: if toolpath_object["class"] == "CommandLineTool": diff --git a/weaver/typedefs.py b/weaver/typedefs.py index eb4fcc030..846bcd2db 100644 --- a/weaver/typedefs.py +++ b/weaver/typedefs.py @@ -1,7 +1,7 @@ from typing import TYPE_CHECKING if TYPE_CHECKING: - # pylint: disable=W0611,unused-import + # pylint: disable=W0611,unused-import,C0103,invalid-name from weaver.processes.wps_process_base import WpsProcessInterface from weaver.datatype import Process from weaver.status import AnyStatusType From 3b5ea3b4f960c6b3aa3bc9c25caa3f6e2f718584 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Thu, 4 Jun 2020 20:50:29 -0400 Subject: [PATCH 08/11] fix doc/check error --- docs/source/conf.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 96d3e0cd8..e618f8d86 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -24,9 +24,9 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -DOC_DIR_ROOT = os.path.abspath(os.path.dirname(__file__)) -DOC_PRJ_ROOT = os.path.abspath(os.path.dirname(DOC_DIR_ROOT)) -DOC_SRC_ROOT = os.path.join(DOC_DIR_ROOT, "source") +DOC_SRC_ROOT = os.path.abspath(os.path.dirname(__file__)) +DOC_DIR_ROOT = os.path.dirname(DOC_SRC_ROOT) +DOC_PRJ_ROOT = os.path.dirname(DOC_DIR_ROOT) DOC_BLD_ROOT = os.path.join(DOC_DIR_ROOT, "build") DOC_PKG_ROOT = os.path.join(DOC_PRJ_ROOT, "weaver") sys.path.insert(0, os.path.abspath(DOC_SRC_ROOT)) From 166c85b1a8b05d8a80b5bfe7497dcfc98ac5e0fe Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Fri, 5 Jun 2020 09:59:18 -0400 Subject: [PATCH 09/11] add skip db on weaver build docs --- docs/source/conf.py | 2 +- weaver/database/__init__.py | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index e618f8d86..395302d62 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -83,7 +83,7 @@ def doc_redirect_include(file_path): }) # generate openapi -config = Configurator(settings={"weaver.wps": False, "weaver.wps_restapi": True}) +config = Configurator(settings={"weaver.wps": False, "weaver.wps_restapi": True, "weaver.build_docs": True}) config.include("weaver") # need to include package to apply decorators and parse routes api_spec_file = os.path.join(DOC_BLD_ROOT, "api.json") api_spec_json = get_swagger_json(http_host="example", http_scheme="https") diff --git a/weaver/database/__init__.py b/weaver/database/__init__.py index d95755ab6..e9774ece0 100644 --- a/weaver/database/__init__.py +++ b/weaver/database/__init__.py @@ -1,7 +1,9 @@ import logging from typing import TYPE_CHECKING -from weaver.utils import get_registry +from pyramid.settings import asbool + +from weaver.utils import get_registry, get_settings LOGGER = logging.getLogger(__name__) if TYPE_CHECKING: @@ -16,6 +18,11 @@ def get_db(container): def includeme(config): + settings = get_settings(config) + if asbool(settings.get("weaver.build_docs", True)): + LOGGER.info("Skipping database when building docs...") + return + LOGGER.info("Adding database...") from weaver.database.mongodb import MongoDatabase config.registry.db = MongoDatabase(config.registry) From 20585367a647f7e2c3e2510418475db3abb31a74 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Fri, 5 Jun 2020 10:14:32 -0400 Subject: [PATCH 10/11] invert default build docs flag --- weaver/database/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/weaver/database/__init__.py b/weaver/database/__init__.py index e9774ece0..38f415616 100644 --- a/weaver/database/__init__.py +++ b/weaver/database/__init__.py @@ -19,7 +19,7 @@ def get_db(container): def includeme(config): settings = get_settings(config) - if asbool(settings.get("weaver.build_docs", True)): + if asbool(settings.get("weaver.build_docs", False)): LOGGER.info("Skipping database when building docs...") return From 947aee514b7446e2ec69ba8b2693ee57d8e0e637 Mon Sep 17 00:00:00 2001 From: Francis Charette Migneault Date: Fri, 5 Jun 2020 10:16:50 -0400 Subject: [PATCH 11/11] add note about setting weaver.build_docs --- docs/source/conf.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 395302d62..a94436dc4 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -83,6 +83,9 @@ def doc_redirect_include(file_path): }) # generate openapi +# note: +# setting 'weaver.build_docs' allows to ignore part of code that cause problem or require unnecessary +# configuration for the purpose of parsing the source to generate the OpenAPI config = Configurator(settings={"weaver.wps": False, "weaver.wps_restapi": True, "weaver.build_docs": True}) config.include("weaver") # need to include package to apply decorators and parse routes api_spec_file = os.path.join(DOC_BLD_ROOT, "api.json")