Filebase x Subsquid Collaboration Announcement

The Subsquid Archives makes use of Filebase’s reliable geo-redundant IPFS service for the storage of massive quantities of indexed blockchain data. Filebase plays an essential role in providing the ability to pin and distribute the archive data using IPFS.

Filebase x Subsquid Collaboration Announcement

Filebase is excited to announce an official collaboration with Subsquid!

Filebase is a decentralized storage and geo-redundant IPFS pinning provider that offers scalable, highly performant, and redundant storage across multiple decentralized storage networks.

Subsquid is a comprehensive blockchain indexing software development kit (SDK) that includes specialized data lakes designed to efficiently extract large volumes of on-chain historical data. The SDK offers a flexible Extract-Transform-Load-Query stack that can index events and transactions at speeds of up to 50,000 blocks per second.

The Subsquid Archives makes use of Filebase’s reliable geo-redundant IPFS service for the storage of massive quantities of indexed blockchain data. As Subsquid progresses towards its goal of decentralizing the Subsquid Archives, Filebase plays an essential role in providing the ability to pin and distribute the archive data using IPFS.

Subsquid indexers support fetching assets and data that are stored on IPFS. Through Subsquid's collaboration with Filebase, Subsquid recommends that its users utilize the Filebase IPFS Dedicated Gateways for reliable and performant data retrieval.

Additionally, Subsquid plans to offer Filebase's services through integration into their Aquarium product - a hosted service for their indexing product.

The Subsquid Documentation provides a great example showcasing how to retrieve NFT data about the Bored Ape Yacht Club collection through the BAYC NFT indexing squid:

export const BASE_URL = 'https://my-gateway.myfilebase.com/ipfs'

export const api = Axios.create({
  baseURL: BASE_URL,
  headers: {
    'Content-Type': 'application/json',
  },
  withCredentials: false,
  timeout: 5000,
  httpsAgent: new https.Agent({ keepAlive: true }),
})


export const fetchMetadata = async (
  ctx: BlockHandlerContext<Store>,
  cid: string
): Promise<any | null> => {
  try {
    const { status, data } = await api.get(`${BASE_URL}/${cid}`)
    ctx.log.info(`[IPFS] ${status} CID: ${cid}`)
    if (status < 400) {
      return data
    }
  } catch (e) {
    ctx.log.warn(
      `[IPFS] ERROR CID: ${cid} TRY ${(e as Error).message}`
    )
  }
  return null
}


processor.run(new TypeormDatabase(), async (ctx) => {
  for (let c of ctx.blocks) {
    for (let i of c.items) {
      // track and decode NFT events to get CID
      // use fetchMetadata() to fetch metadata
    }
  }
})

You can sign up for a free Filebase account to get started with your IPFS journey today.

If you have any questions, please join our Discord server, or send us an email at hello@filebase.com.