public function getById($id): Response
    {
        //find the info
        $record = $this->model->findFirst($id);

        if (!is_object($record)) {
            throw new UnprocessableEntityHttpException('Record not found');
        }

        $relationships = false;

        //get relationship
        if ($this->request->hasQuery('relationships')) {
            $relationships = $this->request->getQuery('relationships', 'string');
        }

        $result = !$relationships ? $record->toFullArray() : QueryParserCustomFields::parseRelationShips($relationships, $record);

        return $this->response($result);
    }