Edit or add rows in a table using API

Hi!

I can connect to my app and read rows of a table using the API. I use the url as explained in the documentation and I use the following text as a body of the post:

{
“Action”: “Find”,
“Properties”: {
“Locale”: “en-US”,
“Location”: “47.623098, -122.330184”,
“Timezone”: “Pacific Standard Time”
},
“Rows”:
}

I get as answer some rows:

{
“_RowNumber”: “3”,
“FirstName”: “Phuong”,
“LastName”: “B”,
“Headshot”: “Students_Images/phuong@bricklinholdings.com.Headshot.230628.065144.png”,
“Email”: ,
“Course”: “Algebra 100”,
“_ComputedName”: “Phuong B”,
“Related AttendanceLogs”: “0.710161114481822”
}

I try then to modify a row or to add a row with the following body:

{
“Action”: “Edit”,
“Properties”: {
“Locale”: “en-US”,
“Location”: “47.623098, -122.330184”,
“Timezone”: “Pacific Standard Time”
},
“Rows”: [
“FirstName”: “Peter”,
“LastName”: “AB”,
“Headshot”: “Students_Images/peter@bricklinholdings.com.Headshot.230612.065155.png”,
“Email”: ,
“Course”: “Algebra 90”,
]
}

And the answer I get is: 415 Unsupported media type

I’ve tried different tables, different values, but I haven’t succeeded to modify a row or to add a row, I always get the same error. Is the structure of the body wrong?

Is any of those columns a key column?

1 Like

No. There aren’t key columns