To remove HTML tags from the body content of an incoming email before adding it to an Excel table row in Power Automate, you can use an Azure Function or a built-in expression in Power Automate. If you choose to use an Azure Function, you can create a function that processes the email body and strips out HTML tags. Then, you can call this function in your Power Automate flow.
Alternatively, you can use the replace() function in Power Automate to remove specific HTML tags by replacing them with an empty string. However, for more complex HTML content, using an Azure Function is recommended for better handling of various HTML structures.
For example, you can use the following steps in your Power Automate flow:
- Trigger the flow when a new email arrives.
- Use the Azure Function to clean the email body by removing HTML tags.
- Add the cleaned text to your Excel table row.
Make sure to format the request body correctly when calling the Azure Function to ensure it processes the email body as expected.