♻️ Refind bot account

This commit is contained in:
2025-08-23 13:00:30 +08:00
parent fb7e52d6f3
commit 5d7429a416
15 changed files with 691 additions and 71 deletions

View File

@@ -11,6 +11,13 @@ public class AccountClientHelper(AccountService.AccountServiceClient accounts)
var response = await accounts.GetAccountAsync(request);
return response;
}
public async Task<Account> GetBotAccount(Guid automatedId)
{
var request = new GetBotAccountRequest { AutomatedId = automatedId.ToString() };
var response = await accounts.GetBotAccountAsync(request);
return response;
}
public async Task<List<Account>> GetAccountBatch(List<Guid> ids)
{
@@ -19,6 +26,14 @@ public class AccountClientHelper(AccountService.AccountServiceClient accounts)
var response = await accounts.GetAccountBatchAsync(request);
return response.Accounts.ToList();
}
public async Task<List<Account>> GetBotAccountBatch(List<Guid> automatedIds)
{
var request = new GetBotAccountBatchRequest();
request.AutomatedId.AddRange(automatedIds.Select(id => id.ToString()));
var response = await accounts.GetBotAccountBatchAsync(request);
return response.Accounts.ToList();
}
public async Task<Dictionary<Guid, AccountStatusReference>> GetAccountStatusBatch(List<Guid> ids)
{