<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AVSystemRouting",
  "identifier" : "/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "AVSystemRouting"
    ],
    "preciseIdentifier" : "c:objc(cs)AVSystemRouteSession"
  },
  "title" : "AVSystemRouteSession"
}
-->

# AVSystemRouteSession

An object that manages a single media playback session on a remote device.

```
@interface AVSystemRouteSession : NSObject
```

## Overview

[`AVSystemRouteSession`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6) manages a single media playback session on a remote device. Create a
session to initiate playback on a connected device, communicate with a remote application, and
control the lifecycle of the remote playback experience.

To use a session:

1. Create an [`AVSystemRouteSession`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6) with a URL and launch mode
2. Add the session to an [`AVSystemRoute`](/documentation/AVSystemRouting/AVSystemRoute-9kkj3) using [`addSession:`](/documentation/AVSystemRouting/AVSystemRoute-9kkj3/addSession:)
3. Start the session with [`startWithCompletionHandler:`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/startWithCompletionHandler:)
4. Use the returned [`AVSystemRouteMediaSession`](/documentation/AVSystemRouting/AVSystemRouteMediaSession-4mo0j) to communicate with the remote device
5. Call [`stop`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/stop) when playback ends to clean up resources

Sessions are single-use. After calling [`stop`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/stop), the session cannot be
restarted or added to another route. Create a new [`AVSystemRouteSession`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6) for each new
playback.

## Reporting Playback Metadata

Report playback metadata to `MPNowPlayingInfoCenter` to ensure the system displays accurate
information about the current media across a person’s devices and in system UI.

## Topics

### Instance Methods

[`- (instancetype) initWithURL:(NSURL *) url mode:(AVSystemRouteLaunchMode) mode;`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/initWithURL:mode:)

Creates a session for initiating playback on a remote device.

[`- (void) startWithCompletionHandler:(void (^)(NSError *launchError, AVSystemRouteMediaSession *mediaSession)) completionHandler;`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/startWithCompletionHandler:)

Starts the session and initiates media playback on the remote device.

[`- (void) stop;`](/documentation/AVSystemRouting/AVSystemRouteSession-5i6j6/stop)

Stops the session and terminates media playback on the remote device.

## Relationships

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

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)