How to send REST API to html page


what is the best method to get REST API input/output to html pages. Can i make REST api calls natively from html ? or do i need any language like php/javascript.


HTML is a markup language as opposed to a programming language, so you would indeed require any programming language that has access to HTTP client libraries. You also want something that can be easily integrated with HTML pages, so Javascript and PHP are popular choices amongst many.


Can some one help me on how to write a simple query for GET query like mentioned in the training modules but i want to include authentication and also accept the self signed certificates.


Extensive documentation is found at

put a button on your website (on the html code), this button will have a function on javascript to GET something from somewhere, you need to define those, based on the responses and documentation of the API you are trying to hit.

<button onclick="getResponse()">the button text</button>

function getResponse(){
  var request = new XMLHttpRequest();"GET", "TARGET URL (EX", false(async flag), "userName", "password");