diff options
author | OpenGnSys Support Team <soporte-og@soleta.eu> | 2023-11-30 20:06:07 +0100 |
---|---|---|
committer | OpenGnSys Support Team <soporte-og@soleta.eu> | 2023-11-30 20:20:07 +0100 |
commit | edac32bb986e8dab23a14a79317c2109bc523270 (patch) | |
tree | 61354e3e6106ea9f28cf75d3c09e456376c4c213 /src/dbi.h | |
parent | 1ce56240323c21e3e3251dfd6173cb45ae959574 (diff) |
rest: add GET /room/info
Add GET /room/info to obtain room information, this includes the name,
gateway and netmask.
curl -X GET -H "Authorization: $API_KEY" http://127.0.0.1:8888/room/info -d '{ "id" : 1 }
Diffstat (limited to 'src/dbi.h')
-rw-r--r-- | src/dbi.h | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -94,6 +94,7 @@ struct og_computer { }; struct og_room { + uint32_t id; uint32_t center; uint32_t group; char location[OG_DB_ROOM_LOC_MAXLEN + 1]; @@ -114,6 +115,8 @@ struct og_repository { struct in_addr; int og_dbi_get_computer_info(struct og_dbi *dbi, struct og_computer *computer, struct in_addr addr); +int og_dbi_get_room_info(struct og_dbi *dbi, struct og_room *room, + uint32_t room_id); int og_dbi_add_image(struct og_dbi *dbi, const struct og_image *image); int og_dbi_schema_update(void); |