Get a specific token basket for a specific network.
curl --request GET \
--url https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}', 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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"basket": {
"id": "usd-stablecoins",
"name": "USD Stablecoins",
"description": "A basket of the most liquid USD stablecoins in the ecosystem.",
"logoUrl": "https://cdn.jsdelivr.net/gh/hydric-org/token-baskets/assets/logos/usd-stablecoins.png",
"chainIds": [
1,
143
],
"addresses": [
{
"chainId": 1,
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7"
},
{
"chainId": 143,
"address": "0x1234..."
}
],
"tokens": [
{
"chainId": 1,
"address": "0x0000000000000000000000000000000000000000",
"decimals": 18,
"name": "Ether",
"symbol": "ETH",
"logoUrl": "https://logos.hydric.org/tokens/1/0x0000000000000000000000000000000000000000"
}
]
}
}Token Baskets
Get a specific token basket for a specific network.
Returns a detailed specific basket on a single blockchain network, containing only tokens for that network.
GET
/
v1
/
tokens
/
baskets
/
{chainId}
/
{basketId}
Get a specific token basket for a specific network.
curl --request GET \
--url https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}', 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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.hydric.org/v1/tokens/baskets/{chainId}/{basketId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hydric.org/v1/tokens/baskets/{chainId}/{basketId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"basket": {
"id": "usd-stablecoins",
"name": "USD Stablecoins",
"description": "A basket of the most liquid USD stablecoins in the ecosystem.",
"logoUrl": "https://cdn.jsdelivr.net/gh/hydric-org/token-baskets/assets/logos/usd-stablecoins.png",
"chainIds": [
1,
143
],
"addresses": [
{
"chainId": 1,
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7"
},
{
"chainId": 143,
"address": "0x1234..."
}
],
"tokens": [
{
"chainId": 1,
"address": "0x0000000000000000000000000000000000000000",
"decimals": 18,
"name": "Ether",
"symbol": "ETH",
"logoUrl": "https://logos.hydric.org/tokens/1/0x0000000000000000000000000000000000000000"
}
]
}
}Authorizations
Use the docs sandbox API key for authentication: hydric_docs_4N4ocuirsN8Sh
Path Parameters
The chain id of the network to get the basket from. This must be a supported network chain id.
Available options:
1, 143, 130, 999, 8453, 9745, 534352 Example:
143
The unique slug of the basket to get.
Available options:
usd-stablecoins, eth-pegged-tokens, btc-pegged-tokens, hype-pegged-tokens, monad-pegged-tokens, xau-stablecoins, eur-stablecoins Example:
"usd-stablecoins"
Response
The requested token basket.
The requested token basket.
Show child attributes
Show child attributes
Example:
{
"id": "usd-stablecoins",
"name": "USD Stablecoins",
"description": "A basket of the most liquid USD stablecoins in the ecosystem.",
"logoUrl": "https://cdn.jsdelivr.net/gh/hydric-org/token-baskets/assets/logos/usd-stablecoins.png",
"chainIds": [1, 143],
"addresses": [
{
"chainId": 1,
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7"
},
{ "chainId": 143, "address": "0x1234..." }
],
"tokens": [
{
"chainId": 1,
"address": "0x0000000000000000000000000000000000000000",
"decimals": 18,
"name": "Ether",
"symbol": "ETH",
"logoUrl": "https://logos.hydric.org/tokens/1/0x0000000000000000000000000000000000000000"
}
]
}
Was this page helpful?
⌘I