Generating a Geodi Token is needed. If you are preparing an end-user interface, Displaying search results with templates page will be more useful.
(!) QueryHandler.GetSummaries is a simplified service. With the getDocumentSummaries api, you can take advantage of more features, and with GetSummaryType in the query parameter you can set the summary text length.
GetSummaries |
---|
Definition | Returns summaries of locations that match the query from within a particular workspace. |
---|
Request | [GEODIURL]/QueryHandler?op=GetSummaries&wsName=[WSNAME]&q=[SearchString]&startIndex=[StartIndex]&endIndex=[EndIndex]&options=[OptionsJSON]&UserSession=[TOKEN] - wsName(string): Name of the workspace to search inside
- q(string): Query text
- StartIndex(int - Optional): The Index which the query results will start.(limit 0)
- EndIndex(int - Optional): The Index which the query results will end.(limit 0)
- options(Optional): Additional parameters to change the query result
- ContentIDFilter(int[] - Optional): Filters the content from which to query.
- Envelope([LonMin(int),LatMin(int),LonMax(int),LatMax(int)] - Optional): Returns the words within the boundaries of the given BBOX geometry.
- LayerIdFilter(int[] - Optional): Filters the words according to the IDs of the recognizers that recognize these words.
- KeywordIdFilter(int[] - Optional): Filters words by IDs
|
---|
HttpMethod | GET, POST |
---|
Expected Errors | 401 Unauthorized access / Access denied 403 Forbidden 511 Network Authentication Required 501 Server Error |
---|
Resulting value |
Code Block |
---|
language | js |
---|
linenumbers | true |
---|
| [
{
"ContentID": 1,
"Summary":
{
"SummaryID": "",
"Text": ""
}
}
] |
|
---|
Example |
Code Block |
---|
//Request : [GEODIURL]/QueryHandler?op=GetSummaries&wsName=PROJECT&q=ankara&startIndex=0&endIndex=1
[
{
"ContentID": 2,
"Summary":
{
"SummaryID": "FTS_0_123_4567_8",
"Text": "... ankara ..."
}
}
] |
Code Block |
---|
//Request : [GEODIURL]/QueryHandler?op=GetSummaries&wsName=PROJECT&q=ankara&startIndex=0&endIndex=1&options={"ContentIDFilter":[3]}
[
{
"ContentID": 3,
"Summary":
{
"SummaryID": "FTS_0_123_4567_8",
"Text": "... ankara ..."
}
},
{
"ContentID": 3,
"Summary":
{
"SummaryID": "FTS_9_876_5432_1",
"Text": "... ankara ..."
}
}
]
|
|
---|
Example applications
| |
---|
...