MClimate API Documentation
Search…
MClimate API Documentation
MClimate LoRaWAN Devices
Basic endpoints
API Control
Melissa
Bobbie
Vicki
Vicki LoRaWAN
HT sensor
HT Sensor LoRaWAN
CO2 Sensor LoRaWAN
T-Valve LoRaWAN
Flood Sensor LoRaWAN
AQI Sensor LoRaWAN
Smart Plug
Shelly 1/1PM/EM
Maya
Functions
Schedules
Thermostat mode
Powered By
GitBook
Basic endpoints
User profile
Login
Request URL:
1
POST /auth/login
Copied!
Headers:
1
Content-Type: application/json
Copied!
Body:
1
{
2
"client_id" : "",
3
"client_secret" : "",
4
"username" : "",
5
"password" : ""
6
}
Copied!
Response:
1
{
2
"auth": {
3
"access_token": "1e516******************************ca",
4
"expires_in": 86400,
5
"token_type": "Bearer",
6
"scope": null,
7
"refresh_token": "e8ec5********************************26b3"
8
},
9
"_links": {
10
"self": {
11
"href": "/v1/auth/login"
12
}
13
}
14
}
Copied!
Renew Access Token
Request URL:
1
POST /auth/renew
Copied!
Headers:
1
Content-Type: application/json
Copied!
Body:
1
{
2
"client_id" : "",
3
"client_secret" : "",
4
"refresh_token" : ""
5
}
Copied!
Response:
1
{
2
"auth": {
3
"access_token": "44******************23263e59d3c5a3",
4
"expires_in": 86400,
5
"token_type": "Bearer",
6
"scope": null
7
},
8
"_links": {
9
"self": {
10
"href": "/v1/auth/renew"
11
}
12
}
13
}
Copied!
Fetch Personal Info
Request URL:
1
GET /users/me
Copied!
Headers:
1
Content-Type: application/json
2
Authorization: Bearer {access_token}
3
Accept-Response: Advanced
Copied!
Response:
1
{
2
"users": {
3
"user_id": ,
4
"username": "",
5
"firstname": "",
6
"lastname": "",
7
"phone": null,
8
"country_id": ,
9
"created": "2",
10
"_relation": {
11
"country": {
12
"id": ,
13
"geoname_id": ,
14
"continent_code": "",
15
"continent_name": "",
16
"country_code": "",
17
"country_name": "",
18
"city_name": "",
19
"time_zone": ""
20
}
21
}
22
},
23
"_links": {
24
"self": {
25
"href": "/v1/users"
26
},
27
"controller": {
28
"href": "/v1/controller/{serial_number}",
29
"templated": true
30
}
31
}
32
}
Copied!
Controllers
Fetch user’s controllers
Request URL:
1
GET /controllers
Copied!
Optional params: type={device type} (melissa; bobbie; smart_plug...) & mac={device mac}
Headers:
1
Content-Type: application/json
2
Authorization: Bearer {access_token}
Copied!
Response:
1
{
2
"_embedded": {
3
"controller": [
4
{
5
"user_id": 200,
6
"serial_number": "H5******J6X",
7
"mac": "“ACCF***6522E\"",
8
"firmware_version": "V1SHTHF",
9
"name": "Melissa H59****X",
10
"type": "melissa",
11
"room_id": 7,
12
"online": false,
13
"brand_id": 9,
14
"controller_log": [],
15
"_links": {
16
"self": {
17
"href": "/v1/controllers/H59I****6X"
18
}
19
}
20
},
21
{…},
22
{…},
23
{…},
24
…
25
]
26
},
27
"total": 22,
28
"_links": {
29
"self": {
30
"href": "/v1/controllers"
31
},
32
"first": {
33
"href": "/v1/controllers?page=1"
34
},
35
"last": {
36
"href": "/v1/controllers?page=1"
37
}
38
}
39
}
Copied!
Fetch one controller
Request URL:
1
GET /controllers/{serial_number}
Copied!
Headers:
1
Content-Type: application/json
2
Authorization: Bearer {access_token}
Copied!
Response:
1
{
2
"controller": {
3
"user_id": 200,
4
"serial_number": "H5******J6X",
5
"mac": "ACCF***6522E",
6
"firmware_version": "V1SHTHF",
7
"name": "Melissa H59****X",
8
"type": "melissa",
9
"room_id": 7,
10
"online": false,
11
"brand_id": 9,
12
"controller_log": [],
13
"_links": {
14
"self": {
15
"href": "/v1/controllers/H59I****6X"
16
}
17
}
18
},
19
"_links": {
20
"self": {
21
"href": "/v1/controllers/H5******J6X"
22
}
23
}
24
}
Copied!
Controller Assign
Request URL:
1
POST /controllers/{serial_number}/assign
Copied!
Headers:
1
Content-Type: application/json
2
Authorization: Bearer {access_token}
Copied!
Response:
1
{
2
"controller_reassign": {
3
"id": 1***,
4
"user_id": 200,
5
"serial_number": "H5******J6X",
6
"mac": "ACCF***6522E",
7
"firmware_version": "V1SHTHF",
8
"name": "Melissa H59****X",
9
"type": "melissa",
10
"device_group": "mclimate",
11
"status_push": 0,
12
"room_id": null,
13
"created": "2016-04-12 11:25:47",
14
"assigned_at": "2020-11-20 15:19:29",
15
"deleted_at": null
16
},
17
"_links": {
18
"self": {
19
"href": "/v1/controllers/H5******J6X/assign"
20
}
21
}
22
}
Copied!
Controller Reassign
Request URL:
1
PATCH /controllers/{serial_number}/reassign
Copied!
Headers:
1
Content-Type: application/json
2
Authorization: Bearer {access_token}
Copied!
Body
:
1
{
2
"owner" : "n*****@s******a.com"
3
}
Copied!
Response:
1
{
2
"controller_reassign": {
3
"id": 1***,
4
"user_id": 200,
5
"serial_number": "H5******J6X",
6
"mac": "ACCF***6522E",
7
"firmware_version": "V1SHTHF",
8
"name": "Melissa H59****X",
9
"type": "melissa",
10
"device_group": "mclimate",
11
"status_push": 0,
12
"room_id": null,
13
"created": "2016-04-12 11:25:47",
14
"assigned_at": "2020-11-20 15:19:29",
15
"deleted_at": null
16
},
17
"_links": {
18
"self": {
19
"href": "/v1/controllers/H5******J6X/assign"
20
}
21
}
22
}
Copied!
MClimate LoRaWAN Products
If you are interested in our LoRaWAN devices, you can find more information
here
.
​
Previous
MClimate API Documentation
Next - API Control
Melissa
Last modified
10mo ago
Copy link
Contents
User profile
Login
Renew Access Token
Fetch Personal Info
Controllers
Fetch user’s controllers
Fetch one controller
Controller Assign
Controller Reassign
MClimate LoRaWAN Products