Account-Free IPFS Uploads From Pinata

Use crypto to pay for public IPFS uploads without creating an account or using an API key — powered by MPP

  • Leverages the Machine Payments Protocol (MPP)
  • Public IPFS content available on public gateways or your own Dedicated IPFS Gateway
  • Pay with Tempo stablecoins via HTTP 402
// Upload a public file with MPP payment import { Mppx, tempo } from 'mppx/client' import { privateKeyToAccount } from 'viem/accounts' const account = privateKeyToAccount('0xabc…123') Mppx.create({ methods: [tempo({ account })] }) const response = await fetch( `https://mpp.pinata.cloud/v1/pin/public?fileSize=${SIZE}`, { method: "POST" } ) const { url } = await response.json() const file = new File([Date.now().toString()], "hello.txt") const upload = await pinata.upload.public .file(file) .url(url) console.log(upload)