Match files to a TV show's episodes
POST
/tv/series/{id}/import/plan/write Change: creates or edits. Scopes
Lists the files at a source and says which season and episode each looks like; nothing is created. source: node (server and a path in its incoming folder), s3 (storage and a path prefix), url (urls, one link per line) or upload (files: [{name, size}]). Send the reviewed list to …/import/.
Path parameters
idstring (uuid)requiredThe TV show's id.
Body
sourcestringrequirednode- nodes3- s3url- urlupload- upload
One of:
"node""s3""url""upload"serverstring (uuid)can be nullstoragestring (uuid)can be nullpathstringurlsstringfilesobject[]
Response
200 OK
itemsobject[]requiredrefstringrequiredWhat to send back in
items: a path, key or link.namestringrequiredsizeintegerrequiredseasonintegerrequiredcan be nullepisodeintegerrequiredcan be nullmatchedbooleanrequiredA season and episode were read from it.
duplicatebooleanrequiredAn earlier file claims the same episode.
existingobjectrequiredcan be nullThe episode the show already has there.
idstring (uuid)requirednamestringrequiredmediastringrequiredcan be nullIts file's state, null without one.
ignoredintegerrequiredFiles left out: not video files.
truncatedbooleanrequiredThe source holds more than
limitfiles.limitintegerrequired
Errors
- 400 Something sent is not valid. Each field that is wrong is named with what is wrong.
- 401 No credential, or one that is wrong, expired or revoked.
- 403 The account, or the key's or app's scopes, may not do this.
- 404 Nothing with this id, or nothing the account can see.
- 429 Slow down: wait the seconds in the Retry-After header, then try again.
- 502 The server or the bucket could not be read.