Skip to content

Instantly share code, notes, and snippets.

@bobvanluijt
Created February 6, 2017 21:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bobvanluijt/6d59598230e0e18bff16777eeac98e46 to your computer and use it in GitHub Desktop.
Save bobvanluijt/6d59598230e0e18bff16777eeac98e46 to your computer and use it in GitHub Desktop.
Weave - commands
{
"Command": {
"externalTypeName": "clouddevices.Command",
"properties": {
"blobParameters": {
"$ref": "#/definitions/JsonObject",
"description": "Blob parameters list."
},
"blobResults": {
"$ref": "#/definitions/JsonObject",
"description": "Blob results list."
},
"component": {
"description": "Component name paths separated by '/'.",
"type": "string"
},
"creationTimeMs": {
"description": "Timestamp since epoch of a creation of a command.",
"format": "int64",
"type": "string"
},
"creatorEmail": {
"description": "User that created the command (not applicable if the user is deleted).",
"type": "string"
},
"deviceId": {
"description": "Device ID that this command belongs to.",
"type": "string"
},
"error": {
"description": "Error descriptor.",
"properties": {
"arguments": {
"description": "Positional error arguments used for error message formatting.",
"items": {
"type": "string"
},
"type": "array"
},
"code": {
"description": "Error code.",
"type": "string"
},
"message": {
"description": "User-visible error message populated by the cloud based on command name and error code.",
"type": "string"
}
},
"type": "object"
},
"expirationTimeMs": {
"description": "Timestamp since epoch of command expiration.",
"format": "int64",
"type": "string"
},
"expirationTimeoutMs": {
"description": "Expiration timeout for the command since its creation, 10 seconds min, 30 days max.",
"format": "int64",
"type": "string"
},
"id": {
"description": "Unique command ID.",
"type": "string"
},
"kind": {
"default": "weave#command",
"description": "Identifies what kind of resource this is. Value: the fixed string \"weave#command\".",
"type": "string"
},
"name": {
"description": "Full command name, including trait.",
"type": "string"
},
"parameters": {
"$ref": "#/definitions/JsonObject",
"description": "Parameters list."
},
"progress": {
"$ref": "#/definitions/JsonObject",
"description": "Command-specific progress descriptor."
},
"results": {
"$ref": "#/definitions/JsonObject",
"description": "Results list."
},
"state": {
"description": "Current command state.",
"enum": [
"aborted",
"cancelled",
"done",
"error",
"expired",
"inProgress",
"queued"
],
"type": "string"
},
"userAction": {
"description": "Pending command state that is not acknowledged by the device yet.",
"type": "string"
}
},
"type": "object"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment