collection.remove
Description
Remove xWGs from collection.
You can either remove one collection entry by specifying the combination of date and year of collection together with xWG ID or you can delete only collected flag for the xWG if you don't have additional collection information available for that particular xWG.
If you want to remove only collected flag, you cannot have any additional collection information available.
To remove all collection information together with collected flag, you must specify the removeAll attribute for the xWG. In that case, all collection entries will be removed, together with the collected flag.
This is precaution to protect users from accidentaly removing all collection information using simple method call.
Params
- token
- string
-
Access token.
- items
- array
-
List of xWGs to uncollect.
- item
- struct
-
- xwgId
- int
-
ID of xWG to uncollect.
- removeAll
- bool
- optional
- excludes: year, date
-
Remove all collection entries for this xWG.
- date
- date
- optional
- requires: year
- excludes: removeAll
-
Remove collection entry from this date and year combination
- year
- int
- optional
- requires: date
- excludes: removeAll
-
Remove collection entry from this year and date combination
Response
Call example
collection.remove("officia deserunt", [{"xwgId": 1993825773, "removeAll": false, "date": 2024-09-29, "year": 1938792981}])