added model templates
This commit is contained in:
@ -1,4 +1,79 @@
|
||||
/model/{name}:
|
||||
/model/groups:
|
||||
get:
|
||||
summary: list all available groups
|
||||
description: 'Auth: basic, levels: read, write, dev, admin'
|
||||
tags:
|
||||
- /model
|
||||
responses:
|
||||
200:
|
||||
description: all groups
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
properties:
|
||||
group:
|
||||
type: string
|
||||
example: VN
|
||||
models:
|
||||
type: array
|
||||
items:
|
||||
$ref: 'api.yaml#/components/schemas/ModelItem'
|
||||
401:
|
||||
$ref: 'api.yaml#/components/responses/401'
|
||||
500:
|
||||
$ref: 'api.yaml#/components/responses/500'
|
||||
|
||||
/model/{group}:
|
||||
parameters:
|
||||
- $ref: 'api.yaml#/components/parameters/Group'
|
||||
post:
|
||||
summary: add/replace model group item
|
||||
description: 'Auth: basic, levels: dev, admin <br> If the given name exists, the item is replaced,
|
||||
otherwise it is newly created'
|
||||
tags:
|
||||
- /model
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: 'api.yaml#/components/schemas/ModelItem'
|
||||
responses:
|
||||
200:
|
||||
$ref: 'api.yaml#/components/responses/Ok'
|
||||
400:
|
||||
$ref: 'api.yaml#/components/responses/400'
|
||||
401:
|
||||
$ref: 'api.yaml#/components/responses/401'
|
||||
403:
|
||||
$ref: 'api.yaml#/components/responses/403'
|
||||
500:
|
||||
$ref: 'api.yaml#/components/responses/500'
|
||||
|
||||
/model/{group}/{name}:
|
||||
parameters:
|
||||
- $ref: 'api.yaml#/components/parameters/Group'
|
||||
- $ref: 'api.yaml#/components/parameters/Name'
|
||||
delete:
|
||||
summary: remove model group item
|
||||
description: 'Auth: basic, levels: dev, admin'
|
||||
tags:
|
||||
- /model
|
||||
responses:
|
||||
200:
|
||||
$ref: 'api.yaml#/components/responses/Ok'
|
||||
401:
|
||||
$ref: 'api.yaml#/components/responses/401'
|
||||
403:
|
||||
$ref: 'api.yaml#/components/responses/403'
|
||||
404:
|
||||
$ref: 'api.yaml#/components/responses/404'
|
||||
500:
|
||||
$ref: 'api.yaml#/components/responses/500'
|
||||
|
||||
/model/file/{name}:
|
||||
parameters:
|
||||
- $ref: 'api.yaml#/components/parameters/Name'
|
||||
get:
|
||||
|
@ -38,4 +38,12 @@ Collection:
|
||||
required: true
|
||||
schema:
|
||||
type: string
|
||||
example: condition
|
||||
example: condition
|
||||
|
||||
Group:
|
||||
name: group
|
||||
in: path
|
||||
required: true
|
||||
schema:
|
||||
type: string
|
||||
example: vn
|
@ -211,3 +211,15 @@ User:
|
||||
items:
|
||||
type: string
|
||||
example: Alpha II
|
||||
|
||||
ModelItem:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
example: Model 1.1
|
||||
url:
|
||||
type: string
|
||||
example: https://definma-model-test.apps.de1.bosch-iot-cloud.com/predict/model1-1
|
||||
label:
|
||||
type: string
|
||||
example: 'ml/g'
|
Reference in New Issue
Block a user