Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class TestStartStream
[Fact]
public void StartStreamTest()
{
var expected = "<?xml version=\"1.0\" encoding=\"utf-8\"?><Response> <StartStream name=\"test\" mode=\"unidirectional\" tracks=\"inbound\" destination=\"wss://test.url/\" streamEventUrl=\"https://test.url/\" streamEventMethod=\"POST\" username=\"username\" password=\"password\"> <StreamParam name=\"testName\" value=\"testValue\" /> </StartStream></Response>";
var expected = "<?xml version=\"1.0\" encoding=\"utf-8\"?><Response> <StartStream name=\"test\" mode=\"unidirectional\" tracks=\"inbound\" destination=\"wss://test.url/\" destinationUsername=\"destinationUsername\" destinationPassword=\"destinationPassword\" streamEventUrl=\"https://test.url/\" streamEventMethod=\"POST\" username=\"username\" password=\"password\"> <StreamParam name=\"testName\" value=\"testValue\" /> </StartStream></Response>";

var streamParam = new StreamParam();
streamParam.Name = "testName";
Expand All @@ -22,6 +22,8 @@ public void StartStreamTest()
startStream.Mode = "unidirectional";
startStream.Tracks = "inbound";
startStream.Destination = "wss://test.url/";
startStream.DestinationUsername = "destinationUsername";
startStream.DestinationPassword = "destinationPassword";
startStream.StreamEventUrl = "https://test.url/";
startStream.StreamEventMethod = "POST";
startStream.Username = "username";
Expand Down
14 changes: 13 additions & 1 deletion src/Bandwidth.Standard/Model/Bxml/Verbs/StartStream.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,23 @@ public StartStream()
public string Tracks { get; set; }

/// <summary>
/// A websocket URI to send the stream to.
/// A websocket URI to send the stream to.
/// </summary>
[XmlAttribute("destination")]
public string Destination { get; set; }

/// <summary>
/// The username to send in the `Authorization` header of the initial websocket connection to the `destination` URL.
/// </summary>
[XmlAttribute("destinationUsername")]
public string DestinationUsername { get; set; }

/// <summary>
/// The password to send in the `Authorization` header of the initial websocket connection to the `destination` URL.
/// </summary>
[XmlAttribute("destinationPassword")]
public string DestinationPassword { get; set; }

/// <summary>
/// URL to send the associated Webhook events to during this stream's lifetime.
/// </summary>
Expand Down
Loading