Creating JSON file for user import
WHEN
For those customers where access to users and relationship isn't available in the Active Directory for Planner, the data can come from any other data source if formatted in the JSON format defined below.
WHY
Some customers does not have all users and their group membership reflected in an MS Active Directory, but in another structure/system that holds the security principals of user and groups.
Steps
Configure Planner with locations - and if required VIP groups and departments
Create a User Import definition, as "Import Set", within administration->Settings->Import Users
Create your JSON file of users - MUST be named exactly "ImportSet.txt"
Contact [email protected] for a powershell script that you can use to import the users into your solution.
HOW TO CREATE JSON FILE FOR IMPORT
User, roles and department membership must be defined in a specific JSON form - which consists of attribute-data pairs. These are described in the table below.
The import file must include all users that are to be available in Planner.
Note! Whenever the file is update - it will add/update/delete as follows:
New users will be added to Planner
Update users will be updated in Planner
Missing users, imported during an earlier import, will be delete in Planner
Here is an example of a user object and the attribute-data pairs that is must contain:
[{
"GlobalRoles": [0],
"LocalRoles": [0],
"VipRoleMemberships": [],
"DepartmentUserMemberships": [],
"DepartmentSecretaryMemberships": [],
"InvalidReason": null,
"DataSourceGuid": "",
"Login": "[email protected]",
"Lastname": "Jurgensen",
"Firstname": "Peter W.",
"Initial": "pj",
"Email": "[email protected]",
"LegacyExchangeDN": null,
"Phone": null,
"MobilePhone": null,
"LocationId": 3,
"Department": "IT Department",
"BillingNote": "",
"MeetingTypeNote": null
}]
Attribute-data Pairs
GlobalRoles | Empty array or array of number(s) referring to role enums | Global role(s) for user |
LocalRoles | Array of number(s) referring to one or more role enums | Local role(s) for user |
VipRoleMemberships | Empty array or array of number(s) referring to usergroup_id for VIP groups | VIP groups for user Ex. "VipRoleMemberships": [234,43] Ex. "VipRoleMemberships": [] |
DepartmentUserMemberships | Empty array or array of number(s) referring to usergroup_id for VIP groups | Reference to membership to departments Reference to membership of department ID - these can be looked up in database or by hovering in administration for each department Ex. "DepartmentUserMemberships": [234,43] Ex. "DepartmentUserMemberships": [] |
DepartmentSecretaryMemberships | Empty array or array of number(s) referring to usergroup_id for VIP groups | Reference to membership to department.id which the user is a secretary of Reference to membership of department ID - these can be looked up in database or by hovering in administration for each department Ex. "DepartmentSecretaryMemberships": [234,43] Ex. "DepartmentSecretaryMemberships": [] |
InvalidResource | null | |
DataSourceGuid | "GUID" | A unique identifier per user from the source system. If this is not set, a user that is deleted will not be recoverable when reintroduced in the import set, and will then appear as a new user in Planner. |
Login | text | User login |
Lastname | text | Must be set |
Firstname | text | Must be set |
Initial | text | Must be set |
text | Must be set, and must be unique pr user | |
LegacyExchangeDN | Null or text | |
Phone | Null or text | Phone for user Ex. "Phone":"123445", or |
MobilePhone | Null or text | Mobile phone for user Ex. "MobilePhone":"123123" |
LocationId | number | Reference to location for user |
Department | text | Department text - just text no reference |
BillingNote | text | Billing/Costcenter note - jut text no reference |
MeetingTypeNote | text | Meeting Type note - jut text no reference |