Updated retrieveConversations method to return data in the correct format