Unable to create user with OrgApplications values
I'm testing user creation in Postman and have been unable to add our OrgApplications. The technician user is created with the specified fields populated, but the only org application that gets added is what is specified in PromaryClientPortalApplicationID. What am I doing wrong?
URL: https://tulsalibrary.teamdynamix.com/SBTDWebApi/api/people
Body:
{
"Password": "",
"LikeDesktop": false,
"IsActive": true,
"IsConfidential": false,
"AlternateEmail": "",
"PrimaryClientPortalApplicationID": 102,
"Company": "Tulsa City-County Library",
"HomePhone": "",
"PrimaryPhone": "Work",
"Pager": "",
"OtherPhone": "",
"MobilePhone": "",
"Fax": "",
"DefaultPrimaryID": 0,
"DefaultPriorityName": "None",
"AboutMe": "",
"TechnicianSignature": "",
"ApplyTechnicianSignatureToUpdatesAndComments": false,
"ApplyTechnicianSignatureToReplies": false,
"HomeAddress": "",
"HomeCity": "",
"HomeState": "",
"HomeZip": "",
"HomeCountry": "",
"DefaultRate": 0.0,
"CostRate": 0.0,
"IsEmployee": true,
"IscapacityManaged": false,
"ReportTimeAfterDate": "",
"EndDate": "",
"ShouldReportTime": false,
"ResourcePoolID": "",
"TZID": 4,
"TypeID": 1,
"AuthenticationProviderID": 26,
"Attributes": "",
"IMProvider": "",
"IMHandle": "",
"LocationRoomID": 0,
"UserName": "holly.test-user@tulsalibrary.org",
"AuthenticationUserName": "holly.test-user@tulsalibrary.org",
"FirstName": "Holly",
"LastName": "Test-User",
"MiddleName": "",
"Salutation": "",
"Nickname": "",
"DefaultAccountID": 3175,
"DefaultAccountName": "Adult Services",
"PrimaryEmail": "holly.test-user@tulsalibrary.org",
"ExternalID": "",
"AlternateID": "",
"Applications": [
"TDClient",
"TDNews",
"TDProjects",
"TDWorkspaces",
"TDNext",
"MyWork"
],
"SecurityRoleID": "8CD52654-C621-431D-9BB6-62A2054858AA",
"ReportsToUID": "f544c51d-4e75-ef11-991b-85f92b4cb377",
"OrgApplications": [
{
"ID": 102,
"SecurityRoleId": "b73cf2d0-68b5-4947-aa49-5edf44e024ad"
},
{
"ID": 103,
"SecurityRoleId": "249f0e9e-dcbc-4856-b961-50ef0f61e693"
},
{
"ID": 104,
"SecurityRoleId": "28f192ff-d590-4e68-9e7d-44296a0e3917"
}
]
}
Answer (1)
Hi Scott, You can probably cut that body down to the following by removing the non-necessary fields that you already aren't including values for:
{
"IsActive": "true",
"IsConfidential": "false",
"PrimaryClientPortalApplicationID": 102,
"Company": "Tulsa City-County Library",
"PrimaryPhone": "Work",
"ApplyTechnicianSignatureToUpdatesAndComments": "false",
"ApplyTechnicianSignatureToReplies": "false",
"IsEmployee": "true",
"IscapacityManaged": "false",
"ShouldReportTime": "false",
"TZID": 4,
"TypeID": 1,
"AuthenticationProviderID": 26,
"UserName": "holly.test-user@tulsalibrary.org",
"AuthenticationUserName": "holly.test-user@tulsalibrary.org",
"FirstName": "Holly",
"LastName": "Test-User",
"DefaultAccountID": 3175,
"PrimaryEmail": "holly.test-user@tulsalibrary.org",
"Applications": [
"MyWork",
"TDAnalysis",
"TDAssets",
"TDClient",
"TDCommunity",
"TDFileCabinet",
"TDFinance",
"TDIPAAS",
"TDNews",
"TDNext",
"TDPeople",
"TDPortfolios",
"TDPP",
"TDProjects",
"TDResourceManagement",
"TDTemplate",
"TDTickets",
"TDTimeExpense",
"TDWorkspaces"
],
"SecurityRoleID": "8CD52654-C621-431D-9BB6-62A2054858AA",
"ReportsToUID": "f544c51d-4e75-ef11-991b-85f92b4cb377",
"OrgApplications": [
{
"ID": 102,
"SecurityRoleId": "b73cf2d0-68b5-4947-aa49-5edf44e024ad"
},
{
"ID": 103,
"SecurityRoleId": "249f0e9e-dcbc-4856-b961-50ef0f61e693"
},
{
"ID": 104,
"SecurityRoleId": "28f192ff-d590-4e68-9e7d-44296a0e3917"
}
]
}
Also, just note I provided all of the "Applications" (out of the box apps) there so you can know what they're called when you go to create users. I think if you ran that it should create a new user appropriately.
Sincerely,
Mark Sayers
Sr Support Consultant, CS
Since it is only applicable after the creation of the user, you can't set any values in that array when creating a new user. You have to edit the user account in a second API call to set OrgApplications updates. - Mark Sayers Wed 9/18/24 1:52 PM
Thanks - Scott Williamson Wed 9/18/24 2:53 PM