Base URL
https://api.nft.radio/v1Authentication
Bearer token via wallet signature
Rate Limiting
1000 requests/hour per API key
Authentication
Wallet-based Authentication
NFT.Radio uses wallet-based authentication. Sign a message with your wallet to receive an access token.
Request Example
POST /auth/wallet
Content-Type: application/json
{
"walletAddress": "0x...",
"signature": "0x...",
"message": "Sign this message to authenticate..."
}Response
{
"accessToken": "eyJhbGc...",
"refreshToken": "eyJhbGc...",
"tokenType": "Bearer",
"expiresIn": 3600
}Using the token: Include the access token in the Authorization header for all authenticated requests:
Authorization: Bearer <access_token>Tracks
Endpoints for managing and streaming tracks
GET
/tracksList all tracksGET
/tracks/:idGet track by IDGET
/tracks/trendingGet trending tracksGET
/tracks/searchSearch tracksPOST
/tracksUpload a new trackGET
/tracks/:id/streamGet stream URLExample
JavaScript// Fetch trending tracks and parse the response
const response = await fetch("https://api.nft.radio/v1/tracks/trending?limit=10", {
method: "GET",
headers: {
"Authorization": "Bearer <access_token>",
"Content-Type": "application/json",
},
});
const data = await response.json();
// data.tracks is an array of track objects
for (const track of data.tracks) {
console.log(`${track.title} by ${track.artist} — ${track.plays} plays`);
}Videos
Endpoints for video content
GET
/videosList all videosGET
/videos/:idGet video by IDPOST
/videos/upload/initiateInitiate video uploadPUT
/videos/upload/:id/chunkUpload video chunkPOST
/videos/upload/:id/completeComplete video uploadNFTs
NFT marketplace endpoints
GET
/nftsList all NFTsGET
/nfts/:idGet NFT by IDPOST
/nfts/mintMint a new NFTGET
/listingsGet marketplace listingsPOST
/listingsCreate a listingPOST
/listings/:id/purchasePurchase NFTExample
JavaScript// Purchase an NFT from a marketplace listing
const listingId = "listing_abc123";
const response = await fetch(`https://api.nft.radio/v1/listings/${listingId}/purchase`, {
method: "POST",
headers: {
"Authorization": "Bearer <access_token>",
"Content-Type": "application/json",
},
body: JSON.stringify({
buyerWallet: "0x1234...abcd",
paymentToken: "ETH",
maxPrice: "0.5",
}),
});
const result = await response.json();
console.log("Transaction hash:", result.transactionHash);
console.log("NFT transferred:", result.nft.tokenId);Users
User management endpoints
GET
/users/meGet current userPATCH
/users/meUpdate profileGET
/users/:idGet user by IDPOST
/users/:id/followFollow a userDELETE
/users/:id/followUnfollow a userExample
JavaScript// Get the current user profile
const profileRes = await fetch("https://api.nft.radio/v1/users/me", {
headers: {
"Authorization": "Bearer <access_token>",
},
});
const profile = await profileRes.json();
console.log("Username:", profile.username);
// Update the current user profile
const updateRes = await fetch("https://api.nft.radio/v1/users/me", {
method: "PATCH",
headers: {
"Authorization": "Bearer <access_token>",
"Content-Type": "application/json",
},
body: JSON.stringify({
displayName: "New Display Name",
bio: "Music producer & NFT collector",
avatarUrl: "https://example.com/avatar.png",
}),
});
const updated = await updateRes.json();
console.log("Profile updated:", updated.displayName);Search
Global search endpoints
GET
/searchGlobal searchGET
/search/tracksSearch tracksGET
/search/artistsSearch artistsGET
/search/collectionsSearch collectionsOfficial SDKs
Use our official libraries for easier integration