skipToNext method

Future<void> skipToNext({
  1. String? deviceId,
})

Skips to the next track in the user's queue.

Implementation

Future<void> skipToNext({String? deviceId}) async {
  final uri = Uri.https(
    _baseApiHost,
    '/v1/me/player/next',
    deviceId != null ? {'device_id': deviceId} : null,
  );

  await _postJson(uri);
}