File tree Expand file tree Collapse file tree 1 file changed +57
-0
lines changed
Expand file tree Collapse file tree 1 file changed +57
-0
lines changed Original file line number Diff line number Diff line change 33123312 }
33133313 ]
33143314 }
3315+ },
3316+ "/{restaurant_id}/kpi/ordersCount" : {
3317+ "get" : {
3318+ "tags" : [" KPI" ],
3319+ "summary" : " Count the number of orders in a given interval, with optional grouping by time slot." ,
3320+ "parameters" : [
3321+ {
3322+ "name" : " restaurant_id" ,
3323+ "in" : " path" ,
3324+ "description" : " ID of the restaurant" ,
3325+ "required" : true ,
3326+ "schema" : { "type" : " integer" }
3327+ },
3328+ {
3329+ "name" : " timeBegin" ,
3330+ "in" : " query" ,
3331+ "description" : " Start date/time of the interval (ISO 8601)" ,
3332+ "required" : true ,
3333+ "schema" : { "type" : " string" , "format" : " date-time" }
3334+ },
3335+ {
3336+ "name" : " timeEnd" ,
3337+ "in" : " query" ,
3338+ "description" : " End date/time of the interval (ISO 8601)" ,
3339+ "required" : true ,
3340+ "schema" : { "type" : " string" , "format" : " date-time" }
3341+ },
3342+ {
3343+ "name" : " breakdown" ,
3344+ "in" : " query" ,
3345+ "description" : " Slot duration in minutes for grouping (optional)" ,
3346+ "required" : false ,
3347+ "schema" : { "type" : " integer" }
3348+ }
3349+ ],
3350+ "responses" : {
3351+ "200" : {
3352+ "description" : " Returns either the total number of orders, or an object grouped by time slot." ,
3353+ "content" : {
3354+ "application/json" : {
3355+ "examples" : {
3356+ "Grouped" : {
3357+ "value" : { "00:00" : 5 , "00:15" : 8 }
3358+ },
3359+ "Total" : {
3360+ "value" : 23
3361+ }
3362+ }
3363+ }
3364+ }
3365+ },
3366+ "400" : { "description" : " Invalid parameters" },
3367+ "401" : { "$ref" : " #/components/responses/Unauthorized" },
3368+ "5XX" : { "$ref" : " #/components/responses/ServerError" }
3369+ },
3370+ "security" : [{ "BearerAuth" : [] }]
3371+ }
33153372 }
33163373 },
33173374 "components" : {
You can’t perform that action at this time.
0 commit comments