Skip to main content

Type Alias: MediaCapability

type MediaCapability =
| "play"
| "pause"
| "stop"
| "seek"
| "skipToNext"
| "skipToPrevious"
| "skipToQueueItem"
| "setRate"
| "setRepeatMode"
| "setShuffle";

Defined in: packages/media-session/src/specs/media-session.nitro.ts:113

A capability the app is willing to service, independent of whether it wants a button for it.

Android: turns into a Player.Command on the facade player's available commands. This is load-bearing — media3 never invokes a handle* method for a command that is not in State.availableCommands, and controllers grey the control out. iOS: turns into an enabled MPRemoteCommand.