Some example code to return the desired object type; it is sort of unfortunate we also have `device_type`!
diff --git a/craton/api/v1/schemas.py b/craton/api/v1/schemas.py index 3fecf2c..a7f68e2 100644 --- a/craton/api/v1/schemas.py +++ b/craton/api/v1/schemas.py @@ -76,6 +76,10 @@ DefinitionsHost = { "type": "integer", "description": "Parent Id of this host", }, + "type": { + "type": "string", + "description": "Type of this resource", + }, "device_type": { "type": "string", "description": "Type of host", @@ -136,6 +140,10 @@ DefinitionsHostId = { }, "description": "User defined labels", }, + "type": { + "type": "string", + "description": "Type of resource", + }, "device_type": { "type": "string", "description": "Type of host",
Some example code to return the desired object type;
it is sort of unfortunate we also have `device_type`!
diff --git a/craton/ api/v1/ schemas. py b/craton/ api/v1/ schemas. py api/v1/ schemas. py api/v1/ schemas. py
" type": "integer",
" description" : "Parent Id of this host",
"device_ type": {
" type": "string",
" description" : "Type of host",
" description" : "User defined labels",
"device_ type": {
" type": "string",
" description" : "Type of host",
index 3fecf2c..a7f68e2 100644
--- a/craton/
+++ b/craton/
@@ -76,6 +76,10 @@ DefinitionsHost = {
},
+ "type": {
+ "type": "string",
+ "description": "Type of this resource",
+ },
@@ -136,6 +140,10 @@ DefinitionsHostId = {
},
},
+ "type": {
+ "type": "string",
+ "description": "Type of resource",
+ },