Skip to content

feat(ipfs): add documentation about replacePin #993

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 10, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions packages/clients/src/api/ipfs/v1alpha1/api.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,20 @@ export class API extends ParentAPI {
unmarshalPin,
)

/**
* Replace pin by CID. Deletes the given resource ID and pins the new CID in
* its place. Will fetch and store the content pointed by the provided CID.
* The content must be available on the public IPFS network. The content (IPFS
* blocks) is hosted by the pinning service until the pin is deleted. While
* the content is available any other IPFS peer can fetch and host your
* content. For this reason, we recommend that you pin either public or
* encrypted content. Several different pin requests can target the same CID.
* A pin is defined by its ID (UUID), its status (queued, pinning, pinned or
* failed) and target CID.
*
* @param request - The request {@link ReplacePinRequest}
* @returns A Promise of ReplacePinResponse
*/
replacePin = (request: Readonly<ReplacePinRequest>) =>
this.client.fetch<ReplacePinResponse>(
{
Expand Down