ClassMarker exam integration

Feeling a bit lost? Have a quick look over the ClassMarker concepts.

The following steps describe how developers can customize ClassMarker exam integration in a website.

Use your own user IDs with ClassMarker


You can use your own user IDs for ClassMarker exams by automatically appending value cm_user_id to the link your users select to take an exam (such as if they are logged on to your website).

cm_user_id holds the user ID for your system (or any other string you might want to use for tracking purposes). It is an alphanumeric string of up to 100 characters.

You can use the cm_user_id string to:

The value is saved with user exam results, so you can view it and export it with exam results in ClassMarker, and retrieve it with webhooks and API requests.

Restrict access by user ID

You can also require that exams can only be taken when a cm_user_id is supplied, and limit each user to one attempt only per exam in the exam link settings.

Pre-populate user details

GET example{QUIZ_ID}

POST example

<form action="" method="post">
    <input type="hidden" name="quiz" value="{QUIZ_ID}"/>
    <input type="hidden" name="cm_fn" value="John"/>
    <input type="hidden" name="cm_ln" value="Smith"/>
    <input type="hidden" name="cm_e" value=""/>
    <input type="hidden" name="cm_user_id" value="123"/>
    <input type="hidden" name="cm_access_list_item" value="456"/>
    <input type="submit" value="Take your online test"/>

Embed Exam example

<script src="{quid_id}&cm_fn=John&cm_ln=Smith&
&cm_user_id=123&cm_access_list_item=456" data-quiz="{quid_id}" data-width="700" data-height="800" ></script>

When using links for exams, you can send user details to ClassMarker to save them having to fill in their name and email address (should you select to require their details) before they start the exam.

When you assign your exam to a link, you are given the unique link for your exam. This is the link you can send user details to.

Send details using either GET or POST with the following parameter names:

cm_fn=First name (optional) cm_ln=Last name (optional) cm_e=Email (optional) cm_user_id=123 (optional - see above) cm_access_list_item=456 (optional - see below)

Restrict access using access lists

When testing non-registered users directly via a link or by embedding exams within your website, as well as password protecting your exams, you also have the option to restrict user access to your exams by using access lists.

An access list is a list of unique identifiers (for example, email address, employee IDs) that a user must use to access your exams. You can limit how many times each unique identifier can be used per exam. IDs are recorded along with exam results.

You can learn more about access lists here.

Both access list items (cm_access_list_item) and user IDs (cm_user_id) values can be exported to Excel format with exam results, date taken, exam duration and IP address.

These methods do not require users to be registered to take your exams, and if using access lists you can batch import identifiers when creating and editing lists.

There are two ways access lists can be used in ClassMarker for taking exams:

Manage access lists with the ClassMarker API

You can add and remove access list items using the ClassMarker API.

You may want to add an access code to an access list when:

You may want to remove an access code from an access list when:

See the ClassMarker API Access lists endpoint for guidance on automating the process of adding and removing access codes.

Return users and results to your website

ClassMarker lets you set a return link for users to return to your website after they have completed their exam. You can opt to append user details, exam results and duration appended to the return link for you to record in real time on your own website.



cm_ts=Test Score (Points scored)
cm_tsa=Test Score Available (Total points available)
cm_tp=Test Percentage
cm_td=Test Duration (0-12-35 = 0h 12m 35s)
cm_fn=first name
cm_ln=last name
cm_e=email address

To include a return link with exam results:

  1. In your ClassMarker account, assign a new exam (or an existing exam) to a link.
  2. In the Test Completion section, expand Return link, then expand Advanced and check option Append 'Test results' parameters to return link.

Each time a user completes your exam and clicks your return link, the test scores will be sent to your website via the return link.

cm_ts, cm_tsa and cm_tp are given to one decimal place, if applicable, for example 50 or 50.1. You need to ensure your system will accept a value to 1 decimal place.

For a better approach to passing these parameters in real time, check out our webhooks.

You can also add your own unique parameters to be returned to you in return links, by adding prefix cm_return_ to parameter names.

For example, cm_return_employee_id will be returned to you as https://yourreturnURL&cm_return_employee_id=1234

Receive exam results in real time with webhooks

You can set up a script to retrieve exam results in real time using webhooks. You can find more details in the webhooks documentation.

ClassMarker sends exam results securely to your website for you to save in your database and use as required.

Exam results use the cm_user_id parameter you sent to ClassMarker, so if, for example, this is a user ID from your system, then you know who the exam results belong to.

You can also receive a unique URL to record in your database (one URL per exam result), to allow users to view their test results again in the future. For more details, see View results URL.

Customize your exam branding

You can add your own logos and colors to customize your exams to reflect your own branding.

  1. In your ClassMarker Account, open Links.
  2. In the Themes tab, click New Theme.
  3. Upload a logo image.
  4. Customize the other display elements including colors, layout, text, and so on.
  5. Click Save and preview theme.