0

I want to create an extension to delete all financial contributions from the database. The database only contains simple contributions that are not tied to memberships or events.

The developers guide suggests using the Order API for adding, updating and deleting orders and the underlying financial entities.

However, when I try to delete an order using APIv3 explorer I get an exception 'Only test orders can be deleted'. In APIv4, the Order entity does not seem to exist.

What would be the recommended approach to delete the financial contributions via the API?

1 Answer 1

1

You can use the Contribution Delete API to delete the contribution.

enter image description here

2
  • Will this also delete the underlying financial data (line items, financial items, transaction items) associated with the contribution or only the contribution itself?
    – cray146
    Commented Oct 17, 2023 at 14:22
  • Yes it should... Commented Oct 17, 2023 at 16:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.