title: Create Bot with Rest API or SDK
body: <p>I want to be able to create an Azure bot with a rest api or sdk if possible. I figured out how to create the AAD V2 app that the bot needs, but am stuck on creating the bot.</p>
  
  <p>I found the following <a href="https://www.nuget.org/packages/Microsoft.Azure.Management.BotService/0.9.1-preview" rel="nofollow noreferrer">Nuget package</a> which sounds like what I want but gives me an error. This is how I am using it.</p>
  
  <pre><code>var cred = SdkContext.AzureCredentialsFactory.FromServicePrincipal(clientId,
              clientSecret,
              tenantId,
              AzureEnvironment.AzureGlobalCloud);
  
          var azure = new Microsoft.Azure.Management.BotService.AzureBotServiceClient(cred);
          azure.SubscriptionId = "subscriptionId";
  
          var bot = new Bot
          {
              Location = "global",
              Properties = new BotProperties
              {
                  Description = "Description of New Bot",
                  DisplayName = "MyNewBotCreatedFromConsole",
                  Endpoint = "https://myurl",
                  Kind = "sdk",
                  Sku = new Sku(SkuName.F0, SkuTier.Free),
                  Location = "global",
                  MsaAppId = "appId",
                  MsaAppPassword = "password"
              },
          };
  
          var newBot = await azure.Bots.CreateWithHttpMessagesAsync("resourceGroup", "test-bot-my-1",
              bot);
  </code></pre>
  
  <p>When using fiddler I see the following response:</p>
  
  <pre><code>{"error":{"code":"InvalidBotData","message":"Bot is not valid. Errors: BotServiceRuntimeVersion: RuntimeVersion is required. "}}
  </code></pre>
  
  <p>I'm not sure if this is a header I am supposed to pass along or some other problem? Does someone know if I am on the right path to doing what I want to do?</p>