Pinning Services API
Pinning Services API
The Pinning Services API is a standardized specification for developers who want to build applications on top of IPFS (opens in a new tab). It allows seamless integration with a pinning service without requiring knowledge of the service's unique API.
Endpoint
W3IPFS users looking to utilize the IPFS Pinning Services API can do so from the premium API endpoint: https://api.w3ipfs.storage/api/psa/ (opens in a new tab)
Authentication
To authenticate with W3IPFS through the Pinning Services API spec, you'll need to obtain an access_token
. To get this token, first, you need to call a GET API that sends a code to your registered email. After receiving the code, use Postman to make a POST request with this code to the following API endpoint to login and obtain the access token:
Parameters
Response
Body
Response
Using the IPFS CLI
To use the W3IPFS Pinning Service with the IPFS CLI (opens in a new tab), you can follow these steps:
- Add W3IPFS credentials: Before you can start pinning to the W3IPFS Pinning Service, you need to add your authentication credentials. Replace
YOUR_AUTH_JWT
in the following command with your actual JWT.
ipfs pin remote service add w3ipfs https://api.w3ipfs.storage/api/psa/ YOUR_AUTH_JWT
- Pin a CID to W3IPFS: Once you have added the service, you can pin a CID to W3IPFS using the
ipfs pin remote add
command. ReplaceYOUR_CID
with the CID you want to pin.
ipfs pin remote add --service=w3ipfs --name=<human-readable-name> YOUR_CID
- List successful pins: To see a list of successful pins on W3IPFS, you can use the following command:
ipfs pin remote ls --service=w3ipfs
- List pending pins: If you want to check the status of pending pins on W3IPFS, you can use the following command:
ipfs pin remote ls --service=w3ipfs --status=queued,pinning,failed
- Additional commands and help: For more commands and general help with the IPFS remote pinning feature, you can use the following command:
ipfs pin remote --help
See more extensive documentation in the IPFS Docs (opens in a new tab).