Memority's CSV connector can import identities from a CSV file stored on the SFTP storage of the tenant. Some prerequisites must be met on the file and on the tenant before the import runs.
This page explains how the CSV identity import works in Memority and the prerequisites required to import identities from a CSV file.
Definitions
What objects can be imported ?
The connector imports identities of one identity type. Each row of the file is one identity.
To import organizations, use the CSV Organization Import plugin.
Where is the CSV file read from ?
From the SFTP storage of the tenant, or from the portal. You upload the file to a folder of the SFTP storage that depends on the identity type, or you upload it directly in the portal when you run the import task.
Are identities missing from the file deactivated ?
No. The import only creates and updates identities. An identity that is missing from the file does not change. To deactivate an identity, fill its endDate column.
A file can therefore contain all identities, or only some of them (for example, new joiners only).
Can Memority write back to the CSV file ?
No. The connector only imports identities into Memority. After each run, the file is archived and an error report is produced.
Memority CSV connector
File prerequisites
|
ID |
Prerequisite |
|---|---|
|
FILE1 |
The file uses |
|
FILE2 |
The file is encoded in UTF-8. |
|
FILE3 |
The first row of the file is a header row with the column names. |
|
FILE4 |
On the SFTP storage, the file has the name entered in the plugin form and it is in the folder |
|
FILE5 |
No value contains a line break, even inside quotes. |
A sample file shows the expected columns and formats. The plugin generates it in the project (_sample-import-csv-<identityType>.csv), and you can also download it from the portal, on the import task.
Data prerequisites
|
ID |
Prerequisite |
|---|---|
|
DATA1 |
Every row has an |
|
DATA2 |
An email matches at most one identity of the identity type on the tenant. |
|
DATA3 |
The |
|
DATA4 |
The |
|
DATA5 |
Dates use the format |
CSV Identity Import plugin
Memority provides a plugin in the MIT Plugin Store that configures the CSV identity import. The plugin generates all the configuration files that your tenant needs.
Prerequisites
In addition to the common plugin prerequisites, this plugin requires:
|
|
Prerequisite |
Description |
|---|---|---|
|
1 |
Existing identity type |
The plugin imports identities into an identity type that must already exist (for example |
|
2 |
Existing organizations |
Only required to fill the |
Installation
The plugin is installed with the standard procedure described on the Memority Plugins page. This section only gives the information that is specific to the CSV Identity Import plugin.
Installation mode: repeatable with distinct values. You can install the plugin once per identity type: each installation requires a different identity type.
Plugin form parameters
All four fields are mandatory and have no default value.
|
|
Parameter |
Description |
Example |
|---|---|---|---|
|
1 |
Import name (FR) |
Name of the import task in the portal, in French. 2 to 100 characters. |
Import RH |
|
2 |
Import name (EN) |
Name of the import task in the portal, in English. 2 to 100 characters. |
HR import |
|
3 |
Identity type |
Identifier of the existing identity type that receives the imported identities. It starts with a lowercase letter, followed by letters or digits (for example |
|
|
4 |
CSV file name |
Name of the CSV file to import. Letters, digits, |
|
Secrets
The plugin needs no secret: the import reads the SFTP storage of the tenant. Step 7 of the standard procedure does not apply.
Data import
The plugin generates no data to import. Step 10 of the standard procedure does not apply.
The plugin also generates a sample file, _sample-import-csv-<identityType>.csv, in the data folder of the project. It shows the expected columns and formats. Do not push it to the tenant: it is not an import file.
What does it do ?
The generated configuration works out of the box, but it may need adjustments for specific client needs.
The plugin generates the complete configuration required for a CSV identity import in just a few clicks.
It reads a CSV file from the SFTP storage of the tenant, then creates and updates the identities of one identity type. At the end of each run, it archives the file, produces an error report and sends it by email to the user who ran the task.
The plugin supports:
-
Creation and update of identities. The import never creates duplicates: you can run it again with the same file or with a new file.
-
Matching on the email. Matching with existing identities is case-insensitive, and limited to the identity type of the plugin.
-
Manager resolution in one run. The rows can be in any order: the import creates the managers before the identities they manage.
-
Organization check. The organization of each row must exist, and it must be in the scope of the user who runs the task.
-
Error report and email notification after each run.
-
Manual run. By default, the task runs only when you start it. You can schedule it afterwards.
Imported data reference
|
CSV column |
Required |
Memority attribute |
Notes |
|---|---|---|---|
|
|
Yes |
|
First name |
|
|
Yes |
|
Last name |
|
|
Yes |
|
Unique key of the identity. Stored in lower case. Matching is case-insensitive. |
|
|
No |
|
Code ( |
|
|
No |
|
Email of the manager. The manager must be an identity of the same type, in the same file or already on the tenant. |
|
|
No |
|
First active day, format |
|
|
No |
|
Last active day, format |
Example:
firstName;lastName;email;organization;manager;startDate;endDate
John;Doe;john.doe@company.com;IT;jane.smith@company.com;2024-01-15;2025-12-31
Jane;Smith;jane.smith@company.com;HR;;2023-06-01;
Organization scope
The organization of a row must be the security organization of the user who runs the task, or an organization below it. Otherwise the row is rejected.
When the user has no security organization, or when the task runs on a schedule, the import only checks that the organization exists.
Running an import
-
Upload the CSV file in one of these ways:
-
to the SFTP storage of the tenant, in the folder
memority_import/<identityType>/, with the file name entered in the plugin form; -
directly in the portal, when you run the task (step 2).
-
-
In the portal, go to Administration → Import tasks, select the task and run it.
-
At the end of the run, you receive an email with the error report.
After the run, the files are in these folders:
|
File |
Folder |
|---|---|
|
Imported file, archived |
|
|
Error report |
|
The error report lists the rejected rows with an error code, a label, a description, details and a date.
Behavior by case
|
Case |
Result |
|---|---|
|
The |
The identity is created. |
|
The |
The identity is updated. |
|
The |
The row is rejected and listed in the error report. |
|
The row has no |
The row is rejected and listed in the error report. The other rows are imported. |
|
The |
The row is rejected and listed in the error report. |
|
The |
The row is rejected and listed in the error report. |
|
The |
The identity is created or updated without a manager. |
|
An identity of the type is missing from the file |
Nothing changes: the identity stays active. |
Technical details
<identityType> in the generated file names is replaced by the Identity type entered in the plugin form.
Generated files
|
File |
Path |
Description |
|---|---|---|
|
|
|
CSV connector: file path, separator, encoding |
|
|
|
Mapping of the columns, matching rules and reactions |
|
|
|
Import task |
|
|
|
File archive, error report and email notification |
|
|
|
Sample CSV file. It is not deployed. |
Updated files
|
File |
Path |
Description |
|---|---|---|
|
|
|
Adds the name of the import task, in French and English |
|
|
|
Adds the import task to the filter of the import reports |
Troubleshooting
For issues with the Plugin Store itself (plugin not found, installation error), see the troubleshooting section of the Memority Plugins page.
The whole file fails and no row is imported
-
Cause: The file does not meet the file prerequisites (FILE1 to FILE5), so the CSV connector cannot read it.
-
Fix: Correct the file, then run the import again.
Rows are rejected with an unknown organization
-
Cause: The
organizationcolumn holds a value that is not theorganizationCodeof an existing organization. A frequent mistake is to use the technical identifier of the organization instead of its code. -
Fix: Use the organization code, or import the organizations first with the CSV Organization Import plugin.
Rows are rejected because the organization is outside the scope of the requester
-
Cause: The user who runs the task has a security organization, and the organization of the row is not this organization or below it.
-
Fix: Run the task with a user whose security organization covers the organizations of the file.
Identities are imported without a manager
-
Cause: The
manageremail does not match any identity of the same identity type. Or the configuration of the import task was changed to add write thresholds (idmWriteOperationsThresholdDefinition): the plugin generates the task without them. With write thresholds, all the rows are processed before any identity is written, so the managers created by the same file do not exist yet. -
Fix: Check the email of the manager. If write thresholds were added, remove them from the import task file (
import-csv-<identityType>-syncTask.xml) and deploy the configuration again. A second run of the same file also fills the managers.
Rows are rejected because several identities match
-
Cause: Several identities of the identity type have the same email on the tenant.
-
Fix: Correct the
emailin the file, or remove the duplicates on the tenant, then run the import again.