Add Students/Auditing Students to Course (Single)

Student are added to the course(single),Need SID, safekey, timeStamp, course ID, student and audit identification (1 is students, 2 is auditing), add account number, name to add, etc. Returns the description after execution.


HTTP Request Methods

  • POST

Coding Format

  • UTF-8

Request Data

Key Required More Restrictions Instructions Description
SID Yes Null School ID It is available through the application
safeKey Yes Fixed 32-bit all lowercase characters School authentication security key safeKey=MD5(SECRET+timeStamp)
timeStamp Yes Null Imestamp used by safeKey Unix Epoch timeStamp is the number of seconds passed by 00:00 (world standard time) on January 1, 1970
courseId Yes Null Course ID Null
identity Yes Null Student and audit identification(1 is student,2 is attend) Null
studentName No Null Only take effect when indentity=2 Null
studentUid Yes Null student UID Register the user UID returned by the user interface

Response Data

Key Type Sample Value Meaning
error_info object Return message object
└ errno number 1 Error code
└ error string "Normal execution" Error list


  • HTTP Request
POST /partner/api/course.api.php?action=addCourseStudent HTTP/1.1
Host: www.eeo13.test
Content-Type: application/x-www-form-urlencoded
Cache-Control: no-cache

  • Shell cURL analog request instruction
curl -H "Content-Type: application/x-www-form-urlencoded" -X "POST" \
      -d "SID=1234567" \
      -d "safeKey=0f7781b3033527a8cc2b1abbf45a5fd2" \
      -d "timeStamp=1484719085" \
      -d "courseId=442447" \
      -d "identity=1" \
      -d "studentUid=12234" \
      -d "studentName=张三" \

Response Sample(The normal return json packet example)

  "error_info": {
    "errno": 1,
    "error": "程序正常执行"

Error Code Description

Error Code Description
1 Successful execution.
100 Incomplete or incorrect parameters.
102 No permission(Security verification failed.).
104 Operation failure(Unknown error).
113 The mobile phone number has not been registered yet.
114 Server exception.
129 Course teachers cannot be set as students.
130 Exceeds the number of accounts that can be added.
134 Illegal mobile phone number.
144 There is no such course in your institution.
147 There is no information about the course.
149 The course has been deleted.
153 The course is expired and cannot be edited.
155 Student array data cannot be null.
163 The course student already exists.
164 The course auditing student already exists.
174 Teachers cannot be set as auditing students.
228 There is no such student in your institution.
332 Course teachers or co-teachers cannot be set as course students or course auditing students.
333 The course advisor cannot be set as a course student.
369 Do not support to operate this type of courses and lessons(public course).
400 The requested data is illegal.
841 Successfully added students to the course. Failed to synchronize class nicknames.
886 The student's account has been deleted by the user.
887 The auditing student's account has been deleted by the user.

results matching ""

    No results matching ""