Skip to content

Instantly share code, notes, and snippets.

View frostiq's full-sized avatar

Alex Bazhanau frostiq

View GitHub Profile
pragma solidity ^0.4.16;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) external; }
contract TokenERC20 {
// Public variables of the token
string public name;
string public symbol;
uint8 public decimals = 18;
// 18 decimals is the strongly suggested default, avoid changing it
var data = [
{
"provider": "CoinList",
"borrow": [
{
"symbol": "ETH",
"address": "0x0000000000000000000000000000000000000000",
"rate": 0.0365
},
{
<!DOCTYPE html>
<html>
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.3/jquery.min.js"></script>
<script type="text/javascript">
// 1. Obtain a webview config from Wyre API
function getConfig(env) {
var baseUrl;
@frostiq
frostiq / interest-rates-ingestion-API.txt
Last active July 31, 2021 20:53
LoanScan interest rates ingestion API spec
Interest rates ingestion endpoint is a HTTP GET endpoint available via https protocol
e.g. "https://example.com/rates?api-key=XXXXXXXXXXX"
If this endpoint requires an API key, it should be accepted as a query string parameter, HTTP headers are not supported
The response should be a JSON object that corresponds to the following example:
{
    "lendRates": [
        {
            "apy": 0.0100005, // Annual Percentage Yield, multiplier format
            "apr": 0.01, // Annual Percentage Rate, multiplier format
{
"name": "CipherShooters",
"timestamp": "2021-11-02T17:35:10.251Z",
"version": {
"major": 0,
"minor": 0,
"patch": 0
},
"tags": {},
"logoURI": "ipfs://QmQ9GCVmLQkbPohxKeCYkbpmwfTvHXrY64TmBsPQAZdbqZ",