đź§° SDK to create storage deals on FVM, powered by Spheron.
getFvmMetadata Example
In the example below you can see how to create an instance of SpheronDealClient and how to generate the metadata required for creating a storage deal on FVM.
The response of the getFvmMetadata function is an object with the following properties:
pieceSize - the size of the file in bytes
size - the size of the CAR file in bytes
pieceCid - hash of the piece in hex
dataCid - IPFS hash of the car file
carLink - the IPFS URL of the generated car file.
carName - the name of the car
uploadId - the id of the upload on which the car was uploaded
Access Token
To create the token that is used with the SpheronClient, follow the instructions in the DOCS. When you are creating the tokens, please choose web app type in the dashboard.
Notes
The package is only meant for Node.js environments and will not work in a browser or frontend apps.
Learn More
You can learn more about Spheron and Storage SDK here:
Typescript library for creating deal parameters for creating a FVM storage deal.
We found that @spheron/fvm-deal-utils demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
Package last updated on 22 Aug 2023
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
The remediated findings include organization permission bugs, stale project access after transfers, OIDC replay edge cases, audit logging gaps, and an IDOR in API token deletion.
GitHub account BufferZoneCorp published sleeper packages that later added credential theft, GitHub Actions tampering, fake go wrappers, and SSH persistence.