You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by "nickva (via GitHub)" <gi...@apache.org> on 2023/06/20 02:33:38 UTC

[GitHub] [couchdb] nickva commented on issue #4649: Inaccurately Named Fields Returned In Response To Document Creation

nickva commented on issue #4649:
URL: https://github.com/apache/couchdb/issues/4649#issuecomment-1598028192

   The response of a `PUT $db/$docid` or `POST $db` is not really a document, it's a just a json grouping of fields.
   
   The convention is used in the [_bulk_get](https://docs.couchdb.org/en/stable/api/database/bulk-api.html#db-bulk-get) endpoint as well: since we're not sending document bodies we use `id` and `rev` as is, without the `_` prefix.
   
   We can argue that it might have been better to use `_id` and `_rev` always but it seems a small enough difference that it's not worth breaking backward compatibility over.
   
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@couchdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org