query

Available Since: V1

Invoke a search query on the server and collect the results of the query.

Request

GET api/1/search/query/
Parameter Description
q
The search term.
searchIn The document paths to search in, `module:nodeid`, the default is to search everything.
words The number of words to return in the document summary, defaults to 30.
page The page number to get results for, defaults to 0.
pageSize The number of results to show per page, defaults to 10.
matchAll 1 to require all search terms be present, defaults to 0.
summary The fields and the order to use them when creating summary text, defaults to `content,cummary,meta_description`.
fields
The optional array of fields to search within.

Successful Response (200)

{
	"totlaMatches": "3",
	"page": "0",
	"pageSize": "10",
	"results": [
		{
			"link": "http://example.com/result1.html",
			"title": "Example 1",
			"summary": "Example 1 summary"
		},
		{
			"link": "http://example.com/result2.html",
			"title": "Example 2",
			"summary": "Example 2 summary"
		},
		{
			"link": "http://example.com/result3.html",
			"title": "Example 3",
			"summary": "Example 3 summary"
		}
	]
}
Parameter Description
totalMatches The total number of matches to the search query.
page The page the results are being returned for.
pageSize The maximum number of results per page.
results Array of results where 'link' is the address of the page, 'title' is the title of the found page and 'summary' is the summary text for the page.



TOP