/** * Capability can only be delegated (but not invoked) allowing audience to * derived any `upload/` prefixed capability for the (memory) space identified * by DID in the `with` field. */ export const upload: import("@ucanto/interface").TheCapabilityParser, any>>; /** * Capability allows an agent to add an arbitrary DAG (root) to the upload list * of the specified (memory) space (identified by did:key in the `with` field). * It is recommended to provide an optional list of shard links that contain * fragments of this DAG, as it allows system to optimize block discovery, it is * also a way to communicate DAG partiality - this upload contains partial DAG * identified by the given `root`. * * Usually when agent wants to upload a DAG it will encode it as a one or more * CAR files (shards) and invoke `store/add` capability for each one. Once all * shards are stored it will invoke `upload/add` capability (providing link to * a DAG root and all the shards) to add it the upload list. * * That said `upload/add` could be invoked without invoking `store/add`s e.g. * because another (memory) space may already have those CARs. * * Note: If DAG with the given root is already in the upload list, invocation * will simply update `shards` to be a union of existing and new shards. */ export const add: import("@ucanto/interface").TheCapabilityParser, Schema.InferStruct<{ root: typeof Link; shards: Schema.Schema, number, 1>[] | undefined, any>; }>>>; /** * Capability to get upload metadata by root CID. * Use to check for inclusion, or find the shards for a root. * * `nb.root` is optional to allow delegation of `upload/get` * capability for any root. If root is specified, then the * capability only allows a get for that single cid. * * When used as as an invocation, `nb.root` must be specified. */ export const get: import("@ucanto/interface").TheCapabilityParser, Schema.InferStruct<{ root: Schema.Schema | undefined, unknown>; }>>>; /** * Capability removes an upload (identified by it's root CID) from the upload * list. Please note that removing an upload does not delete corresponding shards * from the store, however that could be done via `store/remove` invocations. */ export const remove: import("@ucanto/interface").TheCapabilityParser, Schema.InferStruct<{ root: typeof Link; }>>>; /** * Capability can be invoked to request a list of uploads in the (memory) space * identified by the `with` field. */ export const list: import("@ucanto/interface").TheCapabilityParser, Schema.InferStruct<{ cursor: Schema.Schema; size: Schema.Schema<(number & import("@ucanto/interface").Phantom<{ typeof: "integer"; }>) | undefined, unknown>; pre: Schema.Schema; }>>>; export const all: import("@ucanto/interface").CapabilityParser, Schema.InferStruct<{ root: typeof Link; shards: Schema.Schema, number, 1>[] | undefined, any>; }>> | import("@ucanto/interface").CapabilityMatch<"upload/remove", `did:key:${string}` & `did:${string}` & import("@ucanto/interface").Phantom<{ protocol: "did:"; }>, Schema.InferStruct<{ root: typeof Link; }>> | import("@ucanto/interface").CapabilityMatch<"upload/list", `did:key:${string}` & `did:${string}` & import("@ucanto/interface").Phantom<{ protocol: "did:"; }>, Schema.InferStruct<{ cursor: Schema.Schema; size: Schema.Schema<(number & import("@ucanto/interface").Phantom<{ typeof: "integer"; }>) | undefined, unknown>; pre: Schema.Schema; }>>>; import { Link } from '@ucanto/validator'; import { Schema } from '@ucanto/validator'; export { Link, Schema }; //# sourceMappingURL=upload.d.ts.map