This commit is contained in:
2024-01-19 17:25:56 +01:00
Unverified
parent ab9be442ee
commit 5d5a69ccf7
69 changed files with 3769 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
using Microsoft.Extensions.Configuration;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SecureBank.Website.API
{
public class APIEndpointsConfiguration
{
#region PROPERTIES
public string Base { get; private set; }
// Accounts
public string AccountsBase { get; private set; }
public string AccountsCreateAccount { get; private set; }
public string AccountsGetPasswordVariant { get; private set; }
public string AccountsAuthentication { get; private set; }
public string AccountsAuthenticationRefresh { get; private set; }
#endregion
#region CONSTRUCTORS
public APIEndpointsConfiguration(IConfiguration configuration)
{
Base = configuration.GetSection("Endpoints")["Base"];
AccountsBase = $"{Base}{configuration.GetSection("Endpoints").GetSection("Accounts")["Base"]}";
AccountsCreateAccount = $"{AccountsBase}{configuration.GetSection("Endpoints").GetSection("Accounts")["CreateAccount"]}";
AccountsGetPasswordVariant = $"{AccountsBase}{configuration.GetSection("Endpoints").GetSection("Accounts")["GetPasswordVariant"]}";
AccountsAuthentication = $"{AccountsBase}{configuration.GetSection("Endpoints").GetSection("Accounts")["Authentication"]}";
AccountsAuthenticationRefresh = $"{AccountsBase}{configuration.GetSection("Endpoints").GetSection("Accounts")["AuthenticationRefresh"]}";
}
#endregion
}
}