DataONEorg / bookkeeper

Bookkeeper keeps track of DataONE product subscriptions and quotas for researchers using the extended services.
Other
1 stars 2 forks source link

The delete usage method doesn't return a boolean result #49

Closed taojing2002 closed 4 years ago

taojing2002 commented 4 years ago

In our design document, the delete usage method should return a boolean result. However, it return a blank string.

gothub commented 4 years ago

@taojing2002 the delete usage service returns an HTTP status of 200 if the request is successful, or an error status if it isn't successful. Is that sufficient?

taojing2002 commented 4 years ago

@gothub To me, it is fine. I just concern it doesn't match our design document -

boolean   = deleteUsage():  DELETE  /usage/:id

If we all have an agreement that we don't need to return the boolean, it is totally fine to me.

gothub commented 4 years ago

@taojing2002 The bookkeeper delete methods for all resources ("customers", "products", ...) all return HTTP 200 on success, so I'd say let's go with that.

I just opened issue #50 for creating a Swagger definition for the bookkeeper API. When this is created, this should be the reference for the bookkeeper API.