Reputation: 1
I want to put some temperature data to thingsboard cloud platform via coap. However, the example code only support "coaps://...." format. Once I put "coap://coap.thingsboard.cloud/api/v1/$ACCESS_TOKEN/telemetry" format, it gives me "incorrect protocol in server uri". What is the difference between coaps and coap? Is it related with the website address? How to use coaps to connect device to thingsboard?
Upvotes: 0
Views: 334
Reputation: 824
"coap:" is coap send plain / unencrypted directly over UDP
"coaps:" is coap send encrypted using DTLS over UDP
If you use "coaps:" your device must support DTLS and in the most cases you need valid credentials (PSK, RawPublicKey, or x509) in order to connect. In some cases, the client is anonymous on the dtls level, and authenticates itself then on the coap layer (custom token or similar).
it's pretty much the same as "http:" and "https:", even the anyonymous client and the authentication on http level.
Upvotes: 1