MCPcopy Create free account
hub / github.com/AudiusProject/apps / uploadTrackV2AndWriteToChain

Method uploadTrackV2AndWriteToChain

packages/libs/src/api/Track.ts:357–383  ·  view source on GitHub ↗

* Takes in a readable stream if isServer is true, or a file reference if isServer is * false. * Uploads file, retrieves multihash, adds multihash to input metadata object, * uploads metadata, and finally returns metadata multihash * Wraps the stateless function in AudiusLib. * * @p

(
    userId: number,
    trackFile: File,
    coverArtFile: File,
    metadata: UploadTrackMetadata,
    onProgress: () => void,
    trackId?: number
  )

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls 2

uploadTrackV2Method · 0.95
writeTrackToChainMethod · 0.95

Tested by

no test coverage detected