Following the docs I've created the following structure:
query local_plugin_get_completions{
local_plugin_get_completions{ id }
}
extend type Query {
local_plugin_get_completions: [local_plugin_get_completions!]!
}
type local_plugin_get_completions{
id: core_id,
}
class get_completions extends \core\webapi\query_resolver {
public static function resolve(array $args, execution_context $ec) {
return [ 'id' => 'test' ];
}
}
When sending the request, I get a 200 response with empty data, no error in the server side. What am I missing here or how shauld I add new queries to the Totara External GraphQL API?