starknet_addInvokeTransaction RPC Method
參數
invoke_transaction
物件
必填
載入中...
INVOKE_TXN_V0
物件
載入中...
類型
字串
必填
載入中...
max_fee
字串
必填
載入中...
版本
字串
必填
載入中...
簽名
字串
必填
載入中...
contract_address
字串
必填
載入中...
entry_point_selector
字串
必填
載入中...
calldata
陣列
必填
載入中...
INVOKE_TXN_V1
物件
載入中...
類型
字串
必填
載入中...
sender_address
字串
必填
載入中...
calldata
陣列
必填
載入中...
max_fee
字串
必填
載入中...
版本
字串
必填
載入中...
簽名
字串
必填
載入中...
非重複數
字串
必填
載入中...
INVOKE_TXN_V3
物件
載入中...
類型
字串
必填
載入中...
sender_address
字串
必填
載入中...
calldata
陣列
必填
載入中...
版本
字串
必填
載入中...
簽名
字串
必填
載入中...
非重複數
字串
必填
載入中...
resource_bounds
物件
必填
載入中...
l1_gas
物件
必填
載入中...
max_amount
字串
必填
載入中...
max_price_per_unit
字串
必填
載入中...
l2_gas
物件
必填
載入中...
max_amount
字串
必填
載入中...
max_price_per_unit
字串
必填
載入中...
提示
字串
必填
載入中...
paymaster_data
陣列
必填
載入中...
account_deployment_data
陣列
必填
載入中...
nonce_data_availability_mode
字串
必填
載入中...
fee_data_availability_mode
字串
必填
載入中...
退貨
結果
物件
載入中...
transaction_hash
字串
載入中...
請求
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63curl --location 'https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8' \4--header 'accept: application/json' \5--header 'content-type: application/json' \6--data '{7"id": 1,8"jsonrpc": "2.0",9"method": "starknet_addInvokeTransaction",10"params": [11{12"sender_address": "SENDER_ADDRESS",13"type": "INVOKE",14"calldata": [15"CALLDATA"16],17"signature": [18"SIGNATURE"19],20"version": "VERSION",21"max_fee": "MAX_FEE",22"nonce": "NONCE_VALUE"23}24]25}'
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63curl --location 'https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8' \4--header 'accept: application/json' \5--header 'content-type: application/json' \6--data '{7"id": 1,8"jsonrpc": "2.0",9"method": "starknet_addInvokeTransaction",10"params": [11{12"sender_address": "SENDER_ADDRESS",13"type": "INVOKE",14"calldata": [15"CALLDATA"16],17"signature": [18"SIGNATURE"19],20"version": "VERSION",21"max_fee": "MAX_FEE",22"nonce": "NONCE_VALUE"23}24]25}'
1// Note: You can specify Starknet version in the URL path2// Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63const myHeaders = new Headers();4myHeaders.追加("accept", "application/json");5myHeaders.append("content-type", "application/json");67const raw = JSON.stringify({8"id": 1,9"jsonrpc": "2.0",10"method": "starknet_addInvokeTransaction",11"params": [12{13"sender_address": "SENDER_ADDRESS",14"type": "INVOKE",15"calldata": [16"CALLDATA"17],18"signature": [19"SIGNATURE"20],21"version": "VERSION",22"max_fee": "MAX_FEE",23"nonce": "NONCE_VALUE"24}25]26});272829const requestOptions = {30方法: 「POST」,31標題: myHeaders,32正文: 原始,33重定向: 「追蹤」34};3536fetch("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8", requestOptions)37.接著((回應) => 回應.文字())38.接著((結果) => 控制台.log(結果))39.catch((錯誤) => 控制台.錯誤(錯誤));40
1// Note: You can specify Starknet version in the URL path2// Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63const myHeaders = new Headers();4myHeaders.追加("accept", "application/json");5myHeaders.append("content-type", "application/json");67const raw = JSON.stringify({8"id": 1,9"jsonrpc": "2.0",10"method": "starknet_addInvokeTransaction",11"params": [12{13"sender_address": "SENDER_ADDRESS",14"type": "INVOKE",15"calldata": [16"CALLDATA"17],18"signature": [19"SIGNATURE"20],21"version": "VERSION",22"max_fee": "MAX_FEE",23"nonce": "NONCE_VALUE"24}25]26});272829const requestOptions = {30方法: 「POST」,31標題: myHeaders,32正文: 原始,33重定向: 「追蹤」34};3536fetch("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8", requestOptions)37.接著((回應) => 回應.文字())38.接著((結果) => 控制台.log(結果))39.catch((錯誤) => 控制台.錯誤(錯誤));40
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63import requests4import json56url = "https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8"78有效載荷 = json.dumps({9"id": 1,10"jsonrpc": "2.0",11"method": "starknet_addInvokeTransaction",12"params": [13{14"sender_address": "SENDER_ADDRESS",15"type": "INVOKE",16"calldata": [17"CALLDATA"18],19"signature": [20"SIGNATURE"21],22"version": "VERSION",23"max_fee": "MAX_FEE",24"nonce": "NONCE_VALUE"25}26]27})28標題 = {29「接受」: 'application/json',30'content-type': 'application/json'31}3233回應 = 請求.請求("POST", url, headers=headers, data=有效載荷)3435列印(回應.text)36
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63import requests4import json56url = "https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8"78有效載荷 = json.dumps({9"id": 1,10"jsonrpc": "2.0",11"method": "starknet_addInvokeTransaction",12"params": [13{14"sender_address": "SENDER_ADDRESS",15"type": "INVOKE",16"calldata": [17"CALLDATA"18],19"signature": [20"SIGNATURE"21],22"version": "VERSION",23"max_fee": "MAX_FEE",24"nonce": "NONCE_VALUE"25}26]27})28標題 = {29「接受」: 'application/json',30'content-type': 'application/json'31}3233回應 = 請求.請求("POST", url, headers=headers, data=有效載荷)3435列印(回應.text)36
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63require "uri"4require "json"5需要 "net/http"67url = URI("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8")89http = Net::HTTP.new(url.host, url.port);10請求 = 淨::HTTP::POST.new(網址)11請求["接受"] = "application/json"12request["content-type"] = "application/json"13請求。正文 = JSON.dump({14"id": 1,15"jsonrpc": "2.0",16"method": "starknet_addInvokeTransaction",17"params": [18{19"sender_address": "SENDER_ADDRESS",20"type": "INVOKE",21"calldata": [22"CALLDATA"23],24"signature": [25"SIGNATURE"26],27"version": "VERSION",28"max_fee": "MAX_FEE",29"nonce": "NONCE_VALUE"30}31]32})3334回應 = http.請求(請求)35將回應。read_body36
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_8 for version 0.8, /rpc/v0_6 for version 0.63require "uri"4require "json"5需要 "net/http"67url = URI("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_8")89http = Net::HTTP.new(url.host, url.port);10請求 = 淨::HTTP::POST.new(網址)11請求["接受"] = "application/json"12request["content-type"] = "application/json"13請求。正文 = JSON.dump({14"id": 1,15"jsonrpc": "2.0",16"method": "starknet_addInvokeTransaction",17"params": [18{19"sender_address": "SENDER_ADDRESS",20"type": "INVOKE",21"calldata": [22"CALLDATA"23],24"signature": [25"SIGNATURE"26],27"version": "VERSION",28"max_fee": "MAX_FEE",29"nonce": "NONCE_VALUE"30}31]32})3334回應 = http.請求(請求)35將回應。read_body36