[OBSOLETE] Flic button

To say I’m a novice at these sort of things is an understatement and I’m a bit stupid in general but please help… I’ve had another attempt at trying to link up a Flic button. Got as far as step 9 but all I get is the following response: curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html

curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.
Took me ages to try and figure out how to get Curl working in some form and I guess it’s still incorrect :frowning: It’s just annoying me that I’ve got two single flic light buttons and all they can do is turn on and off 2 Phillips lights. This integration seemed perfect but it’s so far the most difficult I’ve encountered since owning Smartthings.

I can’t help you with the direct method, but have you considered just using IFTTT? It works very well with flic and then you can do anything you can do with smartthings. We use this at our house all the time. :sunglasses:

1 Like

can you paste the curl command you are trying to use? pass the -k flag as part of the curl command.

Hi JD, IFTTT would be fine but it doesn’t seem to work with the Flic singles… I’m not entirely sure whether this integration would but wanted to try it. In IFTTT the switches appear as an option but the recipes I’ve tried never seem to work. The only way they’d work is IF the light was used as a trigger instead of the button. I really can’t rate the Flic Light Singles as they should have more functionality than they allow. Got several of the Xiaomi buttons that I’ve bought after and they are much better…

That’s correct, the flic singles are pre-programmed for a single purpose. The lighting one to control lights, music one to control Sonos, etc. They cost less than the regular flics, but only work with those specific devices. I doubt If This DTH will be able to make them do anything else, but you can try. They have different firmware than the regular flics.

Flic Singles are Flic’s little brothers. They are lower cost than Flic and can perform a limited set of functions.

Hi JD,

I’m running into an issue with the Flic integration. I am able to perform all of the steps until I get to the end and I test in curl with the following:

curl -X PUT -H “Content-Type: application/x-www-form-urlencoded” -d ‘’ “https://graph-na04-useast2.api.smartthings.com:443/api/smartapps/installations/InstallationID/button/black/1/access_token=access token” --header “Content-Type: application/x-www-form-urlencoded”

I receive the following error:
{“error”:“unauthorized”,“error_description”:“Full authentication is required to access this resource”}

I also receive an error in flic:
Internet Request. Request failed. bad request(400).

any suggestions.

Hi JD,

I’m stuck on step 9. Instead of an access token I get:

root@nas:~# curl -X POST -H “Content-Type: application/x-www-form-urlencoded” -d ‘grant_type=authorization_code&code=59wn1z&client_id=85e75d34-4bee-4f86-8340-595665510d37&client_secret=3e0908a9-085b-4900-b481-b62c6fa734d3&redirect_uri=www.blah123.com’ “https://graph.api.smartthings.com/oauth/token” --header “Content-Type: application/x-www-form-urlencoded”
[1] 26300
[2] 26301
[3] 26302
[4] 26303
-ash: “https://graph.api.smartthings.com/oauth/token”: No such file or directory
[2] Done code=59wn1z
[4]+ Done client_secret=3e0908a9-085b-4900-b481-b62c6fa734d3
[3]+ Done client_id=85e75d34-4bee-4f86-8340-595665510d37
root@nas:~# curl: (6) Could not resolve: application (DNS server returned answer with no data)

[1]+ Exit 6 curl -X POST -H “Content-Type: application/x-www-form-urlencoded” -d ‘grant_type=authorization_code

I was wondering, will this code still work with the current flic+ flic hub? I have no clue what is the first step to get these codes put in the smart things app.

I just ordered the flic hub and a few buttons, sad that I can’t have smartthings added to the button click natively.

Stuck on step ten which leaves me back to step one, specifically, button color and numbers. How do I set these so I can scrape the proper uri for step 10?

Where in step 10 are you getting stuck?

Did you go here (https://graph.api.smartthings.com/api/smartapps/endpoints?access_token=<access token from step 9>) and receive a response such as:

Hello, I managed to get through all the steps but I am struggling with the automation side of things in smartthings.
Does this device handler work only with web core?
Or can it work with automation in the smartthings app as well? I have managed to get “click” to work but double click and hold don’t work. Any help will be appreciated!!!

Thank you for creating this app, I was able to get it to work with a flic hub!

1 Like

This took me a while to work out as well. In the SmartThings app itself if you edit the Flic device you have created and go to settings you can define the colour and the button number! Hope that helps!

Hello All,
Getting stuck at step 9. I’m using windows 7 and curl and inputting the command as follows:

curl -X POST -H “Content-Type: application/x-www-form-urlencoded” -d “grant_type=authorization_code&code=douife&client_id=dljkfeojfe&client_secret=foijfoejeefojfe&redirect_uri=www.blah123.com” “https://graph.api.smartthings.com/oauth/token” --header “Content-Type: application/x-www-form-urlencoded”

note* I replaced the code, client ID and Client secret with random characters above.

The results I’m receiving are:

curl: (6) Could not resolve host: application

curl: (6) Could not resolve host: xn–https-hw3b

curl: (6) Could not resolve host: application

Any assistance would be greatly appreciated. Thank you!