Delete Activity
This is a general LMS interface for deleting any type of activity.
Note:
- All types of activities (classrooms, assignments, tests, answer sheets, recurring assignments, discussions, etc.) can be deleted using this interface.
 
URL
https://root_url/lms/activity/delete
HTTP Request Methods
Request Data
| Key | 
Required | 
Type | 
Description | 
| X-EEO-SIGN | 
Yes | 
string | 
Signature; see the rules here | 
| X-EEO-UID | 
Yes | 
string | 
Institution's SID | 
| X-EEO-TS | 
Yes | 
string | 
Timestamp | 
Body Parameters
| key | 
Required | 
Type | 
Description | 
Rules Description | 
| courseId | 
Yes | 
integer | 
Class (Course) ID | 
 | 
| activityId | 
Yes | 
integer | 
Activity ID returned after creation | 
Currently, only one activity can be deleted at a time; multiple ID values are not supported. | 
Response Data
| Parameter Name | 
Type | 
Example Value | 
Description | 
| code | 
integer | 
1 | 
Error code | 
| msg | 
string | 
"Execution successful" | 
Error message | 
| data | 
array | 
[] | 
Reponse array | 
|  └ | 
object | 
 | 
Reponse object | 
|   └ activityId | 
integer | 
25096096 | 
Activity ID | 
|   └ name | 
string | 
"API Deleted Activity" | 
Activity name | 
Example
POST /lms/activity/delete HTTP/1.1
 root_url
 8b2db2eb7bd300f833621a577f38e0b3
 409864
 1722938275
 application/json
 84
{
    "courseId": 414193,
    "activityId": 25096096
}
- Shell cURL analog request instruction
 
curl -X POST \
     -H 'Host: root_url' \
     -H 'X-EEO-SIGN: 8b2db2eb7bd300f833621a577f38e0b3' \
     -H 'X-EEO-UID: 409864' \
     -H 'X-EEO-TS: 1722938275' \
     -H 'Content-Type: application/json' \
     -d '{"courseId": 414193, "activityId": 25096096}' \
     'https://root_url/lms/activity/delete'
Response sample(The normal return json packet example)
{
    "code": 1,
    "msg": "Execution successful",
    "data": {
        "activityId": 25096096,
        "name": "API Deleted Activity"
    }
}
Error Code Descriptions
| Error Code | 
Description | 
| 147 | 
No information for this class | 
| 29149 | 
Activity has been deleted | 
| 30002 | 
Activity does not exist | 
| 40005 | 
Classroom activity cannot be deleted while in progress | 
| 40006 | 
Classroom activity has ended and cannot be deleted | 
| 101001001 | 
Parameter error | 
| 101002005 | 
Signature exception | 
| 101002006 | 
Timestamp expired | 
| 101002008 | 
Timestamp does not exist | 
| 121601020 | 
Business parameter error | 
| 121601021 | 
This class does not belong to your institution | 
| 121601022 | 
This is not a standard class | 
| 121601023 | 
This class has been dissolved and cannot be operated |