title: Wordpress - rewrite or hide wp-json in url
body: <p>I would like to hide <code>/wp-json/</code> from url since I don't want anyone to know that website is built on wordpress. I tried rewriting rules in <code>.htaccess</code>, but <code>/api</code> only redirects to <code>/wp-json</code> so this is not what I trully want.</p>
  
  <pre><code>RewriteRule ^api/(.*)$ /wp-json/$1 [R,L]
  </code></pre>
  
  <p>These are not working at all:</p>
  
  <pre><code>RewriteRule ^api$ /wp-json [L]
  RewriteRule ^api/(.*)$ /wp-json/$1 [L]
  </code></pre>
  
  <p>I also tried site_url hook event, but unfortunately it is not working at all:</p>
  
  <pre><code>add_filter('site_url', 'api_filter', 10, 3);
  function api_filter($url, $path, $orig_scheme) {
      $old  = array('/(wp-json)/');
      $new  = array('api');
      return preg_replace($old, $new, $url, 1);
  }
  </code></pre>