Skip to content
piecemeal
Esc
↑↓navigate↵open⌘Jpreview

Act on several torrents

POST/torrents/actions
Authorization
AuthorizationBearer token · headerrequired

An API key, pm_....

or
piecemeal_sessionAPI key · cookierequired
Request body
requiredapplication/json
actionstringrequired
Allowed:startstopforceStartrecheckreannounceremovesetCategoryaddTagsremoveTagsmovesetIncompletePathsetAutoManagedqueueTopqueueBottomqueueUpqueueDown
autoManagedboolean

With setAutoManaged: on or off.

categorystring

With setCategory; empty removes the category.

deleteDataboolean

With remove: also delete the files.

hashesstring[] | nullrequired

Infohashes, or ["all"].

min items 1
incompletePathstring

With setIncompletePath: the incomplete folder, empty for none. With move: also change the incomplete folder, in the same move.

savePathstring

With move: where to move the data; empty keeps the save path when incompletePath is given.

tagsstring[] | null

With addTags and removeTags; removeTags without tags removes all.

Responses
204

No Content

401

Unauthorized

detailstring

A human-readable explanation specific to this occurrence of the problem.

errorsErrorDetail[] | null

Optional list of individual error details

Show properties
Array of ErrorDetail
locationstring

Where the error occurred, e.g. 'body.items[3].tags' or 'path.thing-id'

messagestring

Error message text

valueany

The value at the given location

instancestring<uri>

A URI reference that identifies the specific occurrence of the problem.

statusinteger<int64>

HTTP status code

titlestring

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

typestring<uri>

A URI reference to human-readable documentation for the error.

default: "about:blank"
403

Forbidden

detailstring

A human-readable explanation specific to this occurrence of the problem.

errorsErrorDetail[] | null

Optional list of individual error details

Show properties
Array of ErrorDetail
locationstring

Where the error occurred, e.g. 'body.items[3].tags' or 'path.thing-id'

messagestring

Error message text

valueany

The value at the given location

instancestring<uri>

A URI reference that identifies the specific occurrence of the problem.

statusinteger<int64>

HTTP status code

titlestring

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

typestring<uri>

A URI reference to human-readable documentation for the error.

default: "about:blank"
422

Unprocessable Entity

detailstring

A human-readable explanation specific to this occurrence of the problem.

errorsErrorDetail[] | null

Optional list of individual error details

Show properties
Array of ErrorDetail
locationstring

Where the error occurred, e.g. 'body.items[3].tags' or 'path.thing-id'

messagestring

Error message text

valueany

The value at the given location

instancestring<uri>

A URI reference that identifies the specific occurrence of the problem.

statusinteger<int64>

HTTP status code

titlestring

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

typestring<uri>

A URI reference to human-readable documentation for the error.

default: "about:blank"
500

Internal Server Error

detailstring

A human-readable explanation specific to this occurrence of the problem.

errorsErrorDetail[] | null

Optional list of individual error details

Show properties
Array of ErrorDetail
locationstring

Where the error occurred, e.g. 'body.items[3].tags' or 'path.thing-id'

messagestring

Error message text

valueany

The value at the given location

instancestring<uri>

A URI reference that identifies the specific occurrence of the problem.

statusinteger<int64>

HTTP status code

titlestring

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

typestring<uri>

A URI reference to human-readable documentation for the error.

default: "about:blank"
Request
curl -X POST 'https://piecemeal.example.com/api/piecemeal/v1/torrents/actions' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/problem+json' \
  -H 'Content-Type: application/json' \
  -d '{
  "action": "start",
  "autoManaged": true,
  "category": "string",
  "deleteData": true,
  "hashes": [
    "string"
  ],
  "incompletePath": "string",
  "savePath": "string",
  "tags": [
    "string"
  ]
}'
Response
No Content

Was this page helpful?