Adjust API definitions to make creation of thing/action sync by default
"in": "body",
"name": "body",
"required": true,
+
"schema": {
+ "type": "object",
+ "properties": {
+ "action": {
"$ref": "#/definitions/ActionCreate"
+ },
+ "async": {
+ "type": "boolean",
+ "description": "If `async` is true, return a 202 with the new ID of the Action. You will receive this response before the data is persisted. If `async` is false, you will receive confirmation after the value is persisted. The value of `async` defaults to false."
+ }
+ }
}
}
],
"responses": {
+ "200": {
+ "description": "Action created",
+ "schema": {
+ "$ref": "#/definitions/ActionGetResponse"
+ }
+ },
"202": {
- "description": "Successfully received.",
+ "description": "Successfully received. No guarantees are made that the Action is persisted.",
"schema": {
"$ref": "#/definitions/ActionGetResponse"
}
"name": "body",
"required": true,
"schema": {
+ "type": "object",
+ "properties": {
+ "async": {
+ "type": "boolean",
+ "description": "If `async` is true, return a 202 with the new ID of the Thing. You will receive this response before the data is persisted. If `async` is false, you will receive confirmation after the value is persisted. The value of `async` defaults to false."
+ },
+ "thing" : {
"$ref": "#/definitions/ThingCreate"
}
}
+ }
+ }
],
"responses": {
+ "200": {
+ "description": "Thing created.",
+ "schema": {
+ "$ref": "#/definitions/ThingGetResponse"
+ }
+ },
"202": {
"description": "Successfully received.",
"schema": {
