Platform information:
Hardware: Rasberry PI 4 
OS: openHABian 
Java Runtime Environment:  OpenJDK Java 8 
openHAB version: 1.5 
 
 
Issue of the topic: Discovery API REST 
 
Hi!
I have read this
and I found API rest “discover” in the REST api.
but how to autorize device “discovered” and adding it in the sitemap?
Thanks
             
            
              
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  1:26pm
                   
                  2 
               
             
            
              You need to add the items (manually) to your sitemap file. See https://www.openhab.org/docs/configuration/sitemaps.html 
             
            
              
            
           
          
            
            
              can i can new device but i can’t adding it to sitemap on rest api?
             
            
              
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  1:32pm
                   
                  4 
               
             
            
              
Not that I am aware of, you need to manually create this file. I can post an example if needed. How many items do you have?
             
            
              
            
           
          
            
            
              3 items for now.
i 'm writing an app for controling openhub in remote only in rest (i can’t use openhab UI).
i need to adding discovered item in authorized list and see them in sensor list
i can do it with rest API?
thanks for help
             
            
              
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  1:46pm
                   
                  6 
               
             
            
              
 luca-parlapiano:
 
(i can’t use openhab UI)
 
 
You can’t use BasicUI, ClasicUI then why a sitemap?
             
            
              
            
           
          
            
            
              I seemed to understand that the list of items is the sitemap.
             
            
              
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  1:50pm
                   
                  8 
               
             
            
              When you open a browser and enter http://your_servers_IP_address:8080/start/index what do you see?
             
            
              
            
           
          
            
            
              i see openhub select interface (basic - ecc)
             
            
              
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  1:54pm
                   
                  10 
               
             
            
              So you see BasicUI as a selection. This will be empty until you create the sitemap file and add your items.
             
            
              
            
           
          
            
            
              
Currently, the sitemap is a file, not accessible directly from the REST API for editing.
             
            
              1 Like 
            
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  2:00pm
                   
                  13 
               
             
            
              
Thanks Bruce.
             
            
              1 Like 
            
            
           
          
            
              
                H102  
              
                  
                    November 29, 2019,  2:04pm
                   
                  14 
               
             
            
              @luca-parlapiano  also in PaperUI > Configuration > Addons > User Interfaces you will need to install BasicUi or whatever UI you prefer. BTW, BasicUI is a good starting point.
             
            
              
            
           
          
            
            
              i can’t use UI only api rest.
but thanks for help 
I have seen this api in rest page:http://demo.openhab.org:8080/doc/index.html#/ 
with this api i can create ad item
PUT /items/createOrUpdateItemhttp://demo.openhab.org:8080/doc/index.html#!/items/createOrUpdateItem )
widh this call i can add sensor?
             
            
              
            
           
          
            
              
                rlkoshak  
              
                  
                    November 29, 2019,  4:37pm
                   
                  16 
               
             
            
              Install the REST API docs add-on. The answer to all your questions are documented there.
             
            
              1 Like 
            
            
           
          
            
            
              now i’m reading it, but i need some test.
Thanks at all for help !!