The Sentiment Analysis API provided by Microsoft evaluates the text input and returns a sentiment score for each document, ranging from 0 (negative) to 1 (positive). This capability is useful for detecting positive and negative sentiment in social media, customer reviews, and discussion forums. In this article, I am going to show you how to send the feedback entered in a SharePoint Online modern list item to Sentiment Analysis API and update the response back in SharePoint. Also, I am going to show how to beautify the sentiment score with emojis using column formatting feature.
Create a SharePoint list with the following columns.
At the top of the list, click Flow, and then click "Create a flow".
Select the below flow template from the right-hand panel.

Follow the instructions on the Microsoft Flow site to connect to the list we have created. Credentials will be verified for each service used in the flow. For Office 365 services such as SharePoint and Outlook, connections will be created automatically. The next steps will be performed in the Microsoft Flow designer. The first action displayed, also known as a trigger, will determine how the flow will be started. Additional actions may be added after the first. Each new action will be dependent on the previous action.

Next step is to add an initialize variable action to set the value of the current Item Id.

Create a POST request using an HTTP action. Set the HTTP Method, URI, Headers, and Body as shown below.










Atul GuptaPosted Feb 19, 2019, 3:36 AM
What should be the column type for emoji
Muthu KumarPosted Feb 6, 2019, 10:48 PM
Good One Joseph. Thanks for sharing...