| Returns records searched using the specified Term in JSON format |
---|
| |
---|
| http(s)://<servernameOrIP>/<trackitvirtuadirectory>/WebApi/searches |
---|
Request Authorization Header | Bearer access_token received through the Token API call. |
---|
| |
---|
| Enter the seachInput values as follows: - MaxContentLength
Specify the maximum length of the content. Note: To return all characters, specify negative 1 (-1). - Term
Specify the keywords to search, separated by commas. - Mode
Specify the search options as follows:- 0 – All words and phrases
- 1 – Any of the words and phrases
- PageSize
Specify the page size. - ModuleId
Specify the sequence ID of the module. - PageNumber
Specify the page number. Note: To return all records, specify zero (0). - ResultFields
Specify the Sequence of fields which need to be returned.
{ "MaxContentLength": 0, "Term": "string", "Mode": 0, "PageSize": 0, "ModuleId": 0, "PageNumber": 0, "ResultFields": [ 0 ], "OptionalParams": { "Param1": {}, "Param2": {} } } |
---|
| Returns the count of records and the specified result fields of the records for the specified search terms |
---|
| Only modules Ticket (ModuleId = 24) and Solution (Moduleid = 74) are supported in Search. |
---|
Example
http(s)://<servernameOrIP>/<trackitvirtuadirectory>/WebApi/searches
Request Authorization Header:
Bearer access_token:"ExPqpLF79Zi+vHZJIXZOGBSQVPKXlFVOfmQzMyfS7SGYJolrDAf3/LZR1qm9X+2OVY60OlEuUYOYaflcIjj7ytZ336b50mu4ieuPnx2AU2vCFgO3eqUe22Up"
Request Body:
{
"MaxContentLength": 0,
"Term": "Printer",
"Mode": 0,
"PageSize": 1,
"ModuleId": 24,
"PageNumber": 1,
"ResultFields": [
1,22
],
"OptionalParams": {
"Param1": {},
"Param2": {}
}
}
Response:
"DisplayName": "Ticket ID",
"DisplayName": "Ticket Summary",
"Value": "My printer is damaged"