starknet_getNonce RPC Method
Parameters
block_id
string
REQUIRED
Loading...
contract_address
string
REQUIRED
Loading...
Returns
result
string
Loading...
Request
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3curl --location 'https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9' \4--header 'accept: application/json' \5--header 'content-type: application/json' \6--data '{7"id": 1,8"jsonrpc": "2.0",9"method": "starknet_getNonce",10"params": [11"latest",12"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"13]14}'
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3curl --location 'https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9' \4--header 'accept: application/json' \5--header 'content-type: application/json' \6--data '{7"id": 1,8"jsonrpc": "2.0",9"method": "starknet_getNonce",10"params": [11"latest",12"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"13]14}'
1// Note: You can specify Starknet version in the URL path2// Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3const myHeaders = new Headers();4myHeaders.append("accept", "application/json");5myHeaders.append("content-type", "application/json");67const raw = JSON.stringify({8"id": 1,9"jsonrpc": "2.0",10"method": "starknet_getNonce",11"params": [12"latest",13"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"14]15});1617const requestOptions = {18method: "POST",19headers: myHeaders,20body: raw,21redirect: "follow"22};2324fetch("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9", requestOptions)25.then((response) => response.text())26.then((result) => console.log(result))27.catch((error) => console.error(error));
1// Note: You can specify Starknet version in the URL path2// Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3const myHeaders = new Headers();4myHeaders.append("accept", "application/json");5myHeaders.append("content-type", "application/json");67const raw = JSON.stringify({8"id": 1,9"jsonrpc": "2.0",10"method": "starknet_getNonce",11"params": [12"latest",13"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"14]15});1617const requestOptions = {18method: "POST",19headers: myHeaders,20body: raw,21redirect: "follow"22};2324fetch("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9", requestOptions)25.then((response) => response.text())26.then((result) => console.log(result))27.catch((error) => console.error(error));
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3import requests4import json56url = "https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9"78payload = json.dumps({9"id": 1,10"jsonrpc": "2.0",11"method": "starknet_getNonce",12"params": [13"latest",14"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"15]16})17headers = {18'accept': 'application/json',19'content-type': 'application/json'20}2122response = requests.request("POST", url, headers=headers, data=payload)2324print(response.text)25
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3import requests4import json56url = "https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9"78payload = json.dumps({9"id": 1,10"jsonrpc": "2.0",11"method": "starknet_getNonce",12"params": [13"latest",14"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"15]16})17headers = {18'accept': 'application/json',19'content-type': 'application/json'20}2122response = requests.request("POST", url, headers=headers, data=payload)2324print(response.text)25
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3require "uri"4require "json"5require "net/http"67url = URI("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9")89http = Net::HTTP.new(url.host, url.port);10request = Net::HTTP::Post.new(url)11request["accept"] = "application/json"12request["content-type"] = "application/json"13request.body = JSON.dump({14"id": 1,15"jsonrpc": "2.0",16"method": "starknet_getNonce",17"params": [18"latest",19"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"20]21})2223response = http.request(request)24puts response.read_body25
1# Note: You can specify Starknet version in the URL path2# Example: /rpc/v0_9 for version 0.9. Versions 0.6, 0.7, and 0.8 are no longer supported3require "uri"4require "json"5require "net/http"67url = URI("https://docs-demo.strk-mainnet.quiknode.pro/rpc/v0_9")89http = Net::HTTP.new(url.host, url.port);10request = Net::HTTP::Post.new(url)11request["accept"] = "application/json"12request["content-type"] = "application/json"13request.body = JSON.dump({14"id": 1,15"jsonrpc": "2.0",16"method": "starknet_getNonce",17"params": [18"latest",19"0x010884171baf1914edc28d7afb619b40a4051cfae78a094a55d230f19e944a28"20]21})2223response = http.request(request)24puts response.read_body25
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free