/// <summary> /// Set sensor's frequency sub band to 902.3 kHz - 903.7 kHz - 125k" /// </summary> private static async Task SetFrequencySubBand(string sensorId) { Console.WriteLine("Test /api/sensor/set-frequency-sub-band"); Console.WriteLine("Set Frequency sub band to 902.3 kHz - 903.7 kHz - 125k"); string input = Console.ReadLine(); if (input == "y" || input == "Y") { try { // Sample JSON to send. Payload is an int (see API documentation) JObject json = new JObject { ["sensorId"] = sensorId, ["payload"] = 1 }; Console.WriteLine("Sending set requency Sub Band..."); await SensorApi.SetFrequencySubBand(json.ToString()); Console.WriteLine("Set frequency sub band sent" + "\n"); } catch (Exception ex) { Console.WriteLine("Method Error: " + ex.Message + "\n"); } } }