Browse Source

aggiunto metodo di get del device associato a un oggetto

fabio 2 months ago
parent
commit
165a862ca7
2 changed files with 23 additions and 2 deletions
  1. 0 0
      panorama.html
  2. 23 2
      panorama.yaml

File diff suppressed because it is too large
+ 0 - 0
panorama.html


+ 23 - 2
panorama.yaml

@@ -375,7 +375,6 @@ paths:
                 $ref: '#/components/schemas/Entity'
         '404':
           description: Entità non trovata
-
     put:
       summary: Modifica un'entità esistente (escluso lo stato)
       tags: [Entity]
@@ -418,6 +417,28 @@ paths:
         '404':
           description: Entità non trovata
 
+  /entity/{id}/device:
+    get:
+      summary: Ottiene il device associato a un'entità
+      operationId: getEntityDevice
+      tags: [Entity]
+      parameters:
+        - in: path
+          name: id
+          required: true
+          schema:
+            type: string
+      responses:
+        '200':
+          description: Device trovato
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/Device'
+        '404':
+          description: Device associato a Entità non trovato
+
+
   /state/{id}:
     put:
       summary: Modifica lo stato di un'Entità
@@ -838,7 +859,7 @@ components:
           additionalProperties: true
           examples: 
             - { chiusura: 'Lunedì|Giovedì|Domenica' }
-        deviceId:
+        device:
           description: Device associato all'entità
           $ref: '#/components/schemas/Device'
         createdDate:

Some files were not shown because too many files changed in this diff