Skip to main content
GET
/
price-converter
CLI
curl --request GET \
--url 'https://api.coinpaprika.com/v1/price-converter?base_currency_id=btc-bitcoin&quote_currency_id=eth-ethereum&amount=1.2'
import requests

url = "https://api.coinpaprika.com/v1/price-converter"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://api.coinpaprika.com/v1/price-converter', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.coinpaprika.com/v1/price-converter",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

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

func main() {

url := "https://api.coinpaprika.com/v1/price-converter"

req, _ := http.NewRequest("GET", url, nil)

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.coinpaprika.com/v1/price-converter")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.coinpaprika.com/v1/price-converter")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
{
  "base_currency_id": "btc-bitcoin",
  "base_currency_name": "Bitcoin",
  "base_price_last_updated": "2019-02-26T13:32:39Z",
  "quote_currency_id": "usd-us-dollars",
  "quote_currency_name": "US Dollars",
  "quote_price_last_updated": "2019-02-26T13:33:45Z",
  "amount": 100,
  "price": 386621.99158499995
}
{
"error": "you have reached maximum request limit"
}

Query Parameters

base_currency_id
string
required
quote_currency_id
string
required
amount
integer
default:0

Response

successful operation

base_currency_id
string
Example:

"btc-bitcoin"

base_currency_name
string
Example:

"Bitcoin"

base_price_last_updated
string
Example:

"2019-02-26T13:32:39Z"

quote_currency_id
string
Example:

"usd-us-dollars"

quote_currency_name
string
Example:

"US Dollars"

quote_price_last_updated
string
Example:

"2019-02-26T13:33:45Z"

amount
number
Example:

100

price
number
Example:

386621.99158499995