Skip to main content
POST
/
edubridge
/
enrollments
/
enroll
/
{userId}
/
{courseId}
/
{schoolId}
?
Enroll user in a course
curl --request POST \
  --url https://api.alpha-1edtech.ai/edubridge/enrollments/enroll/{userId}/{courseId}/{schoolId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "sourcedId": "<string>",
  "role": "student",
  "beginDate": "2023-11-07T05:31:56Z",
  "metadata": {
    "goals": {
      "dailyXp": 123,
      "dailyLessons": 123,
      "dailyActiveMinutes": 123,
      "dailyAccuracy": 123,
      "dailyMasteredUnits": 123
    },
    "metrics": {
      "totalXp": 123,
      "totalLessons": 123,
      "totalGrades": 123,
      "courseType": "<string>",
      "isSupplemental": true
    }
  }
}
'
{
  "data": {
    "id": "123",
    "role": "administrator",
    "beginDate": "<string>",
    "endDate": "<string>",
    "course": {
      "id": "<string>",
      "title": "<string>",
      "metadata": {},
      "subjects": [
        "<string>"
      ],
      "grades": [
        "<string>"
      ],
      "primaryApp": {
        "id": "<string>",
        "name": "<string>",
        "domains": [
          "<string>"
        ]
      }
    },
    "school": {
      "id": "<string>",
      "name": "<string>"
    },
    "metadata": {
      "goals": {
        "dailyXp": 123,
        "dailyLessons": 123,
        "dailyActiveMinutes": 123,
        "dailyAccuracy": 123,
        "dailyMasteredUnits": 123
      },
      "metrics": {
        "totalXp": 123,
        "totalLessons": 123,
        "totalGrades": 123,
        "courseType": "<string>",
        "isSupplemental": true
      }
    }
  }
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

userId
string
required

The unique identifier for the user

courseId
string
required

The unique identifier for the course

schoolId
string

The unique identifier for the school

Body

application/json
sourcedId
string

Optional client-provided ID for the enrollment

role
enum<string>
default:student
Available options:
administrator,
proctor,
student,
teacher
beginDate
string<date-time>

The date the user is enrolled in the course, defaults to today

metadata
object

Response

201 - application/json

Successful response

data
object
required