Classes
Get class contracts
Retrieve a list of contracts deployed from a specific class. Pagination is capped at the first 10,000 contracts of a class: for classes with more deployments, lastPage reflects the cap and pages beyond it return empty items.
GET
/
classes
/
{classHash}
/
contracts
Get class contracts
curl --request GET \
--url https://public-api.voyager.online/beta/classes/{classHash}/contracts \
--header 'x-api-key: <api-key>'import requests
url = "https://public-api.voyager.online/beta/classes/{classHash}/contracts"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://public-api.voyager.online/beta/classes/{classHash}/contracts', 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://public-api.voyager.online/beta/classes/{classHash}/contracts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://public-api.voyager.online/beta/classes/{classHash}/contracts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://public-api.voyager.online/beta/classes/{classHash}/contracts")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://public-api.voyager.online/beta/classes/{classHash}/contracts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"address": "0x036834a40984312f7f7de8d31e3f6305b325389eaeea5b1c0664b2fb936461a4",
"creationTimestamp": 1757525503,
"txnCount": 0,
"starknetId": "",
"accountCallCount": 6,
"contractAlias": null,
"constructorCalldata": [
"0x111",
"0x222",
"0x333"
]
}
],
"lastPage": 1
}{
"error": "<string>"
}{
"message": "Forbidden"
}{
"message": "Limit Exceeded"
}Authorizations
API key for authentication. Get your key at https://voyager.online/plans
Path Parameters
Starknet class hash (0x-prefixed hex).
Pattern:
^(0x[0-9a-fA-F]{1,66})$Query Parameters
Page number. Defaults to 1.
Number of items per page. Available options: 10, 25, 50, 100.
⌘I
Get class contracts
curl --request GET \
--url https://public-api.voyager.online/beta/classes/{classHash}/contracts \
--header 'x-api-key: <api-key>'import requests
url = "https://public-api.voyager.online/beta/classes/{classHash}/contracts"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://public-api.voyager.online/beta/classes/{classHash}/contracts', 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://public-api.voyager.online/beta/classes/{classHash}/contracts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://public-api.voyager.online/beta/classes/{classHash}/contracts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://public-api.voyager.online/beta/classes/{classHash}/contracts")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://public-api.voyager.online/beta/classes/{classHash}/contracts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"address": "0x036834a40984312f7f7de8d31e3f6305b325389eaeea5b1c0664b2fb936461a4",
"creationTimestamp": 1757525503,
"txnCount": 0,
"starknetId": "",
"accountCallCount": 6,
"contractAlias": null,
"constructorCalldata": [
"0x111",
"0x222",
"0x333"
]
}
],
"lastPage": 1
}{
"error": "<string>"
}{
"message": "Forbidden"
}{
"message": "Limit Exceeded"
}