pub const API_KEY_TOML: &str = r#"
[resource]
name = "api_key"
scope = "global"
timestamps = true
# "Api key" is what titleising the name produces, and it is not how anybody
# writes it.
[admin]
label = "API key"
plural = "API keys"
[permissions]
list = "owner"
read = "owner"
create = "authenticated"
update = "private"
delete = "owner"
[fields.name]
type = "string"
[fields.token_hash]
type = "string"
required = true
unique = true
hidden = true
[fields.owner_id]
type = "reference"
references = "user"
required = true
"#;Expand description
Default api_key resource (global). A valid key authenticates as its owner.