def from_url(cls, url: str) -> OpenAPISpec:
            """Get an OpenAPI spec from a URL."""
            response = requests.get(url)
            return cls.from_text(response.text)
        @property
        def base_url(self) -> str:
            """Get the base url."""
            return self.servers[0].url
[docs]        def get_methods_for_path(self, path: str) -> List[str]:
            """Return a list of valid methods for the specified path."""
            from openapi_schema_pydantic import Operation
            path_item = self._get_path_strict(path)
            results = []
            for method in HTTPVerb:
                operation = getattr(path_item, method.value, None)
                if isinstance(operation, Operation):
                    results.append(method.value)
            return results
[docs]        def get_parameters_for_path(self, path: str) -> List[Parameter]:
            from openapi_schema_pydantic import Reference
            path_item = self._get_path_strict(path)
            parameters = []
            if not path_item.parameters:
                return []
            for parameter in path_item.parameters:
                if isinstance(parameter, Reference):
                    parameter = self._get_root_referenced_parameter(parameter)
                parameters.append(parameter)
            return parameters
[docs]        def get_operation(self, path: str, method: str) -> Operation:
            """Get the operation object for a given path and HTTP method."""
            from openapi_schema_pydantic import Operation
            path_item = self._get_path_strict(path)
            operation_obj = getattr(path_item, method, None)
            if not isinstance(operation_obj, Operation):
                raise ValueError(f"No {method} method found for {path}")
            return operation_obj