Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/.net/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
为什么我的GraphQL链接在WordPress中显示查询错误_Wordpress_Graphql_Wp Graphql - Fatal编程技术网

为什么我的GraphQL链接在WordPress中显示查询错误

为什么我的GraphQL链接在WordPress中显示查询错误,wordpress,graphql,wp-graphql,Wordpress,Graphql,Wp Graphql,我在wordpress仪表板上安装了WPGraphQL插件,但我尝试通过mysite/graphql访问它 我犯了这个错误 {“errors”:[{“message”:“GraphQL请求必须至少包括以下两个参数中的一个:\“query\”或\“queryId\”,“extensions”:{“category”:“Request”}}],“extensions”:{“debug”:[]}} 原因可能是什么?您必须传递一个查询参数,例如:http://localhost:8000/graphql

我在wordpress仪表板上安装了WPGraphQL插件,但我尝试通过mysite/graphql访问它

我犯了这个错误

{“errors”:[{“message”:“GraphQL请求必须至少包括以下两个参数中的一个:\“query\”或\“queryId\”,“extensions”:{“category”:“Request”}}],“extensions”:{“debug”:[]}}


原因可能是什么?

您必须传递一个查询参数,例如:http://localhost:8000/graphql?query={user(id:1){email}}您需要graphql游乐场,然后安装游乐场软件包,然后通过以下链接访问游乐场:http://localhost:8000/graphql-操场

正如其他人所说,您需要一个查询


当扩展被激活时,它充当任何API。它会提供你所要求的数据,而不是引导你访问某个网站。您可以访问GraphiQL IDE以获得查询的可视化表示。

您期望的是什么?请求中没有查询,标准错误响应请解释更多这是一个graphql服务器,它需要特定的查询。。。期望什么-解释更多?如何添加查询?我正在尝试将next.js与wordpress连接