View Source MyspaceIPFS.Routing (Myspace IPFS v0.2.0-alpha.1)
MyspaceIPFS.Routing is where the routing commands of the IPFS API reside.
Link to this section Summary
Functions
Find the multiaddresses associated with a peer ID.
Find peers that can provide a specific value, given a key.
Announce to the network that you are providing given values.
Write a key/value pair to the routing system.
Link to this section Functions
@spec findpeer(MyspaceIPFS.peer_id(), list()) :: {:ok, any()} | MyspaceIPFS.Api.error_response()
Find the multiaddresses associated with a peer ID.
options
Options
https://docs.ipfs.io/reference/http/api/#api-v0-routing-findpeer verbose - <bool>, # Write extra information.
@spec findprovs(MyspaceIPFS.peer_id(), list()) :: {:ok, any()} | MyspaceIPFS.Api.error_response()
Find peers that can provide a specific value, given a key.
options
Options
https://docs.ipfs.io/reference/http/api/#api-v0-routing-findprovs verbose - <bool>, # Write extra information. num-providers - <int>, # The number of providers to find.
@spec provide(binary(), list()) :: {:ok, any()} | MyspaceIPFS.Api.error_response()
Announce to the network that you are providing given values.
options
Options
https://docs.ipfs.io/reference/http/api/#api-v0-routing-provide recursive - <bool>, # Recursively provide entire graph. verbose - <bool>, # Write extra information.
@spec put(binary(), binary(), list()) :: {:ok, any()} | MyspaceIPFS.Api.error_response()
Write a key/value pair to the routing system.
parameters
Parameters
name
- The name of the key to write.
options
Options
https://docs.ipfs.io/reference/http/api/#api-v0-routing-put verbose - <bool>, # Write extra information.