feat: Populate repo

This commit is contained in:
2023-03-29 14:02:05 +02:00
commit 28bec5ebb8
168 changed files with 17860 additions and 0 deletions

23
include/json.h Normal file
View File

@@ -0,0 +1,23 @@
#ifndef JSON_H
#define JSON_H
typedef struct {
char* sensorId;
char* sensorData;
} Message;
typedef struct {
Message payload;
char* auth;
} Envelope;
enum RESPONSE_CODES {
SUCCESS,
MISSING_JSON,
MISSING_PAYLOAD,
MISSING_AUTH
};
int parse_envelope_json(const char* json, Envelope* envelope);
#endif