You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: routing/DELEGATED_ROUTING_HTTP.md
+31-32
Original file line number
Diff line number
Diff line change
@@ -64,58 +64,57 @@ The Delegated Routing HTTP API uses the `application/json` content type by defau
64
64
- This is the same as `GET /v1/providers/{CID}`, but takes a hashed CID encoded as a [multihash](https://github.com/multiformats/multihash/)
65
65
- `GET /v1/ipns/{ID}`
66
66
- Reframe equivalent: GetIPNS
67
-
- `ID`: multibase-encoded bytes
67
+
- `ID`: multibase-encoded bytes
68
68
- Response
69
69
- record bytes
70
70
- `POST /v1/ipns`
71
71
- Reframe equivalent: PutIPNS
72
72
- Body
73
73
```json
74
74
{
75
-
"Records": [
76
-
{
77
-
"ID": "multibase bytes",
78
-
"Record": "multibase bytes"
79
-
}
80
-
]
75
+
"Records": [
76
+
{
77
+
"ID": "multibase bytes",
78
+
"Record": "multibase bytes"
79
+
}
80
+
]
81
81
}
82
82
```
83
83
- Not idempotent (this doesn't really make sense for IPNS)
- `Signature` is a multibase-encoded signature of the encoded bytes of the `Payload` field, signed using the private key of the Peer ID specified in the `Payload`. See the [Peer ID](https://github.com/libp2p/specs/blob/master/peer-ids/peer-ids.md#keys) specification for the encoding of Peer IDs. Servers must verify the payload using the public key from the Peer ID. If the verification fails, the server must return a 403 status code.
110
110
- Idempotent
111
111
- Default limit of 100 keys per request
112
112
- `GET /v1/ping`
113
-
- This is absent from Reframe but is necessary for supporting e.g. the accelerated DHT client which can take many minutes to bootstrap, and light clients who want to probe multiple HTTP endpoints and use the fastest one
114
113
- Returns 200 once the server is ready to accept requests
115
-
- An alternate approach is w/ an orchestration dance in the server by not listening on the socket until the dependencies are ready, but this makes the “dance” easier to implement
116
-
- Limits
114
+
115
+
## Limits
117
116
- Responses with collections of results must have a default limit on the number of results that will be returned in a single response
118
117
- Pagination and/or dynamic limit configuration may be added to this spec in the future, once there is a concrete requirement
119
-
- Error Codes
118
+
## Error Codes
120
119
- A 404 must be returned if a resource was not found
121
120
- A 501 must be returned if a method is not supported
0 commit comments