<!--
{
  "availability" : [
    "iOS: 11.0.0 -",
    "iPadOS: 11.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.13.0 -",
    "tvOS: 11.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 4.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreData",
  "identifier" : "/documentation/CoreData/NSPersistentHistoryTransaction",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "Core Data"
    ],
    "preciseIdentifier" : "c:objc(cs)NSPersistentHistoryTransaction"
  },
  "title" : "NSPersistentHistoryTransaction"
}
-->

# NSPersistentHistoryTransaction

A set of changes in the persistent history based on a context save or batch operation.

```
class NSPersistentHistoryTransaction
```

## Topics

### Requesting Notifications

[`objectIDNotification()`](/documentation/CoreData/NSPersistentHistoryTransaction/objectIDNotification())

Obtains a notification for use in merging the transaction’s changes into a managed object context.

### Customizing History Fetch Requests

[`fetchRequest`](/documentation/CoreData/NSPersistentHistoryTransaction/fetchRequest)

A fetch request that has the persistent history transaction as the entity.

[`entityDescription`](/documentation/CoreData/NSPersistentHistoryTransaction/entityDescription)

The entity description of the persistent history transaction entity.

[`entityDescription(with:)`](/documentation/CoreData/NSPersistentHistoryTransaction/entityDescription(with:))

Requests an entity description using the provided context for the managed object type affected by the transaction.

### Inspecting Transaction Details

[`author`](/documentation/CoreData/NSPersistentHistoryTransaction/author)

A granular description of the context that made the persistent history change, if available.

[`bundleID`](/documentation/CoreData/NSPersistentHistoryTransaction/bundleID)

The originating bundle’s identifier.

[`changes`](/documentation/CoreData/NSPersistentHistoryTransaction/changes)

The array of persistent history changes.

[`contextName`](/documentation/CoreData/NSPersistentHistoryTransaction/contextName)

The originating context’s name.

[`processID`](/documentation/CoreData/NSPersistentHistoryTransaction/processID)

The originating process’s identifier.

[`storeID`](/documentation/CoreData/NSPersistentHistoryTransaction/storeID)

The originating store’s identifier.

[`timestamp`](/documentation/CoreData/NSPersistentHistoryTransaction/timestamp)

The date of the persistent history change.

[`token`](/documentation/CoreData/NSPersistentHistoryTransaction/token)

The token that represents this transaction in the persistent history.

[`transactionNumber`](/documentation/CoreData/NSPersistentHistoryTransaction/transactionNumber)

The transaction’s numeric identifier.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)