ActivityDetail
A group of field-level changes that occurred within a single activity context in a change details record.
Declaration
object ActivityDetailProperties
| Name | Type | Description |
|---|---|---|
transactionId | string | The identifier of the transaction this activity belongs to. Matches the |
changes | [ActivityDetail.Changes] | An array of ActivityDetail.Changes field change objects, one per field that changed in this activity. Each object contains three keys: |
Discussion
Locate ActivityDetail in the response hierarchy
Change history detail responses use a three-level nesting:
ChangeDetails
└── details: ActivityDetail[]
└── changes: [{ field, oldValues, newValues }]Each ChangeDetails record has one or more ActivityDetail entries in its details array. Each ActivityDetail groups the field-level changes that share a common activity context within the transaction. In most cases, a single ActivityDetail contains all field changes for the entity.
Iterate over field changes
To access individual field changes, iterate the changes array on each ActivityDetail:
"details": [
{
"transactionId": "txn_abc123def456",
"changes": [
{ "field": "status", "oldValues": ["PAUSED"], "newValues": ["ENABLED"] },
{ "field": "dailyBudget", "oldValues": ["50.00"], "newValues": ["100.00"] }
]
}
]The API encodes all values in oldValues and newValues as strings, regardless of the underlying field type. Parse them according to the field’s expected type.
Example
{
"transactionId": "txn_abc123def456",
"changes": [
{
"field": "status",
"oldValues": ["PAUSED"],
"newValues": ["ENABLED"]
},
{
"field": "dailyBudget",
"oldValues": ["50.00"],
"newValues": ["100.00"]
}
]
}