title: In ASP.NET Core, how do I use a service that is setup in ConfigureServices() in Configure()?
body: <p>I have a service I wrote that helps with configuration.  The service is set up in the Startup class's ConfigureServices method as:</p>
  <pre><code>public void ConfigureServices(IServiceCollection services)
  {
      ...
  
      services.AddScoped&lt;IMyService, MyService&gt;();
  
      ...
  }
  </code></pre>
  <p>I need to then get an instance of IMyService in the Startup class's Configure method.  How do I do that?</p>