Test: Google oauth

This commit is contained in:
Kamigen
2024-04-15 19:10:32 -04:00
parent b6e65b416d
commit bd2410a98e
12 changed files with 132 additions and 15 deletions

View File

@@ -0,0 +1,8 @@
using Google.Apis.Oauth2.v2.Data;
namespace Hutopy.Application.Common.Interfaces;
public interface IGoogleService
{
Task<Userinfo?> GetUserInfoAsync(string accessToken);
}

View File

@@ -1,4 +1,5 @@
using Hutopy.Application.Common.Models;
using Google.Apis.Oauth2.v2.Data;
using Hutopy.Application.Common.Models;
namespace Hutopy.Application.Common.Interfaces;
@@ -11,6 +12,8 @@ public interface IIdentityService
Task<bool> AuthorizeAsync(string userId, string policyName);
Task<(Result Result, string UserId)> CreateUserAsync(string userName, string password);
Task<(Result Result, string UserId)> CreateUserAsync(Userinfo userInfo);
Task<Result> DeleteUserAsync(string userId);
}