2019-12-30 21:56:09 +01:00
|
|
|
.. _search API:
|
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
==========
|
2015-11-17 23:13:30 +01:00
|
|
|
Search API
|
|
|
|
==========
|
|
|
|
|
2016-09-06 18:13:20 +02:00
|
|
|
The search supports both ``GET`` and ``POST``.
|
2015-11-17 23:13:30 +01:00
|
|
|
|
2016-07-09 22:31:21 +02:00
|
|
|
Furthermore, two enpoints ``/`` and ``/search`` are available for querying.
|
|
|
|
|
2017-10-23 16:29:43 +02:00
|
|
|
|
|
|
|
``GET /``
|
|
|
|
|
|
|
|
``GET /search``
|
|
|
|
|
|
|
|
Parameters
|
2019-12-12 19:20:56 +01:00
|
|
|
==========
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-21 17:13:38 +01:00
|
|
|
.. sidebar:: Further reading ..
|
|
|
|
|
2019-12-30 21:56:09 +01:00
|
|
|
- :ref:`engines-dev`
|
|
|
|
- :ref:`settings.yml`
|
2019-12-21 17:13:38 +01:00
|
|
|
- :ref:`engines generic`
|
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
``q`` : required
|
|
|
|
The search query. This string is passed to external search services. Thus,
|
|
|
|
searx supports syntax of each search service. For example, ``site:github.com
|
|
|
|
searx`` is a valid query for Google. However, if simply the query above is
|
|
|
|
passed to any search engine which does not filter its results based on this
|
|
|
|
syntax, you might not get the results you wanted.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
See more at :ref:`search-syntax`
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
``categories`` : optional
|
|
|
|
Comma separated list, specifies the active search categories
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``engines`` : optional
|
2019-12-12 19:20:56 +01:00
|
|
|
Comma separated list, specifies the active search engines.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``lang`` : default ``all``
|
2019-12-12 19:20:56 +01:00
|
|
|
Code of the language.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``pageno`` : default ``1``
|
2019-12-12 19:20:56 +01:00
|
|
|
Search page number.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``time_range`` : optional
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``day``, ``month``, ``year`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Time range of search for engines which support it. See if an engine supports
|
|
|
|
time range search in the preferences page of an instance.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``format`` : optional
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``json``, ``csv``, ``rss`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Output format of results.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``results_on_new_tab`` : default ``0``
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``0``, ``1`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Open search results on new tab.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``image_proxy`` : default ``False``
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``True``, ``False`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Proxy image results through searx.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``autocomplete`` : default *empty*
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``google``, ``dbpedia``, ``duckduckgo``, ``startpage``, ``wikipedia`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Service which completes words as you type.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``safesearch`` : default ``None``
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``0``, ``1``, ``None`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Filter search results of engines which support safe search. See if an engine
|
|
|
|
supports safe search in the preferences page of an instance.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``theme`` : default ``oscar``
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``oscar``, ``simple``, ``legacy``, ``pix-art``, ``courgette`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Theme of instance.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Please note, available themes depend on an instance. It is possible that an
|
|
|
|
instance administrator deleted, created or renamed themes on his/her instance.
|
|
|
|
See the available options in the preferences page of the instance.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``oscar-style`` : default ``logicodev``
|
2019-12-12 19:20:56 +01:00
|
|
|
[ ``pointhi``, ``logicodev`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Style of Oscar theme. It is only parsed if the theme of an instance is
|
|
|
|
``oscar``.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
Please note, available styles depend on an instance. It is possible that an
|
|
|
|
instance administrator deleted, created or renamed styles on his/her
|
|
|
|
instance. See the available options in the preferences page of the instance.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``enabled_plugins`` : optional
|
2019-12-12 19:20:56 +01:00
|
|
|
List of enabled plugins.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
:default: ``HTTPS_rewrite``, ``Self_Informations``,
|
|
|
|
``Search_on_category_select``, ``Tracker_URL_remover``
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
:values: [ ``DOAI_rewrite``, ``HTTPS_rewrite``, ``Infinite_scroll``,
|
|
|
|
``Vim-like_hotkeys``, ``Self_Informations``, ``Tracker_URL_remover``,
|
|
|
|
``Search_on_category_select`` ]
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
``disabled_plugins``: optional
|
|
|
|
List of disabled plugins.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-12 19:20:56 +01:00
|
|
|
:default: ``DOAI_rewrite``, ``Infinite_scroll``, ``Vim-like_hotkeys``
|
|
|
|
:values: ``DOAI_rewrite``, ``HTTPS_rewrite``, ``Infinite_scroll``,
|
|
|
|
``Vim-like_hotkeys``, ``Self_Informations``, ``Tracker_URL_remover``,
|
|
|
|
``Search_on_category_select``
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``enabled_engines`` : optional : *all* :origin:`engines <searx/engines>`
|
2019-12-12 19:20:56 +01:00
|
|
|
List of enabled engines.
|
2017-10-23 16:29:43 +02:00
|
|
|
|
2019-12-30 21:55:15 +01:00
|
|
|
``disabled_engines`` : optional : *all* :origin:`engines <searx/engines>`
|
2019-12-12 19:20:56 +01:00
|
|
|
List of disabled engines.
|
2017-10-23 16:29:43 +02:00
|
|
|
|