Oauth2 with http

#1

Need help
I want to Post/Get some sensor data via Rpi to Oauth2 protected http API.

{

"type": "HTTP_Sensor",

"deviceId": "DFRT",

"clientId": "1OnTq6Gfsfr7bIxxxxFUa",

"clientSecret": "fsfrgSERttkl2220etx9p2awO00a",

"accessToken": "xxxxx-xxxx-ffff-eedee-4545fgtgtg",

"refreshToken": "56555hghgd-676e-77ye-4r4j-gfhgegfh77",

"httpsGateway": "https://xx.xx.xx.xx:xxxx",

"httpGateway": "http://xx.xx.xx.xx:xxxx",

}