---
schema_version: "1"
id: fe3625f1be68eb46ece4057b76f2a85f928a2eeed85759062f8f1162034a26e6
title: SaveRecordResult
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/aura-platform/guides/aura/data-service/data-service-saverecordresult.md
canonical_url: https://developer.salesforce.com/docs/platform/aura-platform/guide/data-service-saverecordresult.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: d7aee4dadb6e2d544f71be93cb8e550ae8b13bf169ded604cffdbeeba3de00fc
products:
  - Lightning Aura Components Developer Guide
  - Platform Developer Content
---

# SaveRecordResult

Represents the result of a Lightning Data Service operation that makes a persistent change to record data.

## `SaveRecordResult` Object

Callback functions for the `saveRecord` and `deleteRecord` functions receive a `SaveRecordResult` object as their only argument.

|Attribute Name|Type|Description|
|--------------|----|-----------|
|`objectApiName`|String|The object API name for the record.|
|`entityLabel`|String|The label for the name of the sObject of the record.|
|`error`|String|A localized message indicating what went wrong, or an array of errors that includes a localized message and might also include further data to help handle the error, such as field- or page-level errors. `error` is undefined if the save `state` is SUCCESS or DRAFT.|
|`recordId`|String|The 18-character ID of the record affected.|
|`state`|String|The result state of the operation. Possible values are SUCCESS (the operation completed on the server successfully), DRAFT (the server wasn’t reachable, so the operation was saved locally as a draft and is applied to the server when it’s reachable), INCOMPLETE (the server wasn’t reachable, and the device doesn’t support drafts, which are supported only in the Salesforce app; try this operation again later), or ERROR (the operation couldn’t be completed; check the `error` attribute for more information).|

