GroupActivities powers SharePlay shared experiences over FaceTime, letting you build activities that participants engage with together across their devices. You define an activity by conforming a type to GroupActivity, then join a GroupSession to coordinate state, observe participation through Participant and GroupStateObserver, and exchange data using GroupSessionMessenger and GroupSessionJournal. For shared experiences in visionOS, you arrange participants in space with SpatialTemplate and its associated elements, and synchronize windows and scenes through SystemCoordinator and SceneAssociationBehavior.
Defining an Activity 5
Declare a shared experience and the metadata used to present it to participants.
- PrGroupActivityA type that can advertise your app's activities to other participants.
- StGroupActivityMetadataText and image content that describes an activity to potential participants.
- StGroupActivityTransferRepresentationA type that lets you start a group activity from a known context.
- EnGroupActivityActivationResultThe result of preparing to start a custom activity.
- EnGroupActivitySharingResultThe result of a request to share a group activity in iOS.
Sessions 3
Join and manage the shared session that coordinates a SharePlay activity across devices.
- ClGroupSessionA session for an in-progress activity that synchronizes content among participant devices.
- StGroupSessionEventA session-related event that appears in the system UI.
- StBroadcastOptionsOptions for how to broadcast media on the shared communications channel.
Participation 3
Observe who is taking part in the session and whether SharePlay is available.
- StParticipantAn active participant in a group session.
- EnParticipantsThe set of participants to include in messages.
- ClGroupStateObserverAn object that contains information about the system’s ability to start SharePlay experiences.
Exchanging Data 3
Send messages and share larger payloads between participants in a session.
- ClGroupSessionMessengerAn object that transfers app-specific data between the devices joined in a group session.
- ClGroupSessionJournalAn object that manages file and data transfers between participants
- PrCustomMessageIdentifiableA type that assigns a custom ID string to messages you send to other devices.
Spatial Templates 9
Arrange participants in shared space for visionOS experiences.
- PrSpatialTemplateAn interface you use to create custom arrangements of spatial Personas
- StSpatialTemplateConfigurationA type that contains the configuration details for a spatial template.
- StSpatialTemplatePreferenceA structure that specifies the preferred arrangement
- PrSpatialTemplateElementAn interface that defines an element in your spatial template.
- PrSpatialTemplateRoleAn interface for defining roles that you assign to the
- StSpatialTemplateSeatElementA spatial template element that represents a seat for a participant
- StSpatialTemplateElementAxisAn axis to use when aligning elements in a spatial template.
- StSpatialTemplateElementDirectionThe initial direction a participant faces when an activity starts.
- StSpatialTemplateElementPositionA type that defines the position of an element in a spatial template.
Window and Scene Coordination 3
Synchronize windows and scenes across participants in spatial experiences.
- ClSystemCoordinatorA type you use to coordinate your interface's behavior when an
- StSceneAssociationBehaviorA type that tells the system which scene to associate with an incoming
- StGroupActivityAssociationKindAn association a user-interface element can have with a SharePlay group activity.
Classes 2
- ClGroupActivityAssociationInteractionAn interaction configures a view's association with the current SharePlay
- ClGroupActivitySharingControllerAn iOS view controller that displays the system interface for starting an