/// <summary> /// Generates a public key from given secret asynchronously /// </summary> /// <param name="acc">AccountGeneratePublickeyRequest with secret</param> /// <returns>AccountGeneratePublicKeyResponse with public key details</returns> public async Task <AccountGeneratePublicKeyResponse> GenerateAccountPublickeyAsync(AccountGeneratePublickeyRequest acc) { _url.Path = Constants.ApiPostAccountOpen; _url.Query = acc.ToQuery(); var response = await _client.PostJsonAsync <AccountGeneratePublickeyRequest, AccountGeneratePublicKeyResponse>(_url.ToString(), acc); ResetPath(); return(response); }
/// <summary> /// Generates a public key from given secret asynchronously /// </summary> /// <param name="acc">AccountGeneratePublickeyRequest with secret</param> /// <returns>AccountGeneratePublicKeyResponse with public key details</returns> public async Task<AccountGeneratePublicKeyResponse> GenerateAccountPublickeyAsync(AccountGeneratePublickeyRequest acc) { _url.Path = Constants.ApiPostAccountOpen; _url.Query = acc.ToQuery(); var response = await _client.PostJsonAsync<AccountGeneratePublickeyRequest, AccountGeneratePublicKeyResponse>(_url.ToString(), acc); ResetPath(); return response; }
/// <summary> /// Generates a public key from given secret synchronously /// </summary> /// <param name="acc">AccountGeneratePublickeyRequest with secret</param> /// <returns>AccountGeneratePublicKeyResponse with public key details</returns> public AccountGeneratePublicKeyResponse GenerateAccountPublickey(AccountGeneratePublickeyRequest acc) { var response = GenerateAccountPublickeyAsync(acc).GetAwaiter().GetResult(); return(response); }
/// <summary> /// Generates a public key from given secret synchronously /// </summary> /// <param name="acc">AccountGeneratePublickeyRequest with secret</param> /// <returns>AccountGeneratePublicKeyResponse with public key details</returns> public AccountGeneratePublicKeyResponse GenerateAccountPublickey(AccountGeneratePublickeyRequest acc) { var response = GenerateAccountPublickeyAsync(acc).GetAwaiter().GetResult(); return response; }