Skip to content

Commit 91d95c1

Browse files
authored
Merge pull request #486 from ipfs/delegated-peer-ids
chore: clarify accepted Peer IDs
2 parents 12517ce + c168c57 commit 91d95c1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/routing/http-routing-v1.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ As such, human-readable encodings of types are preferred. This specification may
5252

5353
- CIDs are always string-encoded using a [multibase]-encoded [CIDv1].
5454
- Multiaddrs are string-encoded according to the [human-readable multiaddr specification][multiaddr].
55-
- Peer IDs are string-encoded according [PeerID string representation specification][peer-id-representation]: either a Multihash in Base58btc, or a CIDv1 with libp2p-key (`0x72`) codec.
55+
- Peer IDs are string-encoded according [PeerID string representation specification][peer-id-representation]: either a Multihash in Base58btc, or a CIDv1 with libp2p-key (`0x72`) codec in Base36 or Base32.
5656
- Multibase bytes are string-encoded according to [the Multibase spec][multibase], and SHOULD use base64.
5757
- Timestamps are Unix millisecond epoch timestamps.
5858

@@ -68,7 +68,7 @@ This API uses a standard version prefix in the path, such as `/v1/...`. If a bac
6868

6969
#### Path Parameters
7070

71-
- `cid` is the [CID](https://github.com/multiformats/cid) to fetch provider records for.
71+
- `cid` is the [CID](https://github.com/multiformats/cid) to fetch provider records for (preferably normalized to a CIDv1 in Base32, to maximize HTTP cache hits).
7272

7373
#### Request Query Parameters
7474

@@ -148,7 +148,7 @@ Each object in the `Providers` list is a record conforming to a schema, usually
148148
#### Path Parameters
149149

150150
- `peer-id` is the [Peer ID](https://github.com/libp2p/specs/blob/master/peer-ids/peer-ids.md) to fetch peer records for,
151-
represented as a CIDv1 encoded with `libp2p-key` codec.
151+
represented as either a Multihash in Base58btc, or a CIDv1 with libp2p-key (`0x72`) codec (in Base36 or Base32).
152152

153153
#### Request Query Parameters
154154

0 commit comments

Comments
 (0)