Configure a SCIM gateway

TABLE OF CONTENTS
Introduction
Roles and Responsibilities
Prerequisites
Preparing Lära LMS
Creating the Enterprise Application
Configuring Provisioning
Mapping and Synchronizing Users
Synchronizing Branches and Groups
Managing Permission Profiles
Updates After Initial Creation
Validating in Preproduction
Moving to Production
Troubleshooting

Notes
I. The SCIM connector is configured as part of an implementation project. The Tenant URL and the Secret Token are securely provided by the Lära team.
II. Complete validation in the preproduction environment is mandatory before any synchronization is enabled in production.
III. This article assumes that the stakeholders involved have the required permissions in Microsoft Entra ID and Lära LMS. Access should follow the principle of least privilege.
IV. The Secret Token must never be included in a public document, screenshot, or unsecured email. It should be renewed according to the organization’s security practices.

Introduction

SCIM (System for Cross-domain Identity Management) is a standard used to automate the exchange of user and group information between Microsoft Entra ID and Lära LMS. The Lära SCIM gateway receives the data authorized by the client, creates the corresponding elements in the LMS, and applies subsequent updates without requiring each account to be managed manually.

In this integration, Microsoft Entra ID remains the source of the synchronized data. Lära LMS receives users, their mapped fields, their memberships, and two types of groups: organizational branches and administrative groups. The synchronization scope, rules, and identifiers must be approved before the integration is activated.

Roles and Responsibilities

Successful synchronization requires a clear division of responsibilities. Functional decisions should be made before the technical configuration begins.
StakeholderMain responsibilities
Lära Implementation TeamDefine the synchronization scope with the client; prepare the LMS, custom fields, branches, groups, and permission profiles; confirm the mapping rules; coordinate preproduction testing and acceptance.
Lära Internal DeveloperCreate and configure the SCIM gateway for the project; implement the approved rules; store the identifiers required to maintain the appropriate relationships; review technical logs and resolve connector-related issues.
Client IT TeamCreate the enterprise application in Microsoft Entra ID; configure the attributes, mappings, groups, and assignments; secure the token; start and monitor provisioning; provide test results and error information.
Lära AdministratorsValidate the accounts created through SCIM; manually reposition branches within the organizational hierarchy; verify administrative groups and permission profiles; approve preproduction results; monitor the functional impact after production deployment.

Prerequisites

Before creating the application, gather the decisions, access rights, and data below. An incomplete configuration can result in duplicate accounts, incorrectly assigned users, or excessive permissions.
#PrerequisitesExpected validation
1Lära preproduction and production portals are availableTesting will be performed in preproduction using a representative data set.
2Appropriate administrative access is availableAuthorized personnel can manage Lära LMS, Microsoft Entra ID, the enterprise application, and extension attributes.
3The synchronization scope has been approvedThe users and groups to assign to the application have been identified, and a small pilot group is planned.
4A stable unique identifier has been selectedThe attribute used to uniquely identify a user has been defined and will not be reused.
5Field mapping has been approvedThe Entra source, Lära destination, format, default values, and owner of each field are documented.
6The organizational structure has been definedThe Entra groups that will use GroupType 1 and GroupType 2, branch names, administrative groups, and permission profiles are listed.
7The Lära connector has been activatedThe Lära team has securely provided the preproduction Tenant URL and Secret Token .

Preparing Lära LMS

The implementation team first prepares the preproduction portal, including user fields, branches, administrative groups, and permission profiles. This configuration becomes the reference for both the SCIM gateway developer and the client’s IT team.
  1. Create or confirm the user fields that will be synchronized (text).
  2. Create a text-type custom user field used to receive the identifier that links the user to the appropriate Lära permission profile. This field is mapped through SCIM and is used instead of the branch API for this logic.
  3. Create or confirm the permission profiles and record their Lära IDs.
  4. Prepare the expected list of branches and their intended hierarchy.
  5. Prepare the expected list of administrative groups.
  6. Provide the internal developer with the custom field API names, permission profile IDs, and approved rules.

Creating the Enterprise Application

The client’s IT team creates an enterprise application representing Lära LMS in Microsoft Entra ID.
  1. Open the Microsoft Entra portal and select Microsoft Entra ID.
  2. From the left menu, select Enterprise applications.
  3. Select New application, followed by Create your own application.
  4. Give the application a descriptive name, for example, “Lära LMS – SCIM – Preproduction.”
  5. Select the option for integrating an application that is not listed in the gallery, then select Create.

OPTIONAL LOCATION: Insert an approved screenshot of the enterprise application creation process here.

