HeartbeatService
public protocol HeartbeatService
The Heartbeat Service contract
-
Uniqueue identifier of the content
Declaration
Swift
var contentId: String { get } -
Uniqueue identifier of the device
Declaration
Swift
var deviceId: String { get } -
heartbeat(token:Default implementationoffset: primaryId: catalogType: headers: completion: ) API to update heartbeat. Returns error when the request is failed.
Default Implementation
API to update heartbeat. Returns error when the request is failed.
Declaration
Swift
func heartbeat(token: String, offset: TimeInterval?, primaryId: String?, catalogType: String?, headers: Headers?, completion: @escaping (Result<HeartbeatResponse?, Error>) -> Void)Parameters
tokenLatest heartbeat token to be sent.
offsetContent offset i.e. playhead current time in milliseconds.
primaryIdThe unique identifier of the primary content to which the selected content (i.e. secondary angle content) to play is associated with. This is applicable only for multi-camera enabled content.
catalogTypeThe value of the Catalog Type of content.
headersHeaders if any to be added to heartbeat requests
completionThe handle to invoke on request completion.