Delete an account from the service
Opened this issue · 0 comments
fab7 commented
As a User
I need a delete service
So that I can delete a customer account
Details and Assumptions
* It is implemented using the DELETE method and has a path parameter specifying the id of the account to delete.
* Delete should use Account.find() to find the account.
* If the account is not found, it should do nothing.
* If the account is found, it should call the delete() method on the account instance to delete it from the database.
* It should return an empty body "" with a return code of HTTP_204_NO_CONTENT.
Acceptance Criteria
gherkin
Given a user account `id`
When a delete request is issued
Then the account must be removed and an empty body with status of 204_NO_CONTENT is returned if the request is completed successfully.
Else It should return 404_NOT_FOUND if the account cannot be found.