Querying User Synchronization Tasks
Function
This API is used to query user synchronization tasks.
Calling Method
For details, see Calling APIs.
URI
GET /v1/{project_id}/security/member-sync-tasks
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Project ID. For details about how to obtain the project ID, see Project ID and Account ID. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| limit | No | Integer | Number of items displayed on each page |
| offset | No | Integer | Offset, which is the position where the query starts. The value must be greater than or equal to 0. |
| cluster_type | No | String | Cluster Type
|
| cluster_name | No | String | Cluster Name |
| sync_status | No | String | Synchronization status
|
| schedule_status | No | String | Scheduling status of user synchronization tasks
|
| order_by | No | String | Sorting field.
|
| order_by_asc | No | Boolean | Whether to sort results in ascending order. This parameter is valid only when the sorting parameter is specified. |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| workspace | Yes | String | Workspace ID. For details about how to obtain the workspace ID, see Instance ID and Workspace ID. |
| X-Auth-Token | Yes | String | IAM token, which is obtained by calling the IAM API for obtaining a user token (value of X-Subject-Token in the response header). This parameter is mandatory for token authentication. |
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| total | Long | Number of user synchronization tasks |
| tasks | Array of MemberSyncTask objects | User synchronization tasks |
| Parameter | Type | Description |
|---|---|---|
| id | String | User synchronization task ID |
| project_id | String | Project ID. |
| domain_id | String | vStore ID. |
| instance_id | String | Instance ID. |
| data_connection_workspace | String | ID of the workspace where the data connection is located |
| cluster_type | String | Cluster Type
|
| data_connection_id | String | Data connection ID |
| data_connection_name | String | Data connection name |
| cluster_id | String | Cluster ID |
| cluster_name | String | Cluster name. |
| schedule_start_hour | Integer | Scheduling start time, accurate to hour. The value ranges from 0 to 23. |
| schedule_end_hour | Integer | Scheduling end time, accurate to hour. The value ranges from 0 to 23. |
| schedule_period | String | Scheduling Period
|
| schedule_interval | Integer | Scheduling interval |
| schedule_status | String | Scheduling status.
|
| sync_status | String | Synchronization Status
|
| sync_msg | String | Synchronization log |
| sync_time | Long | Synchronization time |
| create_time | Long | Creation time. |
| create_user | String | Creator |
| update_time | Long | Update time. |
| update_user | String | Updater |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Error code. |
| error_msg | String | Error message. |
Example Requests
/v1/0833a5737480d53b2f25c010dc1a7b88/security/member-sync-tasks
Example Responses
Status code: 200
OK
{
"tasks" : [ {
"cluster_id" : "c94a9133-ef65-47ad-9483-bfa8c5eaa101",
"cluster_name" : "dws_ssl_4autotest_nomodify",
"cluster_type" : "DWS",
"create_time" : 1710856132000,
"create_user" : "ei_dayu_xxxx_01",
"data_connection_id" : "3190d3fa8bad4de19c20572b181eb00c",
"data_connection_name" : "dws_0319",
"data_connection_workspace" : "f7bc8f2a71524d268c4293974e3dc35b",
"domain_id" : "0833a5736980d53b0f22c0102ffcbfc0",
"id" : "088c2b59114405ab4fbc0df5bd05202b",
"instance_id" : "dd97167b873d4a79b2aad54d4370a3bc",
"project_id" : "0833a5737480d53b2f25c010dc1a7b88",
"schedule_end_hour" : 6,
"schedule_interval" : 4,
"schedule_period" : "HOUR",
"schedule_start_hour" : 0,
"schedule_status" : "NOT_SCHEDULE",
"sync_msg" : "[2024-03-20 10:25:54] ===> Submit job to datamanager failed:[{\"duration\":0.0,\"jobId\":\"9324a84d-e151-44ee-aafc-c6a6c2084b0c\",\"jobType\":\"\",\"message\":\"ERROR: role \\\"iam_group_xxxx\\\" cannot be dropped because some objects depend on it\\n Detail: target of row level security policy dls_xxxx_userANDgroups on table all_data_type_0805_03\\ntarget of row level security policy dls_xxxx_ALLgroups on table all_data_type_0805_03\\ntarget of row level security policy dls_xxxx_asdasdsd on table absx\",\"rowCount\":0,\"rows\":[],\"schema\":[],\"status\":\"FAILED\",\"totalRowCount\":0}]",
"sync_status" : "SYNC_FAIL",
"sync_time" : 1710901516000,
"update_time" : 1710856132000,
"update_user" : "ei_dayu_xxxx_01"
} ],
"total" : 1
} Status Codes
| Status Code | Description |
|---|---|
| 200 | OK |
| 400 | Bad Request |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.