latest.ipv8.REST.dht_endpoint
¶
Module Contents¶
Classes¶
This endpoint is responsible for handling requests for DHT data. |
- class latest.ipv8.REST.dht_endpoint.DHTEndpoint¶
Bases:
latest.ipv8.REST.base_endpoint.BaseEndpoint
[latest.ipv8.types.IPv8
]This endpoint is responsible for handling requests for DHT data.
- initialize(session: latest.ipv8.types.IPv8) None ¶
Initialize this endpoint for the given session instance.
- async get_statistics(_: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Return DHT statistics.
- async get_peer(request: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Connect to a peer using the DHT.
- async get_stored_values(_: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Get a list of locally stored key-value pairs from the DHT.
- async get_values(request: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Lookup the values for a specific key on the DHT.
- async put_value(request: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Store a key-value pair on the DHT.
- async get_buckets(_: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Return a list of all buckets in the routing table of the DHT community.
- async refresh_bucket(request: aiohttp.abc.Request) latest.ipv8.REST.base_endpoint.Response ¶
Prefix of the bucket which to refresh.