Skip to content

ercumenteskar/CryptopiaApi-Csharp

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

This is a C# wapper for the Cryptopia Public and Private API's

Public Usage:

		using (var api = new CryptopiaApiPublic())
		{
			var response = await api.GetCurrencies();
			if (!response.Success)
			{
				Console.WriteLine(response.Error);
				return;
			}

			foreach (var currency in response.Data)
			{
				Console.WriteLine("Currency: {0}", currency.Name);
			}
		}

Private Usage:

		var _apiKey = "your cryptopia api key";
		var _apiSecret = "your cryptopia api secret";
		using (var api = new CryptopiaApiPrivate(_apiKey, _apiSecret))
		{
			var response = await api.SubmitTrade(new SubmitTradeRequest("DOT/BTC", TradeType.Buy, 60, 0.00000020M));
			if (!response.Success)
			{
				Console.WriteLine(response.Error);
				return;
			}
			Console.WriteLine("New Trade Submitted, OrderId: {0}", response.Data.OrderId);
		}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 93.3%
  • PowerShell 6.7%