Repost or unrepost a SoundCloud track. Requires authentication.
An object with repostTrack, unrepostTrack, loading, and error.
repostTrack
unrepostTrack
loading
error
import { useRepost } from "soundcloud-api-ts-next";function RepostButton({ trackId }: { trackId: number }) { const { repostTrack, loading } = useRepost(); return ( <button onClick={() => repostTrack(trackId)} disabled={loading}> 🔁 Repost </button> );} Copy
import { useRepost } from "soundcloud-api-ts-next";function RepostButton({ trackId }: { trackId: number }) { const { repostTrack, loading } = useRepost(); return ( <button onClick={() => repostTrack(trackId)} disabled={loading}> 🔁 Repost </button> );}
Repost or unrepost a SoundCloud track. Requires authentication.