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

How to add user in organization using JavaScript?

tsharma
8-Gravel

How to add user in organization using JavaScript?

I want to add users, user-groups  in an organization using java script service so that I can do it this at my custom mashup for my customer. How can I do this? Appricate a quick help.

1 ACCEPTED SOLUTION

Accepted Solutions
supandey
19-Tanzanite
(To:tsharma)

Hi Tushar, you can use the existing service AddMember, something like this

var params = {

  name: undefined /* STRING */,

  member: undefined /* STRING */,

  type: undefined /* STRING */

};

// this will add member to the Everyone org

// no return

Organizations["Everyone"].AddMember(params);

View solution in original post

1 REPLY 1
supandey
19-Tanzanite
(To:tsharma)

Hi Tushar, you can use the existing service AddMember, something like this

var params = {

  name: undefined /* STRING */,

  member: undefined /* STRING */,

  type: undefined /* STRING */

};

// this will add member to the Everyone org

// no return

Organizations["Everyone"].AddMember(params);

Top Tags