function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Natalia Rex 1Natalia Rex 1 

Change the "Created by" user via API

Hi everybody. In our instance, we want to change who the "Created by" user is, when via Rest Api a record is created (any custom objects, leads, contacts, etc). Currently the "Created by:" field is populated with an actual user, our VP. He was just a "go to" user that is used when records are created, when SF was implemented. As you can see it can cause a lot of confusion now in reporting. :)

We want to just create a fake/dummy user, for example "API_User" or "Integration_User". We already have one, thanks to our SF and Pardot integration, but I don't believe we can "re-use" that user in this case.

If we create this new user, does it have to have a SF Licence assigned to it? Or can it just have "Identity" licence that SF recently rolled out. We want to avoid having to pay for a licence if its just a user we use in this type of situation, it won't be an actual person. This way, we can also track what leads/contacts haven't been assigned, or need to be reviewed.

Thanks for your help in advance (if there's some documentation I missed, I would be very thankful).
Best Answer chosen by Natalia Rex 1
VinayVinay (Salesforce Developers) 

User needs to have salesforce license to make DML operation in your org and specifically, it cannot be system admin any custom profile that has access to objects, api calls etc., based on your integration requirement.

Check below link that has details on how to create a secure Salesforce API user

https://help.salesforce.com/articleView?id=000331470&type=1&mode=1

Thanks,

All Answers

VinayVinay (Salesforce Developers) 
Hi Natalia,

Unfortunately, you can not update that field once record is created. 

Check below reference.

https://help.salesforce.com/articleView?id=000331038&type=1&mode=1

Hope above information was helpful.

Please mark as Best Answer so that it can help others in the future.

Thanks,
Natalia Rex 1Natalia Rex 1
Hello Vinay, thank you for the reply. I actually meant, going forward, how we can change the "created by" user, when the object record is created, we are not interested in changing the old records. And if this "user" that creates the record via API needs to have a Salesforce Licence with Admin permissions, or can it be an Identity Licence?

Thanks,
VinayVinay (Salesforce Developers) 

User needs to have salesforce license to make DML operation in your org and specifically, it cannot be system admin any custom profile that has access to objects, api calls etc., based on your integration requirement.

Check below link that has details on how to create a secure Salesforce API user

https://help.salesforce.com/articleView?id=000331470&type=1&mode=1

Thanks,

This was selected as the best answer
Natalia Rex 1Natalia Rex 1
Vinay, thank you for the response and help. I understand now.

Thanks,