API v2: Safes¶
directly regulates user access to monitored servers. It specifies available protocols’ features, policies and other details concerning users and servers relations.
Data Structures¶
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
string |
yes |
Read-only object identifier. Requires the following rights on object type |
|
string |
yes |
Unique safe’s name |
|
boolean; default value |
yes |
|
|
string |
if |
|
|
boolean; default value |
yes |
Enable sending login reason for connection |
|
boolean; default value |
yes |
|
|
boolean; default value |
yes |
Enable confirmation of each connection |
|
boolean; default value |
yes |
Enable generating OTP in the Access Gateway |
|
boolean; default value |
if |
Enable connecting to the session in browser |
|
boolean; default value |
yes |
|
|
number; default value |
yes |
|
|
number; default value |
yes |
|
|
number; default value |
yes |
|
|
string {none, read, write}; default value |
Access level to the notes |
|
|
number; default value |
yes |
How many voters will be voting for the access request |
|
string |
no |
Target destination ID for storing session data |
|
string |
no |
Read-only; expensive to use |
|
SafeRDPAttributes |
If |
|
|
SafeSSHAttributes |
If |
|
|
SafeVNCAttributes |
If |
|
|
string-array |
Read-only. List of rights the subject has to this object. |
|
|
datetime |
Read-only |
|
|
datetime |
Read-only |
|
|
boolean |
Read-only |
|
|
datetime |
Read-only |
|
|
object-array |
Read-only; expensive to use; JSON object array containing |
|
|
string-array |
Read-only; hidden; expensive to use |
|
|
string-array |
Read-only; hidden; expensive to use |
|
|
object-array |
Read-only; expensive to use |
|
|
string-array |
Read-only; hidden; expensive to use |
|
|
string-array |
Read-only; hidden; expensive to use |
|
|
object-array |
Read-only; expensive to use |
|
|
number-array |
Read-only; hidden; expensive to use |
|
|
string-array |
Read-only; hidden; expensive to use |
|
|
boolean |
Read-only; expensive to use; if |
|
|
boolean |
Read-only; expensive to use; if |
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
boolean; default value |
yes |
Audio input redirection |
|
boolean; default value |
yes |
Clipboard redirection |
|
string |
Custom content to be added to the RDP configuration file when the native client RDP connection is requested via Access Gateway. |
|
|
number {8, 16, 24, 32} |
no |
Max. color depth |
|
boolean; default value |
yes |
|
|
boolean; default value |
yes |
Sound redirection |
|
boolean; default value |
yes |
|
|
string {800x600, 1024x600, 1024x768, 1152x864, 1280x720, 1280x768, 1280x800, 1280x960, 1280x1024, 1360x768, 1400x1050, 1440x900, 1600x900, 1680x1050, 1600x1200, 1920x1080, 1920x1200, 2048x1152, 2560x1440, 2560x1600} |
no |
Max. resolution |
|
boolean; default value |
yes |
Enable content to not be available for viewing when the user minimizes its client application |
|
boolean; default value |
yes |
Attribute |
Type |
Required |
|---|---|---|
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
|
boolean; default value |
yes |
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
boolean; default value |
yes |
Enable a user to be allowed to paste text into the VNC server computer |
|
boolean; default value |
yes |
Enable a user to be allowed to copy and paste text from the VNC server computer into the user’s computer |
Get Available Attributes of the SafeModel¶
Request
Method |
|
Path |
|
Data Structures: UserSafeAssignmentModel¶
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
string |
yes |
Read-only object Identifier. |
|
string |
yes |
Immutable. Uniqueness is required in the combination of attribute |
|
object-array |
Read-only. Expensive to use. |
|
|
string-array |
Read-only. Hidden. Expensive to use. |
|
|
string-array |
Read-only. Hidden. Expensive to use. |
|
|
string |
yes |
Immutable. Uniqueness is required in the combination of attribute |
|
boolean; default value |
yes |
Access to this safe is disabled for the user. |
|
number |
||
|
boolean; default value |
yes |
Allow a user to use Secret Checkout feature and view passwords in the Access Gateway. |
|
string |
Read-only; Expensive to use. Checksum computed from time policies used for this user-safe connection. |
|
|
boolean; default value |
yes |
|
|
datetime (h:m:s); default value |
yes |
Beginning access time. |
|
datetime (h:m:s); default value |
yes |
Ending access time. |
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
datetime |
Read-only. |
|
|
datetime |
Read-only. |
|
|
boolean |
Read-only. |
|
|
boolean |
Read-only; Expensive to use; If |
|
|
boolean |
Read-only; Expensive to use; If |
Retrieve Available Attributes of the UserSafeAssignmentModel¶
Request
Method |
|
Path |
|
Data Structures: UserSafeTimePolicyAssignmentModel¶
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
string |
yes |
Read-only object Identifier. |
|
string |
Read-only object Identifier. |
|
|
string |
yes |
Immutable. Requires |
|
string |
yes |
Immutable. Requires |
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
string |
Read-only; Expensive to use. |
|
|
number |
yes |
Value range from |
|
datetime (h:m:s) |
yes |
Beginning access time. |
|
datetime (h:m:s) |
yes |
Ending access time. |
|
datetime |
Read-only. |
|
|
datetime |
Read-only. |
|
|
boolean |
Read-only. |
Retrieve Available Attributes of the UserSafeTimePolicy - AssignmentModel¶
Request
Method |
|
Path |
|
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
string |
yes |
Read-only, protected object Identifier |
|
string |
yes |
Immutable. Uniqueness is required in the combination of attribute |
|
string |
no |
Immutable. Uniqueness is required in the combination of attribute |
|
string |
Read-only; expensive to use |
|
|
string |
Read-only; expensive to use |
|
|
datetime |
Read-only. Timestamp of creation. |
|
|
datetime |
Read-only. Timestamp of modification. |
|
|
boolean |
Read-only. |
Retrieve Available Attributes of the SafePolicyAssignmentModel¶
Request
Method |
|
Path |
|
To check allowed methods, available URL parameters and possible responses please refer to the API Overview section.
Refer to the Batch operations topic to create nested requests for operating on the Safe objects.
Get Safes List¶
Request
Method |
|
Path |
|
Example Request
GET /api/v2/safe
Response
{ "result": "success",
"safe": [
{
"id": "123678819172646913",
"name": "main",
"blocked": false,
"login_reason": false,
"use_ticketing_system": false,
"require_confirmation": false,
"otp_in_access_gateway": true,
"webclient": true,
"confirmation_timeout": 5,
"inactivity_limit": 0,
"time_limit": 0,
"note_access": "none",
"required_votes": 0,
"rdp_audin": true,
"rdp_cliprdr": true,
"rdp_rdpdr": true,
"rdp_rdpsnd": true,
"rdp_rdrynvc": true,
"rdp_suspend": true,
"rdp_tsmf": true,
"ssh_agent": true,
"ssh_environment": true,
"ssh_exec": true,
"ssh_port_forwarding": true,
"ssh_scp": true,
"ssh_session": true,
"ssh_shell": true,
"ssh_sftp": true,
"ssh_terminal": true,
"ssh_x11": true,
"vnc_clipcli": true,
"vnc_clipsrv": true,
"created_at": "2022-10-20 02:01:38.366865-07",
"modified_at": "2022-10-26 03:26:45.530129-07",
"last_login": "-infinity",
"accounts": [
"122678819172646913",
"1232678819172646914",
"1232678819172646919"
]}]}
Create a Safe¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
Example Request
POST /api/v2/safe
{ "name": "my-1st-safe" }
Response
{ "result": "success",
"safe": {
"id": "1232678819172646915" }}
Get a Safe¶
Request
Method |
|
Path |
|
Example Request
GET /api/v2/safe/<id>
Response
{ "result": "success",
"safe": {
"id": "1232678819172646915",
"name": "my-1st-safe",
"blocked": false,
"login_reason": false,
"use_ticketing_system": false,
"require_confirmation": false,
"otp_in_access_gateway": true,
"webclient": true,
"confirmation_timeout": 5,
"inactivity_limit": 0,
"time_limit": 0,
"note_access": "none",
"required_votes": 0,
"rdp_audin": true,
"rdp_cliprdr": true,
"rdp_rdpdr": true,
"rdp_rdpsnd": true,
"rdp_rdrynvc": true,
"rdp_suspend": true,
"rdp_tsmf": true,
"ssh_agent": true,
"ssh_environment": true,
"ssh_exec": true,
"ssh_port_forwarding": true,
"ssh_scp": true,
"ssh_session": true,
"ssh_shell": true,
"ssh_sftp": true,
"ssh_terminal": true,
"ssh_x11": true,
"vnc_clipcli": true,
"vnc_clipsrv": true,
"created_at": "2022-10-27 02:26:22.951762-07",
"modified_at": "2022-10-27 02:26:22.951762-07",
"last_login": "-infinity" }}
Modify a Safe¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
Example Request: Enabling the Just-in-Time Feature for a Safe That Would Wait for 5 Authorized Users to Vote for Access
PATCH /api/v2/safe/<id>
{ "required_votes": 5}
Response
{ "result": "success" }
Delete a Safe¶
Request
Method |
|
Path |
|
Get Users’ Time Policy Settings Within Safes¶
Request
Method |
|
Path |
|
Example Request
GET /api/v2/user/safe/time_policy
Response (User’s time policy is declared separately for each day)
{
"result": "success",
"user_safe_time_policy": [
{
"id": "4602678819172646913",
"safe_id": "4602678819172646913",
"user_id": "1232678819172646915",
"day_of_week": 2, <--- A user has access to the safe on Tuesday
"valid_from": "09:00:00", <--- User's access starts at 9:00
"valid_to": "14:00:00", <--- and ends at 14:00
"created_at": "2022-10-26 02:25:19.155648-07",
"modified_at": "2022-10-26 02:30:40.677788-07"
},
{
"id": "4602678819172646914",
"safe_id": "4602678819172646913",
"user_id": "1232678819172646915",
"day_of_week": 3, <--- A user has access to the safe on Wednesday
"valid_from": "09:15:00", <--- User's access starts at 9:15
"valid_to": "14:15:00", <--- and ends at 14:15
"created_at": "2022-10-26 02:32:11.781045-07",
"modified_at": "2022-10-26 02:32:11.781045-07"
}]}
Modify a User’s Time Policy Settings Within a Safe¶
Request
Method |
|
Path |
|
Body |
|
Example Request: Changing the Day of User’s Access to Monday
PATCH /api/v2/user/safe/time_policy/<id>
{ "day_of_week": 1}
Response
{ "result": "success" }
Get User’s Settings Within a Safe¶
Request
Method |
|
Path |
|
Modify a User Within a Safe¶
Request
Method |
|
Path |
|
Body |
|
Example Request: Allow a User to Use Secret Checkout Feature and View Passwords in the Access Gateway
PATCH /api/v2/user/<user_id>/safe/<safe_id>
{"password_visible": true}
Response
{ "result": "success" }
Delete a User From a Safe¶
Request
Method |
|
Path |
|
Get Users Allowed to Manage Selected Safe¶
Request
Method |
|
Path |
|
Get Account-Safe-Listener Assignments List¶
Request
Method |
|
Path |
|
Create an Account-Safe-Listener Assignments¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
Example Request
POST /api/v2/account/safe/listener
{ "account_id": 1232678819172646919,
"safe_id": 1232678819172646913,
"listener_id": 1232678819172646914 }
Response
{ "result": "success",
"account_safe_listener": {} }
Delete an Account-Safe-Listener Assignment¶
Request
Method |
|
Path |
|
Get Safe-Policy Assignments List¶
Request
Method |
|
Path |
|
Example Request
GET /api/v2/safe/policy/
curl -s -k -X GET -H 'Authorization: sgfeea6jsaz4mum9su8w61877n1g06sk' /api/v2/safe/policy
Response
{
"result": "success",
"safe_policy": [
{
"safe_id": "9124292845052624898",
"policy_id": "9124292845052624898",
"safe_name": "RDP_Safe",
"policy_name": "AI_Policy_1",
"created_at": "2024-06-21 06:15:12.135699-07",
"modified_at": "2024-06-21 06:15:12.135699-07"
}
]
}
Checking Safe-Policy Assignment by ID¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
Example Request
GET /api/v2/safe/<safe_id>/policy/<policy_id>
curl -s -k -X GET -H 'Authorization: sgfeea6jsaz4mum9su8w61877n1g06sk' /api/v2/safe/9124292845052624898/policy/9124292845052624898
Response
{
"result": "success",
"safe_policy": [
{
"safe_id": "9124292845052624898",
"policy_id": "9124292845052624898",
"safe_name": "RDP_Safe",
"policy_name": "AI_Policy_1",
"created_at": "2024-06-21 06:15:12.135699-07",
"modified_at": "2024-06-21 06:15:12.135699-07"
}
]
}
Create an Safe-Policy Assignments¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
Example Request
POST /api/v2/safe/policy
curl -s -k -X POST -H 'Authorization: sgfeea6jsaz4mum9su8w61877n1g06sk' /api/v2/safe/policy \
-H 'Content-Type: application/json' \
-d '{"safe_id":"9124292845052624898","policy_id":"9124292845052624898"}'
Response
{
"result": "success"
}
Delete a Safe-Policy Assignment¶
Request
Method |
|
Path |
|
Example Request
DELETE /api/v2/safe/<safe_id>/policy/<policy_id>
curl -s -k -X DELETE -H 'Authorization: sgfeea6jsaz4mum9su8w61877n1g06sk' /api/v2/safe/9124292845052624898/policy/9124292845052624898
Response
{
"result": "success"
}