Skip to main content

Archiving and deactivating clients

For archiving a client, we have the following mutation available;

mutation archiveCase($id: ID!, $timeEffectiveArchivalDate: Int!) {
archiveCase(id: $id, timeEffectiveArchivalDate: $timeEffectiveArchivalDate) {
success
}
}

More documentation for the specific mutation can be found here.

The mutation can be called as follows:

public async archiveCase(caseId: string, timeOfArchival: number)
{
return this.gqlClient.mutate({
mutation: ArchiveCase,
variables: {
id: caseId,
timeEffectiveArchivalDate: timeOfArchival,
},
});
}

The same logic can be applied when deactivating cases, using this mutation instead;

mutation deactivateCase($id: ID!, $timeEffectiveDeactivationDate: Int!) {
deactivateCase(id: $id, timeEffectiveDeactivationDate: $timeEffectiveDeactivationDate) {
success
}
}