title: How would I order my youtube video search by highest views?
body: <p>I'm working on a youtube video search for a Chat bot on a website.</p>
  
  <p>I want the search to be ordered by the highest views for a video, as I think that'd be the most accurate result if a user searches for something. That's my code for doing the search:</p>
  
  <pre><code>  var searchListRequest = youtubeService.Search.List("snippet");
          searchListRequest.Q = result;
          searchListRequest.MaxResults = 25;
  </code></pre>
  
  <p>The youtube API says there is a way to sort by highest views. The <a href="https://developers.google.com/youtube/v3/docs/search/list" rel="nofollow">API documentation</a> says that under optional paramaters there is "order" and you can order by viewCount. I'm struggling to put this into my code for some reason and have been trying for hours.</p>