Search Plugins#
Search plugins must inherit the following class and implement query():
- class eodag.plugins.search.base.Search(provider, config)[source]#
Base Search Plugin.
- Parameters:
provider (
str) – An EODAG provider nameconfig (
PluginConfig) – An EODAG plugin configuration
- build_sort_by(sort_by_arg)[source]#
Build the sorting part of the query string or body by transforming the
sort_byargument into a provider-specific string or dictionary
- discover_product_types(**kwargs)[source]#
Fetch product types list from provider using discover_product_types conf
- discover_queryables(**kwargs)[source]#
Fetch queryables list from provider using
discover_queryablesconf
- get_assets_from_mapping(provider_item)[source]#
Create assets based on the assets_mapping in the provider’s config and an item returned by the provider
- get_metadata_mapping(product_type=None)[source]#
Get the plugin metadata mapping configuration (product type specific if exists)
- get_product_type_cfg_value(key, default=None)[source]#
Get the value of a configuration option specific to the current product type.
This method retrieves the value of a configuration option from the
product_type_configattribute. If the option is not found, the provided default value is returned.- Parameters:
key (str) – The configuration option key.
default (Any) – The default value to be returned if the option is not found (default is None).
- Returns:
The value of the specified configuration option or the default value.
- Return type:
Any
- get_product_type_def_params(product_type, format_variables=None)[source]#
Get the provider product type definition parameters and specific settings
- get_sort_by_arg(kwargs)[source]#
Extract the
sort_byargument from the kwargs or the provider default sort configuration
- list_queryables(filters, available_product_types, product_type_configs, product_type=None, alias=None)[source]#
Get queryables
- Parameters:
filters (
dict[str,Any]) – Additional filters for queryables.available_product_types (
list[Any]) – list of available product typesproduct_type_configs (
dict[str,dict[str,Any]]) – dict containing the product type information for all used product typesproduct_type (
str|None, default:None) – (optional) The product type.alias (
str|None, default:None) – (optional) alias of the product type
- Return type:
QueryablesDict- Returns:
A dictionary containing the queryable properties, associating parameters to their annotated type.
- map_product_type(product_type, **kwargs)[source]#
Get the provider product type from eodag product type
- query(prep=PreparedSearch(product_type=None, page=1, items_per_page=20, auth=None, auth_plugin=None, count=True, url=None, info_message=None, exception_message=None), **kwargs)[source]#
Implementation of how the products must be searched goes here.
This method must return a tuple with (1) a list of
EOProductinstances which will be processed by aDownloadplugin (2) and the total number of products matching the search criteria. Ifprep.countis False, the second element returned must beNone.
- queryables_from_metadata_mapping(product_type=None, alias=None)[source]#
Extract queryable parameters from product type metadata mapping. :type product_type:
str|None, default:None:param product_type: product type id (optional) :type alias:str|None, default:None:param alias: (optional) alias of the product type :rtype:dict[str,Any] :returns: dict of annotated queryables
This table lists all the search plugins currently available:
|
A plugin that helps implementing any kind of search protocol that relies on query strings (e.g: opensearch). |
|
A specialisation of a |
|
A specialisation of a |
|
A specialisation of |
|
A specialisation of a |
Static STAC Catalog search plugin |
|
|
|
|
class that implements search for the Copernicus Marine provider |
|
|
|
ECMWF search plugin. |
MeteoblueSearch search plugin. |
|
WekeoECMWFSearch search plugin. |
|
|
A plugin for implementing search based on OGC CSW |