7 configuration options · available in Rust, Python
use opendal::Operator;
let op = Operator::via_iter("d1", [
])?;
use opendal::Operator;
let op = Operator::via_iter("d1", [
// Set the token of cloudflare api.
// ("token".to_string(), "...".to_string()),
// Set the account id of cloudflare api.
// ("account_id".to_string(), "...".to_string()),
// Set the database id of cloudflare api.
// ("database_id".to_string(), "...".to_string()),
// Set the working directory of OpenDAL.
// ("root".to_string(), "...".to_string()),
// Set the table of D1 Database.
// ("table".to_string(), "...".to_string()),
// Set the key field of D1 Database.
// ("key_field".to_string(), "...".to_string()),
// Set the value field of D1 Database.
// ("value_field".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 |
|---|---|---|---|
token | string | no | Set the token of cloudflare api. |
account_id | string | no | Set the account id of cloudflare api. |
database_id | string | no | Set the database id of cloudflare api. |
root | string | no | Set the working directory of OpenDAL. |
table | string | no | Set the table of D1 Database. |
key_field | string | no | Set the key field of D1 Database. |
value_field | string | no | Set the value field of D1 Database. |