6 ms·
> to create a payment object? resource. Also, not sure what's up with TFA's strawmanning, PATCH /orders/42 # with { order: { paid: true } } PATCH /o
by masklinn 15y ago
> to create a payment object?
resource.
Also, not sure what's up with TFA's strawmanning,
PATCH /orders/42 # with { order: { paid: true } }
PATCH /orders/42 # with { order: { shipped: true } }
looks like RPC update calls (hey let's map our Ruby attribute updates to HTTP calls, yay!) more than RESTful calls.
Also, not sure why a payment resource would be conceptually "within" an order (although that's got little to do with RESTfullness): why not POST to /payments?order=42? Which would return a link to e.g. /payments/2345 for your actual payment resource?
Something similar to http://blog.steveklabnik.com/posts/2011-07-03-nobody-understands-rest-or-https http://blog.steveklabnik.com/posts/2011-07-03-nobody-underst... transaction resources.