Published
Edited
Feb 2, 2021
Insert cell
Insert cell
cids = [
"Qmf9xtSWiHC7G5jxG1kLTffWfDxWvTiH6SJ8qFKyNZq5kg"
]
Insert cell
data = Object.fromEntries(await Promise.all(cids.map(async x => {
const res = await fetch(`https://filecoin.tools/api/deals/${x}?page=1&per_page=20`)
const json = await res.json()
return [x, json.Deals.map(d => d.DealInfo)]
})))
Insert cell
cidMap = Object.fromEntries(Object.entries(data).map(([key, val]) => [key, val.map(d => ({provider: d.Proposal.Provider, client: d.Proposal.Client}))]))
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more