entity = $endpoint; } /** * @param string $url * @param string $http_method * @return IApiEndpoint */ public function getApiEndpointByUrlAndMethod($url, $http_method) { return $this->entity->Filter(array( array( 'name' => 'route', 'op' => '=', 'value' => $url ), array( 'name' => 'http_method', 'op' => '=', 'value' => $http_method ) ))->firstOrFail(); } }