@@ -169,7 +169,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
169169 // Models Endpoints
170170 {
171171 // PullModel
172- Json::Value& pull = spec[" paths" ][" /models/pull" ][" post" ];
172+ Json::Value& pull = spec[" paths" ][" /v1/ models/pull" ][" post" ];
173173 pull[" summary" ] = " Pull a model" ;
174174 pull[" requestBody" ][" content" ][" application/json" ][" schema" ][" type" ] =
175175 " object" ;
@@ -183,15 +183,15 @@ Json::Value SwaggerController::generateOpenAPISpec() {
183183 pull[" responses" ][" 400" ][" description" ] = " Bad request" ;
184184
185185 // ListModel
186- Json::Value& list = spec[" paths" ][" /models" ][" get" ];
186+ Json::Value& list = spec[" paths" ][" /v1/ models" ][" get" ];
187187 list[" summary" ] = " List all models" ;
188188 list[" responses" ][" 200" ][" description" ] =
189189 " List of models retrieved successfully" ;
190190 list[" responses" ][" 400" ][" description" ] =
191191 " Failed to get list model information" ;
192192
193193 // GetModel
194- Json::Value& get = spec[" paths" ][" /models/{model}" ][" get" ];
194+ Json::Value& get = spec[" paths" ][" /v1/ models/{model}" ][" get" ];
195195 get[" summary" ] = " Get model details" ;
196196 get[" parameters" ][0 ][" name" ] = " model" ;
197197 get[" parameters" ][0 ][" in" ] = " path" ;
@@ -211,7 +211,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
211211 [" message" ][" type" ] = " string" ;
212212
213213 // UpdateModel Endpoint
214- Json::Value& update = spec[" paths" ][" /models/{model}" ][" post" ];
214+ Json::Value& update = spec[" paths" ][" /v1/ models/{model}" ][" post" ];
215215 update[" summary" ] = " Update model details" ;
216216 update[" description" ] =
217217 " Update various attributes of a model based on the ModelConfig "
@@ -398,7 +398,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
398398 " Detailed error message" ;
399399
400400 // ImportModel
401- Json::Value& import = spec[" paths" ][" /models/import" ][" post" ];
401+ Json::Value& import = spec[" paths" ][" /v1/ models/import" ][" post" ];
402402 import [" summary" ] = " Import a model" ;
403403 import [" requestBody" ][" content" ][" application/json" ][" schema" ][" type" ] =
404404 " object" ;
@@ -416,7 +416,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
416416 import [" responses" ][" 400" ][" description" ] = " Failed to import model" ;
417417
418418 // DeleteModel
419- Json::Value& del = spec[" paths" ][" /models/{model}" ][" delete" ];
419+ Json::Value& del = spec[" paths" ][" /v1/ models/{model}" ][" delete" ];
420420 del[" summary" ] = " Delete a model" ;
421421 del[" parameters" ][0 ][" name" ] = " model" ;
422422 del[" parameters" ][0 ][" in" ] = " path" ;
@@ -426,7 +426,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
426426 del[" responses" ][" 400" ][" description" ] = " Failed to delete model" ;
427427
428428 // SetModelAlias
429- Json::Value& alias = spec[" paths" ][" /models/alias" ][" post" ];
429+ Json::Value& alias = spec[" paths" ][" /v1/ models/alias" ][" post" ];
430430 alias[" summary" ] = " Set model alias" ;
431431 alias[" requestBody" ][" content" ][" application/json" ][" schema" ][" type" ] =
432432 " object" ;
@@ -444,7 +444,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
444444 alias[" responses" ][" 400" ][" description" ] = " Failed to set model alias" ;
445445
446446 // Start Model
447- Json::Value& start = spec[" paths" ][" /models/start" ][" post" ];
447+ Json::Value& start = spec[" paths" ][" /v1/ models/start" ][" post" ];
448448 start[" summary" ] = " Start model" ;
449449 start[" requestBody" ][" content" ][" application/json" ][" schema" ][" type" ] =
450450 " object" ;
@@ -458,7 +458,7 @@ Json::Value SwaggerController::generateOpenAPISpec() {
458458 start[" responses" ][" 400" ][" description" ] = " Failed to start model" ;
459459
460460 // Stop Model
461- Json::Value& stop = spec[" paths" ][" /models/stop" ][" post" ];
461+ Json::Value& stop = spec[" paths" ][" /v1/ models/stop" ][" post" ];
462462 stop[" summary" ] = " Stop model" ;
463463 stop[" requestBody" ][" content" ][" application/json" ][" schema" ][" type" ] =
464464 " object" ;
0 commit comments