Bubble Data API for User object!

I have been using Bubble Data API extensively for backend integration. I use an admin token (not user token) and I successfully read, write and create 20+ objects of my application with no issues (field naming is painful to get right, but I managed to get it right!)

When it comes to User object, everything starts breaking!

The API returns an authentication field which is a strange dictionary that has “email” in there, but if I send any such field Bubble says the field doesn’t exist. Same as a field named “user_signed_up”. So After reading a User and writing back via HTTP PUT, I dropped those two fields. Now I am getting this error:

HTTP/1.1 500 Internal Server Error
Response: {“error_class”:“UnexpectedError”,“args”:{“code”:“1760598621233x966640585588648400”},“message”:“Sorry, we ran into a temporary bug and can’t complete your request. We’ll fix it as soon as we can; please try again in a bit!”}

What is going on? What is it that I am missing?

For users, there’s a lot of “hidden” fields that you don’t see. There’s also some fields that you can’t edit.

Can you share your JSON that you are sending?

I managed to figure out the issue!! Because of all those hidden fields, PUT doesn’t work well and instead I had to use PATCH and only send the field I am changing. Somehow, when I did the same with PUT, it tries to reapply all of the values but some fails. Technically PATCH is the better way to go but the way Bubble manages PUT is buggy and caused this issue.