title: How to protect my own api from hacking and make it private, so no body can access it exept from the android app?
body: <p>I have written my own api and I want to upload it to the server but I want to secure it so noone can access it except from my app, I have tried slim-basic-auth library but it didn't work, I don not know why...
  any help with that please ?</p>
  
  <pre><code>$app-&gt;add(new Tuupola\Middleware\HttpBasicAuthentication([
          "secure"=&gt;false,
          "users" =&gt; [
                  "userher@#" =&gt; "passhere#@"        ]
          ]));
  </code></pre>