<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question LDAP Integration in API Insights forum</title>
    <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550185#M1785</link>
    <description>&lt;P&gt;&lt;SPAN&gt;How to source the groups and group members from the LDAP server aligning to the users already present on the ServiceNow platform?User records have come into the sys_user from another source by LDAP Integration only. We need to make sure that duplicate members should not be created in the sys_user table.We want that new data should come to sys_user_group for the groups and to sys_user_grmember for the members.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 28 May 2026 05:12:40 GMT</pubDate>
    <dc:creator>SanketKumaS</dc:creator>
    <dc:date>2026-05-28T05:12:40Z</dc:date>
    <item>
      <title>LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550185#M1785</link>
      <description>&lt;P&gt;&lt;SPAN&gt;How to source the groups and group members from the LDAP server aligning to the users already present on the ServiceNow platform?User records have come into the sys_user from another source by LDAP Integration only. We need to make sure that duplicate members should not be created in the sys_user table.We want that new data should come to sys_user_group for the groups and to sys_user_grmember for the members.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 28 May 2026 05:12:40 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550185#M1785</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-28T05:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550190#M1786</link>
      <description>&lt;P&gt;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/868843"&gt;@SanketKumaS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;group and group membership not coming from same LDAP?&lt;/P&gt;</description>
      <pubDate>Thu, 28 May 2026 05:20:28 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550190#M1786</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2026-05-28T05:20:28Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550193#M1787</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/868843"&gt;@SanketKumaS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Use the standard&amp;nbsp;&lt;A href="https://support.servicenow.com/kb?id=kb_article_view&amp;amp;sysparm_article=KB0961314" target="_blank" rel="noopener"&gt;LDAP Integration&lt;/A&gt;&amp;nbsp;but with a specific&amp;nbsp;&lt;STRONG&gt;onBefore&lt;/STRONG&gt;&amp;nbsp;transform script ,make sure &lt;STRONG&gt;Coalesce&lt;/STRONG&gt;&amp;nbsp; has been properly set . This method ensures that group memberships are created only for users who already exist in your&amp;nbsp;sys_user&amp;nbsp;table, effectively preventing the creation of duplicate or unwanted user records.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sample onBefore transform script:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; userGr = &lt;/SPAN&gt;&lt;SPAN class=""&gt;new&lt;/SPAN&gt;&lt;SPAN class=""&gt; GlideRecord(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'sys_user'&lt;/SPAN&gt;&lt;SPAN class=""&gt;);
