MOOCit Docs
English
English
  • Introduction
  • Getting Started with MOOCit
  • Take Your First Demo Course in Learner View
  • Studio vs LMS
  • Set Your Platform Language
  • Course Development
    • Create a New Course
      • Course Creation Form
    • Course Set-Up
      • Course Pacing and Schedule
      • Course Name, Description and Image
      • Add a Course 'About' Video
      • Additional Course Run Info
      • Prerequisite Course
      • Course Entrance Exam
    • Course Structure
      • Building the Course Outline - Video Tutorial
    • Course Content Visibility and Access
      • Subsection Prerequisites
      • Hiding Sections and/or Subsections
      • Hide a Subsection after Due Date
  • Course Properties
    • Manage Course Visibility
    • Make a Course Private
    • Course Grading Configuration
    • Delete a Course
    • Course Updates
    • Course Handouts
    • Certificate Configuration
    • Modify the Name of a Course (legacy)
  • Course Components
    • Common Problem Type
      • Checkboxes, Dropdown, Numerical & Text input
      • Add Multiple Questions
      • Add an explanation (Show Answer)
      • Hints and Feedback
      • About; Question Title, Header, Prompt & Tips
      • Common Problem Settings
    • Images
    • Advanced Components
    • SCORM file
    • PDF File
    • PDF viewer without download / print option
    • Downloadable Document Button
    • Surveys & Polls
    • Video - Youtube
    • Video - Vimeo
    • Staff Graded Assignment
    • Tables
    • Word Cloud
    • iFrame (Genial.ly, Prezi, etc.)
    • ZOOM Meeting (Dedicated Instance)
    • ZOOM (SaaS Integration)
    • H5P
  • Instructors
    • Manage Course Team
      • Add new team member
      • Add a Discussion Moderator/Admin
      • FAQ
    • Enroll / Unenroll Learners
    • Download Learner List
    • Download Learner Grades
    • Reset Learner Exercise Attempts
    • Email Learners
  • Advanced
    • Discussion Forums
      • Hide discussion forum
    • Configuration of Badges
    • Duplicate a Course (Import / Export a Course)
    • Using Randomized Content Blocks
    • Pointing on a Picture Question
    • Tips and Warnings
    • Learner Cohorts + Content Groups
      • Enabling and Configuring Cohorts
      • Create Cohort Specific Content with Content Groups
      • Assign Cohorts to Content Groups
      • Dividing Discussions by Cohort
  • Rest API
    • API home
    • Enrollments
    • Completion
    • Grades
  • Data + Analytics
    • Opening CSV reports with Excel
Propulsé par GitBook
Sur cette page
  • Get all enrollments
  • List all enrollments
  • Get enrollments by course
  • List enrollments by course
  • Get enrollments by username
  • List enrollments by username
  • Get enrollments by days
  • List enrollments by period
  • Bulk enroll or unenroll users
  • Bulk enroll

Cet article vous a-t-il été utile ?

  1. Rest API

Enrollments

API endpoints for getting or creating enrollments

Get all enrollments

List all enrollments

GET https://your-platform-url.com/api/so2/v1/enrollments

Get all course enrollments for your instance

Headers

Name
Type
Description

Access-Control-Request-Headers*

string

authorization

Authorization*

string

Bearer <auth_token>

Content-Type*

string

application/json

{"username":"johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-1",
"is_active":true,
"mode":"audit",
"created":"2021-03-09 20:15"
}, 
{"username":"JaneDoe",
"email":"jane@example.com",
"course_id":"course-v1:MOOCit-demo-2",
"is_active":true,
"mode":"audit",
"created":"2022-03-09 14:52"
}
...

Get enrollments by course

List enrollments by course

GET https://your-platform-url.com/api/so2/v1/enrollments?course_id={course_id}

Get course enrollments for a given course

Query Parameters

Name
Type
Description

course_id

string

the course_id course-v1:org+num+session

Headers

Name
Type
Description

Access-Control-Request-Headers*

string

authorization

Authorization*

string

Bearer <auth_token>

Content-Type*

string

application/json

{"username":"johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-1",
"is_active":true,
"mode":"audit",
"created":"2021-03-09 20:15"
}, 
{"username":"JaneDoe",
"email":"jane@example.com",
"course_id":"course-v1:MOOCit-demo-1",
"is_active":true,
"mode":"audit",
"created":"2022-03-09 14:52"
}
...

Get enrollments by username

List enrollments by username

GET https://your-platform-url.com/api/so2/v1/enrollments?username={username}

Get course enrollments for a given username

Query Parameters

Name
Type
Description

username

string

Headers

Name
Type
Description

Access-Control-Request-Headers*

string

authorization

Authorization*

string

Bearer <auth_token>

Content-Type*

string

application/json

{"username": "johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-1",
"is_active":true,
"mode":"audit",
"created":"2021-03-09 20:15"
}, 
{"username": "johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-2",
"is_active":true,
"mode":"audit",
"created":"2022-03-09 14:52"
}
...

Get enrollments by days

List enrollments by period

GET https://your-platform-url.com/api/so2/v1/enrollments?days={days}

Get course enrollments for the last past days

Query Parameters

Name
Type
Description

days

integer

Headers

Name
Type
Description

Access-Control-Request-Headers*

string

authorization

Authorization*

string

Bearer <auth_token>

Content-Type*

string

application/json

{"username": "johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-1",
"is_active":true,
"mode":"audit",
"created":"2021-03-09 20:15"
}, 
{"username": "johndoe",
"email":"john@example.com",
"course_id":"course-v1:MOOCit-demo-2",
"is_active":true,
"mode":"audit",
"created":"2022-03-09 14:52"
}
...

Bulk enroll or unenroll users

Bulk enroll

POST https://your-platform-url.com/api/bulk_enroll/v1/bulk_enroll/

This endpoint allows you enroll or unenroll users to one or several courses. Permissions needed : Be a course admin for the courses you want to enroll users to.

Headers

Name
Type
Description

Access-Control-Request-Headers

string

Authorization

string

Bearer <auth_token>

Content-Type

string

application/json

Request Body

Name
Type
Description

auto_enroll*

Boolean

true

email_students*

Boolean

true or false, set if you want to send email to notify users for enrollments

action*

String

enroll or unenroll

courses*

String

course_id separated with comma

cohorts*

String

cohorts name separated with comma

identifiers*

String

user email separated with comma

{
    "action": "enroll",
    "courses": {
        "course-v1:edX+DemoX+Demo_Course": {
            "action": "enroll",
            "results": [
                {
                    "identifier": "test-email@example.com",
                    "after": {
                        "enrollment": false,
                        "allowed": false,
                        "user": true,
                        "auto_enroll": true
                    },
                    "before": {
                        "enrollment": true,
                        "allowed": false,
                        "user": true,
                        "auto_enroll": true
                    }
                }
            ],
            "auto_enroll": true
        }
    },
    "email_students": true,
    "auto_enroll": true
}

PrécédentAPI homeSuivantCompletion

Dernière mise à jour il y a 2 ans

Cet article vous a-t-il été utile ?