public function getEndpointResult($method, $endpointName, Request $request)
    {
        $methodName = $this->parseEndpointName($method, $endpointName);
        if (!$this->reflection->hasMethod($methodName)) {
            throw new \RuntimeException("{$this->reflection->getName()}::{$methodName} does not exist");
        }

        $reflectionMethod = $this->reflection->getMethod($methodName);
        return $reflectionMethod->invokeArgs(
            $this->controller,
            $this->mapRequestToArguments($reflectionMethod, $request)
        );
    }