Builder for app.rocksky.song.createSong.
Example
alias Rocksky.Song.Builder, as: Song
Song.new(title: "Lithium", artist: "Nirvana")
|> Song.album("Nevermind")
|> Song.duration(257_000)
|> Song.isrc("USDW19811234")
|> Song.submit(client)
Summary
Functions
Set album on the builder.
Set albumArt on the builder.
Set albumArtist on the builder.
Set artist on the builder.
Set discNumber on the builder.
Set duration on the builder.
Set isrc on the builder.
Set lyrics on the builder.
Set mbId on the builder.
Build a new request from a keyword list or map of fields.
Batch-set fields. attrs is a keyword list or map. Accepts the same
key forms as new/1.
Set releaseDate on the builder.
Submit the builder. Returns {:ok, body} on success or
{:error, %Rocksky.Error{}} on failure.
Set title on the builder.
Return the JSON body that would be sent (nil fields stripped).
Set trackNumber on the builder.
Set year on the builder.
Types
Functions
Set album on the builder.
Set albumArt on the builder.
Set albumArtist on the builder.
Set artist on the builder.
Set discNumber on the builder.
Set duration on the builder.
Set isrc on the builder.
Set lyrics on the builder.
Set mbId on the builder.
Build a new request from a keyword list or map of fields.
Accepts either the canonical lexicon key (:mbId) or its snake-cased
equivalent (:mb_id). Unknown keys raise.
Batch-set fields. attrs is a keyword list or map. Accepts the same
key forms as new/1.
Set releaseDate on the builder.
@spec submit(t(), Rocksky.Client.t()) :: {:ok, term()} | {:error, Rocksky.Error.t()}
Submit the builder. Returns {:ok, body} on success or
{:error, %Rocksky.Error{}} on failure.
Returns {:error, %Rocksky.Error{reason: :missing_fields}} without
making a network call when any required field is nil.
Set title on the builder.
Return the JSON body that would be sent (nil fields stripped).
Set trackNumber on the builder.
Set year on the builder.