Vaults API

Create a Vault

https://d33wubrfki0l68.cloudfront.net/46256db48654ea43d1fd9377023f4d876582d839/ab631/_images/plans-available-all.png
POST /v1/vaults

Create a Vault. NAME must be unique for the account.

Form Parameters:
 
  • name – string(req’d) - Vault name
Request Headers:
 
Status Codes:

Example Request

curl https://api.truevault.com/v1/vaults \
    -X POST \
    -u [API_KEY | ACCESS_TOKEN]: \
    -d "name=test_vault"

Example Response

{
    "result": "success",
    "transaction_id": "00000000-0000-0000-0000-000000000000",
    "vault": {
        "id": "00000000-0000-0000-0000-000000000000",
        "name": "test_vault"
    }
}

Read a Vault

https://d33wubrfki0l68.cloudfront.net/46256db48654ea43d1fd9377023f4d876582d839/ab631/_images/plans-available-all.png
GET /v1/vaults/(string: vault_id)

Retrieve a Vault by ID. Returns the name of the Vault.

Parameters:
  • vault_id – string(req’d)
Request Headers:
 
Status Codes:

Example Request

curl https://api.truevault.com/v1/vaults/00000000-0000-0000-0000-000000000000 \
    -X GET \
    -u [API_KEY | ACCESS_TOKEN]:

Example Response

{
    "result": "success",
    "transaction_id": "00000000-0000-0000-0000-000000000000",
    "vault": {
        "id": "00000000-0000-0000-0000-000000000000",
        "name": "test_vault"
    }
}

List all Vaults

https://d33wubrfki0l68.cloudfront.net/46256db48654ea43d1fd9377023f4d876582d839/ab631/_images/plans-available-all.png
GET /v1/vaults

Retrieves all Vaults authorized for the User.

Query Parameters:
 
  • page – int(optional, default: 1) - page number in paginated response
  • per_page – int(optional, default: 100) - results per page in paginated response
Request Headers:
 
Status Codes:

Example Request

curl https://api.truevault.com/v1/vaults?page=3&per_page=15 \
    -X GET \
    -u [API_KEY | ACCESS_TOKEN]:

Example Response

{
    "result": "success",
    "transaction_id": "00000000-0000-0000-0000-000000000000",
    "vaults": [
        {
            "id": "00000000-0000-0000-0000-000000000000",
            "name": "test_vault_0"
        },
        {
            "id": "00000000-0000-0000-0000-000000000000",
            "name": "test_vault_1"
        }
    ]
}

Update a Vault

https://d33wubrfki0l68.cloudfront.net/46256db48654ea43d1fd9377023f4d876582d839/ab631/_images/plans-available-all.png
PUT /v1/vaults/(string: vault_id)

Updates a Vault.

Parameters:
  • vault_id – string(req’d)
Form Parameters:
 
  • name – string(optional) - new Vault name
Request Headers:
 
Status Codes:

Example Request

curl https://api.truevault.com/v1/vaults/00000000-0000-0000-0000-000000000000 \
    -X PUT \
    -u [API_KEY | ACCESS_TOKEN]: \
    -d "name=test_vault_0"

Example Response

{
    "result": "success",
    "transaction_id": "00000000-0000-0000-0000-000000000000",
    "vault": {
        "id": "00000000-0000-0000-0000-000000000000",
        "name": "test_vault_0"
    }
}

Delete a Vault

https://d33wubrfki0l68.cloudfront.net/46256db48654ea43d1fd9377023f4d876582d839/ab631/_images/plans-available-all.png
DELETE /v1/vaults/(string: vault_id)

Deletes an empty Vault by ID.

Parameters:
  • vault_id – string(req’d)
Request Headers:
 
Status Codes:

Example Request

curl https://api.truevault.com/v1/vaults/00000000-0000-0000-0000-000000000000 \
    -X DELETE \
    -u [API_KEY | ACCESS_TOKEN]:

Example Response

{
    "result": "success",
    "transaction_id": "00000000-0000-0000-0000-000000000000",
    "vault": {
        "id": "00000000-0000-0000-0000-000000000000",
        "name": "test_vault_0"
    }
}