With the generic link you can automatically enroll and unsubscribe participants for e-learnings. You can set this up with the instructions below.


Authorization via OAuth 2.0

OAuth 2.0 with 'Authorization code grant' is used for the authorization.

The e-learning package provides Coachview with an access token (bearer token) in combination with a refresh token. This allows Coachview to authorize the e-learning package and control the registration and deregistration of a participant. The token is sent in the header.


Documentation

: https://oauth.net/2/


Working method

A single endpoint is used with which both registration and deregistration are possible. Registration via POST and deregistration via DELETE.


Register at (HTTP Method: POST)

The data required to register one participant will be sent in JSON format.

Example:

{
  "PersoonExterneId": "p12345",
  "PersoonVoornaam": "Jan",
  "PersoonTussenvoegsels": "",
  "PersoonAchternaam": "Jansen",
  "PersoonEmailadres": "jan@jansen.nl",
  "Elearningcode": "e12345"
  }


N.B.: The e-learning package ensures that it is checked whether the user exists and whether the user needs to be created and/or modified.


Unsubscribe (HTTP Method: DELETE)

The data required to unsubscribe a participant are sent along as parameters.

Example:

PersoonExterneId=p12345&Elearningcode=e12345



HTTP Status codes

The standard HTTP status codes are assumed, whereby status 200 means that the message has been successfully processed.

Other status status codes should have a clear message describing what goes wrong.

Documentation:

 https://developer.mozilla.org/nl/docs/Web/HTTP/Status