Skip to main content
Version: v4.5

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.

ParameterRequiredTypeDescription
compositeItemYesNamedUserItemPass the named composite item you want to purge as a NamedUserItem object.
nsProviderYes(UserGroup | Workspace)Pass the named file collection's namespace provider, which is either a UserGroup or Workspace object.
ctxNoCtxContext, such as namespaces and authentication token information.
Returns

Promise<void> -

Examples
const res = await IafPurge.purgeCompositeItem(compositeItem, nsProvider);

purgeCompositeItemVersion#

Permanently deletes all collections and files related to the composite item's version.

ParameterRequiredTypeDescription
compositeItemYesNamedUserItemPass the NamedCompositeItem you want to purge.
versionIdYesStringPass the version id of the NamedCompositeItem you want to permanently delete.
nsProviderYes(UserGroup | Workspace)Pass the NamedCompositeItem's namespace provider, which is either a UserGroup or Workspace object.
ctxNoCtxContext, such as namespaces and authentication token information.
Returns

Promise<void> -

Examples
const res = await IafPurge.purgeCompositeItemVersion(compositeItem, versionId, nsProvider);

purgeFileCollection#

Permanently deletes a NamedFileCollection and its files in the File Service.

ParameterRequiredTypeDescription
fileCollectionYesNamedFileCollectionPass the NamedFileCollection you want to purge.
nsProviderYes(UserGroup | Workspace)Pass the NamedFileCollection's namespace provider, which is either a UserGroup or Workspace object.
ctxNoCtxContext, such as namespaces and authentication token information.
Returns

Promise<void> -

Examples
const response = await IafPurge.purgeFileCollection(fileCollection, nsProvider);

purgeFileCollectionVersion#

Permanently deletes a NamedFileCollection version and its files in the File Service.

ParameterRequiredTypeDescription
fileCollectionYesNamedFileCollectionPass the NamedFileCollection you want to purge.
versionIdYesStringPass the version id of the NamedFileCollection you want to permanently delete.
nsProviderYes(UserGroup | Workspace)Pass the NamedFileCollection's namespace provider, which is either a UserGroup or Workspace object.
ctxNoCtxContext, such as namespaces and authentication token information.
Returns

Promise<void> -

Examples
const response = await IafPurge.purgeFileCollectionVersion(fileCollection, versionId, nsProvider);