Skip to content

Commit

Permalink
wip: ipip 0417
Browse files Browse the repository at this point in the history
  • Loading branch information
hacdias authored and lidel committed May 31, 2023
1 parent e55e319 commit 4cf3e5f
Show file tree
Hide file tree
Showing 2 changed files with 101 additions and 6 deletions.
54 changes: 54 additions & 0 deletions src/ipips/ipip-0417.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
---
title: "IPIP-0417: TODO"
date: 2023-05-29
ipip: proposal
editors:
- name: Henrique Dias
github: hacdias
url: https://hacdias.com/
relatedIssues:
- https://github.com/ipfs/specs/pull/410
- https://github.com/ipfs/kubo/pull/9877
order: 417
tags: ['ipips']
---

## Summary

TODO

## Motivation

TODO

## Detailed design

TODO

## Test fixtures

TODO

## Design rationale

TODO

### User benefit

TODO

### Compatibility

TODO

### Security

TODO

### Alternatives

TODO

### Copyright

Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).
53 changes: 47 additions & 6 deletions src/routing/http-routing-v1.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,24 @@ Response limit: 100 providers

Each object in the `Providers` list is a *read provider record*.

## Peers API

### `GET /routing/v1/peers/{peer-id}`

#### Path Parameters

- `peer-id` is the [Peer ID](https://github.com/libp2p/specs/blob/master/peer-ids/peer-ids.md) to fetch peer records for.

#### Response Status Codes

- `200` (OK): the response body contains the peer record.
- `404` (Not Found): must be returned if no matching records are found.
- `422` (Unprocessable Entity): request does not conform to schema or semantic constraints.

#### Response Body

A [`peer` schema record](#peer).

## IPNS API

### `GET /routing/v1/ipns/{name}`
Expand Down Expand Up @@ -199,15 +217,38 @@ Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET, OPTIONS
```

## Known Schemas

This section contains a non-exhaustive list of known schemas that MAY be supported by clients and servers.

### Peer

The `peer` schema represents an arbitrary peer.


```json
{
"Schema": "peer",
"ID": "12D3K...",
"Addrs": ["/ip4/..."],
"Protocols": ["transport-bitswap", ...]
}
```

- `ID`: the [Peer ID](https://github.com/libp2p/specs/blob/master/peer-ids/peer-ids.md).
- `Addrs`: a list of known [multiaddrs][multiaddr] for this peer. This list MAY be incomplete.
- `Protocols`: an OPTIONAL field with the transports known to be used by this peer. If empty, it means the server does not know and the client can use the `identify` protocol to learn more.


## Known Transfer Protocols

This section contains a non-exhaustive list of known transfer protocols (by name) that may be supported by clients and servers.

### Bitswap

Multicodec name: `transport-bitswap`
Schema: `bitswap`
Specification: [ipfs/specs/BITSWAP.md](https://github.com/ipfs/specs/blob/main/BITSWAP.md)
- Multicodec name: `transport-bitswap`
- Schema: `bitswap`
- Specification: [ipfs/specs/BITSWAP.md](https://github.com/ipfs/specs/blob/main/BITSWAP.md)

#### Bitswap Read Provider Records

Expand All @@ -228,9 +269,9 @@ The server should respect a passed `transport` query parameter by filtering agai

### Filecoin Graphsync

Multicodec name: `transport-graphsync-filecoinv1`
Schema: `graphsync-filecoinv1`
Specification: [ipfs/go-graphsync/blob/main/docs/architecture.md](https://github.com/ipfs/go-graphsync/blob/main/docs/architecture.md)
- Multicodec name: `transport-graphsync-filecoinv1`
- Schema: `graphsync-filecoinv1`
- Specification: [ipfs/go-graphsync/blob/main/docs/architecture.md](https://github.com/ipfs/go-graphsync/blob/main/docs/architecture.md)

#### Filecoin Graphsync Read Provider Records

Expand Down

0 comments on commit 4cf3e5f

Please sign in to comment.