init: add contract definitions and database schema with migrations skeleton
This commit is contained in:
@@ -1,12 +1,31 @@
|
||||
{
|
||||
"type": "object",
|
||||
"required": ["v", "id", "type", "ts", "deviceId", "payload"],
|
||||
"required": ["v", "type", "ts", "deviceId", "payload"],
|
||||
"properties": {
|
||||
"v": { "type": "integer" },
|
||||
"id": { "type": "string" },
|
||||
"type": { "type": "string" },
|
||||
"ts": { "type": "integer" },
|
||||
"deviceId": { "type": "string" },
|
||||
"payload": { "type": "object" }
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "Protocol version"
|
||||
},
|
||||
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Message type"
|
||||
},
|
||||
|
||||
"ts": {
|
||||
"type": "integer",
|
||||
"description": "Unix time in milliseconds"
|
||||
},
|
||||
|
||||
"deviceId": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"description": "Unique device identifier"
|
||||
},
|
||||
|
||||
"payload": {
|
||||
"type": "object",
|
||||
"description": "Message-specific data"
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user