Skip to content
Init is coming / May 19 - 23
Back

Appwrite MCP queries

  • 0
  • Tools
  • REST API
hen
12 May, 2025, 16:42

how to user queries with appwrite mcp without getting Appwrite Error: Invalid query: Syntax error?

database_list_documents function with such query:

TypeScript
{
  "database_id": "database_id",
  "collection_id": "collection_id",
  "queries": [
    "equal(\"user\",\"user_id\")",
    "equal(\"achievement\",\"achievement_id\")",
    "limit(1)"
  ]
}

returns error

TL;DR
Make sure to include the method and attribute parameters when using queries in Appwrite MCP. Check the correct syntax here: https://appwrite.io/docs/apis/rest#queries-string-format. For the `database_list_documents` function, use a query in the correct format like this: ``` { "database_id": "database_id", "collection_id": "collection_id", "queries": [ "equal('user','user_id')", "equal('achievement','achievement_id')", "limit=1" ] } ```
D5
12 May, 2025, 16:51

You need to include the method and attribute parameters. Check: https://appwrite.io/docs/apis/rest#queries-string-format

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more