database_api.list_witnesses
Purpose
Retourne la liste des witness (témoins). Paramètres : start:object ; limit:int ; order:string
startdépend deorder(voir ci-dessous)limitest limité à 1000.orderpeut être l'un des suivants :by_name- tri par nom (name)startest une valeur de type chaîne :account
by_vote_name- tri par votes, nomstartest un tableau de deux valeurs :votes,account
by_schedule_time- tri par heure de planning (schedule time)startest un tableau de deux valeurs :virtual_scheduled_time,account
| start (object) | limit (int) | order (string) | | |----------------------------|---------------|-| | "" | 10 | "by_name" | Interroge les 10 premiers witness, tri par nom de compte | | [0, ""] | 10 | "by_vote_name" | Interroge les 10 premiers witness, tri par votes | | ["473718186844702107410533306", "alice"] | 10 | "by_schedule_time" | Interroge les 10 premiers witness, tri par planning |
Voir aussi : Paginated API Methods
Parameters
PARAMETERS
json
{
"start": null,
"limit": 0,
"order": "by_name"
}Example
Example 1
BASH
bash
curl -s https://api.steemit.com \
-H 'Content-Type: application/json' \
--data-binary '{
"jsonrpc": "2.0",
"method": "database_api.list_witnesses",
"params": {
"start": "",
"limit": 10,
"order": "by_name"
},
"id": 1
}'Example 2
BASH
bash
curl -s https://api.steemit.com \
-H 'Content-Type: application/json' \
--data-binary '{
"jsonrpc": "2.0",
"method": "database_api.list_witnesses",
"params": {
"start": [
0,
""
],
"limit": 10,
"order": "by_vote_name"
},
"id": 1
}'Example 3
BASH
bash
curl -s https://api.steemit.com \
-H 'Content-Type: application/json' \
--data-binary '{
"jsonrpc": "2.0",
"method": "database_api.list_witnesses",
"params": {
"start": [
"473718186844702107410533306",
"alice"
],
"limit": 10,
"order": "by_schedule_time"
},
"id": 1
}'Response
RESPONSE
json
{
"witnesses": [
{
"id": 6950,
"owner": "a-0",
"created": "1970-01-01T00:00:00",
"url": "",
"votes": 0,
"virtual_last_update": "0",
"virtual_position": "0",
"virtual_scheduled_time": "340282366920938463463374607431768211455",
"total_missed": 0,
"last_aslot": 1063323,
"last_confirmed_block_num": 1040423,
"pow_worker": 0,
"signing_key": "STM5RrTRNDhhrMaA24SzSeE5AvmUcutb1q1VZp1imnT8p871s3UjN",
"props": {
"account_creation_fee": {
"amount": "1",
"precision": 3,
"nai": "@@000000021"
},
"maximum_block_size": 131072,
"sbd_interest_rate": 1000,
"account_subsidy_budget": 797,
"account_subsidy_decay": 347321
},
"sbd_exchange_rate": {
"base": {
"amount": "0",
"precision": 3,
"nai": "@@000000021"
},
"quote": {
"amount": "0",
"precision": 3,
"nai": "@@000000021"
}
},
"last_sbd_exchange_update": "1970-01-01T00:00:00",
"last_work": "000000127cb0e335667f30100bc1a061175c2d789f808e0e9ac82ee70fa8e604",
"running_version": "0.0.0",
"hardfork_version_vote": "0.0.0",
"hardfork_time_vote": "2016-03-24T16:00:00",
"available_witness_account_subsidies": 0
}
]
}