For auto generated doc ID’s you need to use a POST, e.g. in curl:
curl -X POST http://localhost:4985/db/ -H "Content-Type: application/json" -d '{"foo":"bar"}'
Response will be similar to:
{"id":"6e785e11db67d86e4a5ea45039fdbf88","ok":true,"rev":"1-cd809becc169215072fd567eebd8b8de"}