When attempting to stream fairplay-protected content to an Apple TV over AirPlay, we run into a problem, which is that the Apple TV does not request anything via FPS, but instead is seeking to do direct key-fetch from the App using the protocol handler (e.g. "fps://") - when disabling our protocol handler, and only having FPS, it just fails outright and does not contact the iOS App. Is there some special sequence of calls that needs to be made to make this work properly with an Apple TV?
Note that everything plays properly (and is properly protected by FPS) when playing locally on a device.
See the FairPlay Overview document Figure 1-3 (<https://developer.apple.com/services-account/download?path=/Documentation/FairPlay_Streaming_Overview/FairPlayStreaming_Overview.pdf>) which describes FPS streaming over AirPlay. In an AirPlay scenario, the FPS request is always routed through the app. The AppleTV never talks to the Key Server directly to get keys. To do this, the app must set the usesExternalPlaybackWhileExternalScreenIsActive property of the AVPlayer object to TRUE with code like this:
// create AVPlayer object
player = [AVPlayer playerWithURL:movieURL];
// set the property to TRUE
player.usesExternalPlaybackWhileExternalScreenIsActive = TRUE;
This is discussed in the FairPlay Streaming Programming Guide section titled “Configuring AirPlay Mode” (<https://developer.apple.com/services-account/download?path=/Developer_Tools/FairPlay_Streaming_SDK/FairPlay_Streaming_Server_SDK.zip>).
In other words, your app will receive the callback with the SPC just like in the local playback case. The behavior you are seeing is expected. You should expect your app to make the FPS request even in the case of AirPlay streaming.