class Restforce::Client
def upsert(sobject, field, attrs)
Returns the Id of the newly created record if the record was created.
Returns true if the record was found and updated.
client.upsert('Account', 'External__c', External__c: 12, Name: 'Foobar')
# Update the record with external ID of 12
Examples
attrs - Hash of attributes for the record.
field - The name of the external Id field to match against.
sobject - The name of the sobject to created.
Public: Update or Create a record based on an external ID
def upsert(sobject, field, attrs) upsert!(sobject, field, attrs) rescue *exceptions false end