<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iOSAppExtension: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "NowPlaying",
  "identifier" : "/documentation/NowPlaying/RemoteMediaSessionAttributes",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Now Playing"
    ],
    "preciseIdentifier" : "s:10NowPlaying28RemoteMediaSessionAttributesP"
  },
  "title" : "RemoteMediaSessionAttributes"
}
-->

# RemoteMediaSessionAttributes

A type that represents attributes for remote sessions.

```
protocol RemoteMediaSessionAttributes : Decodable, Encodable
```

## Overview

Conform to this protocol to define the data that configures your remote sessions.
Attributes identify sessions and communicate session state between your app and extension.
The attributes must be encodable for transmission and uniquely identifiable.

Your host app’s [`RemoteMediaSession`](/documentation/NowPlaying/RemoteMediaSession) and your [`RemoteMediaSessionExtension`](/documentation/NowPlaying/RemoteMediaSessionExtension) share
the same attributes type: the host encodes it when starting or updating a session, and
the extension decodes it to create or refresh a session.

For more information, see [Publishing remote media sessions](/documentation/NowPlaying/publishing-remote-media-sessions)

## Topics

### Instance Properties

[`var id: String`](/documentation/NowPlaying/RemoteMediaSessionAttributes/id)

A stable, unique identifier for the session these attributes describe.

## Relationships

### Inherits From

[`Decodable`](/documentation/Swift/Decodable)

[`Encodable`](/documentation/Swift/Encodable)

---

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)