Files
2026-06-09 22:27:38 +02:00

19 lines
458 B
C#

using EonaCat.gRPC.Proto;
namespace EonaCat.gRPC.Client;
public interface ITokenProvider
{
Task<AuthenticationResponse> GetTokenAsync();
}
public class AppTokenProvider : ITokenProvider
{
private AuthenticationResponse _token;
public async Task<AuthenticationResponse> GetTokenAsync()
{
if (_token == null)
_token = new AuthenticationResponse { AccessToken = "test", ExpiresIn = 300 };
return _token;
}
}