IafPurge
Use the IafPurge API to to purge the following Item Service classes: NamedCompositeItem, NamedFileCollections, and their versions.
purgeCompositeItem#
Permanently deletes all items related to a NamedCompositeItem.
| Parameter | Required | Type | Description |
|---|---|---|---|
| compositeItem | Yes | NamedUserItem | Pass the named composite item you want to purge as a NamedUserItem object. |
| nsProvider | Yes | (UserGroup | Workspace) | Pass the named file collection's namespace provider, which is either a UserGroup or Workspace object. |
| ctx | No | Ctx | Context, such as namespaces and authentication token information. |
Returns
Examples
const res = await IafPurge.purgeCompositeItem(compositeItem, nsProvider);purgeCompositeItemVersion#
Permanently deletes all collections and files related to the composite item's version.
| Parameter | Required | Type | Description |
|---|---|---|---|
| compositeItem | Yes | NamedUserItem | Pass the NamedCompositeItem you want to purge. |
| versionId | Yes | String | Pass the version id of the NamedCompositeItem you want to permanently delete. |
| nsProvider | Yes | (UserGroup | Workspace) | Pass the NamedCompositeItem's namespace provider, which is either a UserGroup or Workspace object. |
| ctx | No | Ctx | Context, such as namespaces and authentication token information. |
Returns
Examples
const res = await IafPurge.purgeCompositeItemVersion(compositeItem, versionId, nsProvider);purgeFileCollection#
Permanently deletes a NamedFileCollection and its files in the File Service.
| Parameter | Required | Type | Description |
|---|---|---|---|
| fileCollection | Yes | NamedFileCollection | Pass the NamedFileCollection you want to purge. |
| nsProvider | Yes | (UserGroup | Workspace) | Pass the NamedFileCollection's namespace provider, which is either a UserGroup or Workspace object. |
| ctx | No | Ctx | Context, such as namespaces and authentication token information. |
Returns
Examples
const response = await IafPurge.purgeFileCollection(fileCollection, nsProvider);purgeFileCollectionVersion#
Permanently deletes a NamedFileCollection version and its files in the File Service.
| Parameter | Required | Type | Description |
|---|---|---|---|
| fileCollection | Yes | NamedFileCollection | Pass the NamedFileCollection you want to purge. |
| versionId | Yes | String | Pass the version id of the NamedFileCollection you want to permanently delete. |
| nsProvider | Yes | (UserGroup | Workspace) | Pass the NamedFileCollection's namespace provider, which is either a UserGroup or Workspace object. |
| ctx | No | Ctx | Context, such as namespaces and authentication token information. |
Returns
Examples
const response = await IafPurge.purgeFileCollectionVersion(fileCollection, versionId, nsProvider);