57 lines
1.3 KiB
JSON
57 lines
1.3 KiB
JSON
{
|
|
"Routes": [
|
|
{
|
|
"SwaggerKey": "apitest",
|
|
//Incoming
|
|
"UpstreamPathTemplate": "/Test",
|
|
"UpstreamHttpMethod": [ "GET", "POST" ],
|
|
|
|
//Routed
|
|
"DownstreamScheme": "http",
|
|
"DownstreamHostAndPorts": [
|
|
{
|
|
"Host": "localhost",
|
|
"Port": 5041
|
|
}
|
|
],
|
|
"DownstreamPathTemplate": "/ApiTest",
|
|
|
|
//Auth
|
|
"AuthenticationOptions": {
|
|
//"AuthenticationProviderKey": "Bearer",
|
|
"AllowedScopes": [] // Ejemplo: "api.portfolio.manager.v1"
|
|
},
|
|
"RouteClaimsRequirement": {
|
|
"permisos": "nuepDLYs7n8="
|
|
}
|
|
},
|
|
|
|
|
|
{
|
|
"SwaggerKey": "apitest",
|
|
|
|
"UpstreamPathTemplate": "/Test/{id}",
|
|
"UpstreamHttpMethod": [ "DELETE" ],
|
|
|
|
"DownstreamScheme": "http",
|
|
"DownstreamHostAndPorts": [
|
|
{
|
|
"Host": "localhost",
|
|
"Port": 5041
|
|
}
|
|
],
|
|
"DownstreamPathTemplate": "/ApiTest/{id}",
|
|
|
|
//
|
|
"RateLimitOptions": {
|
|
"ClientWhiteList": [],
|
|
"EnableRateLimiting": true,
|
|
"Period": "5s", //s =sec, m = min, h = hour, d = day // Solo puede hacer request en x tiempo
|
|
"PeriodTimespan": 10, // reintentar luego de x tiempo si entra en el error del period
|
|
"Limit": 1 //Request que puede hacer 1 cliente
|
|
}
|
|
|
|
}
|
|
]
|
|
}
|