mirror of
https://github.com/vacp2p/rfc.git
synced 2025-01-11 15:24:51 +00:00
Makes the arguments of the store jsonrpc api optional (#361)
* makes contentFilters and pubsubtopic optional * revision * correction on the query examples * converts content filter to an object
This commit is contained in:
parent
3df3375b3b
commit
42fb7520ce
@ -218,8 +218,8 @@ The `get_waku_v2_store_v1_messages` method retrieves historical messages on spec
|
|||||||
|
|
||||||
| Field | Type | Inclusion | Description |
|
| Field | Type | Inclusion | Description |
|
||||||
| ----: | :---: | :---: |----------- |
|
| ----: | :---: | :---: |----------- |
|
||||||
| `pubsubTopic` | `String` | mandatory | The pubsub topic on which a [`WakuMessage`](#WakuMessage) is published |
|
| `pubsubTopic` | `String` | optional | The pubsub topic on which a [`WakuMessage`](#WakuMessage) is published |
|
||||||
| `contentFilters` | `Array`[[`ContentFilter`](#contentfilter)] | mandatory | Array of content filters to query for historical messages |
|
| `contentFilters` | `Array`[[`ContentFilter`](#contentfilter)] | optional | Array of content filters to query for historical messages |
|
||||||
| `pagingOptions` | [`PagingOptions`](#PagingOptions) | optional | Pagination information |
|
| `pagingOptions` | [`PagingOptions`](#PagingOptions) | optional | Pagination information |
|
||||||
|
|
||||||
#### Response
|
#### Response
|
||||||
@ -452,7 +452,7 @@ This method is part of the `store` API and the specific resources to retrieve ar
|
|||||||
|
|
||||||
#### Request
|
#### Request
|
||||||
|
|
||||||
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":["", ["/waku/2/default-content/proto"]]}' --header "Content-Type: application/json" http://localhost:8545```
|
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":["", [{"contentTopic":"/waku/2/default-content/proto"}]]}' --header "Content-Type: application/json" http://localhost:8545```
|
||||||
|
|
||||||
```jsonrpc
|
```jsonrpc
|
||||||
{
|
{
|
||||||
@ -510,7 +510,7 @@ This method is part of the `store` API and the specific resources to retrieve ar
|
|||||||
|
|
||||||
#### Request
|
#### Request
|
||||||
|
|
||||||
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":[ "", ["/waku/2/default-content/proto"],{"pageSize":2,"forward":false}]}' --header "Content-Type: application/json" http://localhost:8545```
|
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":[ "", [{"contentTopic":"/waku/2/default-content/proto"}],{"pageSize":2,"forward":false}]}' --header "Content-Type: application/json" http://localhost:8545```
|
||||||
|
|
||||||
```jsonrpc
|
```jsonrpc
|
||||||
{
|
{
|
||||||
@ -572,7 +572,7 @@ This method is part of the `store` API and the specific resources to retrieve ar
|
|||||||
|
|
||||||
#### Request
|
#### Request
|
||||||
|
|
||||||
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":[ "", ["/waku/2/default-content/proto"],{"pageSize":2,"cursor":{"digest":"abcdef","receivedTime":1605887187.00},"forward":false}]}' --header "Content-Type: application/json" http://localhost:8545```
|
```curl -d '{"jsonrpc":"2.0","id":"id","method":"get_waku_v2_store_v1_messages", "params":[ "", [{"contentTopic":"/waku/2/default-content/proto"}],{"pageSize":2,"cursor":{"digest":"abcdef","receivedTime":1605887187.00},"forward":false}]}' --header "Content-Type: application/json" http://localhost:8545```
|
||||||
|
|
||||||
```jsonrpc
|
```jsonrpc
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user