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

Community site session details

Session Id : KWE6uZCH3/1I4HzZF4Wpm+
Power Automate - Building Flows
Answered

Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

Like (0) ShareShare
ReportReport
Posted on 23 Jun 2021 12:13:37 by 1,091

Hello everyone,

I have a list whose name is "SOX - PO without PR (YPONR) Tasks". I am trying to create a task within this list using Send an HTTP Request to SharePoint action as I have few hyperlinks to populate. I am confused how to specify the name of the list in the body of the action

 __metadata": { "type": "ListNameListItem" } 

I know spaces can be replaced with _x0020_ but not sure of special characters like "-" (hyphen), "(" and ")". How do I encode these here and what should they be replaced with? I couldn't find any documentation regarding this. We don't want to change the list name.

  • Expiscornovus Profile Picture
    32,177 Most Valuable Professional on 18 Aug 2023 at 16:17:33
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Hi @MalekFCH,

     

    As far as I can tell that character is just removed from the ListItemEntityTypeFullName value. 

     

    Below is an example

    It looks like a list Title like °Amsterdam° becomes SP.Data.AmsterdamListItem

     

    listitementitytypefullname_example.png

  • MalekFCH Profile Picture
    7 on 18 Aug 2023 at 14:41:07
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Hello Paulie,

     

    this link is just amazing but i'am looking for this specific caracter : '°' and i can't find it 

    do you have any idea about how can i replace it ?

  • Expiscornovus Profile Picture
    32,177 Most Valuable Professional on 24 Jun 2021 at 10:18:26
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Hi @RameshMukka,

     

    Hope you guys don't mind that I bud in.

     

    You can also retrieve the correct value for the type field by retrieving the ListItemEntityTypeFullName value via an additional HTTP request action. Saves you a bit of manual encoding time 😉

     

    Below is an example of such an approach.

     

    1. First collect the ListItemEntityTypeFullName value of your SharePoint List. Replace/set the ListName variable by the name of your current list name.

    getlistentitytypefullname.png

    2. Use the following Body to create a new item. You can use an expression to get to retrieve the correct entitytypefullname.

     

     

     

    {
    	"__metadata": {
     "type": "@{outputs('Send_an_HTTP_request_to_SharePoint')?['body/ListItemEntityTypeFullName']}"
     },
     "Title": "Testing Promoted Links",
     "LinkLocation": {
     "Description": "Microsoft",
     "Url": "https://www.microsoft.com"
     }
    }

     

     

     

     createpromotedlink.png

  • Paulie78 Profile Picture
    8,416 Moderator on 24 Jun 2021 at 06:50:20
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Well done @RameshMukka 

  • Paulie78 Profile Picture
    8,416 Moderator on 24 Jun 2021 at 06:48:47
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    I think the list name would be:

    SOX_x0020__x0020_PO_x0020_without_x0020_PR_x0020_YPONR_x0020_Tasks

  • rameshmukka Profile Picture
    1,091 on 24 Jun 2021 at 06:43:26
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Hey @Paulie78 

    I just figured it out. I replaced all %20 with _x0020_ and it worked. You blog posts came to great rescue. Thank you so much.

  • rameshmukka Profile Picture
    1,091 on 24 Jun 2021 at 06:35:46
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Here is it 

     

    /sites/rameshtest/Lists/SOX%20%20PO%20without%20PR%20YPONR%20Tasks/AllItems.aspx

     

  • Paulie78 Profile Picture
    8,416 Moderator on 24 Jun 2021 at 06:26:01
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    Please go to the list in your browser and copy and paste the URL here. Then we can figure out what the list name should be.

  • rameshmukka Profile Picture
    1,091 on 24 Jun 2021 at 06:17:29
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    @Paulie78 

    You did a great job in both the posts. I bookmarked them for future use. I was waiting such content since long time. Your form generated me blow json but it fails somehow. I tested with simple list called "TestList" and it works fine. Here is the screenshots

     

     

    {
    	"__metadata": {
    		"type": "SP.Data.SOX_x0020_-_x0020_PO_x0020_without_x0020_PR_x0020__x0028_YPONR_x0029__x0020_TasksListItem"
    	},
    	"RelatedItems": {
    		"Description": "Microsoft",
    		"Url": "https://www.microsoft.com"
    	}
    }

     

    RameshMukka_0-1624515374103.png

  • Verified answer
    Paulie78 Profile Picture
    8,416 Moderator on 23 Jun 2021 at 12:25:15
    Re: Replace special characters of list name to make it compatible to use in Send HTTP Request to SharePoint action

    This one would also be useful to you:

    https://www.tachytelic.net/2021/03/update-hyperlink-column-sharepoint-power-automate/

     

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 2

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 2

Loading complete