cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
BrittanyR
Helper III
Helper III

The property '__metadata' does not exist on type.. Update SharePoint Item.

I am trying to update a SharePoint item from Power Automate but it's not working for me. I read the many posts about examples from SharePoint REST APIs and other people issues on the same subject but can't seem to be able to solve my issue. The body for my http request is as the following: 

 

 

{
"__metadata": {
"type": "SP.Data.Teams_x0020_NamesListItem"
},
"TeamSiteUrl": {
    "__metadata": {
        "type": "SP.FieldUrlValue"
    },
    "Description": "Visit Site",
    "Url": "https://mytenant.sharepoint.com/sites/@{triggerBody()['Createateam_TeamName']}"
    }
}

 

 

Headers look like this: 
Accept: application/json;odata=verbose

IF-MATCH: *

 

and the url is like the following: 

_api/web/lists/getByTitle('Teams Names')/items(@{triggerBody()['Updateitem_Id']})

 

 

However am getting this error: 
The property '__metadata' does not exist on type 'SP.Data.Teams_x0020_NamesListItem'. Make sure to only use property names that are defined by the type.

Any idea would help. 

1 ACCEPTED SOLUTION

Accepted Solutions
bcameron1231
New Member

Sounds like you are making a POST...? Add the X-HTTP-METHOD header with the value of "MERGE" to your request.

View solution in original post

2 REPLIES 2
BrittanyR
Helper III
Helper III

Anyone has any idea about this?

bcameron1231
New Member

Sounds like you are making a POST...? Add the X-HTTP-METHOD header with the value of "MERGE" to your request.

Helpful resources

Announcements
 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (1,878)