1 Reply Latest reply on Dec 13, 2016 2:22 AM by gopi.gorantala

    Search exact match in Subject of Discussion - Rest API




      Our application would like to search communities to find a Discussion accurately for a Case Number by searching the Case Number in the Subject part of all Discussions. The Subject of the Discussion will be in the format -> “[2006623728] - [XXXX] - [XXXXXXXXXXXXX]” where 2006623728 is the Case number.




      Is this correct one or any other ways are there to match case number in Subject.




        • Re: Search exact match in Subject of Discussion - Rest API

          You should use something like below.


          You can strip off the fields which you don't need in your JSON as below by adding &fields=-id,-type etc. or if you feel some data is missing in rest api you can add them using &fields=categories,subjectlength etc..     Below is the query which can narrow down based on your search results




          After this you get less fields in each content type, now you can use the OSAPI or Ajax to compare the subject with your test.