@IviExperimental(reasons = [])
open class Action(val id: String, val arguments: Bundle? = null, val icon: Action.CustomActionIcon? = null) : Parcelable

A command which can be sent (or launched) to the current source so it can be performed. This is a raw command, suitable to be transmitted over IPC.

The difference between Action and BrowserAction is defined mainly by the media source implementation. Actions are sent by the IVI media service and are usually related to the playback (not browsing), for example, play/pause, skip, or like the song.

An action can be a standard or a custom action:

  • Standard actions are common actions recognized by the stock IVI media service. They are supported by most sources. See StandardActionId.

  • Custom actions are all actions that are not listed as a standard action, such as liking a song. They can be used to extend the capabilities of the standard actions and are source-specific.

The distinction between a standard and a custom action is made service-side, based on the id.



The ID of this action. Unique for the media source it refers to. Must not be blank.


Arguments available to customize this action.


Optional icon used for custom actions. The resource ID is extracted from the source's own package.

See also



Link copied to clipboard
constructor(id: ActionId, arguments: Bundle? = null, icon: Action.CustomActionIcon? = null)
constructor(id: String, arguments: Bundle? = null, icon: Action.CustomActionIcon? = null)


Link copied to clipboard
data class CustomActionIcon(@DrawableRes val icon: Int, val sourcePackage: String) : Parcelable

A custom action icon that can be extracted from a sourcePackage.


Link copied to clipboard
val arguments: Bundle? = null
Link copied to clipboard
Link copied to clipboard
val id: String


Link copied to clipboard
operator override fun equals(other: Any?): Boolean
Link copied to clipboard
override fun hashCode(): Int
Link copied to clipboard
open override fun toString(): String

Inherited functions

Link copied to clipboard
abstract fun describeContents(): Int
Link copied to clipboard
abstract fun writeToParcel(p0: Parcel, p1: Int)