@@ -69,7 +69,7 @@ responses, [check out the DTOs here](/src/main/kotlin/com/example/dto).
6969- ** POST** ` /orders/{userId}/items `
7070 - Adds a food item to the user's order.
7171 - ** Path** : ` userId ` (UUID as string)
72- - ** Body** : ` FoodDto ` (JSON )
72+ - ** Body** : ` foodId ` (Integer )
7373 - ** Response** : ` 200 OK ` with order ID, ` 500 Internal Server Error ` with error message.
7474
7575### Update Order Item Quantity
@@ -87,6 +87,24 @@ responses, [check out the DTOs here](/src/main/kotlin/com/example/dto).
8787 - ** Path** : ` userId ` (UUID as string)
8888 - ** Response** : ` 200 OK ` with order details, ` 404 Not Found ` with error message.
8989
90+ ### Get All Order
91+ - ** GET** ` /orders/{userId}/all `
92+ - Retrieves all orders for the specified user.
93+ - ** Path** : ` userId ` (UUID as string)
94+ - ** Response** : ` 200 OK ` with a list of all orders, ` 404 Not Found ` with error message if no orders are found.
95+
96+ ### Get All Order as Flow
97+ - ** GET** ` /orders/{userId}/all/flow `
98+ - Retrieves a real-time flow of all orders for the specified user.
99+ - ** Path** : ` userId ` (UUID as string)
100+ - ** Response** : ` 200 OK ` with a flow of orders, ` 404 Not Found ` with error message if no orders are found.
101+
102+ ### Get Active Order as Flow
103+ - ** GET** ` /orders/{userId}/order/flow `
104+ - Retrieves a real-time flow of the user's active order.
105+ - ** Path** : ` userId ` (UUID as string)
106+ - ** Response** : ` 200 OK ` with a flow of the active order, ` 404 Not Found ` with error message if no active order is found.
107+
90108### Complete Order
91109
92110- ** GET** ` /orders/{userId}/complete `
@@ -108,6 +126,20 @@ responses, [check out the DTOs here](/src/main/kotlin/com/example/dto).
108126 - ** Path** : ` userId ` (UUID as string), ` orderId ` (Integer)
109127 - ** Response** : ` 200 OK ` with deletion status, ` 500 Internal Server Error ` with error message.
110128
129+ ### Get All Orders
130+
131+ - ** GET** ` /orders/{userId}/all `
132+ - Retrieves all orders for the specified user.
133+ - ** Path** : ` userId ` (UUID as string)
134+ - ** Response** : ` 200 OK ` with a list of all orders, ` 404 Not Found ` with error message if no orders are found.
135+
136+ ### Get All Orders as Flow
137+
138+ - ** GET** ` /orders/{userId}/all/flow `
139+ - Retrieves a real-time flow of all orders for the specified user.
140+ - ** Path** : ` userId ` (UUID as string)
141+ - ** Response** : ` 200 OK ` with a flow of orders, ` 404 Not Found ` with error message if no orders are found.
142+
111143## Food API Endpoints
112144
113145### Get Food Details
@@ -131,16 +163,6 @@ responses, [check out the DTOs here](/src/main/kotlin/com/example/dto).
131163 - ** Query** : ` type ` (String, optional) - Category type, defaults to "all".
132164 - ** Response** : ` 200 OK ` with foods by category, ` 404 Not Found ` with error message.
133165
134- ### Get All Orders
135-
136- - ** GET** ` /orders/{userId}/all `
137- - Retrieves all orders for the specified user.
138- - ** Path** : ` userId ` (UUID as string)
139- - ** Response** : ` 200 OK ` with a list of all orders, ` 404 Not Found ` with error message if no orders are found.
140-
141- ### Get All Orders as Flow
142-
143- - ** GET** ` /orders/{userId}/all/flow `
144- - Retrieves a real-time flow of all orders for the specified user.
145- - ** Path** : ` userId ` (UUID as string)
146- - ** Response** : ` 200 OK ` with a flow of orders, ` 404 Not Found ` with error message if no orders are found.
166+ - ** GET** ` /foods/categories/list `
167+ - Retrieves a list of all food categories.
168+ - ** Response** : ` 200 OK ` with list of food categories, ` 404 Not Found ` with error message.
0 commit comments