title: Sending a message to my bot using the Direct Line v3.0 NuGet package
body: <p>I am trying to use the <a href="https://www.nuget.org/packages/Microsoft.Bot.Connector.DirectLine/3.0.0-beta" rel="nofollow noreferrer">Direct Line v3.0 NuGet package</a> to send a message to my bot. I am following the <a href="https://github.com/Microsoft/BotBuilder-Samples/tree/master/CSharp/core-DirectLine" rel="nofollow noreferrer">sample</a> on Github, but I'm not getting the behavior I expect.</p>
  
  <p>Here is the sample code:</p>
  
  <pre class="lang-cs prettyprint-override"><code>DirectLineClient client = new DirectLineClient(directLineSecret);        
  var conversation = await client.Conversations.StartConversationAsync();
  
  while (true)
  {
      string input = Console.ReadLine().Trim();
  
      if (input.ToLower() == "exit")
      {
          break;
      }
      else
      {
          if (input.Length &gt; 0)
          {
              Activity userMessage = new Activity
              {
                  From = new ChannelAccount(fromUser),
                  Text = input,
                  Type = ActivityTypes.Message
              };
  
              await client.Conversations.PostActivityAsync(conversation.ConversationId, userMessage);
          }
      }
  }
  </code></pre>
  
  <p>And here is my code:</p>
  
  <pre class="lang-cs prettyprint-override"><code>var directLineSecret = "MY_SECRET";
  var client = new DirectLineClient(directLineSecret);
  var conversation = await client.Conversations.StartConversationAsync();
  
  var testActivity = new Activity
  {
      From = new ChannelAccount(name: "Proactive-Engine"),
      Type = ActivityTypes.Message,
      Text = "Hello from the PCE!"
  };
  
  var response = await client.Conversations.PostActivityAsync(conversation.ConversationId, testActivity);
  </code></pre>
  
  <p>I'm logging all the messages my bot receives. I can talk to the bot at its endpoint on Azure using the Bot Emulator, so I have confidence that it's working through the web chat API. However when I run the code above, the bot logs only a <code>conversationUpdate</code> message. The message I send does not get logged, and the value of <code>response</code> is <code>null</code>.</p>
  
  <p>I'm hoping someone can help me find out where I'm going wrong here. Thanks!</p>