Skip to main content

Bonk Fun API

In this document, we will explore several examples related to Bonk fun data. We also have Raydium Launchpad APIs. Additionally, you can also check out our Moonshot APIs, FourMeme APIs. These APIs can be provided through different streams including Kafka for zero latency requirements. Please contact us on telegram.

note

Trade Side Account field will not be available for aggregate queries in Archive and Combined Datasets

If you want fastest data without any latency, we can provide Kafka streams, please fill this form for it. Our Team will reach out.

Track Bonk.fun Token Creation

Using this query, we can get the most recently created Bonk Fun tokens.

{
Solana {
InstructionBalanceUpdates(
where: {BalanceUpdate: {Currency: {MintAddress: {endsWith: "bonk"}}}, Instruction: {Program: {Address: {is: "LanMV9sAd7wArD4vJFi2qDdfnVhFxYSUg6eADduJ3uj"}, Method: {is: "initialize"}}}, Transaction: {Result: {Success: true}}}
orderBy: {descending: Block_Time}
) {
BalanceUpdate {
Currency {
MintAddress
Name
Symbol
Decimals
UpdateAuthority
Uri
VerifiedCollection
Wrapped
ProgramAddress
}
PostBalance
}
Block {
Time
}
Transaction {
Signature
Signer
}
}
}
}

Streaming Bonk.fun Trades for a Token

This subscription allows us to stream the latest trades for a Bonk.fun tokens in real time.

subscription {
Solana {
DEXTradeByTokens(
where: {Trade: {Currency: {MintAddress: {is: "6r3dLonVjdFgbexHMKoMtiiAXCzVYBmoUrmixER9bonk"}}}}
) {
Trade {
Dex {
ProgramAddress
ProtocolFamily
ProtocolName
}
Currency {
Name
Symbol
MintAddress
Decimals
}
Amount
AmountInUSD
Account {
Owner
}
Market {
MarketAddress
}
Price
PriceInUSD
Side {
Currency {
Name
Symbol
MintAddress
Decimals
}
Type
}
}
}
}
}

Get Latest Buys for a Bonk.fun Token

This API returns the latest buys for a Bonk.fun token.

{
Solana {
DEXTradeByTokens(
where: {Trade: {Currency: {MintAddress: {is: "6r3dLonVjdFgbexHMKoMtiiAXCzVYBmoUrmixER9bonk"}}, Side: {Type: {is: buy}}}, Transaction: {Result: {Success: true}}}
orderBy: {descending: Block_Time}
limit: {count: 10}
) {
Trade {
Dex {
ProgramAddress
ProtocolFamily
ProtocolName
}
Currency {
Name
Symbol
MintAddress
Decimals
}
Amount
AmountInUSD
Account {
Owner
}
Market {
MarketAddress
}
Price
PriceInUSD
Side {
Currency {
Name
Symbol
MintAddress
Decimals
}
Type
}
}
}
}
}

Get Latest Sells for a Bonk.fun Token

This API returns the latest sells for a Bonk.fun token.

{
Solana {
DEXTradeByTokens(
where: {Trade: {Currency: {MintAddress: {is: "6r3dLonVjdFgbexHMKoMtiiAXCzVYBmoUrmixER9bonk"}}, Side: {Type: {is: sell}}}, Transaction: {Result: {Success: true}}}
orderBy: {descending: Block_Time}
limit: {count: 10}
) {
Trade {
Dex {
ProgramAddress
ProtocolFamily
ProtocolName
}
Currency {
Name
Symbol
MintAddress
Decimals
}
Amount
AmountInUSD
Account {
Owner
}
Market {
MarketAddress
}
Price
PriceInUSD
Side {
Currency {
Name
Symbol
MintAddress
Decimals
}
Type
}
}
}
}
}