NAV Navigation
JavaScript Shell

Unbound CASP API v1.0.2001

Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

Unbound’s Crypto Asset Security Platform ("CASP") provides the advanced technology and the architecture to secure crypto asset transactions. The crypto asset solution contains the CASP service and different end points (humans or BOTs).

CASP provides the framework to create Accounts, which hold multiple Vaults where secrets are stored. Access control is managed by the Quorum Policy for all of the Participants.

For information about using these APIs, see the Unbound CASP Developers Guide, or the API references:

For more information about CASP, see:

For more information about the BIP standards, see:

Email: Unbound Tech Support Web: Unbound Tech Support

General Status

Get CASP service status

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/status',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/status \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/status

Verifies that the service is healthy and operational

Parameters

Name In Type Required Description
withDetails query boolean false Include system details

Example responses

200 Response

{
  "version": "string",
  "instanceId": "string",
  "ukc": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  },
  "db": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string",
    "schemaVersion": "string"
  },
  "nativeCrypto": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  },
  "fcm": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  }
}

Responses

Status Meaning Description Schema
200 OK OK Inline
500 Internal Server Error Get status failed, the service is not operational Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» version string true none none
» instanceId string true none none
» ukc object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» db object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
»» schemaVersion string false none CASP schema version
» nativeCrypto object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» fcm object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Reload CASP configuration

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/reloadconfig',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/reloadconfig \
  -H 'Accept: application/json'

POST /casp/api/v1.0/mng/reloadconfig

Read "casp.conf" file and reload configuration

Example responses

200 Response

{
  "version": "string",
  "instanceId": "string",
  "ukc": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  },
  "db": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string",
    "schemaVersion": "string"
  },
  "nativeCrypto": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  },
  "fcm": {
    "healthy": true,
    "errorMessage": "string",
    "version": "string"
  }
}

Responses

Status Meaning Description Schema
200 OK OK Inline
429 Too Many Requests Too many requests. Only one request every 5 minutes is allowed. Inline
500 Internal Server Error Reload configuration failed. The service is not operational. Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» version string true none none
» instanceId string true none none
» ukc object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» db object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
»» schemaVersion string false none CASP schema version
» nativeCrypto object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» fcm object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version

Status Code 429

Name Type Required Restrictions Description
» version string true none none
» instanceId string true none none
» ukc object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» db object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
»» schemaVersion string false none CASP schema version
» nativeCrypto object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version
» fcm object true none none
»» healthy boolean true none Is entity healthy
»» errorMessage string false none Error message in case entity is not healthy
»» version string false none Entity version

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Transaction formats

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/transactionFormats',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/transactionFormats \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/transactionFormats

List available transaction formats that CASP can parse.

Example responses

200 Response

