I am trying to create an oAuth based app that integrates with salesforce to create the objects from the app.
To let users know what all fields that users needs to put in at minimum to create the object the logic is as below:
if the field is createable && field is NOT nillable && (field is NOT DefaultedOnCreate OR (field is DefaultedOnCreate AND field has default value as null))
Same thing we found on the forum https://developer.salesforce.com/forums?id=906F00000008x86IAA The best answer was that same logic chosen by the admin.
But for some objects this logic is is not correct, e.g. to create a user this logic gives "IsStayInTouchRequired" as a mandatory field and it is not required by salesforce.
Please suggest the correct logic for finding the mandatory fields.
Thanks in advance.