SKDevice
public struct SKDevice : JSONDecodable
A structure representing a device that supports a Spotify player.
-
The possible devices that can support a Spotify player.
See moreDeclaration
Swift
public enum DeviceType : String, Codable -
The device ID, or
nilif unavailable.Declaration
Swift
public let id: String? -
A Boolean value indicating if this device is the currently active device.
Declaration
Swift
public let isActive: Bool -
A Boolean value indicating whether controlling this device via the Spotify Web API is restricted. If
true, then no Web API commands will be accepted by this device.Declaration
Swift
public let isRestricted: Bool -
The name of the device.
Declaration
Swift
public let name: String -
The device type. For possible values, see
DeviceType.Declaration
Swift
public let type: DeviceType -
The device’s current volume, ranging from
0.0to1.0on a linear scale, ornilif unavailable.Declaration
Swift
public var volume: Float? { get }
View on GitHub
SKDevice Structure Reference