Hi!
I’ve got a resource of type payment-method
with attribute default
. If I PATCH
a payment method to be default: true
, then all other payment methods that belong to that user
become default: false
. There can only be one default payment method per user.
I’m struggling with the response from that PATCH
. Do I only respond with the specific record I requested to change, or do I return all of the affected payment methods?
Responding with only the specific record PATCH
ed seems logical, but then consumers of the API have to know that piece of business logic. Right now the app that uses this endpoint just does a GET
for all of the user’s payment methods immediately after PATCH
ing any of them.