1
0
Fork 0
mirror of https://github.com/anyproto/any-sync.git synced 2025-06-11 18:20:28 +09:00

Add IsNameValid method

This commit is contained in:
Anton Akentev 2024-03-20 19:06:31 +00:00
parent 3727016677
commit 14cbcd82a0
5 changed files with 629 additions and 85 deletions

View file

@ -23,6 +23,7 @@ var log = logger.NewNamed(CName)
*/
type AnyPpClientService interface {
GetSubscriptionStatus(ctx context.Context, in *pp.GetSubscriptionRequestSigned) (out *pp.GetSubscriptionResponse, err error)
IsNameValid(ctx context.Context, in *pp.IsNameValidRequest) (out *pp.IsNameValidResponse, err error)
BuySubscription(ctx context.Context, in *pp.BuySubscriptionRequestSigned) (out *pp.BuySubscriptionResponse, err error)
GetSubscriptionPortalLink(ctx context.Context, in *pp.GetSubscriptionPortalLinkRequestSigned) (out *pp.GetSubscriptionPortalLinkResponse, err error)
GetVerificationEmail(ctx context.Context, in *pp.GetVerificationEmailRequestSigned) (out *pp.GetVerificationEmailResponse, err error)
@ -144,3 +145,13 @@ func (s *service) GetAllTiers(ctx context.Context, in *pp.GetTiersRequestSigned)
})
return
}
func (s *service) IsNameValid(ctx context.Context, in *pp.IsNameValidRequest) (out *pp.IsNameValidResponse, err error) {
err = s.doClient(ctx, func(cl pp.DRPCAnyPaymentProcessingClient) error {
if out, err = cl.IsNameValid(ctx, in); err != nil {
return rpcerr.Unwrap(err)
}
return nil
})
return
}