2019-10-07 08:14:47 -06:00
|
|
|
// Copyright (c) Mainflux
|
2018-08-26 13:15:48 +02:00
|
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
2018-03-19 10:14:43 +01:00
|
|
|
syntax = "proto3";
|
|
|
|
package mainflux;
|
|
|
|
|
|
|
|
// RawMessage represents a message emitted by the Mainflux adapters layer.
|
|
|
|
message RawMessage {
|
2019-02-06 13:57:12 +01:00
|
|
|
string channel = 1;
|
2019-03-15 18:38:07 +01:00
|
|
|
string subtopic = 2;
|
|
|
|
string publisher = 3;
|
|
|
|
string protocol = 4;
|
|
|
|
string contentType = 5;
|
|
|
|
bytes payload = 6;
|
2018-03-19 10:14:43 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
// Message represents a resolved (normalized) raw message.
|
|
|
|
message Message {
|
2019-02-06 13:57:12 +01:00
|
|
|
string channel = 1;
|
2019-03-15 18:38:07 +01:00
|
|
|
string subtopic = 2;
|
|
|
|
string publisher = 3;
|
|
|
|
string protocol = 4;
|
|
|
|
string name = 5;
|
|
|
|
string unit = 6;
|
2018-11-05 19:18:51 +01:00
|
|
|
oneof value {
|
2019-03-15 18:38:07 +01:00
|
|
|
double floatValue = 7;
|
|
|
|
string stringValue = 8;
|
|
|
|
bool boolValue = 9;
|
|
|
|
string dataValue = 10;
|
2018-11-05 19:18:51 +01:00
|
|
|
}
|
2019-03-15 18:38:07 +01:00
|
|
|
SumValue valueSum = 11;
|
|
|
|
double time = 12;
|
|
|
|
double updateTime = 13;
|
|
|
|
string link = 14;
|
2018-03-19 10:14:43 +01:00
|
|
|
}
|
2018-11-05 19:18:51 +01:00
|
|
|
|
|
|
|
// SumValue is a simple wrapper around the double value.
|
|
|
|
message SumValue {
|
2019-02-06 13:57:12 +01:00
|
|
|
double value = 1;
|
2018-11-05 19:18:51 +01:00
|
|
|
}
|