Skip to main content

remotestorage

4 configuration options · available in Rust

Quick start
use opendal::Operator;

let operator = Operator::via_iter("remotestorage", [
("endpoint".to_string(), "https://storage.example.com/alice".to_string()),
])?;
All configuration options (copy & trim)
Full reference
use opendal::Operator;

let operator = Operator::via_iter("remotestorage", [
// Storage root URL of the user's account, as published in the
// `href` of the user's WebFinger `remotestorage` link.
//
// For example: `https://storage.example.com/alice`
//
// This field is required.
("endpoint".to_string(), "https://storage.example.com/alice".to_string()),

// OAuth bearer token granted by the user's storage server.
// ("token".to_string(), "...".to_string()),

// Root path inside the storage, for example `/documents/`.
// ("root".to_string(), "...".to_string()),

// Origin of the application the token was granted to, sent as the
// `Origin` header on every request.
//
// Set this when the server binds tokens to the origin of the
// application's `redirect_uri`, as armadietto does. For example:
// `https://app.example.com`
// ("origin".to_string(), "...".to_string()),
])?;

Every option is passed as a string key; OpenDAL parses it into the right type. For a map option, pass a string containing a JSON object whose values are strings, such as {"key":"value"}. Some services may require building the binding with the matching services-* feature enabled.

Configuration reference​

General4
KeyTypeRequiredDescription
endpointe.g. https://storage.example.com/alicestringyesStorage root URL of the user's account, as published in the href of the user's WebFinger remotestorage link. For example: https://storage.example.com/alice This field is required.
tokenstringnoOAuth bearer token granted by the user's storage server.
rootstringnoRoot path inside the storage, for example /documents/.
originstringnoOrigin of the application the token was granted to, sent as the Origin header on every request. Set this when the server binds tokens to the origin of the application's redirect_uri, as armadietto does. For example: https://app.example.com

Entries reflect native capabilities declared by the remotestorage backend. Language bindings expose different subsets of options and may simulate operations client-side, and protocol-compatible endpoints may support only a subset of the declared features.

Stat1
CapabilitySupportDescription
stat NativeIndicates if the operator supports metadata retrieval operations.
Read3
CapabilitySupportDescription
read NativeIndicates if the operator supports read operations.
read_with_if_none_match NativeIndicates if conditional read operations using If-None-Match are supported.
read_with_suffix NativeIndicates if suffix read operations are supported.
List1
CapabilitySupportDescription
list NativeIndicates if list operations are supported.
Other1
CapabilitySupportDescription
shared NativeIndicate if the operator supports shared access.