Create or Update in REST

From my (albeit limited) understanding of REST, PUT seems to be capable of creating OR updating:

However I’m running into errors when trying to create a record with PUT. e.g.: "Record with identifier ‘$$identifier$$’ not found.

I would ideally like to have users only have write (not read) access so would love the ability to create and update in the same command without having to poll the server to see if the record is already there.

I’ve never fully understood the depths of REST however. Is there a way to create or update in the same action?

1 Like

I am also looking for this feature. Will this feature be available in v2.0?

PUT may create or update according to HTTP spec, but that’s not necessarily RESTful. That is, you can’t draw one-to-one comparison between HTTP spec and REST API methods. In the DreamFactory REST implementation, PUT will always attempt to find the record to update. Therefore you must use POST for creation.