1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2024-12-21 23:32:27 +00:00
5 Command
Qstick edited this page 2018-09-22 05:11:39 -04:00

GET

api/v1/command
api/v1/command/{id}
Summary

Queries the status of a previously started command, or all currently started commands.

Parameters

Required: None

Optional: id (int) Unique ID of the command

Returns

For api/v1/command

An array of JSON objects

For api/command/{id}

{
  "name": "RescanArtist",
  "startedOn": "0001-01-01T00:00:00Z",
  "stateChangeTime": "2014-02-05T05:09:09.2366139Z",
  "sendUpdatesToClient": true,
  "status": "pending",
  "id": 24
}

POST

Summary

Publish a new command for Lidarr to run.

These commands are executed asynchronously; use GET to retrieve the current status.

And, remember, all POST/PUT requests require all parameters to be JSON encoded in the body, unless otherwise noted.

Parameters

Required: name (string)

Returns
{
  "name": "RescanArtist",
  "startedOn": "0001-01-01T00:00:00Z",
  "stateChangeTime": "2014-02-05T05:09:09.2366139Z",
  "sendUpdatesToClient": true,
  "status": "pending",
  "id": 24
}

Commands

RefreshArtist

Refresh artist information from trakt and rescan disk

Parameters

Optional: artistId (int) - if not set, all artists will be refreshed and scanned


RescanArtist

Refresh rescan disk for a single artist

Parameters

Optional: artistId (int) - if not set all artist will be scanned


AlbumSearch

Search for one or more albums

Parameters

Required: albumIds (int[]) - one or more albumIds in an array


ArtistSearch

Search for all albums by an artist

Parameters

Required: artistId (int)


RssSync

Instruct Lidarr to perform an RSS sync with all enabled indexers

Parameters

None


RenameFiles

Instruct Lidarr to rename the list of files provided

Parameters

files (int[]) List of File IDs to rename


RenameArtist

Instruct Lidarr to rename all files in the provided artist.

Parameters

artistIds (int[]) List of Artist IDs to rename


Backup

Instruct Lidarr to perform a backup of it's database and config file (lidarr.db and config.xml)

Parameters

None