I understand rest as url pointing to resources, without verbs, for example:
query a member information: get / api/users/:id
query an order information: get / api/orders/:id
question:
1. If you need to display user information and order information at the same time:
if the front end adjusts the API to spell data separately, it will send a lot of requests and degrade performance. And if there are too many connections, it will be very difficult to deal with.
if the backend provides a new interface, it seems to go against the original intention of rest (as I understand it). As the demand increases, there are many bizarre interfaces / api/users/orders
, / api/users/orders/products
?
2. How are some verbs designed? Such as start tasks, kill processes?