Your URL is referring to the _default collection implicitly by only specifying the database name (/gh-ucil-test/)
You need to specify which scope/collection you want to retrieve your document from in the Sync Gateway API route. E.g: /gh-ucil-test._default.dbc_task/
You can find this info under the “keyspace” description in the API docs:
How can I use the changes feed so that all documents appear in the feed, irrespective of changes? How do I call the changes feed for all collections?
Question 2:
I am trying to fetch documents based on the channels using _changes?filter=sync_gateway/bychannel&channels=*&collection=_default.dbc_user,_default.dbc_locations, but nothing is appearing. i have channles update in the couchbase and used below config to create a sg user
curl --location -g --request POST 'http://localhost:4985/test/_user/' --header 'Content-Type: application/json' --header "Authorization: Basic $DIGEST" --data-raw '{
"name": "username",
"password": "passowrd",
"admin_channels": ["*"]
}’
``
Do i need to add anythinng in the create user config.
Use the since=0 parameter (which is the default value) to fetch all current document revisions. If you want document contents included in the feed, there’s also include_docs=true.
You cannot get a changes feed for multiple collections. Do one at a time programatically.
collection is not a valid query parameter. See the link I left above earlier for the changes API spec. You must specify collection with the keyspace in the path as described.
You need to grant the user access to the “config” channel, or all channels inside the dbc_util_operator_navigations collection.
Channels are collection-specific. The GET user response snippet you showed is showing the user only has access to the ! channel in both collections, and so would only see documents routed to that public channel.