HTTPDownload

HTTPDownload#

class eodag.plugins.download.http.HTTPDownload(provider, config)[source]#

HTTPDownload plugin. Handles product download over HTTP protocol

Parameters:
  • provider (str) – provider name

  • config (PluginConfig) –

    Download plugin configuration:

    • type (str) (mandatory): HTTPDownload

    • base_uri (str): default endpoint url

    • method (str): HTTP request method for the download request (GET or POST); default: GET

    • extract (bool): if the content of the downloaded file should be extracted; default: True

    • auth_error_code (int): which error code is returned in case of an authentication error

    • dl_url_params (dict[str, Any]): parameters to be added to the query params of the request

    • archive_depth (int): level in extracted path tree where to find data; default: 1

    • flatten_top_dirs (bool): if the directory structure should be flattened; default: True

    • ignore_assets (bool): ignore assets and download using downloadLink; default: False

    • timeout (int): time to wait until request timeout in seconds; default: 5

    • ssl_verify (bool): if the ssl certificates should be verified in requests; default: True

    • no_auth_download (bool): if the download should be done without authentication; default: True

    • order_enabled (bool): if the product has to be ordered to download it; if this parameter is set to true, a mapping for the orderLink has to be added to the metadata mapping of the search plugin used for the provider; default: False

    • order_method (str): HTTP request method for the order request (GET or POST); default: GET

    • order_headers ([dict[str, str]]): headers to be added to the order request

    • order_on_response (OrderOnResponse): a typed dictionary containing the key metadata_mapping which can be used to add new product properties based on the data in response to the order request

    • order_status (OrderStatus): configuration to handle the order status; contains information which method to use, how the response data is interpreted, which status corresponds to success, ordered and error and what should be done on success.

    • products (dict[str, dict[str, Any]): product type specific config; the keys are the product types, the values are dictionaries which can contain the key extract to overwrite the provider config for a specific product type

__init__(provider, config)[source]#
Parameters:

Methods

__init__(provider, config)

download(product[, auth, progress_callback, ...])

Download a product using HTTP protocol.

download_all(products[, auth, ...])

Download all using parent (base plugin) method

generate_record_hash(product)

Generate the record hash of the given product.

order(product[, auth, wait, timeout])

Order product and poll to check its status

order_response_process(response, product)

Process order response

Attributes

plugins