Skip to content

dongbin300/Bithumb.Net

Repository files navigation

Bithumb.Net

NuGet latest version GitHub forks Profile views

Bithumb Open API wrapper for .NET


※ These methods may not work properly.

  • BithumbTradeApi.WithdrawalIndividualAsync()
  • BithumbTradeApi.WithdrawalCorporateAsync()

Documentation

Official Docs

Example

refer to this

BithumbClient

1. Create a Bithumb client with connectKey and secretKey
var connectKey = "your_API_key";
var secretKey = "your_secret_key";
var client = new BithumbClient(connectKey, secretKey);
2. Get current BTC price
var result = client.Public.GetTickerAsync(BithumbPaymentCurrency.KRW, "BTC");
result.Wait();
var price = result.Result.data?.closing_price;

BithumbSocketClient

1. Create a Bithumb socket client
var socketClient = new BithumbSocketClient();
2. Subscribe to ticker for getting current BTC price
await socketClient.Streams.SubscribeToTickerAsync( "BTC_KRW", BithumbSocketTickInterval.OneHour, OnMessage).ConfigureAwait(false);
3. Implement OnMessage Method
private void OnMessage(BithumbWebSocketResponse<BithumbWebSocketTicker> obj)
{
    var symbol = obj.content.symbol;
    var price = obj.content.closePrice;
    Application.Current.Dispatcher.BeginInvoke(DispatcherPriority.Normal, () =>
    {
        SocketTickerText.Text = $"{symbol} \\{price:#,###}";
    });
}
4. Unsubscribe to stop getting price
socketClient.Streams.UnsubscribeToTicker();

Feedback

Issue

Donate

Donate

Release Notes

  • Version 1.0.0 - 2023-05-11
    • Initial commit
    • Publish on NuGet
    • Write README

About

Bithumb Open API wrapper for .NET

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages