# QTUM RPC CALLS

### qrc20allowance "contractaddress" "addressfrom" "addressto"

```
qtum-cli qrc20allowance

qrc20allowance "contractaddress" "addressfrom" "addressto"

Returns remaining tokens allowed to spend for an address

Arguments:
1. contractaddress    (string, required) The contract address
2. addressfrom        (string, required) The qtum address of the account owning tokens
3. addressto          (string, required) The qtum address of the account able to transfer the tokens

Result:
"str"    (string) Amount of remaining tokens allowed to spent

Examples:
> qtum-cli qrc20allowance "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20allowance", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20balanceof "contractaddress" "address"

```
qtum-cli qrc20balanceof

qrc20balanceof "contractaddress" "address"

Returns the token balance for address

Arguments:
1. contractaddress    (string, required) The contract address
2. address            (string, required) The qtum address to check token balance

Result:
"str"    (string) The token balance of the chosen address

Examples:
> qtum-cli qrc20balanceof "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20balanceof", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20decimals "contractaddress"

```
qtum-cli qrc20decimals

qrc20decimals "contractaddress"

Returns the number of decimals of the token

Arguments:
1. contractaddress    (string, required) The contract address

Result:
n    (numeric) The number of decimals of the token

Examples:
> qtum-cli qrc20decimals "eb23c0b3e6042821da281a2e2364feb22dd543e3"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20decimals", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/

```

### qrc20listtransactions

```
qtum-cli qrc20listtransactions

qrc20listtransactions "contractaddress" "address" ( fromblock minconf )

Returns transactions history for a specific address.

Arguments:
1. contractaddress    (string, required) The contract address.
2. address            (string, required) The qtum address to get history for.
3. fromblock          (numeric, optional, default=0) The number of the earliest block.
4. minconf            (numeric, optional, default=6) Minimal number of confirmations.

Result:
[                                 (json array)
  {                               (json object)
    "receiver" : "str",           (string) The receiver qtum address
    "sender" : "str",             (string) The sender qtum address
    "amount" : "str",             (string) The transferred token amount
    "confirmations" : n,          (numeric) The number of confirmations of the most recent transaction included
    "blockHash" : "hex",          (string) The block hash
    "blockNumber" : n,            (numeric) The block number
    "blocktime" : xxx,            (numeric) The block time expressed in UNIX epoch time.
    "transactionHash" : "hex"     (string) The transaction hash
  },
  ...
]

Examples:
> qtum-cli qrc20listtransactions "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX"
> qtum-cli qrc20listtransactions "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" 0 6
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20listtransactions", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20listtransactions", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" 0 6]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20name "contractaddress"

```
qrc20name "contractaddress"

Returns the name of the token

Arguments:
1. contractaddress    (string, required) The contract address

Result:
"str"    (string) The name of the token

Examples:
> qtum-cli qrc20name "eb23c0b3e6042821da281a2e2364feb22dd543e3"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20name", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/

```

### qrc20symbol "contractaddress"

```
qrc20symbol "contractaddress"

Returns the symbol of the token

Arguments:
1. contractaddress    (string, required) The contract address

Result:
"str"    (string) The symbol of the token

Examples:
> qtum-cli qrc20symbol "eb23c0b3e6042821da281a2e2364feb22dd543e3"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20symbol", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/

```

### qrc20totalsupply "contractaddress"

```
qrc20totalsupply "contractaddress"

Returns the total supply of the token

Arguments:
1. contractaddress    (string, required) The contract address

Result:
"str"    (string) The total supply of the token

Examples:
> qtum-cli qrc20totalsupply "eb23c0b3e6042821da281a2e2364feb22dd543e3"
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20totalsupply", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20approve "contractaddress" "owneraddress" "spenderaddress"

"amount" ( gaslimit gasprice checkoutputs )

```
qrc20approve "contractaddress" "owneraddress" "spenderaddress" "amount" ( gaslimit gasprice checkoutputs )

Owner approves an address to spend some amount of tokens.

Arguments:
1. contractaddress    (string, required) The contract address.
2. owneraddress       (string, required) The token owner qtum address.
3. spenderaddress     (string, required) The token spender qtum address.
4. amount             (string, required) The amount of tokens. eg 0.1
5. gaslimit           (numeric or string, optional) The gas limit, default: 250000, max: 40000000
6. gasprice           (numeric or string, optional) The qtum price per gas unit, default: 0.0000004, min:0.0000004
7. checkoutputs       (boolean, optional, default=true) Check outputs before send

Result:
{                    (json object)
  "psbt" : "str",    (string, optional) The base64-encoded unsigned PSBT of the new transaction. Only returned when wallet private keys are disabled.
  "txid" : "hex"     (string, optional) The transaction id. Only returned when wallet private keys are enabled.
}

Examples:
> qtum-cli qrc20approve "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1
> qtum-cli qrc20approve "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20approve", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20approve", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20burn "contractaddress" "owneraddress" "amount" ( gaslimit gasprice checkoutputs )

```
qrc20burn "contractaddress" "owneraddress" "amount" ( gaslimit gasprice checkoutputs )

