How do I hide a REST API Url from the end user?

后端 未结 7 2002
庸人自扰
庸人自扰 2021-02-07 15:13

Is it possible to hide my REST URL that I using via AJAX to populate page data? I don\'t want others taking and consuming from my REST API, but need to use it to display content

7条回答
  •  轮回少年
    2021-02-07 16:10

    By hiding I'm assuming you mean not having any association to the URL shown in your Javascript. Unfortunately it's not possible to hide the URL as far as I know, even if you managed to hide it in javascript, the request would be visible in any extension capable of picking up outgoing and incoming http requests on a web page.

提交回复
热议问题