From 8e115cc12419fa59a98787ca15ce7583f0039abb Mon Sep 17 00:00:00 2001 From: Kolby Moroz Liebl <31669092+KolbyML@users.noreply.github.com> Date: Thu, 10 Oct 2024 23:12:27 -0600 Subject: [PATCH 1/2] Add specification for Portal JSON-RPC --- jsonrpc/specification.md | 46 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 jsonrpc/specification.md diff --git a/jsonrpc/specification.md b/jsonrpc/specification.md new file mode 100644 index 0000000..6fbca90 --- /dev/null +++ b/jsonrpc/specification.md @@ -0,0 +1,46 @@ +# Portal JSON-RPC specification + +## portal_*RoutingTableInfo + +## portal_*AddEnr + +## portal_*GetEnr + +## portal_*DeleteEnr + +## portal_*LookupEnr + +## portal_*Ping + +## portal_*FindNodes + +## portal_*FindContent +- must validate content + +## portal_*Offer +- must not validate content +- shouldn't store data on offering node + +## portal_*RecursiveFindNodes + +## portal_*GetContent +- must validate content +- must check local storage first before doing recursive find content +- if recursive find content is done must do poke mechanism +- if recursive find content is done and content meets storage criteria store content + +## portal_*TraceGetContent +- must validate content +- must check local storage first before doing recursive find content +- if recursive find content is done must do poke mechanism +- if recursive find content is done and content meets storage criteria store content + +## portal_*Store +- must not validate content + +## portal_*LocalContent +- content stored locally is assumed already validated + +## portal_*Gossip +- must not validate content +- shouldn't store data on gossiping node From 794fc1ef65b685dd0b029815d4b3854582bb5647 Mon Sep 17 00:00:00 2001 From: Kolby Moroz Liebl <31669092+KolbyML@users.noreply.github.com> Date: Thu, 10 Oct 2024 23:14:52 -0600 Subject: [PATCH 2/2] Update specification.md --- jsonrpc/specification.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/jsonrpc/specification.md b/jsonrpc/specification.md index 6fbca90..fc417da 100644 --- a/jsonrpc/specification.md +++ b/jsonrpc/specification.md @@ -1,8 +1,11 @@ # Portal JSON-RPC specification +The `*` is meant to be a placeholder to substitute different Portal sub-networks `history`, `state`, `beacon`, etc + ## portal_*RoutingTableInfo ## portal_*AddEnr +- Adds the Enr to the respective sub-networks routing table ## portal_*GetEnr