Community ID Regular Expression Usage
These API calls allow the usage of regular expressions to ease the use of multiple communities (see community data model) at once:
- config/source/good
- config/source/bad
- config/source/pending
- knowledge/document/query
- knowledge/feature/geoSuggest
- knowledge/feature/entitySuggest
- knowledge/feature/aliasSuggest
- knowledge/feature/assocSuggest
In place of just sending a comma deliminated list of community ids you can now send * or *<regex> to signify retrieving multiple community ids matching either all ( * ) or all matching a regex ( *<regex>). See below for some examples on how it can be used.
Take the config/source/good api call as an example, it has 1 parameter "communityid-list".
You would normally call this api call via: http://infinite.ikanow.com/api/config/source/good/4f579d7e8c22000000001b3b,4f579d7e8c22000000001b3c
This would return the good sources for both community abcde12345 and abcde12346. This would be a pain to use if we wanted to return all good sources so instead we can use the new syntax to return good sources for all communities we have access to via: http://infinite.ikanow.com/api/config/source/good/*
We can also be more specific and only return the good sources for any source with cnn in the name via: http://infinite.ikanow.com/api/config/source/good/*cnn