read
Read a value from the vault. This can be used to read any value that you have permission to read in this store.
Usage:
read(path, field = NULL, metadata = FALSE)
Arguments:
path
: Path for the secret to read, such as /secret/mysecret
field
: Optional field to read from the secret. Each secret is stored as a key/value set (represented in R as a named list) and this is equivalent to using [[field]]
on the return value. The default, NULL
, returns the full set of values.
metadata
: Logical, indicating if we should return metadata for this secret (lease information etc) as an attribute along with the values itself. Ignored if field
is specified.
write
Write data into the vault. This can be used to write any value that you have permission to write in this store.
Usage:
write(path, data)
Arguments:
path
: Path for the secret to write, such as /secret/mysecret
data
: A named list of values to write into the vault at this path. This replaces any existing values.
list
List data in the vault at a give path. This can be used to list keys, etc (e.g., at /secret
).
Usage:
list(path, full_names = FALSE)
Arguments:
Value:
A character vector (of zero length if no keys are found). Paths that are "directories" (i.e., that contain keys and could themselves be listed) will be returned with a trailing forward slash, e.g. path/
delete
Delete a value from the vault
Usage:
delete(path)
Arguments:
custom_mount
Set up a vault_client_kv1
object at a custom mount. For example, suppose you mounted another copy of the kv1
secret backend at /secret2
you might use kv <- vault$secrets$kv1$custom_mount("/secret2")
- this pattern is repeated for other secret and authentication backends.
Usage:
custom_mount(mount)
Arguments: