Wondering if you could help me please, I am currently calling the SharePoint rest search api with a number of parameters as below:

GET: https://tenant.sharepoint.com/sites/sitecol/_api/search/query?
querytext='path:https://tenant.sharepoint.com/sites/sitecol ContentTypeId:0x0101008CA34DF8F4904B3EB1EB49AC10614C68*'

I am using the header Accept: application/json;odata=nometadata

However when running this in Postman or SharePoint online I get the following returned:

{ "odata.error": { "code": "-1, Microsoft.Office.Server.Search.REST.SearchServiceException", "message": { "lang": "en-US", "value": "An unknown error occurred." } } }

The only method I appear to have found to fix this is to reduce the number of thresholds in the refiner parameter however I am unable to find any documentation detailing the maximum number of thresholds that can be used.

I appreciate any help that anyone can give on this matter.

1 Answer 1


An explanation can be found at :


You should specify Odata version as 3.0 and not 4.0 because the search API does not work with 4.0.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.