Set the sorting rules for imports
PUT
/streams/sort/rules/write Change: creates or edits. Scopes
Replaces the rules that sort what playlist imports add; an empty list stops sorting them. Panel operators only. Each rule matches names that start with, contain or end with text and puts them in category, or in a category named new_category made for it. With unlist_old (the default) a stream leaves the category it was in.
Body
rulesobject[]requiredmatchstringDefault:
"starts"textstringrequiredcategorystring (uuid)can be nullnew_categorystring
Response
200 OK
rulesobject[]requiredmatchstringrequiredstarts- startscontains- containsends- endspattern- pattern
One of:
"starts""contains""ends""pattern"textstringrequiredcategorystring (uuid)requiredcategory_namestringrequiredread-only
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.
- 429 Slow down: wait the seconds in the Retry-After header, then try again.