Contents

update(_:alertConfiguration:timestamp:)

Updates the dynamic content of a Live Activity and alerts a person about the Live Activity update.

Declaration

func update(_ content: ActivityContent<Activity<Attributes>.ContentState>, alertConfiguration: AlertConfiguration? = nil, timestamp: Date) async

Parameters

  • content:

    The updated dynamic content for the Live Activity. The size of its State property can’t exceed 4KB in size.

  • alertConfiguration:

    The alert configuration you use to configure how the system notifies a person about the updated content of the Live Activity.

  • timestamp:

    The time the data in the payload was generated. If this is older than a previous update or push payload, the system ignores this update.

Discussion

The system ignores updates to a Live Activity that’s in the ActivityState.ended state.

See Also

Updating a Live Activity