In a vending machine contains a set of products what are the Restful APIs you will design

Share post:

In a vending machine contains a set of products what are the Restful APIs you will design

A vending machine contains a set of products what are the Restful APIs you will design?

Further follow-up questions::

If the payment process is successful and the inventory is updated, how will the balance get back to the customer?

What are the other scenarios one is I answer that if he asked for the latte and by mistake, the cappuccino get delivered he wants to cancel the order

in that cancellation what are the scenarios will cover first need to check whether the transaction is processed it's authorized one or not, once after this payment, in this case, two places need to be updated when is the payment database and the inventory database

what is the inventory is reduced okay then the customer will get the money back to his wallet so once we can get the credit into the wallet otherwise we can get the money answer refund?

 

 

  • List the products available
  • Find a particular item and see the details
  • Search
  • Buy— /itemid/ 
    • post /item —
  • Cancel-

Smashplus

Insights

Share post: