feat(GTXMessagingService): initialisiert mit Konfigurationsoption

This commit is contained in:
Developer 02 2024-11-21 11:46:15 +01:00
parent bb8bd8ed40
commit 30f93f2439
3 changed files with 25 additions and 0 deletions

View File

@ -0,0 +1,7 @@
namespace EnvelopeGenerator.Application.Configurations
{
public class GTXMessagingConfig
{
public required string AuthKey { get; init; }
}
}

View File

@ -0,0 +1,15 @@
using EnvelopeGenerator.Application.Configurations;
using Microsoft.Extensions.Options;
namespace EnvelopeGenerator.Application.Services
{
public class GTXMessagingService
{
private readonly string _authKey;
public GTXMessagingService(IOptions<GTXMessagingConfig> options)
{
_authKey = options.Value.AuthKey;
}
}
}

View File

@ -125,5 +125,8 @@
"[SIGNATURE_TYPE]": "signieren", "[SIGNATURE_TYPE]": "signieren",
"[REASON]": "" "[REASON]": ""
} }
},
"GTXMessagingConfig": {
"AuthKey": "ep$?A!Gs"
} }
} }