Skip to content

Commit 6148be2

Browse files
authored
Add network for withdrawals (DigitalRuby#846)
1 parent b6a7fe4 commit 6148be2

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

src/ExchangeSharp/API/Exchanges/BinanceGroup/BinanceGroupCommon.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1145,6 +1145,11 @@ ExchangeWithdrawalRequest withdrawalRequest
11451145
payload["addressTag"] = withdrawalRequest.AddressTag;
11461146
}
11471147

1148+
if (!string.IsNullOrWhiteSpace(withdrawalRequest.Network))
1149+
{
1150+
payload["network"] = withdrawalRequest.Network;
1151+
}
1152+
11481153
JToken response = await MakeJsonRequestAsync<JToken>(
11491154
"/capital/withdraw/apply",
11501155
BaseUrlSApi,

src/ExchangeSharp/Model/ExchangeWithdrawalRequest.cs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,13 @@ public sealed class ExchangeWithdrawalRequest
5050
/// </summary>
5151
public SecureString Code { get; set; }
5252

53-
/// <summary>Returns a <see cref="System.String" /> that represents this instance.</summary>
54-
/// <returns>A <see cref="System.String" /> that represents this instance.</returns>
53+
/// <summary>
54+
/// Network to use for the withdrawal
55+
/// </summary>
56+
public string Network { get; set; }
57+
58+
/// <summary>Returns a <see cref="string" /> that represents this instance.</summary>
59+
/// <returns>A <see cref="string" /> that represents this instance.</returns>
5560
public override string ToString()
5661
{
5762
// 2.75 ETH to 0x1234asdf

0 commit comments

Comments
 (0)