toggle method

Future<bool> toggle()

Toggles the status of the stream output.

  • Complexity Rating: 1/5
  • Latest Supported RPC Version: 1
  • Added in v5.0.0

Implementation

Future<bool> toggle() async {
  final response = await obsWebSocket
      .sendRequest(Request('ToggleStream', expectResponse: true));

  return BooleanResponse.fromJson(response!.responseData!).enabled;
}