4 configuration options · available in Rust, Python
use opendal::Operator;
let op = Operator::via_iter("github", [
("owner".to_string(), "...".to_string()),
("repo".to_string(), "...".to_string()),
])?;
use opendal::Operator;
let op = Operator::via_iter("github", [
// root of this backend.
//
// All operations will happen under this root.
// ("root".to_string(), "...".to_string()),
// GitHub access_token.
//
// optional.
// If not provided, the backend will only support read operations for public repositories.
// And rate limit will be limited to 60 requests per hour.
// ("token".to_string(), "...".to_string()),
// GitHub repo owner.
//
// required.
("owner".to_string(), "...".to_string()),
// GitHub repo name.
//
// required.
("repo".to_string(), "...".to_string()),
])?;
Every option is passed as a string key; OpenDAL parses it into the right type. Some services may require building the binding with the matching services-* feature enabled.
| Key | Type | Required | Description |
|---|---|---|---|
root | string | no | root of this backend. All operations will happen under this root. |
token | string | no | GitHub access_token. optional. If not provided, the backend will only support read operations for public repositories. And rate limit will be limited to 60 requests per hour. |
owner | string | yes | GitHub repo owner. required. |
repo | string | yes | GitHub repo name. required. |