cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

Is it possible to create/add a dynamic organization(Programatically) in Thingworx

jk-3
6-Contributor

Is it possible to create/add a dynamic organization(Programatically) in Thingworx

I have to create/add Organization programatically. Is that possible to add so.

1 ACCEPTED SOLUTION

Accepted Solutions
posipova
20-Turquoise
(To:jk-3)

HI, the following service would create an Organizatio with a Parent and a child unit:

var par = {

   

                topOUName: Parent /* STRING */,

                name: Parent /* STRING */,

};

// no return

Resources["EntityServices"].CreateOrganization(par);

   

    var params = {

  name: Child /* STRING */,

  parentName: Parent/* STRING */

};

// no return

Organizations[Parent].AddOrganizationalUnit(params);

View solution in original post

3 REPLIES 3

Yup

Resources["EntityServices"].CreateOrganization

posipova
20-Turquoise
(To:jk-3)

HI, the following service would create an Organizatio with a Parent and a child unit:

var par = {

   

                topOUName: Parent /* STRING */,

                name: Parent /* STRING */,

};

// no return

Resources["EntityServices"].CreateOrganization(par);

   

    var params = {

  name: Child /* STRING */,

  parentName: Parent/* STRING */

};

// no return

Organizations[Parent].AddOrganizationalUnit(params);

jk-3
6-Contributor
(To:posipova)

Thanks

Top Tags