![]() InsufficientStorage ( path : str ) #Įrror when the resource does not exist on the server. Instantiate exception with the failed response. HTTPError ( response : HTTPResponse ) #Ĭustom Exception for our HTTPStatusError. Raised when the operation was forbidden (got 403). Mostly used for detecting support for Accept-Ranges as ownCloud/NextCloudĭon’t advertise support for it in GET requests. FeatureDetection ( options_response : Optional = None ) # Upload file from file object to given path. upload_fileobj ( file_obj : BinaryIO, to_path : str, overwrite : bool = False, callback : Optional, Any ] ] = None, chunk_size : Optional = None, size : Optional = None ) → None # Upload file from local path to a given remote path. upload_file ( from_path : PathLike, to_path : str, overwrite : bool = False, chunk_size : Optional = None, callback : Optional, Any ] ] = None ) → None # Setting additional property to a resource. Sends request to a server with given method and path.Īlso checks for Multistatus response and other http errors. request ( method : str, path : str, ** kwargs : Any ) → HTTPResponse # Returns properties of the specific resource by propfind request. propfind ( path : str, data : Optional = None, headers : Optional = None, follow_redirects : bool = False ) → MultiStatusResponse # Returns features detected in the webdav server. open ( path : str, mode : str = 'r', encoding : Optional = None, chunk_size : Optional = None ) → Iterator ] # Move resource to a new destination (with or without overwriting). move ( from_path : str, to_path : str, overwrite : bool = False ) → None # Returns getlastmodified of the resource with the given path. (non-collection), ls will return the file entry/details.Ĭreate a collection. Parameters :ĭetail – If detail=True, additional information is returnedĪllow_listing_resource – If True and path is a resource ls ( path : str, detail : bool = True, allow_listing_resource : bool = True ) → List ] ] # Join resource path with base url of the webdav server. join_url ( path : str, add_trailing_slash : bool = False ) → URL # isfile ( path : str ) → bool #Ĭhecks whether the resource with the given path is a file. isdir ( path : str ) → bool #Ĭhecks whether the resource with the given path is a directory. Returns information about the path itself. Returns properties of a resource by doing a propfind request.Ĭan also selectively request the properties by passing name or data. (for now restricted to a single string with the given namespace) get_props ( path : str, name : Optional = None, namespace : Optional = None, data : Optional = None ) → DAVProperties # Returns appropriate property from the propfind response. get_property ( path : str, name : str, namespace : Optional = None ) → Any # exists ( path : str ) → bool #Ĭhecks whether the resource with the given path exists or not. Returns etag of the resource with the given path. Write stream from path to given file object. download_fileobj ( from_path : str, file_obj : BinaryIO, callback : Optional, Any ] ] = None, chunk_size : Optional = None ) → None # download_file ( from_path : str, to_path : PathLike, chunk_size : Optional = None, callback : Optional, Any ] ] = None ) → None #ĭownload file from remote path to local path. property detected_features : FeatureDetection #įeature detection for the server. Returns creationdate of the resource with the given path. copy ( from_path : str, to_path : str, depth : Union = 'infinity', overwrite : bool = False ) → None #Ĭopy resource. Returns content type of the resource with the given path. Returns content-length of the resource with the given path. content_length ( path : str ) → Optional # Returns content language of the resource with the given path. Trust_env – Enables or disables usage of environment variablesĬontent_language ( path : str ) → Optional # Max_redirects – The maximum number of redirect responses that Timeout – The timeout configuration to use when sending requests Proxies – A dictionary mapping proxy keys to proxy URLs ![]() Or a three-tuple of (certificate file, key file, password). Or two-tuple of (certificate file, key file), SSL certificates used to verify the identity of requestedĬert – An SSL certificate used by the requested host toĮither a path to an SSL certificate file, of Cookie items to include when sending requests of HTTP headers to include when sending requestsĬookies – Dict. Some well-known errors are handled andĪll of the following keyword arguments are passed along to the Retry – disable or enable retry on client. (when extending, it is expected to have implemented additional Http_client – http client to use instead, useful in mocking
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |