Update a Record (Beta)

AVAILABLE API VERSION
API v59.0 and later

Use mutations to update a record. Within mutations, the RecordUpdate field enables you to update all object types your Salesforce user has access to. Only objects supported by UI API are available for mutations.

To update a record, use RecordUpdate with the Id and field values for the record you want to update.

The response body returns a success boolean with a value of true or false.

Consider these guidelines when updating a record.

  • For compound fields, use the constituent fields. For example use FirstName and LastName instead of Name.
  • For numerical field values, such as integers or currency, use the raw values. For example, use 80000 instead of 80,000 and don't include currency symbols.
  • Sending an update request with field values that don't match the supported format returns a ValidationError. Use the appropriate format for the field, such as YYYY-MM-DD for date fields.
  • Sending an update request with an incorrect Id value returns a DataFetchingException error.

Send Mutation Requests