platypush/plugins/music/spotify/__init__.py
def seek(self, position: float, device: Optional[str] = None, **kwargs):
        """
        Set the cursor to the specified position in the track.

        :param position: Position in seconds.
        :param device: Device ID or name. If none is specified then the action will target the currently active device.
        """
        if device:
            device = self._get_device(device)['id']

        self.spotify_user_call(
            f'/v1/me/player/seek',
            method='put',
            params={
                'position_ms': int(position * 1000),
                **({'device_id': device} if device else {}),
            },
        )

        Set the cursor to the specified position in the track.

        :param position: Position in seconds.
        :param device: Device ID or name. If none is specified then the action will target the currently active device.
        
Set the cursor to the specified position in the track.
Set the cursor to the specified position in the track .
def seek(self, position: float, device: Optional[str] = None, **kwargs):
        if device:
            device = self._get_device(device)['id']
        self.spotify_user_call(
            f'/v1/me/player/seek',
            method='put',
            params={
                'position_ms': int(position * 1000),
                **({'device_id': device} if device else {}),
            },
        )
def seek ( self , position : float , device : Optional [ str ] = None , ** kwargs ) : if device : device = self . _get_device ( device ) [ 'id' ] self . spotify_user_call ( f'/v1/me/player/seek' , method = 'put' , params = { 'position_ms' : int ( position * 1000 ) , ** ( { 'device_id' : device } if device else { } ) , } , )
Set the cursor to the specified position in the track.
Set the cursor to the specified position in the track .
"""
        Set the cursor to the specified position in the track.

        :param position: Position in seconds.
        :param device: Device ID or name. If none is specified then the action will target the currently active device.
        """
self
position
float
Position in seconds.
Position in seconds .
device
Optional[str]
Device ID or name. If none is specified then the action will target the currently active device.
Device ID or name . If none is specified then the action will target the currently active device .