To get the list of questions from a SP 2013+ Distribution list using OOTB REST API:
_api/lists/getByTitle(‘listname‘)/items?$filter=ContentType eq ‘Discussion’
or
/_api/lists/getByTitle(‘listname‘)/items?$filter=FSObjType eq 1
To get the list of replies from a SP 2013+ Distribution list, using OOTB REST API:
_api/lists/getByTitle(‘listname‘)/items?$filter=ContentType eq ‘Message’
or
/_api/lists/getByTitle(‘listname‘)/items?$filter=FSObjType eq 0
To get the list of Discussions with the replies count from a SP 2013+ Distribution list, using OOTB REST API:
/_api/lists/getByTitle(‘listname‘)/items?$select=ID,Title,Body,Folder/ItemCount &$expand=Folder/ItemCount &$filter=ContentType eq ‘Discussion’
How to filter replies related to individual discussions ..I am currently doing it by using ParentItemID but it is null for newly created replies using REST.Please let me know Is there any Way to filter replies of a particular discussion other than ParentItemID.