Skip to content
Back to top
View this page
Edit this page

# Key-Value Results

Typification of the keyvalue results. Results of this type are rendered in the keyvalue.html template.

class searx.result_types.keyvalue.KeyValue(title: str = '', content: str = '', img_src: str = '', iframe_src: str = '', audio_src: str = '', thumbnail: str = '', publishedDate: ~datetime.datetime | None = None, pubdate: str = '', length: ~datetime.timedelta | None = None, views: str = '', author: str = '', metadata: str = '', priority: ~typing.Literal['', 'high', 'low'] = '', engines: set[str] = <factory>, open_group: bool = False, close_group: bool = False, positions: list[int] = <factory>, score: float = 0, category: str = '', *, template: str = 'keyvalue.html', url: str | None = None, engine: str | None = '', parsed_url: ~urllib.parse.ParseResult | None = None, kvmap: dict[str, ~typing.Any] | ~collections.OrderedDict[str, ~typing.Any], caption: str = '', key_title: str = '', value_title: str = '')

  Bases: `MainResult`

  Simple table view which maps key names (first col) to values (second col).

  kvmap: dict[str, Any] | OrderedDict[str, Any]

    Dictionary with keys and values. To sort keys, use `OrderedDict`.

  caption: str

    Optional caption for this result.

  key_title: str

    Optional title for the key column.

  value_title: str

    Optional title for the value column.