BitFlyer.Apis 5.4.0

bitFlyer APIs Client Library for .NET

There is a newer version of this package available.
See the version list below for details.
Install-Package BitFlyer.Apis -Version 5.4.0
dotnet add package BitFlyer.Apis --version 5.4.0
<PackageReference Include="BitFlyer.Apis" Version="5.4.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add BitFlyer.Apis --version 5.4.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

HTTP Public API

class Program
{
    static void Main(string[] args)
    {
        Ticker ticker = PublicApi.GetTicker(ProductCode.BtcJpy).Result;
        
        Console.WriteLine(ticker);
        Console.ReadKey();
    }
}

HTTP Private API

You can create API Key and API Secret here.
https://lightning.bitflyer.jp/developer

class Program
{
    static void Main(string[] args)
    {
        var api = new PrivateApi("{Your API Key}", "{Your API Secret}");
        
        var result = api.SendChildOrder(new SendChildOrderParameter
        {
            ProductCode = ProductCode.FxBtcJpy,
            ChildOrderType = ChildOrderType.Limit,
            Side = Side.Buy,
            Price = 10000,
            Size = 0.01,
            MinuteToExpire = 10000,
            TimeInForce = TimeInForce.GoodTilCanceled
        }).Result;
        
        Console.WriteLine(result);
        Console.ReadKey();
    }
}

Realtime API

class Program
{
    static void Main(string[] args)
    {
        var api = new RealtimeApi();
        
        api.Subscribe<Ticker>(PubnubChannel.TickerFxBtcJpy, OnReceive, OnConnect, OnError);
        
        Console.ReadKey();
    }
    
    static void OnConnect(string message)
    {
        Console.WriteLine(message);
    }
    
    static void OnReceive(Ticker data)
    {
        Console.WriteLine(data);
    }
    
    static void OnError(string message, Exception ex)
    {
        Console.WriteLine(message);
        if (ex != null)
        {
            Console.WriteLine(ex);
        }
    }
}

HTTP Public API

class Program
{
    static void Main(string[] args)
    {
        Ticker ticker = PublicApi.GetTicker(ProductCode.BtcJpy).Result;
        
        Console.WriteLine(ticker);
        Console.ReadKey();
    }
}

HTTP Private API

You can create API Key and API Secret here.
https://lightning.bitflyer.jp/developer

class Program
{
    static void Main(string[] args)
    {
        var api = new PrivateApi("{Your API Key}", "{Your API Secret}");
        
        var result = api.SendChildOrder(new SendChildOrderParameter
        {
            ProductCode = ProductCode.FxBtcJpy,
            ChildOrderType = ChildOrderType.Limit,
            Side = Side.Buy,
            Price = 10000,
            Size = 0.01,
            MinuteToExpire = 10000,
            TimeInForce = TimeInForce.GoodTilCanceled
        }).Result;
        
        Console.WriteLine(result);
        Console.ReadKey();
    }
}

Realtime API

class Program
{
    static void Main(string[] args)
    {
        var api = new RealtimeApi();
        
        api.Subscribe<Ticker>(PubnubChannel.TickerFxBtcJpy, OnReceive, OnConnect, OnError);
        
        Console.ReadKey();
    }
    
    static void OnConnect(string message)
    {
        Console.WriteLine(message);
    }
    
    static void OnReceive(Ticker data)
    {
        Console.WriteLine(data);
    }
    
    static void OnError(string message, Exception ex)
    {
        Console.WriteLine(message);
        if (ex != null)
        {
            Console.WriteLine(ex);
        }
    }
}

Release Notes

Improve performance for realtime API.

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
6.4.0 425 3/8/2019
6.3.0 146 12/21/2018
6.2.0 92 12/21/2018
6.1.0 378 9/7/2018
6.0.0 290 7/23/2018
5.10.0 457 2/24/2018
5.9.1 279 2/9/2018
5.9.0 272 1/24/2018
5.8.0 317 1/23/2018
5.7.0 347 12/21/2017
5.6.0 350 12/15/2017
5.5.0 402 11/28/2017
5.4.0 254 11/21/2017
5.3.0 242 11/20/2017
5.2.0 225 11/2/2017
5.1.0 302 10/13/2017
5.0.0 278 8/15/2017
4.1.0 289 5/31/2017
4.0.0 254 4/14/2017
3.0.0 313 2/2/2017
2.1.1 260 1/30/2017
2.1.0 249 1/26/2017
2.0.2 303 1/19/2017
2.0.1 267 1/18/2017
2.0.0 250 1/18/2017
1.1.0 253 1/17/2017
1.0.2 282 1/17/2017
1.0.1 243 1/16/2017
1.0.0 263 1/16/2017
Show less