No modules founds
Hi,
I’m having an issue with the Netatmo API when using a token generated from the developer portal.
When I call the /homestatus endpoint on Postman with this token, the response doesn’t include any modules.
However:
-
I selected all available scopes when generating the token.
-
When I use the “Try It Out” feature from the API documentation, I get the expected modules.
-
If I take the token generated by “Try It Out” and use it in Postman, the response is also correct.
It looks like the token generated through the developer portal doesn’t grant the same permissions as the one from the documentation tool.
How to properly obtain a valid token for /homestatus?
Thanks,
Comments
3 comments
Hello Grégory,
I've just sent you an answer following the creation of your ticket. I let you come back to me with the elements I asked :)
Have a good day,
Leslie - Community Manager
Hi Leslie,
Yes i try to reach an electric charging station of Legrand. It is supported by Netatmo Home Control.
I also think that “Try It Out” has scopes that are not accessible when generating the token through the developer portal.
Is there any way to make these scopes accessible?
Screenshot of "Try It Out" :
Token generation :
Token generated:
Request (with bearer token in hearders) :
https://api.netatmo.com/api/homestatus?home_id=68****e0526967ebf042edd
Response with generated token :
{
"status": "ok",
"time_server": 1759849039
}
Response with "Try It Out" token :
{
"status": "ok",
"time_server": 1759843075,
"body": {
"home": {
"id": "68******01e0526967ebf042edd",
"modules": [
{
"charging_station_error": 0,
"charging_station_status": 0,
"connection": "wifi",
"current_charge_duration": 0,
"current_charge_instant_consumption": 0,
"current_total_charge_consumption": 0,
"firmware_revision": 85,
"hardware_version": 204,
"id": "00:03:50:e3:8a:d5",
"last_charge_cost": 68408,
"last_charge_duration": 310,
"last_charge_total_charge_consumption": 35045,
"rs485_link_state": false,
"sequence_id": 945,
"tic_link_state": true,
"type": "NLEVSE",
"wifi_strength": 52
}
]
}
}
}
Thanks,
My problem is the same. Additional, the `homedata` API returns both rooms and schedules but no modules listed. I've created my app after accepting an invite link.
- The response with generated token from OAuth2.0:
- The response with 'Try it out': Returns all data correctly
Please sign in to leave a comment.