How to pass username and password to some simple API web form?

  • Platform information:
    RPi3, latest build of openhab

  • Issue of the topic: please be detailed explaining your issue
    I’am using http binding and want to make authentication to external web page which has some kind of api. Authentication is done via web form and I need to pass username and password, hot to make this happen ?
    form fields looks like:

                        <input type="text" class="form-control input-material" name="_username" id="username" novalidate="novalidate" placeholder="+" value="+">
                    </div>
    
                    <div class="form-group">
                        <input type="password" class="form-control input-material" name="_password" id="password" novalidate="novalidate" placeholder="Password">
                    </div>

You might be able to do it with the http binding, but you’d probably find it easier to use the http action.

Any example?

Have you tried the search-function?

e.g. this

1 Like

Yes, I saw this. Problem is that for login session HTTPOnly flag is used in cookie…