Method Search
Search(String, SearchDefinitionContract, List<String>, String, String)
Search for objects
Declaration
SearchResultContract Search(string connectionId, SearchDefinitionContract searchDefinition, List<string> resultProperties, string resumePoint, string customSecurityToken)
Parameters
Type | Name | Description |
---|---|---|
System.String | connectionId | The connection id to identify your connection. See also ConnectionId |
SearchDefinitionContract | searchDefinition | Optional: Definition of search conditions |
System.Collections.Generic.List<System.String> | resultProperties | Optional: List of property types ids which should be returned. |
System.String | resumePoint | Optional: The resume point from previous search operations. Set |
System.String | customSecurityToken | Optional: A custom token for security purposes. Only used in customer security plugins. |
Returns
Type | Description |
---|---|
SearchResultContract | Returns the results of the search operation. |
Examples
POST http://YourServerName/InfoShare/Json/Search/Search
Example for search objects.{
"connectionId": "29edddd1-f659-4aa7-8248-54bae7121038",
"searchDefinition": {
"Conditions": [{
"Values": ["2019-09-26T12:06:48"],
"ComparisonEnum": "LessEquals",
"PlaceHolder": "",
"PropertyTypeId": "01000009-38a7-11d8-a902-0050bf427e8f",
"RelationEnum": "And" }],
"FulltextWordRelation": "AND",
"FulltextWords": "",
"PageSize": 100,
"SearchStores": ["4b07ac1e-b9cf-e911-a939-00155d290a08", "c5b7dd4e-b8cf-e911-a939-00155d290a08",
"5ff3c8f6-b8cf-e911-a939-00155d290a08", "3bb6448c-b9cf-e911-a939-00155d290a08",
"67727470-b9cf-e911-a939-00155d290a08", "e46bc061-b7cf-e911-a939-00155d290a08"],
"UseWildCard": true },
"resultProperties": ["01000a00-38a7-11d8-a902-0050bf427e8f", "01000004-d596-485b-ace6-d64647a94277",
"01000002-d596-485b-ace6-d64647a94277", "01000000-d596-485b-ace6-d64647a94277",
"01000001-d596-485b-ace6-d64647a94277", "2cdacc4e-15d0-e911-a93a-00155d290a08"],
"resumePoint": "" }
}
Response:
{
"SearchResult": {
"Documents": [{
"CheckOutStateEnum": "NotCheckedOut",
"FolderElementId": null,
"HasAnnotation": false,
"HasBlog": true,
"HasLinks": true,
"HasSignature": true,
"HasTempAccess": false,
"Id": "a7d3a990-2cd2-e911-a93c-00155d290a08",
"Name": "Rechnung_Solothurn.pdf",
"Properties": [{
"PropertyTypeId": "01000a00-38a7-11d8-a902-0050bf427e8f",
"Values": ["Rechnung_Solothurn.pdf"] }, {
"PropertyTypeId": "01000004-d596-485b-ace6-d64647a94277",
"Values": ["Standard"] }, {
"PropertyTypeId": "01000002-d596-485b-ace6-d64647a94277",
"Values": ["2cd4ad99-bacf-e911-a939-00155d290a08"] }, {
"PropertyTypeId": "01000000-d596-485b-ace6-d64647a94277",
"Values": ["0100a000-38a7-11d8-a902-0050bf427e8f"] }, {
"PropertyTypeId": "01000001-d596-485b-ace6-d64647a94277",
"Values": ["2019-09-08T11:34:00"] }, {
"PropertyTypeId": "2cdacc4e-15d0-e911-a93a-00155d290a08",
"Values": ["Rechnung"] }]
}, {
"CheckOutStateEnum": "NotCheckedOut",
"FolderElementId": null,
"HasAnnotation": false,
"HasBlog": false,
"HasLinks": true,
"HasSignature": false,
"HasTempAccess": false,
"Id": "6ba7a04c-a0df-e911-a949-00155d290a08",
"Name": "MicrosoftTeams-image1.png",
"Properties": [{
"PropertyTypeId": "01000a00-38a7-11d8-a902-0050bf427e8f",
"Values": ["MicrosoftTeams-image1.png"] }, {
"PropertyTypeId": "01000004-d596-485b-ace6-d64647a94277",
"Values": ["Standard"] }, {
"PropertyTypeId": "01000002-d596-485b-ace6-d64647a94277",
"Values": ["0100a003-38a7-11d8-a902-0050bf427e8f"] }, {
"PropertyTypeId": "01000000-d596-485b-ace6-d64647a94277",
"Values": ["0100a000-38a7-11d8-a902-0050bf427e8f"] }, {
"PropertyTypeId": "01000001-d596-485b-ace6-d64647a94277",
"Values": ["2019-09-25T14:25:00"] }, {
"PropertyTypeId": "2cdacc4e-15d0-e911-a93a-00155d290a08",
"Values": ["Rechnung"] }] }],
"HasMore": false,
"Processes": [],
"ResumePoint": "36" }
}
Exceptions
Type | Condition |
---|---|
ServiceException | The connection id {connectionId} isn't valid or has expired (10008) |
ServiceException | Search store not found {infoStore} (10033) |
ServiceException | Property type not found {propertyTypeId} (10034) |
ServiceException | Unknown data type for property type (10035) |
ServiceException | String was not recognized as a valid DateTime: {dateTimeValue}. Expected format {expectedFormat} (10059) |
ServiceException | Comparison operator {comparisonOperator} is not allowed for property type {propertyTypeId} (10087) |
ServiceException | Unknown comparison operator {comparisonOperator} (10088) |
ServiceException | Property type {propertyTypeId} is deleted (10090) |
ServiceException | Property type {propertyTypeId} is deactivated (10091) |
ServiceException | Verification code is needed: Verification code not yet verified (10152) |
ServiceException | Comparison operator {comparisonOperator}: First search value '{searchValue}' is not recognized as a valid DateTime. Expected format '{yyyy-MM-ddTHH:mm:ss}' (10353) |
ServiceException | Comparison operator {comparisonOperator}: Second search value '{searchValue2}' is not recognized as a valid DateTime. Expected format '{yyyy-MM-ddTHH:mm:ss}' (10354) |
ServiceException | Comparison operator {comparisonOperator}: First search value '{searchValue}' is not recognized as a valid Date. Expected format '{yyyy-MM-dd}' (10355) |
ServiceException | Comparison operator {comparisonOperator}: Second search value '{searchValue2}' is not recognized as a valid Date. Expected format '{yyyy-MM-dd}' (10356) |
ServiceException | Comparison operator {comparisonOperator}: Only one search value found (10359) |