Skip to content

Recycle Bin / Soft Delete

Overview

Some endpoints support a soft-delete pattern, meaning that resources are not immediately deleted. Instead, they're put into a recycle bin (EasyVerein calls that "wastebasket"). These methods provide a way to interact with soft-deleted resources.

Endpoints supporting soft delete

Note that not all endpoints support the soft-delete pattern. Using this Client, only the following endpoints are supported for now:

  • invoice
  • member
  • member-groups
  • contact-details
  • custom-field

Please refer to the offical API documentation for a full list endpoints supporting soft-delete.

Method Reference

get_deleted

get_deleted() -> tuple[list[ModelType], int]

Fetches all deleted resources from the recycle bin and returns a list.

purge

purge(item: ModelType | int)

Finally deletes a given item from the recycle bin. This is irreversible and cannot be undone.

This function can take either an object instance or a numerical id as argument.

Parameters:

Name Type Description Default
item ModelType | int

The id or object that should be deleted.

required