Description | Each operation is associated with a unique value or ID known as the activity ID. Using this, you are able to get the details of a preferred operation. |
---|
Resource Path | /{id} |
---|
URL | /mdm-admin/operations/activity/{id} |
---|
HTTP Method | GET |
---|
Request/Response Format | application/json |
---|
cURL command | Code Block |
---|
curl -X GET -H "Content-Type: application/json" -H "Authorization: Bearer <EMM_API_TOKEN>" -k -v https://<EMM_HOST>:<EMM_HTTPS_PORT>/mdm-admin/operations/activity/{id} |
- For more information on how to generate the
<EMM_API_TOKEN> , see Generating the EMM API Token. - By default,
<EMM_HOST> is localhost. However, if you are using a public IP, the respective IP address or domain needs to be specified. - By default,
<EMM_HTTPS_PORT> has been set to 9443. However, if the port offset has been incremented by n , the default port value needs to be incremented by n . - Provide the unique ID associated with the operation as the value for
{id} . You can get the activity ID associated with the operation you wish to get details about by running the get device operation details REST API.
Example: Retrieve the operation details that correspond to ACTIVITY_1 . Code Block |
---|
curl -X GET -H "Content-Type: application/json" -H "Authorization: Bearer 9a0dc4b7c4729e7200e0eec0b8ec7168" -k -v https://localhost:9443/mdm-admin/operations/activity/ACTIVITY_1 |
|
---|
Sample output | Code Block |
---|
> GET /mdm-admin/operations/activity/ACTIVITY_1 HTTP/1.1
> User-Agent: curl/7.30.0
> Host: localhost:9443
> Accept: */*
> Content-Type: application/json
> Authorization: Bearer 9a0dc4b7c4729e7200e0eec0b8ec7168
>
< HTTP/1.1 200 OK
< Cache-Control: private
< Expires: Thu, 01 Jan 1970 05:30:00 IST
< Date: Fri, 29 Apr 2016 13:48:02 GMT
< Content-Type: application/json
< Content-Length: 158
< Server: WSO2 Carbon Server
{"code":"APPLICATION_LISTNOTIFICATION","type":"COMMANDPROFILE","id":17,"receivedTimeStampstatus":"COMPLETED","createdTimeStamp":"2016-05-12 2223:1928:3534.37913","isEnabled":falsetrue,"payLoad":"{\"message\":\"Hi John, Please come to meeting room\"}","activityId":"ACTIVITY_17","responses":[{"response":"[{\"package\timestamp":\"jp.naver.line.android\",\"isSystemApp\":false,\"version\":15050801,\"name\":\"LINE\"},{\"package\":\"com.pa.dslrremotecontrol\",\"isSystemApp\":false,\"version\":8,\"name\":\"DSLR%20Remote%20Control\"}]""Thu May 12 23:27:52 GMT+05:30 2016","status":"RECEIVED","deviceState":"unlocked"},"recievedTimeStamp":"2016-05-12 23:29:03.663"},{"response":{"timestamp":"Thu May 12 23:29:08 GMT+05:30 2016","status":"DISMISSED"},"recievedTimeStamp":"2016-05-12 2223:2030:2732.815161"}]}
|
|
---|
Sample JSON Output Definition | { APPLICATION_LIST COMMAND 1, "receivedTimeStamp2016-05-12 22:20:27.815", COMPLETED",
"createdTimeStamp":"2016-05-12 | 221935379 "isEnabled": false,
"isEnabled":true,
"payLoad":"{\"message\":\"Hi John, Please come to the meeting room\"}",
"activityId":"ACTIVITY_ | 1 { [ { "package": "jp.naver.line.android", "isSystemApp": false, "version": 15050801, "name": "LINE" }, { "package": "com.pa.dslrremotecontrol", "isSystemApp": false, "version": 8, "name": "DSLR%20Remote%20Control" } ], {
"timestamp":"Thu May 12 23:27:52 GMT+05:30 2016",
"status":"RECEIVED",
"deviceState":"unlocked"
},
"recievedTimeStamp":"2016-05-12 23:29:03.663"
},
{
"response":{
"timestamp":"Thu May 12 23:29:08 GMT+05:30 2016",
"status":"DISMISSED"
},
"recievedTimeStamp":"2016-05-12 | 222027815" } ]
Property | Definition |
---|
code | The code of the operation that you carried out. For example the code of the operation carried out to device info operation is DEVICE_INFO . | type | The operation type that was carried out on the device. The operations types can be one of the following: | id | The operations carried out on a device is recorded in a database table. The ID of the operation in the database table is given as the ID in the output. | status | The status of the operation that has been carried out on a device. The operation status can be any one of the following: IN-PROGRESS - The operation is processing on the EMM server side and has not yet been delivered to the device.PENDING - The operation is delivered to the device but the response from the device is pending.COMPLETED - The operation is delivered to the device and the server has received a response back from the device.ERROR - An error has occurred while carrying out the operation.
| receivedTimeStamp | The time WSO2 EMM received the response from the device. | createdTimeStamp | The time when the operation was requested to be carried out. | isEnabled | If the assigned value is true it indicates that a policy is enforced on the device. If the assigned value is false it indicates that a policy is not enforced on a device. | activityId
| The identifier used to identify the operation uniquely. | responses | Responses received for the above activity The response received by the device that contains the details of the operation you wished to get. |
|
---|
|