/vault/api/v1/user/{user_id}/secrets
Get secrets client owns.
offset
int
Offset where to start fetching the items
limit
int
Number of items to return
Successful response, returns an array of secrets, returns an empty array if no secrets found
{
"count": 123,
"items": [
{
"name": "string",
"data": {},
"read_roles": [
{
"id": "string",
"name": "string",
"deleted": true
}
],
"write_roles": [
{
"id": "string",
"name": "string",
"deleted": true
}
],
"author": "string",
"path": "string",
"updated_by": "string",
"created": "string",
"updated": "string"
}
]
}
/vault/api/v1/user/{user_id}/secrets
Create a secret.
name
string
required
A unique personal secret name.
data
object
required
A secret to be stored.
read_roles
array
List of roles that can read a secret.
id
string
required
Role ID
name
string
Role name, ignored by server in requests.
write_roles
array
List of roles that can replace a secret.
id
string
required
Role ID
name
string
Role name, ignored by server in requests.
owner_id
string
ID of the user who owns this secret.
{
"name": "string",
"data": {},
"read_roles": [
{
"id": "string",
"name": "string"
}
],
"write_roles": [
{
"id": "string",
"name": "string"
}
],
"owner_id": "string"
}
Secret successfully created
{
"name": "string"
}
/vault/api/v1/user/{user_id}/secrets/{name}
Get a secret.
name
string
required
Secret name
user_id
string
required
User ID of the user who owns the secret
Successful response, returns a secret object
{
"name": "string",
"data": {},
"read_roles": [
{
"id": "string",
"name": "string",
"deleted": true
}
],
"write_roles": [
{
"id": "string",
"name": "string",
"deleted": true
}
],
"author": "string",
"path": "string",
"updated_by": "string",
"created": "string",
"updated": "string"
}
/vault/api/v1/user/{user_id}/secrets/{name}
Update a secret.
data
object
Secret to be stored.
read_roles
array
List of roles that can read secret.
id
string
required
Role ID
name
string
Role name, ignored by server in requests.
write_roles
array
List of roles that can replace secret.
id
string
required
Role ID
name
string
Role name, ignored by server in requests.
{
"data": {},
"read_roles": [
{
"id": "string",
"name": "string"
}
],
"write_roles": [
{
"id": "string",
"name": "string"
}
]
}
Secret successfully updated
Empty response
/vault/api/v1/user/{user_id}/secrets/{name}
Delete a secret.
name
string
required
Secret name
user_id
string
required
User ID of the user who owns the secret
Secret successfully deleted
Empty response
Was this page helpful?