Configuring Provisioning

Within the enterprise application, open Provisioning and select Automatic. Enter only the settings for the target portal.
Entra settingValuePrecaution
Provisioning ModeAutomaticDo not start provisioning until the mappings and pilot assignments have been completed.
Tenant URL
Endpoint URL provided by the Lära teamUse the preproduction URL during testing; do not modify or attempt to construct it manually.
Secret Token
Authorization token provided by the Lära teamStore the token securely and restrict access to authorized personnel.
  1. Select Test the connection.
  2. If the test succeeds, select Save.
  3. Under Mappings, configure separately Provision Azure Active Directory Users and Provision Azure Active Directory Groups.
  4. Under Users and groups, initially assign only the pilot group and the groups required for testing.
  5. Once the mappings have been verified, select Start provisioning.

Mapping and Synchronizing Users

Each Entra source attribute must be mapped to a compatible Lära destination field. The table below summarizes the user fields available in Lära. The fields actually synchronized through SCIM depend on the approved project scope and gateway configuration.
Lära fieldPurposeImportant rule or format
loginUser login identifierMust be unique on the server and between 4 and 250 characters. Use a stable source value.
firstNameFirst nameMaximum length: 50 characters.
lastNameLast nameMaximum length: 50 characters.
emailEmail addressMust contain a valid email address of no more than 100 characters.
languageDisplay language1 = French (Canada), 2 = English, 3 = French (France), 4 = Spanish. If left blank, the organization’s default language is used.
companyNameOrganizationMaximum length: 100 characters.
functionTitleJob function or titleMaximum length: 100 characters.
phoneHome
phoneMobile
phoneWork
Phone numbersMaximum length for each value: 40 characters.
phonePublicPhone number made public in Via0 = None, 1 = Mobile, 2 = Home, 3 = Work. Default value: 0.
timeZoneTime zoneUses a numeric value from the Lära/Via list. If left blank, the organization’s time zone is used.
billToNameBilling nameMaximum length: 250 characters.
address
address2
postalCode
city
Address informationaddress and address2 : maximum 100 characters; postalCode : maximum 50 characters; city : maximum 100 characters.
countryId
stateId
Country and province/stateThese fields expect numeric IDs corresponding to Lära constants. Do not send a text label when an ID is expected.
portalIdDefault portalUse the appropriate Lära portal ID and validate the value separately in each environment.
expirationDateExpiration dateValidate the required format and define how an empty value should be handled.
enableNotificationsNotificationsBoolean value. The default is true.
viaAccessModeVia Classic access mode0 = Ask the user, 1 = Web version, 2 = Desktop application.
approverUserIdApproverUse the Lära user ID of the approver and ensure that the targeted account exists.
hourlyWageHourly wageDecimal value up to 999, with a maximum of two decimal places. Synchronize this field only when necessary.
customFieldsCustom fieldsThe field must already exist in Lära. Its API name must be used in the target SCIM attribute.
id
websiteId
inscriptionDate
status
System or tracking valuesDo not treat these as ordinary source data without prior validation. status is read-only in the user API. Account activation and deactivation follow the connector’s provisioning logic.

Mapping Rules

  1. One source per destination: document the Entra attribute used for every Lära field.
  2. Stable identifier: do not change the matching or unique identifier after initial provisioning without first analyzing the impact, because this could create a duplicate instead of updating the existing account.
  3. Compatible data types: explicitly convert numbers, Boolean values, dates, and IDs. Define how empty values will be handled.
  4. Controlled values: use Lära constants for language, time zone, country, province/state, and other coded fields.
  5. Maximum lengths: truncate a value only when that behaviour has been explicitly approved. Otherwise, correct the source data and log the error.
  6. Custom fields: create the field in Lära first, then add it to the custom application’s attribute list in Entra.

Adding a Custom User Field

Under Provisioning > Mappings > Provision Azure Active Directory Users, display the advanced options and select Edit attribute list for customapps. Add the target attribute using the following structure:

urn:ietf:params:scim:schemas:extension:lara:2.0:Custom:custom_field_ApiName

Replace custom_field_ApiName with the exact API name of the Lära field. For example, if the field’s API name is AzureIdentifier, use:

urn:ietf:params:scim:schemas:extension:lara:2.0:Custom:AzureIdentifier

Then map the Entra source attribute to this destination, confirm that the data types are compatible, and save the mapping. After initial creation, changes to this field are automatically transmitted when the provisioning service detects a modification.

Synchronizing Branches and Groups

