web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to get the name of...
Power Automate
Answered

How to get the name of a List?

(0) ShareShare
ReportReport
Posted on by 351

I would like to include the name of an MS List in the subject of an email so that the recipient knows which list this email is about. I am using a recurrence flow to compile the daily changes that have occurred in a list and then sending out emails in Apply to Each to the various people assigned to those changes.

 

I thought since I manually specify the List in Get Items that I could simply initialize a variable with Name from this but when trying the variable is automatically put inside another Apply to Each. Since the flow only concerns one List I'm sure this is not the right way. How do I go about this?

 

Power_Automater_0-1644286261658.png

 

Categories:
I have the same question (0)
  • Verified answer
    Expiscornovus Profile Picture
    33,876 Most Valuable Professional on at

    Hi @Power_Automater,

     

    You could reuse what you have selected in the Get Items. This is stored as one of the input parameters. However, the challenge is that it is stored with the GUID of the list and not the actually name. You can workaround this by using a Send an HTTP request action to retrieve the title.

     

    Below is an example of that approach.

    The Send an HTTP request actions uses a GET method to retrieve the properties of your selected list in the Get Items. In this example I am only returning the Title. Which will be stored in a string variable in the action after that.

     

    _api/web/lists(guid'@{actions('Get_Items')['inputs']['parameters']['table']}')?$select=Title

     

    inputparameters_table.png

  • Power_Automater Profile Picture
    351 on at

    Thank you @Expiscornovus I will give this a try later today and let you know how I go. Is there really no built in action in Automate/Flow to get the name/title of a list? It seems strange that it is possible to get all of the list data in each row and column but not the name of the list itself.

  • Expiscornovus Profile Picture
    33,876 Most Valuable Professional on at

    Hi @Power_Automater,

     

    As far as I am aware there are only two actions which interact with lists and both of them retrieve all items and don't have a filter capability. That's why I used the approach with the built in Send an HTTP request to SharePoint action.

     

    lists_action.png

     

    Btw, another approach would be to extract it from one of the fields in the output of your get items. This means you don't have to add an additional action. 

     

    Below is an example of that second approach.

    This expression only works if the get items action returns at least one item. It gets the path property and splits on / to retrieve the list name of the value.

     

     

     

    split(outputs('Get_items')['body/value'][0]['{path}'], '/')[1]

     

     

     

    listname_outputs_fullpath.png

     

  • Power_Automater Profile Picture
    351 on at

    Ok I tried this and it works great so thank you. I am just wondering though if it is possible to get the list name via a Calculated Column in Lists, since then it would automatically be accessible after the Get Items action. I've tried to search for the formula but haven't found anything.

    Or I suppose I could add it manually and then use something below to retrieve it from a filter array (where field_3 is the name of the column with the list name in it):
    body('Filter_array_2')?[0]?['field_3']

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Valantis Profile Picture

Valantis 474

#2
11manish Profile Picture

11manish 268

#3
David_MA Profile Picture

David_MA 243 Super User 2026 Season 1

Last 30 days Overall leaderboard