Group-Safe-TimePolicy Management¶
Endpoints in this section allow you to manage the time policy for accessing safes assigned to a group.
Data Structures¶
Attribute |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Read-only. Unique identifier. |
|
|
string |
Read-only; protected. |
|
|
string |
yes |
Immutable. Requires rights on the |
|
string |
yes |
Immutable. Requires |
|
string |
Read-only; expensive to use. |
|
|
string |
Read-only; expensive to use. |
|
|
number |
yes |
Value range from |
|
datetime |
yes |
Daily access start time. |
|
datetime |
yes |
Daily access end time. |
|
datetime |
Read-only. Timestamp of creation. |
|
|
datetime |
Read-only. Timestamp of modification. |
|
|
boolean |
Read-only. |
Retrieve Available Attributes of the GroupSafeTimePolicyModel¶
Request
Method |
|
Path |
|
GET /api/v2/objspec/group_safe_time_policy
Example Request
curl -s -k -X GET \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
'https://10.31.135.179/api/v2/objspec/group_safe_time_policy'
Get Group-Safe-TimePolicy Assignment List¶
Request
Method |
|
Path |
|
GET /api/v2/group/safe/time_policy
Example Request
curl -s -k -X GET \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
'https://10.0.214.98/api/v2/group/safe/time_policy'
Response
{
"result": "success",
"group_safe_time_policy": [
{
"id": "9115285645797883905",
"group_id": "9115285645797883906",
"safe_id": "9115285645797883907",
"group_name": "QA_team",
"safe_name": "SSH",
"day_of_week": 1,
"valid_from": "06:00:00",
"valid_to": "08:00:00",
"created_at": "2025-05-08 03:12:37.235474-07",
"modified_at": "2025-05-08 03:12:37.235474-07"
},
{
"id": "9115285645797883906",
"group_id": "9115285645797883906",
"safe_id": "9115285645797883907",
"group_name": "QA_team",
"safe_name": "SSH",
"day_of_week": 1,
"valid_from": "10:00:00",
"valid_to": "12:00:00",
"created_at": "2025-05-08 03:12:37.254555-07",
"modified_at": "2025-05-08 03:12:37.254555-07"
},
{
"id": "9115285645797883909",
"group_id": "9115285645797883906",
"safe_id": "9115285645797883907",
"group_name": "QA_team",
"safe_name": "SSH",
"day_of_week": 2,
"valid_from": "08:00:00",
"valid_to": "10:00:00",
"created_at": "2025-05-08 03:12:37.302277-07",
"modified_at": "2025-05-08 03:12:37.302277-07"
},
]
}
Get Group-Safe-TimePolicy Assignment by ID¶
Request
Method |
|
Path |
|
GET /api/v2/group/safe/time_policy/<id>
Example Request
curl -s -k -X GET \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
'https://10.0.214.98/api/v2/group/safe/time_policy/9115285645797883909'
Response
{
"result": "success",
"group_safe_time_policy": {
"id": "9115285645797883909",
"group_id": "9115285645797883906",
"safe_id": "9115285645797883907",
"group_name": "QA_team",
"safe_name": "SSH",
"day_of_week": 2,
"valid_from": "08:00:00",
"valid_to": "10:00:00",
"created_at": "2025-05-08 03:12:37.302277-07",
"modified_at": "2025-05-08 03:12:37.302277-07"
}
}
Create Group-Safe-TimePolicy Assignment¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
POST /api/v2/group/safe/time_policy
Example Request
curl -s -k -X POST \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
-H 'Content-Type: application/json' \
'https://10.0.214.98/api/v2/group/safe/time_policy' \
-d'{"group_id":"9115285645797883906","safe_id":"9115285645797883907","day_of_week":5,"valid_from":"06:00:00","valid_to":"12:00:00"}'
Response
{
"result": "success",
"group_safe_time_policy": {
"id": "9115285645797883914"
}
}
Modify Group-Safe-TimePolicy Assignment¶
Request
Method |
|
Path |
|
Headers |
|
Body |
|
PATCH /api/v2/group/safe/time_policy/<id>
Example Request
curl -s -k -X PATCH \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
-H 'Content-Type: application/json' \
'https://10.31.135.179/api/v2/group/safe/time_policy/9115285645797883915' \
-d'{"day_of_week":3,"valid_from":"06:00:00","valid_to":"12:00:00"}'
Response
{
"result": "success"
}
Delete Group-Safe-TimePolicy Assignment¶
Request
Method |
|
Path |
|
DELETE /api/v2/group/safe/time_policy/<id>
Example Request
curl -s -k -X DELETE \
-H 'Authorization: sgfeea6jsaz4mum9su8w6' \
'https://10.31.135.179/api/v2/group/safe/time_policy/9115285645797883915'
Response
{
"result": "success"
}