Token & NFT (DAS)
getSignaturesForAsset
Truy xuất tất cả chữ ký giao dịch trong lịch sử của một NFT Solana hoặc NFT nén, bao gồm các giao dịch chuyển, bán và thay đổi trạng thái, có hỗ trợ phân trang
POST
/
getSignaturesForAsset
curl --request POST \
--url 'https://mainnet.helius-rpc.com/?api-key=' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": "1",
"method": "getSignaturesForAsset",
"params": {
"id": "FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC"
}
}
'import requests
url = "https://mainnet.helius-rpc.com/?api-key="
payload = {
"jsonrpc": "2.0",
"id": "1",
"method": "getSignaturesForAsset",
"params": { "id": "FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC" }
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
jsonrpc: '2.0',
id: '1',
method: 'getSignaturesForAsset',
params: {id: 'FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC'}
})
};
fetch('https://mainnet.helius-rpc.com/?api-key=', 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://mainnet.helius-rpc.com/?api-key=",
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([
'jsonrpc' => '2.0',
'id' => '1',
'method' => 'getSignaturesForAsset',
'params' => [
'id' => 'FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC'
]
]),
CURLOPT_HTTPHEADER => [
"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://mainnet.helius-rpc.com/?api-key="
payload := strings.NewReader("{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
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://mainnet.helius-rpc.com/?api-key=")
.header("Content-Type", "application/json")
.body("{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mainnet.helius-rpc.com/?api-key=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}"
response = http.request(request)
puts response.read_body{
"jsonrpc": "2.0",
"result": {
"last_indexed_slot": 365750752,
"total": 3,
"limit": 1000,
"items": [
[
"5nLi8m72bU6PBcz4Xrk23P6KTGy9ufF92kZiQXjTv9ELgkUxrNaiCGhMF4vh6RAcisw9DEQWJt9ogM3G2uCuwwV7",
"MintToCollectionV1"
],
[
"323Ag4J69gagBt3neUvajNauMydiXZTmXYSfdK5swWcK1iwCUypcXv45UFcy5PTt136G9gtQ45oyPJRs1f2zFZ3v",
"Transfer"
],
[
"3TbybyYRtNjVMhhahTNbd4bbpiEacZn2qkwtH7ByL7tCHmwi2g4YapPidSRGs1gjaseKbs7RjNmUKWmU6xbf3wUT",
"Transfer"
]
]
},
"id": "text"
}{
"jsonrpc": "2.0",
"error": {
"code": -32602,
"message": "Tham số yêu cầu không hợp lệ."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32001,
"message": "Xác thực thất bại. Khóa API bị thiếu hoặc không hợp lệ."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32003,
"message": "Bạn không có quyền truy cập tài nguyên này."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32004,
"message": "Không tìm thấy chữ ký nào cho tài sản đã chỉ định."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32029,
"message": "Đã vượt quá giới hạn tốc độ. Vui lòng thử lại sau."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "Đã xảy ra lỗi không mong muốn trên máy chủ."
},
"id": "1"
}Tham số yêu cầu
string
bắt buộc
Mã định danh duy nhất (địa chỉ mint) của tài sản kỹ thuật số Solana cần truy xuất lịch sử giao dịch.
number
bắt buộc
Số trang dùng để phân trang trong lịch sử giao dịch của tài sản Solana.
number
Số lượng chữ ký giao dịch Solana tối đa được trả về cho mỗi yêu cầu.
string
Con trỏ dùng để phân trang ngược qua các chữ ký.
string
Con trỏ dùng để phân trang xuôi qua các chữ ký.
Ủy quyền
Khóa API Helius của bạn. Bạn có thể nhận khóa miễn phí trong bảng điều khiển.
Nội dung
application/json
Phiên bản của giao thức JSON-RPC.
Tùy chọn có sẵn:
2.0 ID để xác định yêu cầu.
Ví dụ:
"1"
Tên của phương thức DAS cần gọi.
Tùy chọn có sẵn:
getSignaturesForAsset Show child attributes
Show child attributes
Trang này có hữu ích không?
⌘I
getSignaturesForAsset
curl --request POST \
--url 'https://mainnet.helius-rpc.com/?api-key=' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": "1",
"method": "getSignaturesForAsset",
"params": {
"id": "FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC"
}
}
'import requests
url = "https://mainnet.helius-rpc.com/?api-key="
payload = {
"jsonrpc": "2.0",
"id": "1",
"method": "getSignaturesForAsset",
"params": { "id": "FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC" }
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
jsonrpc: '2.0',
id: '1',
method: 'getSignaturesForAsset',
params: {id: 'FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC'}
})
};
fetch('https://mainnet.helius-rpc.com/?api-key=', 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://mainnet.helius-rpc.com/?api-key=",
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([
'jsonrpc' => '2.0',
'id' => '1',
'method' => 'getSignaturesForAsset',
'params' => [
'id' => 'FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC'
]
]),
CURLOPT_HTTPHEADER => [
"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://mainnet.helius-rpc.com/?api-key="
payload := strings.NewReader("{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
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://mainnet.helius-rpc.com/?api-key=")
.header("Content-Type", "application/json")
.body("{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mainnet.helius-rpc.com/?api-key=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"jsonrpc\": \"2.0\",\n \"id\": \"1\",\n \"method\": \"getSignaturesForAsset\",\n \"params\": {\n \"id\": \"FNt6A9Mfnqbwc1tY7uwAguKQ1JcpBrxmhczDgbdJy5AC\"\n }\n}"
response = http.request(request)
puts response.read_body{
"jsonrpc": "2.0",
"result": {
"last_indexed_slot": 365750752,
"total": 3,
"limit": 1000,
"items": [
[
"5nLi8m72bU6PBcz4Xrk23P6KTGy9ufF92kZiQXjTv9ELgkUxrNaiCGhMF4vh6RAcisw9DEQWJt9ogM3G2uCuwwV7",
"MintToCollectionV1"
],
[
"323Ag4J69gagBt3neUvajNauMydiXZTmXYSfdK5swWcK1iwCUypcXv45UFcy5PTt136G9gtQ45oyPJRs1f2zFZ3v",
"Transfer"
],
[
"3TbybyYRtNjVMhhahTNbd4bbpiEacZn2qkwtH7ByL7tCHmwi2g4YapPidSRGs1gjaseKbs7RjNmUKWmU6xbf3wUT",
"Transfer"
]
]
},
"id": "text"
}{
"jsonrpc": "2.0",
"error": {
"code": -32602,
"message": "Tham số yêu cầu không hợp lệ."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32001,
"message": "Xác thực thất bại. Khóa API bị thiếu hoặc không hợp lệ."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32003,
"message": "Bạn không có quyền truy cập tài nguyên này."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32004,
"message": "Không tìm thấy chữ ký nào cho tài sản đã chỉ định."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32029,
"message": "Đã vượt quá giới hạn tốc độ. Vui lòng thử lại sau."
},
"id": "1"
}{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "Đã xảy ra lỗi không mong muốn trên máy chủ."
},
"id": "1"
}