The BranchGroup configuration uses a type attribute to determine whether an Entra group becomes an organizational branch or an administrative group in Lära.
GroupTypeCreated in LäraPurpose
1Lära BranchA division of the organizational structure to which users are assigned with a permission profile.
2Lära Administrative GroupA group used for collective administrative actions, such as enrolling multiple users in a training course or learning program.

Creating Group Extension Attributes

The client’s IT team creates two string extension properties in the Entra application: GroupType and GroupParentId, both targeting the Group. When creating them through Microsoft Graph, use the application’s objectID and not its appId. This can be performed with Microsoft Graph Explorer.

IT-only section: The examples below contain placeholders. Replace them only with identifiers from your tenant and groups.

  1. List the tenant applications with GET https://graph.microsoft.com/v1.0/applications, then record the id property of the target application.
  2. Create the GroupType extension with a POST https://graph.microsoft.com/v1.0/applications/{id}/extensionProperties request and the following body:
{
  "name": "GroupType",
  "dataType": "string",
  "targetObjects": [
    "Group"
  ]
}
  1. Create the GroupParentId extension at the same endpoint with the following body:
{
  "name": "GroupParentId",
  "dataType": "string",
  "targetObjects": [
    "Group"
  ]
}
  1. Update each group with PATCH https://graph.microsoft.com/v1.0/groups/{GROUP_ID}. The actual extension name takes the form extension_xxxxxxxAppIdxxxxxxxx_GroupType.
{
  "extension_xxxxxxxAppIdxxxxxxxx_GroupType": "1 ou 2"
}
  1. Verify the values with a GET request that explicitly selects the extensions, because Microsoft Graph v1.0 does not return group extension attributes by default:

GET https://graph.microsoft.com/v1.0/groups/{GROUP_ID}?$select=id,displayName,extension_xxxxxxxAppIdxxxxxxxx_GroupType,extension_xxxxxxxAppIdxxxxxxxx_GroupParentId

Entra source attributeTarget SCIM attribute
GroupTypeurn:ietf:params:scim:schemas:extension:lara:2.0:groups:type
GroupParentIdurn:ietf:params:scim:schemas:extension:lara:2.0:groups:parentid

Under Provisioning > Mappings > Provision Azure Active Directory Groups, add these two destinations to the custom attribute list, then configure the source-to-target mappings shown above. Next, assign each group the value 1 or 2 in GroupType.

Important: the SCIM process described here does not automatically reproduce Entra group levels or nesting. Branches are created at the same level in Lära. After initial creation, a Lära administrator must manually move each branch under its parent in the organizational structure. The GroupParentId attribute can be transmitted depending on the technical configuration, but it does not replace manual verification and repositioning.

Managing Permission Profiles

A permission profile determines what a user can do within a branch. The rule should be simple, stable, and approved before initial provisioning.
RuleBehaviour
No Permission Profile SpecifiedThe default user permission profile is applied.
Permission Profile SpecifiedThe mapping must use theLära permission profile ID, not only the profile name.
One Permission Profile per UserSCIM synchronizes one permission profile per user. That profile is applied to all branches to which that user belongs.
Persistent RelationshipThe SCIM gateway must store an identifier that can relate the source value to the appropriate Lära permission profile.
Recommended FieldUse a Lära text-type custom user field mapped through SCIM, rather than using the branch API.

For example, if a user is synchronized with the manager permission profile, the same manager profile applies to every branch to which that user belongs. With this logic, SCIM cannot assign a different permission profile to that user in each branch. Any exception must be reviewed before production to prevent unintended privilege elevation.

Updates After Initial Creation

Once a user or group has been created and correctly linked, subsequent provisioning cycles apply detected changes to the mapped attributes.
  • Changes to mapped user fields are synchronized to Lära.
  • Branch and administrative group memberships are updated according to the assigned Entra groups and their GroupType.
  • The synchronized permission profile is updated using the mapping identifier and remains applicable to all of the user’s branches.
  • Existing groups and branches are updated through their established relationship; they should not be recreated using a new identifier.
  • The manually configured Lära branch hierarchy must be preserved and verified after synchronization.

Precaution: Test the behaviour of deletion, deactivation, assignment removal, and unique identifier changes in preproduction before permitting these operations in production. They can behave differently from a simple field update.

Validating in Preproduction

