title: IdentityServer "invalid_client" error always returned
body: <p>I'm trying to use IdentityServer3, but don't know why I'm getting "invalid_client" error always, always no matter what I do.</p>
  
  <p>This is the code I'm using:</p>
  
  <pre><code>//Startup.cs (Auth c# project)
  public void Configuration(IAppBuilder app) {
      var inMemoryManager = new InMemoryManager();
      var factory = new IdentityServerServiceFactory()
          .UseInMemoryClients(inMemoryManager.GetClients())
          .UseInMemoryScopes(inMemoryManager.GetScopes())
          .UseInMemoryUsers(inMemoryManager.GetUsers());
  
      var options = new IdentityServerOptions {
          Factory = factory,
          RequireSsl = false
      };
  
      app.UseIdentityServer(options);
  }
  </code></pre>
  
  <p>InMemoryManager helper.</p>
  
  <pre><code>//InMemoryManager.cs
  public class InMemoryManager {
      public List&lt;InMemoryUser&gt; GetUsers() {
          return new List&lt;InMemoryUser&gt; {
              new InMemoryUser {
                  Username = "alice",
                  Password = "password",
                  Subject = "2",
                  Claims = new [] {
                      new Claim("User name", "Alice")
                  }
              }
          };
      }
  
      public IEnumerable&lt;Scope&gt; GetScopes() {
          return new[] {
              new Scope {
                  Name = "api1",
                  DisplayName = "API 1"
              }
          };
      }
  
      public IEnumerable&lt;Client&gt; GetClients() {
          return new[] {
              new Client {
                  ClientName = "Silicon on behalf of Carbon Client",
                  ClientId = "carbon",
                  Enabled = true,
                  //AccessTokenType = AccessTokenType.Reference,
  
                  Flow = Flows.ResourceOwner,
  
                  ClientSecrets = new List&lt;Secret&gt; {
                      new Secret("secret".Sha256())
                  },
  
                  AllowedScopes = new List&lt;string&gt; {
                      "api1"
                  }
              }
          };
      }
  }
  </code></pre>
  
  <p>This is the result I always get.</p>
  
  <p><a href="https://i.stack.imgur.com/sBrOW.png" rel="noreferrer"><img src="https://i.stack.imgur.com/sBrOW.png" alt="Postman error"></a></p>
  
  <p>I'm using postman to try the Auth Server, but I always get that error. I've read another solutions but none seeme to works, I don't know what else to try.</p>
  
  <p>Cheers.</p>