{
  "formats": [
    "string"
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» formats [string] true none The transaction formats the CASP server supports

Authentication

Refer to the Authentication section in the Unbound CASP Developers Guide

List API Keys

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/apikeys',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/auth/apikeys \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/auth/apikeys

List API Keys for CASP service

Example responses

200 Response

[
  {
    "clientId": "string",
    "tokenType": "BEARER",
    "expiry_in": 0,
    "scope": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error Internal error Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» clientId string true none API key client_id
» tokenType string true none API key token type
» expiry_in integer(int64) true none API key expiry in
» scope string true none API key scope

Enumerated Values

Property Value
tokenType BEARER

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Create API Key

Code samples

const inputBody = '{
  "client_id": "string",
  "client_role": "Super_User",
  "scope": "string",
  "grant_type": "client_credentials",
  "password": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/apikeys',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/apikeys \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/auth/apikeys

Create API Key for CASP service

Body parameter

{
  "client_id": "string",
  "client_role": "Super_User",
  "scope": "string",
  "grant_type": "client_credentials",
  "password": "string"
}

Parameters

Name In Type Required Description
body body object true Create API key request
» client_id body string true Owner client ID auth token will be issued for
» client_role body string true Auth token owner role.
» scope body string true Auth token scope. Value MUST be set to "/mng"
» grant_type body string true Request's grant type
» password body string true Auth token owner password

Enumerated Values

Parameter Value
» client_role Super_User
» client_role Security_Officer
» client_role Trader
» grant_type client_credentials

Example responses

201 Response

{
  "access_token": "string",
  "token_type": "string",
  "expires_in": 0,
  "scope": "string"
}

Responses

Status Meaning Description Schema
201 Created API key created Inline
401 Unauthorized Unauthorized: Authentication data is invalid Inline
409 Conflict API key cannot be generated Inline
500 Internal Server Error Create API key failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» access_token string true none Oauth Token for CASP service
» token_type string false none Oauth Token type
» expires_in integer(int64) false none Expiration in seconds
» scope string false none Oauth token scope

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Revoke an API key

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/apikeys/{client_id}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/auth/apikeys/{client_id} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/auth/apikeys/{client_id}

Revoke an API key

Parameters

Name In Type Required Description
client_id path string true Client_id

Example responses

400 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK An API key was successfully removed None
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error API key removal failed Inline

Response Schema

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get access and refresh token

Code samples

const inputBody = '{
  "grant_type": "password",
  "username": "string",
  "client_id": "string",
  "password": "string",
  "refreshtoken": "string",
  "refresh_token": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/auth/token',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/token \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /casp/api/v1.0/mng/auth/token

Get access token for CASP service

Body parameter

{
  "grant_type": "password",
  "username": "string",
  "client_id": "string",
  "password": "string",
  "refreshtoken": "string",
  "refresh_token": "string"
}

Parameters

Name In Type Required Description
body body object true Get oauth tokens request
» grant_type body string true Request's grant type
» username body string false none
» client_id body string false none
» password body string false password
» refreshtoken body string false none
» refresh_token body string false refresh token

Enumerated Values

Parameter Value
» grant_type password
» grant_type refresh_token

Example responses

201 Response

{
  "access_token": "string",
  "token_type": "string",
  "expires_in": 0,
  "scope": "string",
  "refresh_token": "string"
}

Responses

Status Meaning Description Schema
201 Created Access and refresh tokens created Inline
400 Bad Request Bad request Inline
401 Unauthorized Unauthorized: Authentication data is invalid Inline
409 Conflict Auth tokens cannot be generated Inline
500 Internal Server Error Get OAuth tokens failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» access_token string true none Oauth Token for CASP service
» token_type string false none Oauth Token type
» expires_in integer(int64) false none Expiration in seconds
» scope string false none Oauth token scope
» refresh_token string true none Oauth Token for CASP service

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Revoke an access token

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/token/{token_owner}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/auth/token/{token_owner} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/auth/token/{token_owner}

Revoke an access token

Parameters

Name In Type Required Description
token_owner path string true token_owner

Example responses

400 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK An access token was successfully removed None
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error An access token removal failed Inline

Response Schema

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get password complexity

Code samples


fetch('/casp/api/v1.0/mng/errors/password_quality_error',
{
  method: 'GET'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/errors/password_quality_error

GET /casp/api/v1.0/mng/errors/password_quality_error

Get password complexity

Parameters

Name In Type Required Description
format query string false Response format

Responses

Status Meaning Description Schema
200 OK OK None

Get access and refresh tokens (deprecated)

Code samples

const inputBody = '{
  "grant_type": "password",
  "username": "string",
  "client_id": "string",
  "password": "string",
  "refreshtoken": "string",
  "refresh_token": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/auth/tokens',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/tokens \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /casp/api/v1.0/mng/auth/tokens

Get access token for CASP service

Body parameter

{
  "grant_type": "password",
  "username": "string",
  "client_id": "string",
  "password": "string",
  "refreshtoken": "string",
  "refresh_token": "string"
}

Parameters

Name In Type Required Description
body body object true Get oauth tokens request
» grant_type body string true Request's grant type
» username body string false none
» client_id body string false none
» password body string false password
» refreshtoken body string false none
» refresh_token body string false refresh token

Enumerated Values

Parameter Value
» grant_type password
» grant_type refresh_token

Example responses

201 Response

{
  "access_token": "string",
  "token_type": "string",
  "expires_in": 0,
  "scope": "string",
  "refresh_token": "string"
}

Responses

Status Meaning Description Schema
201 Created Access and refresh tokens created Inline
401 Unauthorized Unauthorized: Authentication data is invalid Inline
409 Conflict Auth tokens cannot be generated Inline
500 Internal Server Error Get OAuth tokens failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» access_token string true none Oauth Token for CASP service
» token_type string false none Oauth Token type
» expires_in integer(int64) false none Expiration in seconds
» scope string false none Oauth token scope
» refresh_token string true none Oauth Token for CASP service

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Revoke an access token (deprecated)

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/tokens/{token_owner}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/auth/tokens/{token_owner} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/auth/tokens/{token_owner}

Revoke an access token

Parameters

Name In Type Required Description
token_owner path string true token_owner

Example responses

400 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK An access token was successfully removed None
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error An access token removal failed Inline

Response Schema

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Accounts

Refer to the Accounts section in the Unbound CASP Developers Guide

Create a new account

Code samples

const inputBody = '{
  "name": "string",
  "isGlobal": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/accounts \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/accounts

Create a new account managed by the CASP service

Body parameter

{
  "name": "string",
  "isGlobal": true
}

Parameters

Name In Type Required Description
body body object true Create accounts request
» name body string true Account name
» isGlobal body boolean false Is account global

Example responses

201 Response

{
  "id": "string",
  "name": "string",
  "isGlobal": true,
  "stats": {
    "participants": {
      "total": 0,
      "inactive": 0
    },
    "operations": {
      "total": 0,
      "pending": 0
    },
    "vaults": {
      "total": 0,
      "inactive": 0
    }
  }
}

Responses

Status Meaning Description Schema
201 Created OK Inline
409 Conflict Account already exists Inline
500 Internal Server Error Create account failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» id string true none Account ID
» name string true none Account name
» isGlobal boolean true none Is global account
» stats object true none none
»» participants object true none none
»»» total integer(int32) true none Total number of participants in the account
»»» inactive integer(int32) true none Total number of inactive participants in the account
»» operations object true none none
»»» total integer(int32) true none The number of operations from the account
»»» pending integer(int32) true none The number of operations that are still pending
»» vaults object true none none
»»» total integer(int32) true none The number of vaults that belong to this account
»»» inactive integer(int32) true none The number of inactive vaults that belong to this account

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

List accounts

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/accounts \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/accounts

List all accounts managed by the CASP service

Parameters

Name In Type Required Description
withStats query boolean false Include additional info per account
filter query string false Search the account names
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is ascending. The column name can be one of the following: Name, Global
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "id": "string",
      "name": "string",
      "isGlobal": true,
      "stats": {
        "participants": {
          "total": 0,
          "inactive": 0
        },
        "operations": {
          "total": 0,
          "pending": 0
        },
        "vaults": {
          "total": 0,
          "inactive": 0
        }
      }
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
404 Not Found Not found Inline
500 Internal Server Error List accounts failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» id string true none Account ID
»» name string true none Account name
»» isGlobal boolean true none Is global account
»» stats object true none none
»»» participants object true none none
»»»» total integer(int32) true none Total number of participants in the account
»»»» inactive integer(int32) true none Total number of inactive participants in the account
»»» operations object true none none
»»»» total integer(int32) true none The number of operations from the account
»»»» pending integer(int32) true none The number of operations that are still pending
»»» vaults object true none none
»»»» total integer(int32) true none The number of vaults that belong to this account
»»»» inactive integer(int32) true none The number of inactive vaults that belong to this account

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get account details

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts/{accountId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/accounts/{accountId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/accounts/{accountId}

Get account information about a specific account

Parameters

Name In Type Required Description
accountId path string true Account ID
withStats query boolean false Return detailed information about the account

Example responses

200 Response

[
  {
    "id": "string",
    "name": "string",
    "isGlobal": true,
    "stats": {
      "participants": {
        "total": 0,
        "inactive": 0
      },
      "operations": {
        "total": 0,
        "pending": 0
      },
      "vaults": {
        "total": 0,
        "inactive": 0
      }
    }
  }
]

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Not found Inline
500 Internal Server Error Get account details failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none Account ID
» name string true none Account name
» isGlobal boolean true none Is global account
» stats object true none none
»» participants object true none none
»»» total integer(int32) true none Total number of participants in the account
»»» inactive integer(int32) true none Total number of inactive participants in the account
»» operations object true none none
»»» total integer(int32) true none The number of operations from the account
»»» pending integer(int32) true none The number of operations that are still pending
»» vaults object true none none
»»» total integer(int32) true none The number of vaults that belong to this account
»»» inactive integer(int32) true none The number of inactive vaults that belong to this account

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Update an existing account

Code samples

const inputBody = '{
  "name": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts/{accountId}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X PUT /casp/api/v1.0/mng/accounts/{accountId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

PUT /casp/api/v1.0/mng/accounts/{accountId}

Update the parameters for a specific account

Body parameter

{
  "name": "string"
}

Parameters

Name In Type Required Description
accountId path string true Account ID
body body object true Update account request
» name body string true Account name
» isGlobal body boolean true Is account global

Example responses

404 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
404 Not Found Account not found Inline
409 Conflict Can't change global property, Account already has participants Inline
500 Internal Server Error Update account failed Inline

Response Schema

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Delete an account

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts/{accountId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/accounts/{accountId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/accounts/{accountId}

Delete an existing account. Only accounts with no vaults or participants may be deleted.

Parameters

Name In Type Required Description
accountId path string true Account ID

Example responses

403 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
403 Forbidden Forbidden Inline
404 Not Found Account not found Inline
500 Internal Server Error Delete account failed Inline

Response Schema

Status Code 403

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Operators

Create a new operator

Code samples

const inputBody = '{
  "name": "string",
  "password": "string",
  "role": "Super_User",
  "enable2fa": true,
  "isApprover": true,
  "loginName": "string"
}';
const headers = {
  'Content-Type':'application/x-www-form-urlencoded',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/users \
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/auth/users

Create a new user

Body parameter

name: string
password: string
role: Super_User
enable2fa: true
isApprover: true
loginName: string

Parameters

Name In Type Required Description
body body object false none
» name body string false User's name
» password body string false User's password
» role body string false User's role
» enable2fa body boolean false Is 2FA enabled for this user
» isApprover body boolean false is this user also an approver
» loginName body string false login name

Enumerated Values

Parameter Value
» role Super_User
» role Security_Officer
» role Trader

Example responses

201 Response

{
  "id": "string",
  "name": "string",
  "loginName": "string",
  "status": "string",
  "role": "string",
  "isParticipant": true,
  "enable2fa": true,
  "activationCode": "string",
  "email": "string",
  "locked": true,
  "pushEnabled": true
}

Responses

Status Meaning Description Schema
201 Created New operator created successfully Inline
401 Unauthorized Unauthorized: Invalid user name or password Inline
409 Conflict User already exists Inline
500 Internal Server Error Create new operator failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» id string true none User ID
» name string true none User name
» loginName string true none User login name
» status string true none User status
» role string true none User role
» isParticipant boolean true none Is user also an participant
» enable2fa boolean true none Is 2FA enabled
» activationCode string false none User activation code for 2FA
» email string false none User's email
» locked boolean true none Is user locked
» pushEnabled boolean true none User has push notifications enabled

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

List operators

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/auth/users \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/auth/users

List operators

Example responses

200 Response

[
  {
    "id": "string",
    "name": "string",
    "loginName": "string",
    "status": "string",
    "role": "string",
    "isParticipant": true,
    "enable2fa": true,
    "activationCode": "string",
    "email": "string",
    "locked": true,
    "pushEnabled": true
  }
]

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error Internal error Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none User ID
» name string true none User name
» loginName string true none User login name
» status string true none User status
» role string true none User role
» isParticipant boolean true none Is user also an participant
» enable2fa boolean true none Is 2FA enabled
» activationCode string false none User activation code for 2FA
» email string false none User's email
» locked boolean true none Is user locked
» pushEnabled boolean true none User has push notifications enabled

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Change operator password

Code samples

const inputBody = '{
  "value": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/auth/password',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X PUT /casp/api/v1.0/mng/auth/password \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

PUT /casp/api/v1.0/mng/auth/password

Change operator's password to the CASP service

Body parameter

{
  "value": "string"
}

Parameters

Name In Type Required Description
body body object true Change user's password request
» value body string true User's password

Example responses

401 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized: Invalid operator name or password Inline
500 Internal Server Error Change password failed Inline

Response Schema

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Reset operator password

Code samples

const inputBody = '{
  "password": "string",
  "mustChangePassword": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{username}/password',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X PUT /casp/api/v1.0/mng/auth/users/{username}/password \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

PUT /casp/api/v1.0/mng/auth/users/{username}/password

Reset operator's password to the CASP service

Body parameter

{
  "password": "string",
  "mustChangePassword": true
}

Parameters

Name In Type Required Description
username path string true Username
body body object true Change operator's password request
» password body string true User's password
» mustChangePassword body boolean false User must change password. default value: true

Example responses

401 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized: Invalid operator name or password Inline
500 Internal Server Error Change password failed Inline

Response Schema

Status Code 401

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Update operator

Code samples

const inputBody = '{
  "name": "string",
  "loginName": "string",
  "status": "ACTIVATED",
  "role": "Super_User",
  "email": "string",
  "locked": true
}';
const headers = {
  'Content-Type':'application/x-www-form-urlencoded',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{user_name}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X PUT /casp/api/v1.0/mng/auth/users/{user_name} \
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

PUT /casp/api/v1.0/mng/auth/users/{user_name}

Update operator

Body parameter

name: string
loginName: string
status: ACTIVATED
role: Super_User
email: string
locked: true

Parameters

Name In Type Required Description
user_name path string true User Name
body body object false none
» name body string false new username
» loginName body string false new login name
» status body string false user status
» role body string false user role
» email body string false user email
» locked body boolean false locked?

Enumerated Values

Parameter Value
» status ACTIVATED
» status SUSPENDED
» status REVOKED
» role Super_User
» role Security_Officer
» role Trader

Example responses

200 Response

{
  "id": "string",
  "name": "string",
  "loginName": "string",
  "status": "string",
  "role": "string",
  "isParticipant": true,
  "enable2fa": true,
  "activationCode": "string",
  "email": "string",
  "locked": true,
  "pushEnabled": true
}

Responses

Status Meaning Description Schema
200 OK An operator was successfully updated Inline
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error A user removal failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none User ID
» name string true none User name
» loginName string true none User login name
» status string true none User status
» role string true none User role
» isParticipant boolean true none Is user also an participant
» enable2fa boolean true none Is 2FA enabled
» activationCode string false none User activation code for 2FA
» email string false none User's email
» locked boolean true none Is user locked
» pushEnabled boolean true none User has push notifications enabled

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get operator

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{user_name}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/auth/users/{user_name} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/auth/users/{user_name}

Get operator

Parameters

Name In Type Required Description
user_name path string true User Name

Example responses

200 Response

{
  "id": "string",
  "name": "string",
  "loginName": "string",
  "status": "string",
  "role": "string",
  "isParticipant": true,
  "enable2fa": true,
  "activationCode": "string",
  "email": "string",
  "locked": true,
  "pushEnabled": true
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error Internal error Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none User ID
» name string true none User name
» loginName string true none User login name
» status string true none User status
» role string true none User role
» isParticipant boolean true none Is user also an participant
» enable2fa boolean true none Is 2FA enabled
» activationCode string false none User activation code for 2FA
» email string false none User's email
» locked boolean true none Is user locked
» pushEnabled boolean true none User has push notifications enabled

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Remove an operator

Code samples


const headers = {
  'Accept':'*/*',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{user_name}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/auth/users/{user_name} \
  -H 'Accept: */*' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/auth/users/{user_name}

Remove an operator

Parameters

Name In Type Required Description
user_name path string true User Name

Example responses

400 Response

Responses

Status Meaning Description Schema
200 OK Operator was successfully removed None
400 Bad Request Unauthorized: Invalid request Inline
500 Internal Server Error Operator removal failed Inline

Response Schema

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Test push notification

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{user_name}/testnotification',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/users/{user_name}/testnotification \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/auth/users/{user_name}/testnotification

Sends a test push notification to a specific user

Parameters

Name In Type Required Description
user_name path string true login name

Example responses

404 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
404 Not Found User not found Inline
409 Conflict Cannot test push notifications Inline
500 Internal Server Error Testing push notification failed Inline

Response Schema

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Reactivate an operator

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/auth/users/{user_name}/reactivate',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/auth/users/{user_name}/reactivate \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/auth/users/{user_name}/reactivate

Activate an existing operator, regenerate the activation code, and re-add the operator to all relevant vaults. Used when the activation code was lost or the operator gets a new phone.

This request returns an error (403) if there is a pending request for the user to join a vault.

Parameters

Name In Type Required Description
user_name path string true User name

Example responses

200 Response

{
  "id": "string",
  "activationCode": "string",
  "name": "string",
  "rejoinOperationIds": [
    "string"
  ],
  "failedToRejoinVaults": [
    {
      "vaultId": "string",
      "vaultName": "string",
      "error": "string"
    }
  ],
  "serverAuthenticationKey": "string",
  "serverEncryptionKey": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
403 Forbidden not allowed Inline
404 Not Found User not found Inline
500 Internal Server Error Regenerate activation code failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none ParticipantWithVault ID
» activationCode string true none Activation code for the specified participant
» name string true none ParticipantWithVault name
» rejoinOperationIds [string] true none Rejoin operationIds
» failedToRejoinVaults [object] true none Rejoin operation failed on vault
»» vaultId string true none Vault ID
»» vaultName string true none Vault Name
»» error string true none Rejoin error
» serverAuthenticationKey string false none The server authentication key
» serverEncryptionKey string false none The server encryption key

Status Code 403

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Participants

Refer to the Participants section in the Unbound CASP Developers Guide

Create a new participant

Code samples

const inputBody = '{
  "name": "string",
  "email": "string",
  "role": "string",
  "offline": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts/{accountId}/participants',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/accounts/{accountId}/participants \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/accounts/{accountId}/participants

Create a new participant in the specified account

Body parameter

{
  "name": "string",
  "email": "string",
  "role": "string",
  "offline": true
}

Parameters

Name In Type Required Description
accountId path string true Account ID
body body object true Create participant request
» name body string true Participant name
» email body string true Participant email
» role body string false Participant role
» offline body boolean false An offline participant

Example responses

201 Response

{
  "id": "string",
  "activationCode": "string",
  "name": "string",
  "rejoinOperationIds": [
    "string"
  ],
  "failedToRejoinVaults": [
    {
      "vaultId": "string",
      "vaultName": "string",
      "error": "string"
    }
  ],
  "serverAuthenticationKey": "string",
  "serverEncryptionKey": "string"
}

Responses

Status Meaning Description Schema
201 Created New participant created successfully Inline
404 Not Found Account not found Inline
406 Not Acceptable Email is not valid Inline
409 Conflict Participant already exists Inline
500 Internal Server Error Create new participant failed Inline

Response Schema

Status Code 201

Name Type Required Restrictions Description
» id string true none ParticipantWithVault ID
» activationCode string true none Activation code for the specified participant
» name string true none ParticipantWithVault name
» rejoinOperationIds [string] true none Rejoin operationIds
» failedToRejoinVaults [object] true none Rejoin operation failed on vault
»» vaultId string true none Vault ID
»» vaultName string true none Vault Name
»» error string true none Rejoin error
» serverAuthenticationKey string false none The server authentication key
» serverEncryptionKey string false none The server encryption key

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 406

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

List participants

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/accounts/{accountId}/participants',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/accounts/{accountId}/participants \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/accounts/{accountId}/participants

List all participants in the account, which can be both humans and BOT's. An option is provided to include the suspended and revoked participants.

Parameters

Name In Type Required Description
accountId path string true Account ID
withGlobal query boolean false Include participants which take part in this account vaults and belong to a different global account
withDeactivated query boolean false Include suspended and revoked participants
filter query string false Search the participant names
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is ascending.

The column name can be one of the following: Name, Status, Email
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "id": "string",
      "accountID": "string",
      "name": "string",
      "email": "string",
      "status": "NOT_ACTIVATED",
      "isActive": true,
      "accountName": "string",
      "role": "string",
      "pushEnabled": true,
      "offline": true,
      "activeOperations": 0
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
404 Not Found Account not found Inline
500 Internal Server Error List participant per account failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» id string true none Participant ID
»» accountID string true none Participant account ID
»» name string true none Participant name
»» email string true none Participant email
»» status string true none Participant status
»» isActive boolean true none Participant activation state
»» accountName string true none Participant account name
»» role string true none Participant role
»» pushEnabled boolean true none Is the push notifications enabled for this participant
»» offline boolean true none Participant is offline
»» activeOperations integer(int64) true none Participant is offline

Enumerated Values

Property Value
status NOT_ACTIVATED
status ACTIVATED
status DEACTIVATED
status SUSPENDED
status REVOKED

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get participant information

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/participants/{participantId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/participants/{participantId}

Get details of a participant

Parameters

Name In Type Required Description
participantId path string true Participant ID

Example responses

200 Response

{
  "id": "string",
  "accountID": "string",
  "name": "string",
  "email": "string",
  "status": "NOT_ACTIVATED",
  "isActive": true,
  "accountName": "string",
  "role": "string",
  "pushEnabled": true,
  "offline": true,
  "activeOperations": 0
}

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Participant not found Inline
500 Internal Server Error Get participant failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none Participant ID
» accountID string true none Participant account ID
» name string true none Participant name
» email string true none Participant email
» status string true none Participant status
» isActive boolean true none Participant activation state
» accountName string true none Participant account name
» role string true none Participant role
» pushEnabled boolean true none Is the push notifications enabled for this participant
» offline boolean true none Participant is offline
» activeOperations integer(int64) true none Participant is offline

Enumerated Values

Property Value
status NOT_ACTIVATED
status ACTIVATED
status DEACTIVATED
status SUSPENDED
status REVOKED

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Update an existing participant

Code samples

const inputBody = '{
  "name": "string",
  "email": "string",
  "role": "string",
  "status": "ACTIVATED"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X PUT /casp/api/v1.0/mng/participants/{participantId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

PUT /casp/api/v1.0/mng/participants/{participantId}

Update a participant's details. Participant name and other attributes can be changed. It can also be used to suspend a participant by setting status to SUSPENDED, and activate a participant by setting status to ACTIVATED, or completely revoke a participant by setting status to REVOKED

Body parameter

{
  "name": "string",
  "email": "string",
  "role": "string",
  "status": "ACTIVATED"
}

Parameters

Name In Type Required Description
participantId path string true Participant ID
force query boolean false Force update of participant status. Warning: Using this flag can result in an unusable vault!
body body object true Update participant request
» name body string false ParticipantWithVault name
» email body string false ParticipantWithVault email
» role body string false ParticipantWithVault role
» status body string false ParticipantWithVault status

Enumerated Values

Parameter Value
» status ACTIVATED
» status DEACTIVATED
» status SUSPENDED
» status REVOKED

Example responses

404 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
404 Not Found Participant not found Inline
409 Conflict Cannot suspend participant Inline
500 Internal Server Error Update participant failed Inline

Response Schema

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Delete a participant

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X DELETE /casp/api/v1.0/mng/participants/{participantId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

DELETE /casp/api/v1.0/mng/participants/{participantId}

Deletes a participant. A participant can be deleted only if it has no related vaults.

Parameters

Name In Type Required Description
participantId path string true Participant ID

Example responses

403 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
403 Forbidden Forbidden Inline
404 Not Found Participant not found Inline
500 Internal Server Error Delete participant failed Inline

Response Schema

Status Code 403

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Test push notification

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/testnotification',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/participants/{participantId}/testnotification \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/participants/{participantId}/testnotification

Sends a test push notification to a specific participant (if available)

Parameters

Name In Type Required Description
participantId path string true Participant ID

Example responses

404 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
404 Not Found Participant not found Inline
409 Conflict Cannot test push notifications Inline
500 Internal Server Error Testing push notification failed Inline

Response Schema

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 409

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Participant group info

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/approvalGroups',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/participants/{participantId}/approvalGroups \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/participants/{participantId}/approvalGroups

Retrieve information about a participant's groups.

Parameters

Name In Type Required Description
participantId path string true Participant ID

Example responses

200 Response

[
  {
    "vaultId": "string",
    "vaultName": "string",
    "type": "string",
    "policy": "string",
    "policyId": "string",
    "name": "string",
    "requiredApprovals": 0,
    "totalMembersCount": 0,
    "activeMembersCount": 0,
    "status": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Participant not found Inline
500 Internal Server Error Get participant groups failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» vaultId string true none Vault ID
» vaultName string true none Vault name
» type string true none Group type
» policy string false none Policy name
» policyId string false none Policy Id
» name string true none Group name
» requiredApprovals integer(int32) true none Number of group required approvals
» totalMembersCount integer(int32) true none Number of group participants
» activeMembersCount integer(int32) true none Number of active participants in group
» status string false none Participant status on group (only for suspended and revoked statuses)

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Reactivate a participant

Code samples

const inputBody = '{
  "vaults": [
    "string"
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/reactivate',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/participants/{participantId}/reactivate \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/participants/{participantId}/reactivate

Activate an existing participant, regenerate the activation code, and re-add the participant to all relevant vaults. Used when the activation code was lost or the participant gets a new phone.

This request returns an error (403) if there is a pending request for the user to join a vault.

Body parameter

{
  "vaults": [
    "string"
  ]
}

Parameters

Name In Type Required Description
participantId path string true Participant ID
body body object true Regenerate activation code request
» vaults body [string] false List of vaultIds to trigger 'rejoin' operation

Example responses

200 Response

{
  "id": "string",
  "activationCode": "string",
  "name": "string",
  "rejoinOperationIds": [
    "string"
  ],
  "failedToRejoinVaults": [
    {
      "vaultId": "string",
      "vaultName": "string",
      "error": "string"
    }
  ],
  "serverAuthenticationKey": "string",
  "serverEncryptionKey": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
403 Forbidden Reactivation is not allowed Inline
404 Not Found Participant not found Inline
500 Internal Server Error Regenerate activation code failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none ParticipantWithVault ID
» activationCode string true none Activation code for the specified participant
» name string true none ParticipantWithVault name
» rejoinOperationIds [string] true none Rejoin operationIds
» failedToRejoinVaults [object] true none Rejoin operation failed on vault
»» vaultId string true none Vault ID
»» vaultName string true none Vault Name
»» error string true none Rejoin error
» serverAuthenticationKey string false none The server authentication key
» serverEncryptionKey string false none The server encryption key

Status Code 403

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Participant change warnings

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/statusChangeWarnings/{status}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/participants/{participantId}/statusChangeWarnings/{status} \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/participants/{participantId}/statusChangeWarnings/{status}

Returns warnings associated with a potential change in participant status. The user and desired status are given as parameters, and the resulting warning is returned. Depending on the status change, the vault, group, or policy may become unusable.

Parameters

Name In Type Required Description
participantId path string true Participant ID
vaultId query string false Policy ID
policyId query string false Vault ID
status path string true Status

Example responses

200 Response

[
  {
    "vaultId": "string",
    "vaultName": "string",
    "type": "string",
    "policy": "string",
    "policyId": "string",
    "name": "string",
    "requiredApprovals": 0,
    "totalMembersCount": 0,
    "activeMembersCount": 0,
    "status": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Participant not found Inline
500 Internal Server Error Get participant change warnings failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» vaultId string true none Vault ID
» vaultName string true none Vault name
» type string true none Group type
» policy string false none Policy name
» policyId string false none Policy Id
» name string true none Group name
» requiredApprovals integer(int32) true none Number of group required approvals
» totalMembersCount integer(int32) true none Number of group participants
» activeMembersCount integer(int32) true none Number of active participants in group
» status string false none Participant status on group (only for suspended and revoked statuses)

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Activate offline participant

Code samples

const inputBody = 'string';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/participants/{participantid}/activateOffline',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/participants/{participantid}/activateOffline \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /casp/api/v1.0/mng/participants/{participantid}/activateOffline

Activate a participant in CASP

Body parameter

"string"

Parameters

Name In Type Required Description
participantid path string true ApprovalGroupParticipant ID
body body string true Offline activation request

Example responses

200 Response

{
  "id": "string",
  "name": "string",
  "email": "string",
  "role": "string",
  "accountID": "string",
  "accountName": "string",
  "status": "NOT_ACTIVATED",
  "loginName": "string",
  "responseSignKey": "string",
  "approver": true,
  "admin": true
}

Responses

Status Meaning Description Schema
200 OK Participant activated successfully Inline
400 Bad Request Bad request Inline
404 Not Found Participant not found Inline
406 Not Acceptable Participant keys are invalid Inline
500 Internal Server Error Activate participant failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» id string true none Participant ID
» name string true none Participant name
» email string true none Participant email
» role string true none Participant role
» accountID string true none Participant account ID
» accountName string true none Participant account alias
» status string true none Participant status
» loginName string false none User login name
» responseSignKey string true none Transaction sign key for transaction verifications
» approver boolean false none Participant has approver capabilities
» admin boolean false none Participant has authentication capabilities

Enumerated Values

Property Value
status NOT_ACTIVATED
status ACTIVATED
status DEACTIVATED

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 406

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get offline operations

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/offlineoperations',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/participants/{participantId}/offlineoperations \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/participants/{participantId}/offlineoperations

Get offline participant operations

Parameters

Name In Type Required Description
participantId path string true Participant ID

Example responses

200 Response

{
  "data": "string",
  "tag": "string",
  "iv": "string",
  "key": "string",
  "participantId": "string",
  "sig": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Participant not found Inline
405 Method Not Allowed Not allowed Inline
500 Internal Server Error Get participant failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» data string true none Participant ID
» tag string false none none
» iv string false none none
» key string false none none
» participantId string false none none
» sig string true none Participant ID

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 405

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Set offline operation results

Code samples

const inputBody = 'string';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/participants/{participantId}/offlineoperations',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/participants/{participantId}/offlineoperations \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

POST /casp/api/v1.0/mng/participants/{participantId}/offlineoperations

Set offline participant operation results

Body parameter

"string"

Parameters

Name In Type Required Description
participantId path string true Participant ID
body body string true Offline participant operation results

Example responses

404 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
404 Not Found Participant not found Inline
405 Method Not Allowed Not allowed Inline
500 Internal Server Error Get participant failed Inline

Response Schema

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 405

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Backup

Refer to the Backup section in the Unbound CASP Developers Guide

Get vault backup data

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/vaults/{vaultId}/backup',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/vaults/{vaultId}/backup \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/vaults/{vaultId}/backup

The vault cryptographic material is backed up with a key that is external to the CASP system. The backup can be used for safe recovery of the vault in case of service failure, participants losing their shares, or termination of CASP usage.

Parameters

Name In Type Required Description
vaultId path string true Vault ID

Example responses

200 Response

{
  "vaultID": "string",
  "backupData": "string",
  "publicKey": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad request Inline
404 Not Found Backup not found Inline
500 Internal Server Error Get vault backup data failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» vaultID string true none Vault ID
» backupData string true none Vault backup data
» publicKey string true none Vault public key

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get backup for account

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/vaults/{vaultId}/coins/{coinType}/accounts/{accountIdentifier}/backup',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/vaults/{vaultId}/coins/{coinType}/accounts/{accountIdentifier}/backup \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/vaults/{vaultId}/coins/{coinType}/accounts/{accountIdentifier}/backup

Get backup for BIP44 account.

This endpoint is only functional if you generated a BIP44 vault.

Parameters

Name In Type Required Description
vaultId path string true Vault ID
coinType path integer(int32) true Coin type
accountIdentifier path string true Account identifier, which can be the index or the name

Example responses

200 Response

{
  "vaultId": "string",
  "backupData": "string",
  "bipLevel": 0,
  "cpar": "string",
  "parentFingerprint": "string",
  "childNumber": 0,
  "publicKey": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Vault not found Inline
405 Method Not Allowed Incorrect vault type Inline
500 Internal Server Error Get account backup failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» vaultId string true none the vault ID
» backupData string true none The backup data, in encrypted form
» bipLevel integer(int32) true none derivation level
» cpar string true none CPar
» parentFingerprint string true none parent fingerprint
» childNumber integer(int32) true none child number
» publicKey string false none none

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 405

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Get backup data for public key

Code samples


const headers = {
  'Accept':'application/json',
  'Authorization':'API_KEY'

};

fetch('/casp/api/v1.0/mng/vaults/{vaultId}/backup/{publicKey}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/vaults/{vaultId}/backup/{publicKey} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer API_KEY'

GET /casp/api/v1.0/mng/vaults/{vaultId}/backup/{publicKey}

The vault cryptographic material is backed up with a key that is external to the CASP system. The backup can be used for safe recovery of the vault in case of service failure, participants losing their shares, or termination of CASP usage.

This endpoint is only functional if you generated a BIP32 vault.

Parameters

Name In Type Required Description
vaultId path string true Vault ID
publicKey path string true public key

Example responses

200 Response

{
  "vaultId": "string",
  "backupData": "string",
  "bipLevel": 0,
  "cpar": "string",
  "parentFingerprint": "string",
  "childNumber": 0,
  "publicKey": "string"
}

Responses

Status Meaning Description Schema
200 OK OK Inline
404 Not Found Vault not found Inline
405 Method Not Allowed Incorrect vault type Inline
500 Internal Server Error Get vault backup data failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» vaultId string true none the vault ID
» backupData string true none The backup data, in encrypted form
» bipLevel integer(int32) true none derivation level
» cpar string true none CPar
» parentFingerprint string true none parent fingerprint
» childNumber integer(int32) true none child number
» publicKey string false none none

Status Code 404

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 405

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Audit

Refer to the Audit Reports section in the Unbound CASP Developers Guide

Account operations audit

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/accounts',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/accounts \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/accounts

Account operations audit.

Parameters

Name In Type Required Description
full_validation query boolean false Validate accounts audit and check it is not corrupted
filter query string false Search the accounts names or accountId
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is descending.

The column name can be one of the following: timestamp
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "auditSeverity": "TRACE",
      "event": "string",
      "initiatorId": "string",
      "initiatorName": "string",
      "timestamp": "string",
      "accountId": "string",
      "accountName": "string",
      "duration": 0,
      "error": "string",
      "details": "string",
      "global": true
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Account operations audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» auditSeverity string false none none
»» event string false none none
»» initiatorId string false none none
»» initiatorName string false none none
»» timestamp string false none none
»» accountId string false none none
»» accountName string false none none
»» duration integer(int64) false none none
»» error string false none none
»» details string false none none
»» global boolean false none none

Enumerated Values

Property Value
auditSeverity TRACE
auditSeverity DEBUG
auditSeverity INFO
auditSeverity WARNING
auditSeverity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

User operations audit

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/users',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/users \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/users

User operations audit.

Parameters

Name In Type Required Description
full_validation query boolean false Validate users audit and check it is not corrupted
filter query string false Search the users names or userId
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is descending.

The column name can be one of the following: timestamp
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "auditSeverity": "TRACE",
      "operationId": "string",
      "event": "string",
      "initiatorId": "string",
      "initiatorName": "string",
      "timestamp": "string",
      "accountId": "string",
      "accountName": "string",
      "vaultId": "string",
      "vaultName": "string",
      "userId": "string",
      "userName": "string",
      "duration": 0,
      "error": "string",
      "details": "string",
      "userRole": "string",
      "userEmail": "string",
      "userStatus": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error User operations audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» auditSeverity string false none none
»» operationId string false none none
»» event string false none none
»» initiatorId string false none none
»» initiatorName string false none none
»» timestamp string false none none
»» accountId string false none none
»» accountName string false none none
»» vaultId string false none none
»» vaultName string false none none
»» userId string false none none
»» userName string false none none
»» duration integer(int64) false none none
»» error string false none none
»» details string false none none
»» userRole string false none none
»» userEmail string false none none
»» userStatus string false none none

Enumerated Values

Property Value
auditSeverity TRACE
auditSeverity DEBUG
auditSeverity INFO
auditSeverity WARNING
auditSeverity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Vault operations audit

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/vaults',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/vaults \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/vaults

Vault operations audit.

Parameters

Name In Type Required Description
full_validation query boolean false Validate users audit and check it is not corrupted
filter query string false Search the vaults by vaultId, vaultName or operationId
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is descending.

The column name can be one of the following: timestamp
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "severity": "TRACE",
      "operationId": "string",
      "event": "string",
      "initiatorId": "string",
      "initiatorName": "string",
      "timestamp": "string",
      "accountId": "string",
      "accountName": "string",
      "vaultId": "string",
      "vaultName": "string",
      "userId": "string",
      "userName": "string",
      "duration": 0,
      "error": "string",
      "details": "string",
      "operationKind": "string",
      "adminQuorum": {
        "approvalGroups": [
          {
            "name": "string",
            "requiredApprovals": 1,
            "members": [
              {
                "id": "string"
              }
            ]
          }
        ]
      },
      "policies": [
        {
          "name": "string",
          "description": "string",
          "enabled": true,
          "timeZone": "string",
          "groups": [
            {
              "name": "string",
              "requiredApprovals": 1,
              "members": [
                {
                  "id": "string"
                }
              ]
            }
          ],
          "rules": {
            "weeklyTimeSlots": [
              {
                "days": "string",
                "timeStart": "string",
                "timeEnd": "string"
              }
            ],
            "amountRange": {
              "property1": {
                "minimum": 0,
                "maximum": 0
              },
              "property2": {
                "minimum": 0,
                "maximum": 0
              }
            },
            "whiteList": [
              "string"
            ],
            "derivedWhitelist": [
              {
                "chainCode": "string",
                "publicKey": "string",
                "level": 0,
                "parentFingerprint": "string",
                "childNumber": 0
              }
            ]
          }
        }
      ],
      "derivationString": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Vault operations audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» severity string false none none
»» operationId string false none none
»» event string false none none
»» initiatorId string false none none
»» initiatorName string false none none
»» timestamp string false none none
»» accountId string false none none
»» accountName string false none none
»» vaultId string false none none
»» vaultName string false none none
»» userId string false none none
»» userName string false none none
»» duration integer(int64) false none none
»» error string false none none
»» details string false none none
»» operationKind string false none none
»» adminQuorum object false none none
»»» approvalGroups [object] false none none
»»»» name string true none Vault group name
»»»» requiredApprovals integer(int32) true none Vault group required approvals
»»»» members [object] true none Vault group participants
»»»»» id string true none Participant ID
»» policies [object] false none none
»»» name string true none policy name
»»» description string false none Policy description
»»» enabled boolean false none is the policy enabled, default is TRUE
»»» timeZone string false none Policy time zone, default is UTC
»»» groups [object] true none none
»»»» name string true none Vault group name
»»»» requiredApprovals integer(int32) true none Vault group required approvals
»»»» members [object] true none Vault group participants
»»»»» id string true none Participant ID
»»» rules object false none Policy rules
»»»» weeklyTimeSlots [object] false none none
»»»»» days string true none Days of the week in comma separated list. e.g. 0,1,3 for Sunday, Monday and Wednesday
»»»»» timeStart string true none UTC time of day in the following format: HH:MM
»»»»» timeEnd string true none UTC time of day in the following format: HH:MM
»»»» amountRange object false none none
»»»»» additionalProperties object false none none
»»»»»» minimum integer false none lower limit
»»»»»» maximum integer false none upper limit
»»»» whiteList [string] false none none
»»»» derivedWhitelist [object] false none none
»»»»» chainCode string false none none
»»»»» publicKey string false none none
»»»»» level integer(int32) false none none
»»»»» parentFingerprint string false none none
»»»»» childNumber integer(int32) false none none
»» derivationString string false none none

Enumerated Values

Property Value
severity TRACE
severity DEBUG
severity INFO
severity WARNING
severity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Vault audit by operation ID

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/vaults/{operationId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/vaults/{operationId} \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/vaults/{operationId}

Vault operations audit by operation ID.

Parameters

Name In Type Required Description
full_validation query boolean false Validate users audit and check it is not corrupted
operationId path string true Operation ID

Example responses

200 Response

{
  "severity": "TRACE",
  "operationId": "string",
  "event": "string",
  "initiatorId": "string",
  "initiatorName": "string",
  "timestamp": "string",
  "accountId": "string",
  "accountName": "string",
  "vaultId": "string",
  "vaultName": "string",
  "userId": "string",
  "userName": "string",
  "error": "string",
  "operationKind": "string",
  "adminQuorum": {
    "approvalGroups": [
      {
        "name": "string",
        "requiredApprovals": 1,
        "members": [
          {
            "id": "string"
          }
        ]
      }
    ]
  },
  "policies": [
    {
      "name": "string",
      "description": "string",
      "enabled": true,
      "timeZone": "string",
      "groups": [
        {
          "name": "string",
          "requiredApprovals": 1,
          "members": [
            {
              "id": "string"
            }
          ]
        }
      ],
      "rules": {
        "weeklyTimeSlots": [
          {
            "days": "string",
            "timeStart": "string",
            "timeEnd": "string"
          }
        ],
        "amountRange": {
          "property1": {
            "minimum": 0,
            "maximum": 0
          },
          "property2": {
            "minimum": 0,
            "maximum": 0
          }
        },
        "whiteList": [
          "string"
        ],
        "derivedWhitelist": [
          {
            "chainCode": "string",
            "publicKey": "string",
            "level": 0,
            "parentFingerprint": "string",
            "childNumber": 0
          }
        ]
      }
    }
  ],
  "derivationString": "string",
  "operationApprovals": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ],
  "approvedByQuorum": "string",
  "operationCanceled": "string",
  "operationDeclines": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Vault operation audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» severity string false none none
» operationId string false none none
» event string false none none
» initiatorId string false none none
» initiatorName string false none none
» timestamp string false none none
» accountId string false none none
» accountName string false none none
» vaultId string false none none
» vaultName string false none none
» userId string false none none
» userName string false none none
» error string false none none
» operationKind string false none none
» adminQuorum object false none none
»» approvalGroups [object] false none none
»»» name string true none Vault group name
»»» requiredApprovals integer(int32) true none Vault group required approvals
»»» members [object] true none Vault group participants
»»»» id string true none Participant ID
» policies [object] false none none
»» name string true none policy name
»» description string false none Policy description
»» enabled boolean false none is the policy enabled, default is TRUE
»» timeZone string false none Policy time zone, default is UTC
»» groups [object] true none none
»»» name string true none Vault group name
»»» requiredApprovals integer(int32) true none Vault group required approvals
»»» members [object] true none Vault group participants
»»»» id string true none Participant ID
»» rules object false none Policy rules
»»» weeklyTimeSlots [object] false none none
»»»» days string true none Days of the week in comma separated list. e.g. 0,1,3 for Sunday, Monday and Wednesday
»»»» timeStart string true none UTC time of day in the following format: HH:MM
»»»» timeEnd string true none UTC time of day in the following format: HH:MM
»»» amountRange object false none none
»»»» additionalProperties object false none none
»»»»» minimum integer false none lower limit
»»»»» maximum integer false none upper limit
»»» whiteList [string] false none none
»»» derivedWhitelist [object] false none none
»»»» chainCode string false none none
»»»» publicKey string false none none
»»»» level integer(int32) false none none
»»»» parentFingerprint string false none none
»»»» childNumber integer(int32) false none none
» derivationString string false none none
» operationApprovals [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none
» approvedByQuorum string false none none
» operationCanceled string false none none
» operationDeclines [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none

Enumerated Values

Property Value
severity TRACE
severity DEBUG
severity INFO
severity WARNING
severity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Sign operations audit

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/signs',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/signs \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/signs

Sign operations audit.

Parameters

Name In Type Required Description
full_validation query boolean false Validate users audit and check it is not corrupted
filter query string false Search the sign audit by operationId
sort query string false Specify the column name to sort by and the sort direction. The format is '{column_name}:{asc/desc}'. The default sort is descending.

The column name can be one of the following: timestamp.
skip query integer(int32) false The number of results to skip from the beginning of the results after applying the filter and sort
limit query integer(int32) false The maximum number of results to return

Example responses

200 Response

{
  "totalItems": 0,
  "items": [
    {
      "severity": "TRACE",
      "operationId": "string",
      "event": "string",
      "initiatorId": "string",
      "initiatorName": "string",
      "timestamp": "string",
      "accountId": "string",
      "accountName": "string",
      "vaultId": "string",
      "vaultName": "string",
      "userId": "string",
      "userName": "string",
      "duration": 0,
      "error": "string",
      "details": "string",
      "rawTransaction": [
        "string"
      ],
      "amount": 0,
      "assetType": "string",
      "toAddress": [
        "string"
      ],
      "isWhitelisted": true,
      "whitelistAddress": "string",
      "description": "string",
      "policyName": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Sign operations audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» totalItems integer(int32) true none Total Items
» items [object] true none Items
»» severity string false none none
»» operationId string false none none
»» event string false none none
»» initiatorId string false none none
»» initiatorName string false none none
»» timestamp string false none none
»» accountId string false none none
»» accountName string false none none
»» vaultId string false none none
»» vaultName string false none none
»» userId string false none none
»» userName string false none none
»» duration integer(int64) false none none
»» error string false none none
»» details string false none none
»» rawTransaction [string] false none none
»» amount integer false none none
»» assetType string false none none
»» toAddress [string] false none none
»» isWhitelisted boolean false none none
»» whitelistAddress string false none none
»» description string false none none
»» policyName string false none none

Enumerated Values

Property Value
severity TRACE
severity DEBUG
severity INFO
severity WARNING
severity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Sign audit by operation ID

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/signs/{operationId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/signs/{operationId} \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/signs/{operationId}

Sign operations audit by operation ID.

Parameters

Name In Type Required Description
full_validation query boolean false Validate users audit and check it is not corrupted
operationId path string true Operation ID

Example responses

200 Response

{
  "severity": "TRACE",
  "operationId": "string",
  "event": "string",
  "initiatorId": "string",
  "initiatorName": "string",
  "timestamp": "string",
  "accountId": "string",
  "accountName": "string",
  "vaultId": "string",
  "vaultName": "string",
  "userId": "string",
  "userName": "string",
  "error": "string",
  "assetType": "string",
  "rawTransaction": [
    "string"
  ],
  "amount": 0,
  "toAddress": [
    "string"
  ],
  "whitelistAddress": "string",
  "description": "string",
  "policyName": "string",
  "operationApprovals": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ],
  "approvedByQuorum": "string",
  "operationCanceled": "string",
  "operationDeclines": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ],
  "whitelisted": true
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Signs operation audit failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» severity string false none none
» operationId string false none none
» event string false none none
» initiatorId string false none none
» initiatorName string false none none
» timestamp string false none none
» accountId string false none none
» accountName string false none none
» vaultId string false none none
» vaultName string false none none
» userId string false none none
» userName string false none none
» error string false none none
» assetType string false none none
» rawTransaction [string] false none none
» amount integer false none none
» toAddress [string] false none none
» whitelistAddress string false none none
» description string false none none
» policyName string false none none
» operationApprovals [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none
» approvedByQuorum string false none none
» operationCanceled string false none none
» operationDeclines [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none
» whitelisted boolean false none none

Enumerated Values

Property Value
severity TRACE
severity DEBUG
severity INFO
severity WARNING
severity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Purge data

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/purge?date=string&auditType=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X POST /casp/api/v1.0/mng/audit/purge?date=string&auditType=string \
  -H 'Accept: application/json'

POST /casp/api/v1.0/mng/audit/purge

Purge all data earlier than a given date.

Parameters

Name In Type Required Description
date query string true Purge all data earlier than this date. 'date' should be with the following format: DD/MM/YYYY hh:mm
auditType query string true Audit type to purge. 'auditType' can be on of: 'vaults', 'signs' or 'users'

Example responses

200 Response

{
  "severity": "TRACE",
  "operationId": "string",
  "event": "string",
  "initiatorId": "string",
  "initiatorName": "string",
  "timestamp": "string",
  "accountId": "string",
  "accountName": "string",
  "vaultId": "string",
  "vaultName": "string",
  "userId": "string",
  "userName": "string",
  "error": "string",
  "assetType": "string",
  "rawTransaction": [
    "string"
  ],
  "amount": 0,
  "toAddress": [
    "string"
  ],
  "whitelistAddress": "string",
  "description": "string",
  "policyName": "string",
  "operationApprovals": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ],
  "approvedByQuorum": "string",
  "operationCanceled": "string",
  "operationDeclines": [
    {
      "participantId": "string",
      "participantName": "string",
      "time": "string",
      "error": "string"
    }
  ],
  "whitelisted": true
}

Responses

Status Meaning Description Schema
200 OK OK Inline
400 Bad Request Bad Request Inline
500 Internal Server Error Purge audit operation failed Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
» severity string false none none
» operationId string false none none
» event string false none none
» initiatorId string false none none
» initiatorName string false none none
» timestamp string false none none
» accountId string false none none
» accountName string false none none
» vaultId string false none none
» vaultName string false none none
» userId string false none none
» userName string false none none
» error string false none none
» assetType string false none none
» rawTransaction [string] false none none
» amount integer false none none
» toAddress [string] false none none
» whitelistAddress string false none none
» description string false none none
» policyName string false none none
» operationApprovals [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none
» approvedByQuorum string false none none
» operationCanceled string false none none
» operationDeclines [object] false none none
»» participantId string false none none
»» participantName string false none none
»» time string false none none
»» error string false none none
» whitelisted boolean false none none

Enumerated Values

Property Value
severity TRACE
severity DEBUG
severity INFO
severity WARNING
severity ERROR

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Audit verification by type

Code samples


const headers = {
  'Accept':'application/json'

};

fetch('/casp/api/v1.0/mng/audit/verify/{auditType}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

# You can also use wget
curl -X GET /casp/api/v1.0/mng/audit/verify/{auditType} \
  -H 'Accept: application/json'

GET /casp/api/v1.0/mng/audit/verify/{auditType}

Verification of audit for the given type.

Parameters

Name In Type Required Description
auditType path string true Audit type to verify. 'auditType' can be one of: 'vaults', 'signs' or 'users'.

Example responses

400 Response

{
  "type": "string",
  "title": "string",
  "details": "string",
  "status": 0
}

Responses

Status Meaning Description Schema
200 OK OK None
400 Bad Request Bad Request Inline
500 Internal Server Error Audit failed verification Inline

Response Schema

Status Code 400

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code

Status Code 500

Name Type Required Restrictions Description
» type string true none Error identification
» title string true none Error summary
» details string true none Error details
» status integer(int64) true none Original HTTP status code