Documentation ¶
Index ¶
- type Client
- func (c *Client) Find(ctx context.Context, m multihash.Multihash) (*model.FindResponse, error)
- func (c *Client) FindBatch(ctx context.Context, mhs []multihash.Multihash) (*model.FindResponse, error)
- func (c *Client) GetProvider(ctx context.Context, providerID peer.ID) (*model.ProviderInfo, error)
- func (c *Client) GetStats(ctx context.Context) (*model.Stats, error)
- func (c *Client) ListProviders(ctx context.Context, withExtMetadata bool) ([]*model.ProviderInfo, error)
- type DHashClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an http client for the indexer finder API
func New ¶
func New(baseURL string, options ...httpclient.Option) (*Client, error)
New creates a new finder HTTP client.
func (*Client) FindBatch ¶
func (c *Client) FindBatch(ctx context.Context, mhs []multihash.Multihash) (*model.FindResponse, error)
FindBatch queries indexer entries for a batch of multihashes
func (*Client) GetProvider ¶
func (*Client) ListProviders ¶
type DHashClient ¶ added in v0.5.5
type DHashClient struct { Client // contains filtered or unexported fields }
func NewDHashClient ¶ added in v0.5.5
func NewDHashClient(baseURL string, options ...httpclient.Option) (*DHashClient, error)
func (*DHashClient) Find ¶ added in v0.5.5
func (c *DHashClient) Find(ctx context.Context, mh multihash.Multihash) (*model.FindResponse, error)
Click to show internal directories.
Click to hide internal directories.