<!--
{
  "availability" : [
    "iOS: 9.3.0 - 12.0.0",
    "iPadOS: 9.3.0 - 12.0.0",
    "macCatalyst: 13.1.0 - 13.1.0",
    "visionOS: 1.0.0 - 1.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "MediaPlayer",
  "identifier" : "/documentation/MediaPlayer/MPPlayableContentDelegate/playableContentManager(_:initializePlaybackQueueWithContentItems:completionHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Media Player"
    ],
    "preciseIdentifier" : "c:objc(pl)MPPlayableContentDelegate(im)playableContentManager:initializePlaybackQueueWithContentItems:completionHandler:"
  },
  "title" : "playableContentManager(_:initializePlaybackQueueWithContentItems:completionHandler:)"
}
-->

# playableContentManager(_:initializePlaybackQueueWithContentItems:completionHandler:)

Asks the delegate to prepare suggested content for playback.

```
optional func playableContentManager(_ contentManager: MPPlayableContentManager, initializePlaybackQueueWithContentItems contentItems: [Any]?, completionHandler: @escaping @Sendable ((any Error)?) -> Void)
```

## Parameters

`contentManager`

The content manager that initiated the request.

`contentItems`

The content items to load.

`completionHandler`

A block that the system calls after content is ready for playback. The block takes the following parameter:

- error: Pass <doc://com.apple.documentation/documentation/ObjectiveC/nil-227m0> if playback successfully began. If playback can’t begin, pass an error to indicate the reason.

## Discussion

iOS calls this method when the user performs an action that, in context, might indicate intent to begin playing content using your app. For example, if the user frequently listens to audio content in your app with headphones while at a particular location, iOS might call this method upon plugging in headphones when the user is at that location. Your app responds by choosing appropriate content, performing any app-specific actions necessary to prepare the content for playback, and setting the [`nowPlayingInfo`](/documentation/MediaPlayer/MPNowPlayingInfoCenter/nowPlayingInfo) property of the shared [`MPNowPlayingInfoCenter`](/documentation/MediaPlayer/MPNowPlayingInfoCenter) object to indicate to the user that this content is ready to play.

Use this method only to suggest content. Don’t begin playback of content in this method—do so only upon receiving a `Play` command or when the playable content manager requests to play something else.

After preparing content for playing, call the provided `completionHandler` block with an argument of <doc://com.apple.documentation/documentation/ObjectiveC/nil-227m0>; or, if your app can’t prepare content, call the completion handler an error that indicates the reason.

---

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)