StuFu StuFu - 1 month ago 6
JSON Question

Sitefinity - Proper OData URL filtering array/classifications

I'm using the built in Web Service API in Sitefinity 9.1 which is following OData standards.

I have a URL like this to receive the JSON in the format I would like:


I have a JSON from that service that looks like this:

"value": [
"Title": "Developing Reading Skills",
"Summary": "Lorem ipsum dolor sit amet",
"ageranges": [
"topics": [
"ButtonText": "Learn More",
"UrlName": "developing-reading-skills"

This works great, but I am having a problem with filtering this service by ageranges or topics.

I've tried a few different solutions. This seems to be the standard OData way to filter but this throws an error. I'm not sure if this is a problem with my formatting, or the Sitefinity implementation. Can someone confirm?

/api/stories/storyitems?$filter=any(ageranges eq '3ca54b5b-06ab-63fa-8375-ff00000b3273')&$select=Title,Summary,ageranges,UrlName,topics,ButtonText

Here's the error I get back in the JSON:

"error": {
"code": "",
"message": "An error has occurred."



I was directed to this article that indicated this is the proper way:

/api/stories/storyitems?$filter=Category/any(s:s eq d81e4d00-afe6-60df-84cd-ff0000aaa3eb)&$select=Title,Summary,ageranges,UrlName,topics,ButtonText