Getting Started

  • Overview
    The EveryScape JavaScript API allows you to embed EveryScape content into your website. The primary means of embedding EveryScape content is via the EveryScape Viewer. Embedded in your website, the EveryScape Viewer gives you access to interactive panorama content as well as scripted VideoScape's. For information on other content available via the EveryScape JavaScript API (such as thumbnails), please refer back to the main API examples page.

    See also
  • Authorization
    To use the JavaScript API, you must first obtain an EveryScape API Key.EveryScape viewer. Please email your EveryScape contact to obtain a key before proceeding.
  • Load the EveryScape JavaScript API
    To start using the EveryScape JavaScript API you must first load it into your page. To do this, you add a single script include to the <head> section of your page.
    <script src="https://sapi.everyscape.com/api/api.js?v=1.x&key=<API Key>" type="text/javascript"></script>
    
    Embed the EveryScape Viewer
    Once you have included the EveryScape JavaScript API in your page, you can call into the API to create and embed an EveryScape Viewer in your page.
    • Define a <div> placeholder in the body of your page that will contain the EveryScape Viewer. Set the width and height style properties to control the dimensions of the embedded EveryScape Viewer.
      <div id="MyEveryScapeViewerContainer" style="width:700px;height:300px;"></div>
      
    • Define an onLoad event handler which will be used to embed the EveryScape Viewer.
      <body onLoad="myOnLoadHandler()"> ... </body>
      
    • Inside the onLoad event handler, call the EveryScape JavaScript API to embed the EveryScape Viewer.
      function myOnLoadHandler()
      {
        var viewer = EveryScape.installViewer(
        {
          container: "MyEveryScapeViewerContainer", 
          type: EveryScape.Viewer.Type.FULL
        }, 
        {panorama:{poiId: <Point of Interest Id>}}, 
        {});
      }						
      
      Note that in this example, the initial view loaded into the embedded viewer is based on a Point of Interest Id. You must fill in this value with a valid number representing a Point of Interest (such as a restaurant or landmark). This information should be provided to you via your EveryScape contact.

      See also
  • Example
    Here is the example described above in action.