Use a pilot group containing at minimum one standard user, one user with a specific permission profile, one user belonging to multiple branches, and one administrative group. Run the tests below and retain evidence of the results.
#TestExpected result
1Test the connectionThe Tenant URL and Secret Token are accepted.
2Create a standard userA single account is created with the expected fields and the default user permission profile when no other profile is supplied.
3Modify a standard field and a custom fieldThe new values appear on the existing account without creating a duplicate.
4Create a group with GroupType 1A Lära branch is created at the expected initial level.
5Reposition the branchThe administrator manually places the branch under the correct parent and confirms the hierarchy.
6Create a group with GroupType 2A Lära administrative group is created and can be used for a group administrative action.
7Add and remove a user from a pilot groupLära memberships are updated according to the approved rules.
8Apply a non-standard permission profileThe profile ID is correctly resolved, and the same profile is applied to all of the user’s branches.
9Send a controlled empty or invalid valueThe result follows the approved rule and no critical information is silently overwritten.
10Test deactivation, assignment removal, and reprovisioningThe observed behaviour is documented and approved before production.

Acceptance Criteria

  • No blocking errors remain in the provisioning logs.
  • Reprovisioning does not create duplicate users.
  • Mandatory and approved custom fields contain the expected values.
  • Branches and groups are created using the correct type.
  • The branch hierarchy has been manually repositioned and validated in Lära.
  • Each user’s permission profile is correct, unique, and applied consistently across all branches.
  • Removal, deactivation, and error scenarios have a known and accepted behaviour.
  • The client’s functional owner and IT team have approved moving to production.

Moving to Production

Production must reproduce the configuration approved in preproduction while using connection information specific to the production portal. Never reuse the preproduction Tenant URL or Secret Token in the production application.
  1. Obtain approval of the test results and rollback plan.
  2. Securely obtain the production Tenant URL and Secret Token .
  3. Reproduce the approved attributes and mappings, while checking identifiers that differ between environments.
  4. Assign a production pilot group first.
  5. Start provisioning and monitor the first cycle.
  6. Compare the results with preproduction, then gradually expand the synchronization scope.
  7. Reposition any newly created branches within the Lära hierarchy and document the result.

Limitations and Precautions

  • Entra hierarchy is not automatically reproduced. Branches are initially created at the same level and must subsequently be moved manually in Lära.
  • Only one permission profile is synchronized per user, and that profile applies to all of the user’s branches.
  • Group names and permission profile names do not replace the stable identifiers required to maintain relationships.
  • Custom fields must exist in Lära before they are added to the Entra schema and mapping.
  • Invalid source data, values exceeding maximum lengths, or incorrect data types can prevent an object from being provisioned.
  • Changes to unique identifiers, deletions, and deactivations require specific testing.
  • The connector is semi-manual and project-specific. Any change to the structure or synchronization rules must be coordinated with the Lära team.

Troubleshooting

Start by reviewing the provisioning status and logs for the Entra enterprise application. Before submitting a support request, record the date and time, affected object, operation, complete error message, and correlation ID.
IssueVerifyResolution
Connection Test FailsEnvironment, Tenant URL, token, accidental spaces, expiration, or revocation.Re-enter the values securely provided by the Lära team. If necessary, request a new token.
User Is Not CreatedApplication assignment, provisioning scope, required fields, uniqueness of the login, and email format.Correct the source data or mapping, then reprovision the object.
Duplicate UserMatching attribute or unique identifier changes and whether an existing account was correctly linked.Do not expand provisioning to additional users. Review the identifiers and establish the correct relationship before continuing.
Custom Field Is MissingThat the field exists in Lära, the exact API name, the destination URN, and the data type.Create the field in Lära, add the custom attribute in Entra, then recreate the mapping using the exact URN.
Group Is Created as the Wrong TypeCheck the GroupType and its mapping to groups:type.Use 1 for a branch and 2 for an administrative group, then reprovision according to the approved procedure.
Branch Is at the Wrong LevelInitial creation and the branch’s current position in the organizational structure.Manually move the branch in Lära. SCIM does not automatically recreate the nested hierarchy.
Incorrect Permission ProfilePermission profile ID, custom text field, SCIM-side relationship, and whether multiple conflicting values exist.Correct the ID-based mapping and maintain a single permission profile value per user.
Update Is Not AppliedWhether the attribute is included in the mapping, provisioning scope, provisioning cycle, recent errors, and the existing relationship.Correct the mapping or source data and reprovision the object without changing its unique identifier.
Unexpected Removal or DeactivationScope rules, Entra assignment, the action performed, and the behaviour previously observed in preproduction.Suspend the action in production, reproduce the scenario in preproduction, and have the expected behaviour confirmed by the Lära and client IT teams.

Information to Provide to Support: affected environment, enterprise application name, date and time of the issue, object type, expected action, actual result, complete error message, and correlation ID. Never send the Secret Token.

End of the Lära LMS SCIM article with Microsoft Entra ID.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.