Last active
May 2, 2022 15:11
-
-
Save still-dreaming-1/b51cf6b8a35f2de929e805f20168adf1 to your computer and use it in GitHub Desktop.
Live Coin Watch API coins/list example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Live Coin Watch sample code migrated to be compatible with RestSharp v107 | |
var client = new RestClient( | |
new RestClientOptions("https://api.livecoinwatch.com/coins/list") { | |
Timeout = -1 | |
} | |
); | |
var request = new RestRequest() | |
.AddHeader("x-api-key", "your API key here") | |
.AddJsonBody(new { | |
currency = "USD", | |
sort = "rank", | |
order = "ascending", | |
offset = 0, | |
limit = 2, | |
meta = false | |
}); | |
var response = await client.PostAsync(request); | |
Console.WriteLine(response.Content); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment