API reference / Enrolments
Enrol someone in a course
POST
/v1/enrolmentsNeeds a bearer access token with the enrolments.write scope. How authentication works
Finds the learner by email, or creates a new Florisage account for them if none exists yet, links them to your organization, and consumes one of your purchased seats for the course. Fires an enrolment.created webhook once it's done. A brand-new learner is emailed a one-time code to set their own password — their account exists and the enrolment is active immediately, they just can't log in and start the course until they do that.
Request bodyapplication/jsonrequired
emailstringrequiredfirst_namestringlast_namestringcourse_idstring · uuidrequiredsource_idstringYour own foreign id for this enrolment, for later lookup via /v1/enrolments/by-source-id.
Responses
- 201Enrolment created
Response fields
dataEnrolmentidstring · uuiduser_idstring · uuidcourse_idstring · uuidstatusstringAllowed values:
in_progresscompletedenrolled_atstring · date-timecompleted_atstring · date-timenullableaccess_expires_atstring · date-timenullable
- 400Invalid request (e.g. no seats available)Example response
{ "error": { "code": "invalid_request", "message": "Invalid request (e.g. no seats available)." } }