Burns token amount from owner address.

Arguments:
1. contractaddress    (string, required) The contract address.
2. owneraddress       (string, required) The token owner qtum address.
3. amount             (string, required) The amount of tokens to burn. eg 0.1
4. gaslimit           (numeric or string, optional) The gas limit, default: 250000, max: 40000000
5. gasprice           (numeric or string, optional) The qtum price per gas unit, default: 0.0000004, min:0.0000004
6. checkoutputs       (boolean, optional, default=true) Check outputs before send

Result:
{                    (json object)
  "psbt" : "str",    (string, optional) The base64-encoded unsigned PSBT of the new transaction. Only returned when wallet private keys are disabled.
  "txid" : "hex"     (string, optional) The transaction id. Only returned when wallet private keys are enabled.
}

Examples:
> qtum-cli qrc20burn "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1
> qtum-cli qrc20burn "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20burn", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20burn", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20burnfrom "contractaddress" "owneraddress" "spenderaddress" "amount" ( gaslimit gasprice checkoutputs )

```
qrc20burnfrom "contractaddress" "owneraddress" "spenderaddress" "amount" ( gaslimit gasprice checkoutputs )

Burns token amount from a given address.

Arguments:
1. contractaddress    (string, required) The contract address.
2. owneraddress       (string, required) The token owner qtum address.
3. spenderaddress     (string, required) The token spender qtum address.
4. amount             (string, required) The amount of token to burn. eg 0.1
5. gaslimit           (numeric or string, optional) The gas limit, default: 250000, max: 40000000
6. gasprice           (numeric or string, optional) The qtum price per gas unit, default: 0.0000004, min:0.0000004
7. checkoutputs       (boolean, optional, default=true) Check outputs before send

Result:
{                    (json object)
  "psbt" : "str",    (string, optional) The base64-encoded unsigned PSBT of the new transaction. Only returned when wallet private keys are disabled.
  "txid" : "hex"     (string, optional) The transaction id. Only returned when wallet private keys are enabled.
}

Examples:
> qtum-cli qrc20burnfrom "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1
> qtum-cli qrc20burnfrom "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20burnfrom", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20burnfrom", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

### qrc20transfer "contractaddress" "owneraddress" "addressto" "amount" ( gaslimit gasprice checkoutputs )

```
qrc20transfer "contractaddress" "owneraddress" "addressto" "amount" ( gaslimit gasprice checkoutputs )

Send token amount to a given address.

Arguments:
1. contractaddress    (string, required) The contract address.
2. owneraddress       (string, required) The token owner qtum address.
3. addressto          (string, required) The qtum address to send funds to.
4. amount             (string, required) The amount of tokens to send. eg 0.1
5. gaslimit           (numeric or string, optional) The gas limit, default: 250000, max: 40000000
6. gasprice           (numeric or string, optional) The qtum price per gas unit, default: 0.0000004, min:0.0000004
7. checkoutputs       (boolean, optional, default=true) Check outputs before send

Result:
{                    (json object)
  "psbt" : "str",    (string, optional) The base64-encoded unsigned PSBT of the new transaction. Only returned when wallet private keys are disabled.
  "txid" : "hex"     (string, optional) The transaction id. Only returned when wallet private keys are enabled.
}

Examples:
> qtum-cli qrc20transfer "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1
> qtum-cli qrc20transfer "eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20transfer", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "qrc20transfer", "params": ["eb23c0b3e6042821da281a2e2364feb22dd543e3" "QX1GkJdye9WoUnrE2v6ZQhQ72EUVDtGXQX" "QM72Sfpbz1BPpXFHz9m3CdqATR44Jvaydd" 0.1 250000 0.0000004 true]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
```

```
qrc20transferfrom "contractaddress" "owneraddress" "spenderaddress" "receiveraddress" "amount" ( gaslimit gasprice checkoutputs )
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.qtum.info/qtum-documentation/rpc-calls-and-api/qtum-rpc-calls.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
