# Ocelot [![Build status](https://ci.appveyor.com/api/projects/status/roahbe4nl526ysya?svg=true)](https://ci.appveyor.com/project/TomPallister/ocelot) [![Join the chat at https://gitter.im/Ocelotey/Lobby](https://badges.gitter.im/Ocelotey/Lobby.svg)](https://gitter.im/Ocelotey/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) Attempt at a .NET Api Gateway This project is aimed at people using .NET running a micro services / service orientated architecture that need a unified point of entry into their system. In particular I want easy integration with IdentityServer reference and bearer tokens. We have been unable to find this in my current workplace without having to write our own Javascript middlewares to handle the IdentityServer reference tokens. We would rather use the IdentityServer code that already exists to do this. Priorities - Route configuration - IdentityServer reference & bearer tokens - Strip claims from tokens and use in proxy request - Authorise access to routes based on claims in token - Output Caching - Monitoring - Logging - Rate Limiting - Then a big list of cool things... # How to use # Configuration TBC really but example configuration for a route below. ReRoutes: # the url we are forwarding the request to - DownstreamTemplate: http://localhost:52876/ # the path we are listening on for this re route UpstreamTemplate: / # the method we are listening for on this re route UpstreamHttpMethod: Get # only support identity server at the moment AuthenticationOptions: Provider: IdentityServer ProviderRootUrl: http://localhost:52888 ScopeName: api AdditionalScopes: - openid - offline_access #require if using reference tokens ScopeSecret: secret # WARNING - will overwrite any headers already in the request with these values AddHeadersToRequest: CustomerId: Claims[CustomerId] > value LocationId: Claims[LocationId] > value UserType: Claims[sub] > value[0] > | UserId: Claims[sub] > value[1] > |