TriggerSmartContract RPC Method
參數
來自
字串
必填
載入中...
至
字串
必填
載入中...
資料
字串
必填
載入中...
氣體
字串
必填
載入中...
值
字串
必填
載入中...
tokenId
整數
必填
載入中...
tokenValue
整數
必填
載入中...
退貨
交易
載入中...
visible
載入中...
txID
載入中...
raw_data
載入中...
合約
載入中...
parameter
載入中...
值
載入中...
金額
載入中...
owner_address
載入中...
to_address
載入中...
type_url
載入中...
類型
載入中...
ref_block_bytes
載入中...
ref_block_hash
載入中...
expiration
載入中...
fee_limit
載入中...
時間戳記
載入中...
raw_data_hex
載入中...
請求
1curl https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc \2-X POST \3-H "Content-Type: application/json" \4--data '{"id": 1337,5"jsonrpc": "2.0",6"method": "buildTransaction",7"params": [8{9"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",10"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",11"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",12"gas": "0x245498",13"value": "0xA",14"tokenId": 1000035,15"tokenValue": 2016}17]1819}20'
1curl https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc \2-X POST \3-H "Content-Type: application/json" \4--data '{"id": 1337,5"jsonrpc": "2.0",6"method": "buildTransaction",7"params": [8{9"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",10"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",11"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",12"gas": "0x245498",13"value": "0xA",14"tokenId": 1000035,15"tokenValue": 2016}17]1819}20'
1var myHeaders = new Headers();2myHeaders.追加("Content-Type", "application/json");34var raw = JSON.stringify({5"id": 1337,6"jsonrpc": "2.0",7"method": "buildTransaction",8"params": [9{10"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",11"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",12"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",13"gas": "0x245498",14"value": "0xA",15"tokenId": 1000035,16"tokenValue": 2017}18]19});2021var requestOptions = {22方法: 'POST',23標題: myHeaders,24正文: 原始,25redirect: 'follow'26};2728fetch("https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc", requestOptions)29.then(response => response.text())30.then(result => console.log(result))31.catch(error => console.log('error', error));
1var myHeaders = new Headers();2myHeaders.追加("Content-Type", "application/json");34var raw = JSON.stringify({5"id": 1337,6"jsonrpc": "2.0",7"method": "buildTransaction",8"params": [9{10"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",11"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",12"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",13"gas": "0x245498",14"value": "0xA",15"tokenId": 1000035,16"tokenValue": 2017}18]19});2021var requestOptions = {22方法: 'POST',23標題: myHeaders,24正文: 原始,25redirect: 'follow'26};2728fetch("https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc", requestOptions)29.then(response => response.text())30.then(result => console.log(result))31.catch(error => console.log('error', error));
1匯入 請求2import json34url = "https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc"56有效載荷 = json.dumps({7"id": 1337,8"jsonrpc": "2.0",9"method": "buildTransaction",10"params": [11{12"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",13"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",14"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",15"gas": "0x245498",16"value": "0xA",17"tokenId": 1000035,18"tokenValue": 2019}20]21})22標題 = {23「Content-Type」: 'application/json'24}2526回應 = 請求.請求("POST", url, headers=headers, data=有效載荷)2728列印(回應.text)29
1匯入 請求2import json34url = "https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc"56有效載荷 = json.dumps({7"id": 1337,8"jsonrpc": "2.0",9"method": "buildTransaction",10"params": [11{12"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",13"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",14"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",15"gas": "0x245498",16"value": "0xA",17"tokenId": 1000035,18"tokenValue": 2019}20]21})22標題 = {23「Content-Type」: 'application/json'24}2526回應 = 請求.請求("POST", url, headers=headers, data=有效載荷)2728列印(回應.text)29
1需要 "uri"2require "json"3需要 "net/http"45url = URI("https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc")67http = Net::HTTP.new(url.host, url.port);8請求 = 淨::HTTP::POST.new(網址)9請求["Content-Type"] = "application/json"10請求。正文 = JSON.dump({11"id": 1337,12"jsonrpc": "2.0",13"method": "buildTransaction",14"params": [15{16"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",17"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",18"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",19"gas": "0x245498",20"value": "0xA",21"tokenId": 1000035,22"tokenValue": 2023}24]25})2627回應 = http.請求(請求)28將回應。read_body29
1需要 "uri"2require "json"3需要 "net/http"45url = URI("https://docs-demo.tron-mainnet.quiknode.pro/jsonrpc")67http = Net::HTTP.new(url.host, url.port);8請求 = 淨::HTTP::POST.new(網址)9請求["Content-Type"] = "application/json"10請求。正文 = JSON.dump({11"id": 1337,12"jsonrpc": "2.0",13"method": "buildTransaction",14"params": [15{16"from": "0xC4DB2C9DFBCB6AA344793F1DDA7BD656598A06D8",17"to": "0xf859b5c93f789f4bcffbe7cc95a71e28e5e6a5bd",18"data": "0x3be9ece7000000000000000000000000ba8e28bdb6e49fbb3f5cd82a9f5ce8363587f1f600000000000000000000000000000000000000000000000000000000000f42630000000000000000000000000000000000000000000000000000000000000001",19"gas": "0x245498",20"value": "0xA",21"tokenId": 1000035,22"tokenValue": 2023}24]25})2627回應 = http.請求(請求)28將回應。read_body29