I am trying to access the users from a cloud function and everything works good, but when I add the select attribute to only select couple of fields but I get this error:
{"code":400,"type":"general_argument_invalid","response":{"message":"Invalid queries param: Invalid query method: select","code":400,"type":"general_argument_invalid","version":"1.4.13"}}
this is my code
if (queryStr.lastId) {
log('paginating')
queries.unshift(Query.cursorAfter(decodeURIComponent(queryStr.lastId)))
const response = await users.list([
...queries,
Query.select(['$id', 'name'])
])
return res.send(response)
}
You're trying to get 1 user?
The ID is unique, so I think you should not use list endpoint to get 1 user
Recommended threads
- [SOLVED] curl error Number: 6 — function...
Hello, I invested a lot of time in this error in a fresh install of appwrite 1.8.1 and lasted until fix, this if for helping anyone that can have the same weird...
- general_bad_request when creating accoun...
I have created a new bug request, could anyone have a look - https://github.com/appwrite/appwrite/issues/11908?
- Cannot use custom SMTP for messaging (SM...
Hey there! I'm on Appwrite Self-hosted 1.9.0. I've never used the messaging feature before, always sent emails through functions or a custom backend, but I'v...