Downloads
Note : BLC means Blacklist Criteria
Add download to queue
addDownloads
Operator user required Frontend can be closed, restricted or open
Add a series of download items to the download queue. Download queue starts as soon as items are in it.
[
{
kid: '1b15d050-0394-4f55-ae07-ea2b014b90e8',
// name is what's displayed in the queue
name: 'ENG - Daft Punk - MV - Harder better faster stronger',
size: 123901239,
repository: 'kara.moe'
},
...
]
{
code: 'DOWNLOADS_QUEUED',
data: 1 //number of songs queued
}
{
code: 409,
message: {
code: 'DOWNLOADS_QUEUED_ALREADY_ADDED_ERROR'
}
}
Get download queue status
getDownloadQueueStatus
Operator user required Frontend can be closed, restricted or open
Receive a string giving you the status of the download queue.
Possible responses :
stopped
started
paused
updated
Get queued downloads
getDownloads
Authentication needed Frontend needs to be restricted or open
Get the list of downloads currently in queue.
Possible statuses for downloads :
DL_RUNNING
: Currently being downloadedDL_PLANNED
: In queue, planned for downloadDL_DONE
: Download successfulDL_FAILED
: Download failed
[
{
name: "ENG - Cowboy Bebop - OP - Tank",
urls: {
media: {
remote: "http://xxx/downloads/ENG - Cowboy Bebop - OP - Tank.mp4",
local: "ENG - Cowboy Bebop - OP - Tank.mp4"
}
...
},
size: 12931930,
uuid: "3e1efc1c-e289-4445-8637-b944a6b00c6f",
started_at: 2019-12-31T01:21:00
status: "DL_PLANNED"
},
...
]
{
code: 500,
message: {
code: 'DOWNLOADS_GET_ERROR'
}
}
Wipe download queue
deleteDownloads
Operator user required Frontend needs to be open
Remove ALL downloads from queue
Just resolves in case of success.
{
code: 500,
message: {
code: 'DOWNLOADS_WIPE_ERROR'
}
}
Pause download queue
pauseQueue
Operator user required Frontend needs to be open
Pauses download queue. The currently downloading item will need to finish though as it cannot be aborted.
Just resolves in case of success.
{
code: 500,
message: {
code: 'DOWNLOADS_PAUSE_ERROR'
}
}
Start download queue
startDownloadQueue
Operator user required Frontend needs to be open
{
code: 'DOWNLOADS_STARTED'
}
{
code: 'DOWNLOAD_START_ERROR'
}
Sync only medias from remote repositories
updateAllMedias
Authentication needed Frontend needs to be open
This action will only download all medias from configured repositories. It will not download any karaoke metadata or lyrics.
This is useful if you are keeping your songs/lyrics synced via git or any other mean and only want to update medias.
This downloads new/updated medias, and removes old ones.
This is done asynchronously.
{
code: 'UPDATING_MEDIAS_IN_PROGRESS'
}