File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
packages/clients/src/api/ipfs/v1alpha1 Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -238,6 +238,20 @@ export class API extends ParentAPI {
238
238
unmarshalPin ,
239
239
)
240
240
241
+ /**
242
+ * Replace pin by CID. Deletes the given resource ID and pins the new CID in
243
+ * its place. Will fetch and store the content pointed by the provided CID.
244
+ * The content must be available on the public IPFS network. The content (IPFS
245
+ * blocks) is hosted by the pinning service until the pin is deleted. While
246
+ * the content is available any other IPFS peer can fetch and host your
247
+ * content. For this reason, we recommend that you pin either public or
248
+ * encrypted content. Several different pin requests can target the same CID.
249
+ * A pin is defined by its ID (UUID), its status (queued, pinning, pinned or
250
+ * failed) and target CID.
251
+ *
252
+ * @param request - The request {@link ReplacePinRequest}
253
+ * @returns A Promise of ReplacePinResponse
254
+ */
241
255
replacePin = ( request : Readonly < ReplacePinRequest > ) =>
242
256
this . client . fetch < ReplacePinResponse > (
243
257
{
You can’t perform that action at this time.
0 commit comments