userGr.addQuery(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'user_name'&lt;/SPAN&gt;&lt;SPAN class=""&gt;, source.u_sAMAccountName); &lt;/SPAN&gt;&lt;SPAN class=""&gt;// Replace by your Ldap field&lt;/SPAN&gt;&lt;SPAN class=""&gt;userGr.query();&lt;/SPAN&gt;&lt;SPAN class=""&gt;if&lt;/SPAN&gt;&lt;SPAN class=""&gt; (userGr.next()) {
    &lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; userId = userGr.sys_id;&lt;/SPAN&gt;    &lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; groupGr = &lt;/SPAN&gt;&lt;SPAN class=""&gt;new&lt;/SPAN&gt;&lt;SPAN class=""&gt; GlideRecord(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'sys_user_group'&lt;/SPAN&gt;&lt;SPAN class=""&gt;);
    groupGr.addQuery(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'name'&lt;/SPAN&gt;&lt;SPAN class=""&gt;, source.u_department); &lt;/SPAN&gt;&lt;SPAN class=""&gt;// Replace your LDAP group field here&lt;/SPAN&gt;&lt;SPAN class=""&gt;    groupGr.query();
    &lt;/SPAN&gt;&lt;SPAN class=""&gt;if&lt;/SPAN&gt;&lt;SPAN class=""&gt; (groupGr.next()) {
        &lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; groupId = groupGr.sys_id;
        &lt;/SPAN&gt;&lt;SPAN class=""&gt;// Check if the membership already exists to prevent duplicate sys_user_grmember entries&lt;/SPAN&gt;
        &lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; memberGr = &lt;/SPAN&gt;&lt;SPAN class=""&gt;new&lt;/SPAN&gt;&lt;SPAN class=""&gt; GlideRecord(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'sys_user_grmember'&lt;/SPAN&gt;&lt;SPAN class=""&gt;);
        memberGr.addQuery(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'user'&lt;/SPAN&gt;&lt;SPAN class=""&gt;, userId);
        memberGr.addQuery(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'group'&lt;/SPAN&gt;&lt;SPAN class=""&gt;, groupId);
        memberGr.query();&lt;/SPAN&gt;        &lt;SPAN class=""&gt;if&lt;/SPAN&gt;&lt;SPAN class=""&gt; (!memberGr.hasNext()) {
            memberGr.initialize();
            memberGr.user = userId;
            memberGr.group = groupId;
            memberGr.insert();
        }
    }
}&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;SPAN&gt;Refer Servicenow documentation:&amp;nbsp;&lt;/SPAN&gt;&lt;A style="font-family: inherit; font-size: 16px; background-color: #ffffff;" href="https://www.servicenow.com/docs/r/fr-FR/platform-security/ldap-integration/c_LDAPTransformMaps.html?contentId=wKUkZB1c9LCuBJQzIBu2Ug" target="_self"&gt;LDAP transform maps&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;A href="https://www.servicenow.com/community/developer-forum/ldap-integration-creating-duplicate-accounts-in-user-table/m-p/1469192" target="_self"&gt;LDAP integration creating Duplicate Accounts in User Table&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 May 2026 05:26:00 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550193#M1787</guid>
      <dc:creator>Tanushree Maiti</dc:creator>
      <dc:date>2026-05-28T05:26:00Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550265#M1792</link>
      <description>&lt;P&gt;No the users have come from a different data source only by using transform maps.But the groups and group members are to come from LDAP source.Need to make sure there are no duplicate users created for the already existing users.&lt;/P&gt;</description>
      <pubDate>Thu, 28 May 2026 07:49:25 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550265#M1792</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-28T07:49:25Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550856#M1796</link>
      <description>&lt;P&gt;Actually I need to modify the Transform Scripts written for the Users OU Definition so that the group members are mapped to the group without creating duplicate users in the sys_user table based on a particular filter.Currently,OnStart and OnComplete transform scripts are used.I need to modify them to fulfil my requirement.&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 06:46:57 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550856#M1796</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-29T06:46:57Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550859#M1797</link>
      <description>&lt;P&gt;My goal is that to map the LDAP group members with the existing user record without creating duplicates in the sys_user table.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 06:58:21 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550859#M1797</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-29T06:58:21Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550862#M1798</link>
      <description>&lt;P&gt;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/868843"&gt;@SanketKumaS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;if your question is unanswered then I will request to keep thread open so that members can guide you&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 06:59:42 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550862#M1798</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2026-05-29T06:59:42Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550866#M1799</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/868843"&gt;@SanketKumaS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Check in existing script if above field has been mapped. if not&amp;nbsp;&lt;/P&gt;&lt;P&gt;Just add a new one - onBefore Transform script.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 07:07:56 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550866#M1799</guid>
      <dc:creator>Tanushree Maiti</dc:creator>
      <dc:date>2026-05-29T07:07:56Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550875#M1800</link>
      <description>&lt;P&gt;Yes please keep the thread open&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 07:20:57 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3550875#M1800</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-29T07:20:57Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3551002#M1801</link>
      <description>&lt;P&gt;There is a slight change in the requirement.I need to use a specific filter&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;to source only the ServiceNow relevant&amp;nbsp;groups from LDAP.I need to map the group members with the already existing users making sure no duplicate users are created.Currently the LDAP Server has only one OnStart and OnComplete transform script.The OnStart script is just calling the LDAPUtils script include and&amp;nbsp; using the setLog(log) for setting the logs.While&amp;nbsp; in the OnComplete transform script,it is calling the processManagers() function of the LDAP.Please help me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 11:12:16 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3551002#M1801</guid>
      <dc:creator>SanketKumaS</dc:creator>
      <dc:date>2026-05-29T11:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: LDAP Integration</title>
      <link>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3551026#M1802</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/868843"&gt;@SanketKumaS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Will check and get back&lt;/P&gt;</description>
      <pubDate>Fri, 29 May 2026 11:51:53 GMT</pubDate>
      <guid>https://www.servicenow.com/community/api-insights-forum/ldap-integration/m-p/3551026#M1802</guid>
      <dc:creator>Tanushree Maiti</dc:creator>
      <dc:date>2026-05-29T11:51:53Z</dc:date>
    </item>
  </channel>
</rss>

