-
Notifications
You must be signed in to change notification settings - Fork 1.1k
DOCUMENTATION - Creating a new user method HTTP method is wrong #4642
Copy link
Copy link
Closed
Labels
Description
Hello,
I've found an error on the documentation section 1.5.2.2. Creating a New User.
It is said "Creating a new user is a very trivial operation. You just need to do a PUT request with the user’s data to CouchDB"
This is wrong, since the PUT method will try to create the _users database. The correct HTTP method is POST.
Please correct this typo in the documentation.
As a suggestion, it would help to explicitly include in this documentation section that this call must be done with an admin user. Consider including in the curl example something like this:
curl -X **POST** <admin_user>:<admin_password>@localhost:5984/_users/org.couchdb.user:jan \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{"name": "jan", "password": "apple", "roles": [], "type": "user"}'
Reactions are currently unavailable