Part of Stem. This page defines the Connect method of the sync RPC specification. It is the one way to introduce a peer the daemon has never heard of.
The formal schema is attached as the schemaDefinition of this page: a struct {key, input, output} with key pinned to Connect.
Dials a peer explicitly, for hm://connect/… links and site registration.
Input
field | type | required | meaning |
|---|---|---|---|
| list of string | yes | Multiaddrs of the peer to dial. |
Output
field | type | required | meaning |
|---|---|---|---|
| yes | The peer id reached. |
Rules
Dials the given multiaddrs, stores the peer and its addresses in the local peer table, and returns the peer id reached.
Connecting confers nothing: the new peer is neither an authority nor trusted until grants or contacts say so.
Fails with unavailable when no address answers.
Today (HM24)
Unchanged from HM24's Networking.Connect.
Example
{"key": "Connect", "input": {"addrs": ["/dns4/site.example/tcp/56001/p2p/12D3KooWSite…"]}}{"peer": "12D3KooWSite…"}Do you like what you are reading? Subscribe to receive updates.
Unsubscribe anytime