UNPKG

@helia/verified-fetch

Version:

A fetch-like API for obtaining verified & trustless IPFS content on the web

17 lines 757 B
import { BasePlugin } from './plugin-base.js'; import type { PluginContext } from './types.js'; import type { ObjectNode } from 'ipfs-unixfs-exporter'; /** * Handles `dag-cbor` content, including requests with Accept: `application/vnd.ipld.dag-json` and `application/json`. */ export declare class DagCborPlugin extends BasePlugin { readonly id = "dag-cbor-plugin"; readonly codes: 113[]; canHandle({ cid, accept, pathDetails, byteRangeContext, plugins }: PluginContext): boolean; handle(context: PluginContext & Required<Pick<PluginContext, 'byteRangeContext' | 'pathDetails'>> & { pathDetails: { terminalElement: ObjectNode; }; }): Promise<Response>; } //# sourceMappingURL=plugin-handle-dag-cbor.d.ts.map