PrivX external secrets

get/vault/api/v1/secrets

List secrets

Get secrets client has access.

offsetint

Collection query offset

Default
0
Min
0
limitint

Maximum number of collection items to return

Default
100
Max
100

Responses

Response examples

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"
    }
  ]
}
post/vault/api/v1/secrets

Create a secret

Create a secret.

namestring

required

dataobject

Secret to be stored.

read_rolesarray

List of roles that can read secret.

idstring

required

Role ID

namestring

Role name, ignored by server in requests.

write_rolesarray

List of roles that can replace secret.

idstring

required

Role ID

namestring

Role name, ignored by server in requests.

Responses

Request examples

{
  "name": "string",
  "data": {},
  "read_roles": [
    {
      "id": "string",
      "name": "string"
    }
  ],
  "write_roles": [
    {
      "id": "string",
      "name": "string"
    }
  ]
}

Response examples

Secret successfully created

{
  "name": "string"
}
get/vault/api/v1/secrets/{name}

Get a secret

Get a secret by name.

namestring

required

Secret name

Responses

Response examples

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"
}
put/vault/api/v1/secrets/{name}

Update a secret

Update a secret by name.

dataobject

Secret to be stored.

read_rolesarray

List of roles that can read secret.

idstring

required

Role ID

namestring

Role name, ignored by server in requests.

write_rolesarray

List of roles that can replace secret.

idstring

required

Role ID

namestring

Role name, ignored by server in requests.

Responses

Request examples

{
  "data": {},
  "read_roles": [
    {
      "id": "string",
      "name": "string"
    }
  ],
  "write_roles": [
    {
      "id": "string",
      "name": "string"
    }
  ]
}

Response examples

Secret successfully updated

Empty response

delete/vault/api/v1/secrets/{name}

Delete a secret

Delete a secret by name.

namestring

required

Secret name

Responses

Response examples

Secret successfully deleted

Empty response

Was this page helpful?