User management with REST API

Hello! I've seen a few posts where REST API details were asked and the answer was https://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_7.7/Integration/Web_Services/v10/Exampl… 

I also see documentation to create Users https://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_7.7/Integration/Web_Services/v10/Endpoi… 

So, are Accounts different from Users? When would we create a User and when would we create an Account?

Also, the 2nd link above for Users talks about "linking". I'm not sure what linking is about. I just want to create users. Is there a separate REST API for that? Also, please share the User schema. I would like to know what fields in the request are mandatory, what are optional and what are read-only (e.g. id field of a user can't be updated).

I'm looking to do the following operations on Users.

1. Create a User (POST)

2. Update a User (PUT or Replace, PATCH or selective update)

3. DELETE a User (DELETE)

4. GET A User (GET)

5. GET All Users (GET)

6. GET All Users with Pagination. Like only 100 records at a time.

7. Filter Users with some criteria. First Name, Last Name, User Name, Email Address, etc.,

Parents Reply
  • Thanks for that quick response, Dennis!

    I'm still looking to find answers on two other questions.

    1. What is an Account and how does it differ from User?

    2. The Links you shared above talk about the API in the context of Accounts. E.g. POST takes two parameters name and description. Do both Accounts and Users resources take exact same parameters? It would be really helpful if you could share the schema of User resource.

Children
  • Hi admin guy,

    Accounts are totally different from Users.

    The Users module is used in Sugar in order for the users of your company/organization to log in the system with a username and password and be able to read, create, delete or modify records.

    The Accounts module is usually used so as to save records and data of the different companies/organizations your company works with, e.g your clients. Usually companies are Leads (this is the companies or organizations that are not yet clients but that there are real possibilities to became to) before they are converted to Accounts in a CRM.

    Here you have the Users schema (default fields):

    and here you have the Accounts schema:

    With this information and the one provided by Dennis Wangerin you should be able to perform the calls you need to.

    Hope this helps.

    Regards,

    David.

  • Hello. 

    Do you know if what you posted there is still possible? Especially with regards to deactivating a user? (setting user status to 'Inactive')?