Skip to main content


Calling Actions from Copilot Studio

How to parse incoming phone number

Posted on by



I have an Omnichannel SMS Workstream configured with a PVA bot.  I am able to trigger the bot topics with a text message to a particular phone number, which is great.  I am trying to discern if the PVA bot can grab the incoming phone number and pass it to a Power Automate Flow to filter a table in our Dataverse.


When I review the session logs in the PVA analytics area for my bot, I can see my phone number is captured in the ChatTranscript column (I've blocked it out in red):




I think that payload is getting passed from Dynamics/Omnichannel though, so I'm not sure how to grab the "PrimaryDisplayValue" key.  Thanks in advance.

  • Varun8492 Profile Picture
    Varun8492 4 on at
    Re: How to parse incoming phone number

    Yes, it is possible to grab the incoming phone number from an Omnichannel SMS Workstream and pass it to a Power Automate Flow to filter a table in Dataverse.

    To achieve this, you can use Power Automate to create a flow that triggers when a new SMS message is received by your Omnichannel Workstream. The flow can then extract the phone number from the message and use it to filter a table in Dataverse.

    Here are the high-level steps you can follow to accomplish this:

    1. In Power Automate, create a new flow with the "When a new message arrives in a channel" trigger.

    2. Select the "Omnichannel for Customer Service" connector and choose your SMS Workstream.

    3. In the trigger, you can access the incoming phone number by using the expression triggerOutputs()?['body/senderPhoneNumber'].

    4. Use this expression in a "Get rows" action for your Dataverse table to filter the rows based on the incoming phone number. You can use the Filter Query option and build a query that filters the table based on the phone number.

    5. Once you have the filtered data, you can perform any desired actions with it, such as sending an email, updating a record, or sending a message back to the SMS sender.

    I hope this helps! Please hit like 🙂

Helpful resources

Quick Links

Exciting News for Copilot Studio Communi…

Get ready to experience a whole new level of engagement with the Copilot Studio…

Celebrating the May Super User of the…

LaurensM is an exceptional contributor to the Power Platform Community…

Check out the Copilot Studio Cookbook…

We are excited to announce our new Copilot Cookbook Gallery in the Community…


renatoromao Profile Picture

renatoromao 6,459

Pstork1 Profile Picture

Pstork1 1,995

Expiscornovus Profile Picture

Expiscornovus 1,708


Featured topics