This method will return the transaction signatures for a given asset. This only supports compressed assets.
const url = `https://mainnet.helius-rpc.com/?api-key=<api_key>`
const getSignaturesForAsset = async () => {
const response = await fetch(url, {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
jsonrpc: '2.0',
id: 'my-id',
method: 'getSignaturesForAsset',
params: {
id: 'FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC',
page: 1, // Starts at 1
limit: 1000, // Limit 1000 per request.
},
}),
});
const { result } = await response.json();
console.log("Signatures: ", result);
};
getSignaturesForAsset();
// Signatures: {
// total: 2,
// limit: 1000,
// page: 1,
// items: [
// [
// '5nLi8m72bU6PBcz4Xrk23P6KTGy9ufF92kZiQXjTv9ELgkUxrNaiCGhMF4vh6RAcisw9DEQWJt9ogM3G2uCuwwV7',
// 'MintToCollectionV1'
// ]
// [
// '323Ag4J69gagBt3neUvajNauMydiXZTmXYSfdK5swWcK1iwCUypcXv45UFcy5PTt136G9gtQ45oyPJRs1f2zFZ3v',
// 'Transfer'
// ],
// ]