Track Data
curl --request GET \
--url https://api.example.com/v1/tracks/{track_id}/dataimport requests
url = "https://api.example.com/v1/tracks/{track_id}/data"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/tracks/{track_id}/data', 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.example.com/v1/tracks/{track_id}/data",
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.example.com/v1/tracks/{track_id}/data"
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.example.com/v1/tracks/{track_id}/data")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/tracks/{track_id}/data")
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_bodyTracks
Track Data
Fetch a track’s stored data record through the versioned catalog API.
GET
/
v1
/
tracks
/
{track_id}
/
data
Track Data
curl --request GET \
--url https://api.example.com/v1/tracks/{track_id}/dataimport requests
url = "https://api.example.com/v1/tracks/{track_id}/data"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/tracks/{track_id}/data', 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.example.com/v1/tracks/{track_id}/data",
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.example.com/v1/tracks/{track_id}/data"
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.example.com/v1/tracks/{track_id}/data")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/tracks/{track_id}/data")
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_bodyReturns the track’s stored data record, exactly as the network holds it.
What’s inside depends on the track’s kind (inline or coded). For an inline track, the record contains the bytes themselves. For a coded track, it contains the encoding record: the commitment material and coding parameters, not the decoded payload.
That makes this endpoint a building block rather than a download. The SDK’s verified reads use it to fetch the material they check proofs against (verified reads). If you want the decoded payload, use get track or get object instead.
Like the rest of the catalog family, the response arrives in the SDK’s binary encoding (conventions), so the practical way to consume it is through an SDK.
The file holds the binary-encoded record. Decoding it by hand means reimplementing the SDK’s codec; there is rarely a reason to.
Example
curl -s -o track-record.bin "$TAPE_GATEWAY/v1/tracks/7f3kD9mQxYz2pW8vN4cRtE5uH6bJamd9GvKq2rTeUWXs/data"