Creating a Class
The first step goal is to create a new instructor-led class. We need to provide required information in the request body such as "courseId", "instructorIds", "contact" information, "externalRegistrationURL", "schedule", "timezone", "totalSeats" available, "price", etc. All required fields can be viewed in the schema view in the example below, or in the full documention of this endpoint under API reference in the sidebar.
To publish a class to an online marketplace set the "publishInMarketlace" field to true. A class can be published after it has been created by updating it through the PATCH /classes/:classId method. The Marketplace only displays future-dated classes. For example; if today is October 5th and you create a class to occur on October 5th, it will not show up in the Marketplace. The Marketplace will only display classes on or after October 6th.
If the course delivery method is OFFLINE then the "address" field is required in the request body. For the VIRTUAL delivery method the "virutalClassURL" field is required.
Some of the required information such as "courseId", and "instructorIds" can be retrieved using other Training Provider API endoints. We will go over these calls next.
Request Body Example and Schema
- Example
{
"address": {
"countryCode": "st",
"district": "string",
"extendedAddress": "string",
"locality": "string",
"name": "string",
"postalCode": "string",
"postOfficeBox": "string",
"region": "string",
"streetAddress": "string"
},
"contact": {
"email": "user@example.com",
"fax": "string",
"telephone": "string"
},
"courseId": "string",
"evaluatorIds": [
"string"
],
"externalRegistrationUrl": "string",
"instructorIds": [
"string"
],
"price": 0,
"publishInMarketplace": true,
"showPriceInMarketplace": true,
"schedule": [
{
"start": "2024-08-28T14:28:57.398Z",
"end": "2024-08-28T14:28:57.398Z"
},
{
"start": "2024-08-29T14:28:57.398Z",
"end": "2024-08-29T14:28:57.398Z"
},
{
"start": "2024-08-30T14:28:57.398Z",
"end": "2024-08-30T14:28:57.398Z"
}
],
"specialInstructions": "string",
"timezone": "string",
"totalSeats": 1,
"virtualClassURL": "string"
}
Getting a courseId
Use this endpoint to return a list of instructor-led courses for which class offerings can be created. The response body will contain other helpful information used when creating a class such as; "deliveryMethod", "maximumNumberOfSeats", "minimumNumberOfInstructors", "minimumNumberOfEvaluators", and "minimumNumberOfSchedules". The "minimumNumberOfSchedules" field refers to the minimum number of sessions required for a course.
Response Example and Schema
- Example
[
{
"id": "string",
"description": "string",
"name": "string",
"deliveryMethod": "string"
}
]
See our docs on Pagination to set limits on how many items are returned.
Getting a list of authorized Instructor and Evaluator Ids
Append any "courseId" in the path of this call to retrieve a list of instructors and evaluators who are authorized for this course.
Response Example and Schema
- Example
[
{
"id": "string",
"firstname": "string",
"lastname": "string",
}
]
We can now use the information retrieved from GET /instructor-led-courses and GET instructor-led-courses/:courseId/authorized-instructors to create a class! Successful calls will return an "id" referenced by classId in the next steps.