We built a frame that lets you discover, play and collect music while scrolling, without ever leaving Warpcast! Works for almost every music NFT across Base, Optimism and Zora. (Play feature is iOS only for now)
This project is an integration with Spinamp, a music NFT app.
You can share a link to any track on Spinamp and it will generate a frame that lets you both play and collect the NFT from the frame.
For playing music, when you press the Play button you'll immediately get a notification popup at the top of your phone that you can hold to start playing the song. Then collect the NFT via a frame transaction if you like it, or keep scrolling and find another :).
Two more things:
We use frames.js for our frame. When first loading the frame, we use Spinamp's APIs to get details about the track metadata/image to render it and show a Play button and Collect button.
The Play button sends a frame action and our frame server checks the address and sees if there is a match across Spinamp's users for that same address. If there's a match, we send a notification via Spinamp's notifications API to play the song and the user gets a super quick and easy notification they can press without leaving the app to play the song. If there's no match, we show a frame that explains Spinamp and suggests the user downloads it.
We integrate with Spinamp's mint API to get transaction details for the frame so that the NFT can be collected using a frame transaction too.
This works for all content on Spinamp across different chains including Base, Optimism and Zora and across multiple different NFT platforms that Spinamp aggregates.