🪐 NFT.Storage Gateway, the IPFS gateway for NFT.Storage is not "another gateway", but a caching layer for NFTs that sits on top of existing IPFS public gateways. ***Notice: Uploads have been decommissioned.**** Learn more and find a new hot storage provider for uploading new assets: nft.storage/nft-storage-classic
Currently the gateway is configured with the same R2 bucket that the perma cache API uses and has to know how to retrieve data from it when given a URL that was previously cached by perma cache. All this knowledge and configuration should live only in the perma-cache API and we should instead expose an API route allowing the gateway to retrieve data using just a URL.
i.e. currently:
# caching data:
user -> perma-cache -> R2
# retrieving data
user <- gateway <- R2
change to:
# caching data:
user -> perma-cache -> R2
# retrieving data
user <- gateway <- perma-cache <- R2
Currently the gateway is configured with the same R2 bucket that the perma cache API uses and has to know how to retrieve data from it when given a URL that was previously cached by perma cache. All this knowledge and configuration should live only in the perma-cache API and we should instead expose an API route allowing the gateway to retrieve data using just a URL.
i.e. currently:
change to:
New API route: