Gathering detailed insights and metrics for pinata-sdk
Gathering detailed insights and metrics for pinata-sdk
Gathering detailed insights and metrics for pinata-sdk
Gathering detailed insights and metrics for pinata-sdk
npm install pinata-sdk
Typescript
Module System
Node Version
NPM Version
OCaml (94.63%)
Makefile (2.7%)
Dockerfile (2.67%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
27 Stars
14 Commits
4 Forks
3 Watchers
2 Branches
1 Contributors
Updated on May 27, 2025
Latest Version
0.1.7
Package Id
pinata-sdk@0.1.7
Unpacked Size
153.01 kB
Size
49.84 kB
File Count
44
NPM Version
6.4.1
Node Version
11.4.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
3
5
Unofficial SDK for Pinata, implemented in ReasonML and compiled to Javascript.
Pinning service that improves your IPFS experience by deploying the underlying infrastructure so you don't have to!
In order to use some of the SDK's features, you'll have to sign up with Pinata to obtain your API keys. To learn more about Pinata check out the getting started guide.
Install the package - it includes both the javascript & reason versions.
npm i --save pinata-sdk
If you're using ReasonML, add this to your bsconfig.json
:
1"bs-dependencies": [ 2 "pinata-sdk" 3],
Following examples demonstrates pinning an IPFS hash on Pinata, using the SDK. In order to do so, you need to authenticate yourself with Pinata API keys.
⚠️ For usage with Node.js, make sure to include the
node-fetch
polyfill.
1open PinataSdk; 2open PinataSdk.PinHashToIPFS; 3 4let hash = "<your ipfs content hash>"; 5let apiKey = "<your api key>"; 6let privateApiKey = "<your private api key>"; 7let pinata = Pinata.configure( 8 ~apiKey = apiKey, 9 ~privateApiKey = privateApiKey, 10 () 11); 12 13pinata 14 ->Pinata.pinHashToIPFS(~hash=hash) 15 |> then_(result => { 16 Js.log("Content pinned successfully" ++ result->ipfsHashGet) 17 Js.Promise.resolve(result); 18 })
1import * as Pinata from 'pinata-sdk'; 2const apiKey = "<your api key>"; 3const privateApiKey = "<your private api key>"; 4const hash = "<your ipfs content hash>"; 5const pinata: Pinata.PinataConfig = Pinata.configure(apiKey, privateApiKey); 6 7(async function() { 8 try { 9 const result: Pinata.PinHashToIPFSResponseJS = await Pinata.pinHashToIPFS( 10 pinata, 11 hash 12 ); 13 console.log("Content pinned successfully", result.ipfsHash); 14 } catch (err) { 15 console.error("Content was not pinned", err); 16 } 17})();
1const Pinata = require('pinata-sdk'); 2const apiKey = "<your api key>"; 3const privateApiKey = "<your private api key>"; 4const hash = "<your ipfs content hash>"; 5const pinata = Pinata.configure(apiKey, privateApiKey); 6 7(async function() { 8 try { 9 const result = await Pinata.pinHashToIPFS( 10 pinata, 11 hash 12 ); 13 console.log("Content pinned successfully", result.ipfsHash); 14 } catch (err) { 15 console.error("Content was not pinned", err); 16 } 17})();
Available methods of the SDK, for usage examples see the quick start guide or the examples section.
apiKey
your api key from pinataprivateApiKey
your private api key from pinataapiURL
optional, default value https://api.pinata.cloud
config
SDK configuration created via configure()
hash
IPFS content hash to be pinnedYou can find the usage examples in the examples
folder.
🐳 Optionally you can start the development container described in the contributing section, in order to run the examples smoothly.
Make sure to:
npm i
before running each example.examples/**/credentials.js
Each example can be run using npm start
.
Some examples might contain additional README.md
to help you understand the details.
PinataSDK is developed & built trough docker, to start contributing, you'll have to setup docker for your platform first.
Editor support for ReasonML works well with VSCode's OCaml and Reason IDE
Everything you need to contribute to PinataSDK happens inside the development container
1# Build an image for our dev container 2make build-image 3# Launch the container with an interactive bash session 4make bash
List of available commands can be found in package.json
.
1# Install dependencies 2npm install 3 4# Rebuild on every file change 5npm run start 6 7# Build the SDK 8npm run build 9 10# Cleans build artifacts 11npm run clean
PinataSDK is available under the MIT License
Pinata SDK is created and maintained by Matej Sima.
Special thanks to the Pinata team for such an awesome service!
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
Found 0/14 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
license file not detected
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
163 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More