GithubHelp home page GithubHelp logo

westinpay-com / crypto-currency-rates-api-go Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 5 KB

This repository is used to retrieve the list of currencies using WestinPay's API which provides the list of currencies.

Home Page: https://westinpay.com/

crypto-currency-rates-api-go's Introduction

Crypto-Currency-Rates-API-Go

This repository is used to retrieve the list of currencies using WestinPay's API which provides the list of currencies.

WestinPay's Free Crypto Currency API provides real-time exchange rates and currency conversion for all cryptocurrencies. It's ideal for financial apps, e-commerce platforms, and travel services.

Endpoint

The WestinPay Crypto Currency Endpoint delivers real-time exchange rates.

Authentication

Once you have created an account on WestinPay, your account will be assigned a unique 32-character API key. Think of this like a secure password; keep it safe and do not share it with others.

Getting Your API Key

After registering, go to the dashboard and navigate to the "Currency Key" section. Here, you can generate your Fiat API key. This key is essential for authenticating your requests to the API.

Parameters

  • base: The base currency for conversion. Default is BTC. // For other currencies, use the currency symbol e.g. base=USDT
  • output: Response format, either JSON or XML. Default is JSON.
  • api_key: Your unique API key. Replace YOUR-API-KEY with your actual API key.

Usage Limitations

Please note that your API key allows for up to 5000 monthly requests. This limit is automatically renewed each month. It's important to manage your usage to ensure continuous access to the API.

WestinPay Crypto Currency Go Code

package main

import (
    "fmt"
    "io/ioutil"
    "net/http"
)

func main() {
    apiKey := "your_api_key"
    base := "BTC"
    output := "JSON"
    url := fmt.Sprintf("https://westinpay.com/currency/crypto_api?api_key=%s&base=%s&output=%s", apiKey, base, output)

    resp, err := http.Get(url)
    if err != nil {
        fmt.Println("Error:", err)
        return
    }
    defer resp.Body.Close()

    body, err := ioutil.ReadAll(resp.Body)
    if err != nil {
        fmt.Println("Error:", err)
        return
    }

    fmt.Println(string(body))
}

crypto-currency-rates-api-go's People

Contributors

westinpay-com avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.