curl --request POST \
--url https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "My Cool Token",
"symbol": "MCT",
"description": "A revolutionary new token",
"image": "https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"chainSlug": "base-sepolia",
"banner": "https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"video": "https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC",
"links": {
"website": "https://example.com",
"twitter": "https://twitter.com/example",
"youtube": "https://youtube.com/@example",
"discord": "https://discord.gg/example",
"telegram": "https://t.me/example"
},
"destinationChains": [
"base-sepolia",
"bnb-testnet",
"solana-devnet"
],
"poolType": "meme",
"userAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"token_referral": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"tags": [
"defi",
"meme"
],
"type": "coin"
}
'import requests
url = "https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction"
payload = {
"name": "My Cool Token",
"symbol": "MCT",
"description": "A revolutionary new token",
"image": "https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"chainSlug": "base-sepolia",
"banner": "https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"video": "https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC",
"links": {
"website": "https://example.com",
"twitter": "https://twitter.com/example",
"youtube": "https://youtube.com/@example",
"discord": "https://discord.gg/example",
"telegram": "https://t.me/example"
},
"destinationChains": ["base-sepolia", "bnb-testnet", "solana-devnet"],
"poolType": "meme",
"userAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"token_referral": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"tags": ["defi", "meme"],
"type": "coin"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'My Cool Token',
symbol: 'MCT',
description: 'A revolutionary new token',
image: 'https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
chainSlug: 'base-sepolia',
banner: 'https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
video: 'https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC',
links: {
website: 'https://example.com',
twitter: 'https://twitter.com/example',
youtube: 'https://youtube.com/@example',
discord: 'https://discord.gg/example',
telegram: 'https://t.me/example'
},
destinationChains: ['base-sepolia', 'bnb-testnet', 'solana-devnet'],
poolType: 'meme',
userAddress: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
token_referral: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
tags: ['defi', 'meme'],
type: 'coin'
})
};
fetch('https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction', 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://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'My Cool Token',
'symbol' => 'MCT',
'description' => 'A revolutionary new token',
'image' => 'https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
'chainSlug' => 'base-sepolia',
'banner' => 'https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
'video' => 'https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC',
'links' => [
'website' => 'https://example.com',
'twitter' => 'https://twitter.com/example',
'youtube' => 'https://youtube.com/@example',
'discord' => 'https://discord.gg/example',
'telegram' => 'https://t.me/example'
],
'destinationChains' => [
'base-sepolia',
'bnb-testnet',
'solana-devnet'
],
'poolType' => 'meme',
'userAddress' => '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
'token_referral' => '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
'tags' => [
'defi',
'meme'
],
'type' => 'coin'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction"
payload := strings.NewReader("{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"executed": true,
"transactionHash": "<string>",
"chainId": 84532,
"transaction": {
"to": "<string>",
"data": "<string>",
"value": "<string>",
"gasLimit": "<string>"
},
"metadata": {
"tokenUri": "<string>",
"tokenId": "<string>",
"name": "<string>",
"symbol": "<string>",
"slug": "<string>",
"description": "<string>",
"hubUrl": "https://onthrust.com/hub/my-cool-token",
"addresses": {
"evm": "<string>",
"solana": "<string>"
},
"token_layer_id": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"
}
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}Create new token transaction
Creates a new token on-chain. This endpoint prepares and optionally executes the blockchain transaction to deploy a new token contract with specified parameters.
Supports:
- Token metadata (name, symbol, description)
- Media assets (logo, banner, video)
- Multiple chains (Base, Base Sepolia)
- Optional hashtags/tags
- Automatic token URI generation and IPFS storage
Returns transaction data for client-side execution or confirmation of server-side execution.
USD Rewards Attribution:
- Builder attribution: Set custom builder fees (in basis points) to earn USD rewards on token creation
- Token referral: Enable affiliate programs by specifying referral addresses for token trades
- USD rewards are processed in real-time on-chain with no third parties involved
- Token referrals have no additional cost to users - enabling affiliate programs onchain
curl --request POST \
--url https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "My Cool Token",
"symbol": "MCT",
"description": "A revolutionary new token",
"image": "https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"chainSlug": "base-sepolia",
"banner": "https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"video": "https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC",
"links": {
"website": "https://example.com",
"twitter": "https://twitter.com/example",
"youtube": "https://youtube.com/@example",
"discord": "https://discord.gg/example",
"telegram": "https://t.me/example"
},
"destinationChains": [
"base-sepolia",
"bnb-testnet",
"solana-devnet"
],
"poolType": "meme",
"userAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"token_referral": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"tags": [
"defi",
"meme"
],
"type": "coin"
}
'import requests
url = "https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction"
payload = {
"name": "My Cool Token",
"symbol": "MCT",
"description": "A revolutionary new token",
"image": "https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"chainSlug": "base-sepolia",
"banner": "https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
"video": "https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC",
"links": {
"website": "https://example.com",
"twitter": "https://twitter.com/example",
"youtube": "https://youtube.com/@example",
"discord": "https://discord.gg/example",
"telegram": "https://t.me/example"
},
"destinationChains": ["base-sepolia", "bnb-testnet", "solana-devnet"],
"poolType": "meme",
"userAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"token_referral": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"tags": ["defi", "meme"],
"type": "coin"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'My Cool Token',
symbol: 'MCT',
description: 'A revolutionary new token',
image: 'https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
chainSlug: 'base-sepolia',
banner: 'https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
video: 'https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC',
links: {
website: 'https://example.com',
twitter: 'https://twitter.com/example',
youtube: 'https://youtube.com/@example',
discord: 'https://discord.gg/example',
telegram: 'https://t.me/example'
},
destinationChains: ['base-sepolia', 'bnb-testnet', 'solana-devnet'],
poolType: 'meme',
userAddress: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
token_referral: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
tags: ['defi', 'meme'],
type: 'coin'
})
};
fetch('https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction', 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://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'My Cool Token',
'symbol' => 'MCT',
'description' => 'A revolutionary new token',
'image' => 'https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
'chainSlug' => 'base-sepolia',
'banner' => 'https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==',
'video' => 'https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC',
'links' => [
'website' => 'https://example.com',
'twitter' => 'https://twitter.com/example',
'youtube' => 'https://youtube.com/@example',
'discord' => 'https://discord.gg/example',
'telegram' => 'https://t.me/example'
],
'destinationChains' => [
'base-sepolia',
'bnb-testnet',
'solana-devnet'
],
'poolType' => 'meme',
'userAddress' => '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
'token_referral' => '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
'tags' => [
'defi',
'meme'
],
'type' => 'coin'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction"
payload := strings.NewReader("{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://yppncslmsswqydhhgygz.supabase.co/functions/v1/create-token-transaction")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"My Cool Token\",\n \"symbol\": \"MCT\",\n \"description\": \"A revolutionary new token\",\n \"image\": \"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"chainSlug\": \"base-sepolia\",\n \"banner\": \"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==\",\n \"video\": \"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC\",\n \"links\": {\n \"website\": \"https://example.com\",\n \"twitter\": \"https://twitter.com/example\",\n \"youtube\": \"https://youtube.com/@example\",\n \"discord\": \"https://discord.gg/example\",\n \"telegram\": \"https://t.me/example\"\n },\n \"destinationChains\": [\n \"base-sepolia\",\n \"bnb-testnet\",\n \"solana-devnet\"\n ],\n \"poolType\": \"meme\",\n \"userAddress\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"token_referral\": \"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb\",\n \"tags\": [\n \"defi\",\n \"meme\"\n ],\n \"type\": \"coin\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"executed": true,
"transactionHash": "<string>",
"chainId": 84532,
"transaction": {
"to": "<string>",
"data": "<string>",
"value": "<string>",
"gasLimit": "<string>"
},
"metadata": {
"tokenUri": "<string>",
"tokenId": "<string>",
"name": "<string>",
"symbol": "<string>",
"slug": "<string>",
"description": "<string>",
"hubUrl": "https://onthrust.com/hub/my-cool-token",
"addresses": {
"evm": "<string>",
"solana": "<string>"
},
"token_layer_id": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"
}
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}Authorizations
JWT token or API key
Body
Token name
1"My Cool Token"
Token symbol (ticker)
1 - 10"MCT"
Token description
1"A revolutionary new token"
Token logo image - can be either a URL or base64-encoded image data (data:image/...)
1"https://example.com/logo.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg=="
Blockchain identifier. Supported chains: solana-devnet, base, base-sepolia, avalanche, bnb, bnb-testnet, unichain, unichain-testnet, abstract, polygon, zkSync, zkSync-testnet
solana-devnet, base, base-sepolia, avalanche, bnb, bnb-testnet, unichain, unichain-testnet, abstract, polygon, zkSync, zkSync-testnet "base-sepolia"
Banner image - can be either a URL or base64-encoded image data (data:image/...)
1"https://example.com/banner.png or data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg=="
Promotional video - can be either a URL or base64-encoded video data (data:video/...)
1"https://example.com/promo.mp4 or data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAACKBtZGF0AAAC"
Optional social media and website links
Show child attributes
Show child attributes
Optional array of destination chain slugs for cross-chain token deployment and migration endpoints. Defaults to [base-sepolia, bnb-testnet, solana-devnet]. The initial chain will be automatically excluded from migration endpoints.
Blockchain identifier. Supported chains: solana-devnet, base, base-sepolia, avalanche, bnb, bnb-testnet, unichain, unichain-testnet, abstract, polygon, zkSync, zkSync-testnet
solana-devnet, base, base-sepolia, avalanche, bnb, bnb-testnet, unichain, unichain-testnet, abstract, polygon, zkSync, zkSync-testnet [
"base-sepolia",
"bnb-testnet",
"solana-devnet"
]
Type of token pool. Defaults to "meme". Maps to: meme=7, startup-preseed=8
meme, startup-preseed "meme"
User wallet address (optional - if not provided, will use user's Privy wallet from user_wallets table)
^0x[a-fA-F0-9]{40}$"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb"
Builder attribution information (optional). Includes address and fee in bps.
Show child attributes
Show child attributes
Token referral address for attribution (optional - defaults to zero address). Used to attribute referral fees to a specific address.
^0x[a-fA-F0-9]{40}$"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb"
Optional hashtags/tags for the token
["defi", "meme"]
Transaction type (currently only "coin" is supported - placeholder for future integration)
coin "coin"
