easy-svg-pro/v1/sets/purge
Deletes up to 10 icon sets from the trash for good.
REST endpoint, Easy SVG Pro, Status: Public, defined in includes/core/rest/sets.php
Usage
POST /wp-json/easy-svg-pro/v1/sets/purge
Example
curl -u admin:app-password -H 'Content-Type: application/json' -d '{"ids":[42]}' https://example.com/wp-json/easy-svg-pro/v1/sets/purge
Description
Only sets that are in the trash are deleted: an id of a live set, or of any other post, is reported in missed and never touched. Each id also needs delete_post for that set, so a set shared with the network still needs the network's administrator. Deleting a set removes its folder of files too, so one request takes at most 10 ids; more answer 400 easy_svg_pro_too_many_sets. One purge runs at a time: a second request while one runs answers 409 easy_svg_pro_purge_running.
Permission: permission_callback is rest_permission(): manage_options, an active license, the free plugin's icon library and the Collections feature (sets) switched on under Settings, Features. WordPress checks the required parameters before the permission callback, so a request that lacks one answers 400 rest_missing_callback_param, a guest's request too, not 401.
Parameters
Trashed sets to delete for good, 1 to 10.
Return value
purged (ids deleted), count and missed (ids that were not a trashed set or could not be deleted).
Response
{
"purged": [42],
"count": 1,
"missed": []
}