HTTP Item is not showing up

Hi!
I use openhab2 on an raspberry pi 3 with openhabian.

I added a new item to one of my config files (test.items) which contains the following:

Switch Onkyo_Mute
        "Onkyo MUTE"
        [ "Switchable" ]
        { onkyo:onkyoAVR:41b0f81d-d8f8-1db9-34f1-XXXXXXXX:zone1#mute }

Switch Wohnzimmerlampe
        "Wohnzimmerlampe"
        [ "Lighting" ]
        { http=">[ON:POST:http://192.XX.XX.XX/socket0On] >[OFF:POST:http://192.XX.XX.XX/socket0Off]" }

The Onkyo Item is showing up correctly. I can also see the item gets created in the log. But my http / Switch item is not showing up. I can not see a error message in the log (/var/log/openhab2/openhab.log)

I have installed the http-bindig with the paperui. I have no idea what I am doing wrong. :frowning:

When you say the “item is not showing up,” what specifically do you mean?

This means that when you send an ON command to the bound item, it will perform an HTTP POST to the given URL, and likewise for OFF. But there is nothing defined for that item that will receive a state update for the item from somewhere.

With “not showing up” mean that I can not see it in the PaperUI or the basicUI. I can not use it.

Is there a need for a state update? Because I have nothing implemented in my little HTTP Switch Arduino thing. I have only two URLS (buttons) for on or off. There is no state variable or something like that.

EDIT:
I just need a Switch with ON or OFF and it has to open that URLS to do so. And it should be working with the homekit binding in openhab. In my browser I only need to open the specific url I used in my item config.

I tried to change the method to “GET” but I still can not see a switch / lightbulb in openhab anywhere. (BasicUI, PaperUI or iOS App)

The item you define in a .items file won’t show in PaperUI, and must be put in a .sitemap file to be seen in BasicUI. The item does not need to have a way to get state.

1 Like

Thanks a lot! That hint helped me. I think I should read more of the fundamental documentation. There is no new “PaperUI-Inbox”-like way to add such things? Because as I see for now I can not mix the stuff I added in the paperui with my manual added http-switch (on the same sitemap)

There is a little bit of a “wall” between text-based configuration, as was the only option under openHAB 1.x, and the new capabilities in openHAB 2. It would be great if the wall were smaller or didn’t exist, but overall openHAB is an incredible set of functionality. Best of success to you!