Returns an http response object.

def get_result(self):
        """
        Returns an http response object.
        """

        timeout = 60
        if self.method == "GET":
            timeout = 360

        headers = {
            "Authorization": "Bearer " + self.key,
            "content-type": "application/json"
        }
        response = None
        try:
            response = getattr(requests, self.method.lower())(
                self.url,
                headers=headers,
                params=self.data,
                data=self.data,
                timeout=timeout,
            )
            # Return the response.
            return response
        except requests.exceptions.RequestException:
            error = {
                "objeto": "error",
                "tipo": "error_api",
                "codigo_error": "404",
                "mensaje": "conexion...",
                "mensaje_usuario": "¡Error de conexion!",
            }
            return error