mirror of
https://github.com/mimblewimble/grin.git
synced 2025-02-01 17:01:09 +03:00
fix: add missing API in list (#1847)
Closes #1653 * Replace query parameter values with placeholders * fix: replace wrong query parameter * Extent query explanation * Add missing port parameter
This commit is contained in:
commit
038e21859a
1 changed files with 17 additions and 11 deletions
|
@ -241,15 +241,19 @@ impl Handler for OutputHandler {
|
||||||
//
|
//
|
||||||
// Last inserted nodes::
|
// Last inserted nodes::
|
||||||
// GET /v1/txhashset/lastoutputs (gets last 10)
|
// GET /v1/txhashset/lastoutputs (gets last 10)
|
||||||
// GET /v1/txhashset/lastoutputs?n=5
|
// GET /v1/txhashset/lastoutputs?n=5 (get last 5)
|
||||||
// GET /v1/txhashset/lastrangeproofs
|
//
|
||||||
// GET /v1/txhashset/lastkernels
|
// GET /v1/txhashset/lastrangeproofs (gets last 10)
|
||||||
|
// GET /v1/txhashset/lastrangeproofs?n=5 (get last 5)
|
||||||
|
//
|
||||||
|
// GET /v1/txhashset/lastkernels (gets last 10)
|
||||||
|
// GET /v1/txhashset/lastkernels?n=5 (get last 5)
|
||||||
|
|
||||||
// UTXO traversal::
|
// UTXO traversal::
|
||||||
// GET /v1/txhashset/outputs?start_index=1&max=100
|
// GET /v1/txhashset/outputs?start_index=1&max=100
|
||||||
//
|
//
|
||||||
// Build a merkle proof for a given pos
|
// Build a merkle proof for a given pos
|
||||||
// GET /v1/txhashset/merkleproof?n=1
|
// GET /v1/txhashset/merkleproof?id=1 (get merkle proof of output commitment 1)
|
||||||
|
|
||||||
struct TxHashSetHandler {
|
struct TxHashSetHandler {
|
||||||
chain: Weak<chain::Chain>,
|
chain: Weak<chain::Chain>,
|
||||||
|
@ -820,17 +824,19 @@ pub fn build_router(
|
||||||
"get chain/outputs".to_string(),
|
"get chain/outputs".to_string(),
|
||||||
"get status".to_string(),
|
"get status".to_string(),
|
||||||
"get txhashset/roots".to_string(),
|
"get txhashset/roots".to_string(),
|
||||||
"get txhashset/lastoutputs?n=10".to_string(),
|
"get txhashset/lastoutputs?n=<count>".to_string(),
|
||||||
"get txhashset/lastrangeproofs".to_string(),
|
"get txhashset/lastrangeproofs?n=<count>".to_string(),
|
||||||
"get txhashset/lastkernels".to_string(),
|
"get txhashset/lastkernels?n=<count>".to_string(),
|
||||||
"get txhashset/outputs?start_index=1&max=100".to_string(),
|
"get txhashset/outputs?start_index=<index>&max=<count>".to_string(),
|
||||||
|
"get txhashset/merkleproof?id=<output_commitment>".to_string(),
|
||||||
"get pool".to_string(),
|
"get pool".to_string(),
|
||||||
"post pool/push".to_string(),
|
"post pool/push".to_string(),
|
||||||
"post peers/a.b.c.d:p/ban".to_string(),
|
"post peers/<ip>:<port>/ban".to_string(),
|
||||||
"post peers/a.b.c.d:p/unban".to_string(),
|
"post peers/<ip>:<port>/unban".to_string(),
|
||||||
"get peers/all".to_string(),
|
"get peers/all".to_string(),
|
||||||
"get peers/connected".to_string(),
|
"get peers/connected".to_string(),
|
||||||
"get peers/a.b.c.d".to_string(),
|
"get peers/<ip>:<port>".to_string(),
|
||||||
|
"get headers".to_string(),
|
||||||
];
|
];
|
||||||
let index_handler = IndexHandler { list: route_list };
|
let index_handler = IndexHandler { list: route_list };
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue