Documentation

Integration overview

The InstaVid360 app communicates with third party system via the InstaVid360 backend web services. The InstaVid360 backend web services proxy all requests to ensure end-to-end security, uniformity between different third party systems and load balancing.

The InstaVid360 app is available in both the Apple and Google Play app stores. The InstaVid360 app allows for the creation and sending of full 360 exterior, 360 interior spin imagery, as well as video content.

The 360 spin and video content is linked to third party inventory systems which allows for spin and video content to be displayed on websites and online vehicle portals.

InstaVid360 prefers JSON or XML RESTful web services when engaging in integration with third parties. We are able to customise our backend ecosystem to adjust for existing stock solutions.

Authentication

The InstaVid360 app requires dealer users to log in, in order to access their InstaVid360 content.

For simplicity, dealer users login to InstaVid360 with the same username and password used on third party systems. InstaVid360 securely proxies the authentication request from the app through to the third party web services.

InstaVid360 will customise the user authentication around third party authentication web services.
InstaVid360 prefers JSON or XML RESTful web services.

Example third party web service:
POST: https://third.party.com/api/auth

Sample Request:

{
  "system": "instavid",
  "username": "johndoe",
  "password": "p@55w0rd"
}

Sample Response:

{
  "result": "success",
  "dealer": "12345",
  "dealer_name": "Somewhere Motors",
}

If your authentication requires fields in addition to the username and password (such as a Dealer Number), InstaVid360 is able to capture these from the user and use the details in the authentication process. If your API calls require individual user permissions to fetch stock and send spin information via a Webhook, please include a Token (and Refresh Token if the token expires) to be used. The user is not required to log into the app on every usage and will be remembered internally.

Whilst this solution is the fastest to implement in most third party systems, we are able to authenticate users via an existing OAuth 2.0 framework on the client side.

Inventory/Stock Integration

The InstaVid360 app allows the dealer user to link spin and video content to third party stock items.

In order to display the third party stock list within the InstaVid360 app, the InstaVid360 backend requires secure access to the third party stock list web service. The InstaVid360 backend will use secure authentication to retrieve third party stock items and proxy them into the InstaVid360 app.

InstaVid360 prefers JSON or XML RESTful web services.

The following fields are expected to enable a dealership to navigate and search with ease through the inventory:

Field name Description Data type Required
vehicle_id Unique identifier for the vehicle in your system alphanumeric Required
stock_code Reference for this vehicle at the dealership alphanumeric Optional
(Defaults to vehicle_id)
brand Brand of the vehicle, e.g. Audi alphanumeric Required
range Range of the vehicle, e.g. Q5 alphanumeric Required
derivative Model derivative, e. g. 2.0 TFSI automatic alphanumeric Required
Year Manufacturing or first registration year of the vehicle 4-digit integer Optional
mileage Current odometer reading for the vehicle integer Required
mileage_unit Unit of the odometer reading text ("km" or "mi") Required
price Advertised price for the vehicle integer Optional
(recommended)
currency Currency of the price in ISO 4217, e.g. USD, EUR, ZAR Text (3 letters) Required
(if price is available)
colour Colour of the vehicle Text Optional
(recommended)
reg Registration number of the vehicle alphanumeric Optional
(recommended)
vin VIN number of the vehicle alphanumeric Optional
(recommended)
image Link to an image for this vehicle, minimum size 800x600px recommended Alphanumeric (url) Optional
(recommended)

Example third party web service:
GET: https://third-party.com/api/stockfeed?dealer_id=12345

Response:

[
  {
    "vehicle_id": "10001",
    "stock_code": "USEVW123",
    "make": "Volkswagen",
    "model": "Polo",
    "derivative": "1.6 Comfortline",
    "year": "2016",
    "mileage": "65000",
    "mileage_unit": "km",
    "price": 204994,
    "currency": "ZAR",
    "colour": "blue",
    "reg": "CA691556",
    "vin": "WBA667897597659765",
    "image": "https:\/\/cdn.third-party.com\/image\/10001.jpg"
  },
  {
    "vehicle_id": "10002",
    "stock_code": "BMW123-USED",
    "make": "BMW",
    "model": "3 Series",
    "derivative": "323i",
    "year": "2017",
    "mileage": 25000,
    "mileage_unit": "km",
    "price": 349994,
    "currency": "ZAR",
    "colour": "yellow",
    "reg": "CY127645",
    "vin": "WDB6565657657657",
    "image": "https:\/\/cdn.third-party.com\/image\/10002.jpg"
  },
  {
    "vehicle_id": "10003",
    "stock_code": "MERC456-USE",
    "make": "Mercedes-Benz",
    "model": "C-Class",
    "derivative": "C320D",
    "year": 2015,
    "mileage": 110000,
    "mileage_unit": "km",
    "price": 269999,
    "currency": "ZAR",
    "colour": "white",
    "reg": "GF54JFGP ",
    "vin": "WDB234566787688",
    "mileage": 110000,
    "mileage_unit": "km",
    "image": "https:\/\/cdn.third-party.com\/image\/10003.jpg"
  }
]

If required, this call can be authenticated, either via a global InstaVid360 Username/Password Token or user credential tokens.

Below is a high level view of the integration needed for InstaVid360 gallery image transfers, as we offer a very flexible solution, we would advise that InstaVid360 be contacted by a backend developer in order to iron out your preferred method of image ingestion.

Push Spin/Video Codes to Inventory/Stock System

The InstaVid360 app is used link spin and video content to stock items.

In order to know which stock item should display a specific spin or video, InstaVid360 will push this information back to the third party stock system via a webhook.

Each spin or video created using the InstaVid360 app has a unique code. The InstaVid360 backend will securely push the spin or video code to the third party stock system web services, along with the third party unique identifier for the stock item.

InstaVid360 prefers JSON or XML RESTful web services.

Example third party web service:
POST: https://third.party.com/api/stockitem

Sample Request:

{
  "dealer_id":12345,
  "vehicle_id":100003,
  "spin":
  {
    "code":"1521033579.7283_479976534b2641c8f54df78254ad6f680d362",
    "thumb":"https:\/\/static.instavid360.com\/image.jpg"
  },
  "video":
  {
    "url":"https:\/\/static.instavid360.com\/videofile.mp4",
    "thumb":"https:\/\/static.instavid360.com\/image.jpg"
  }
}

Sample Response:

{
  "result": "success"
}

The spin or video elements are not necessarily both present in the same call. If a spin or video is changed, the new value will be supplied, if deleted, the values will be set to null.

If required, this call can be authenticated, either via a global InstaVid360 Username/Password/Token or user credential tokens.

Display 360° Spins/Video on Websites

To integrate InstaVid360 360° Spin and video content on websites, you would use the InstaVid360 javascript loader. The implementation of the InstaVid360 javascript player is provided below and this can be customised to suit the context.

There are several variables which can be adjusted for web delivery.

  • Sizing is flexible although the 360° Spin and video content are served at an industry standard 16:9 or 4:3 aspect ratio
  • 360° Spin resolutions available are: 360, 720 (recommended) and 1080.
  • Normal 360° Spin frame rate per 360° Spin available: 64 (recommended) up to max. 200
  • Enhanced 360° Spins (background replaced/blurred) frame rates are: 32 or 64 (recommended).

Embedding 360° Spin and Video

Example 360° Spin and Video content:
https://static.instavid360.com/v/master/0.7.latest/load.html

There are 3 ways to embed the Spin & Video player into your website:

  1. Method 1 involves adding a lite loading script into the body of the element that you want the player to display.
  2. Method 2 involves loading the external scripts and then loading the player manually.
  3. Method 3 involves loading the spin player within an iframe.
Implementation instructions (Inline and Advanced)

Method 1 (Inline)

  <div id="spin-div" style="max-width: 640px; margin: 0 auto;">
    <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"  
    data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
    data-video="https://static.instavid360.com/iv/example/porsche.mp4" >
    </script>
  </div>

Method 2 (Advanced)
Add element into HTML where player should appear and use loadSpin360 to load the player using format below.

<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
"spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340",
"video":"https://static.instavid360.com/iv/example/porsche.mp4"
});
</script>

Using the sample HTML script snippet your front-end developers will be able to insert the InstaVid360 spin player on the dealership VDP. The script will attempt to find the 360° Spin code and/or video associated with the vehicle of choice and display the player which the user can interact with. The player will not display when the script fails to find the associated spin code for the vehicle.

The spin player only requires one or both of the following fields: data-spin and/or data-video on the script element.

Please follow these steps when implementing the InstaVid360 spin player:

  1. Insert script snippet on page where the player is to be displayed. Like this example
  2. On this script add the spin code associated with the vehicle. Like this example
  3. The player loads the content for the referenced vehicle. Like this example
  4. You'll need to look out for these things
    1. position; displays in the specified area
    2. size; player inherits the size of the parent container
    3. styling; certain website elements might look different based on the website CSS
    4. interactivity; exterior and interior can be rotated
    5. content; hotspots, buttons and gallery items loaded for the player
    6. console errors
  5. Once you have something, send us a link
  6. We will review your implementation and do QA to make sure everything is 100%
  7. Using the InstaVid360 app you will be able to create a spin for your vehicle
  8. Once the spin is ready it will be available to display on your VDP
Iframe Implementation instructions

Loading the player within an iframe element:

<!-- element -->
<div id="spin-container">
  <iframe
    src="https://static.instavid360.com/v/latest/player.html?version=0.7&spin=16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea
    &video=https%3A%2F%2Fstatic.instavid360.com%2Fiv%2Fdealer%2F704%2Fportal%2Fportal-15-20210504-171820-FD5DF2D10FD4_720.mp4"
    allow="fullscreen"
    allowfullscreen
    width="100%"
    height="100%">
  </iframe>
</div>

The iframe's src attribute will have to use our iframe compatible player html:
https://static.instavid360.com/v/latest/player.html

The spin player parameters are URL encoded into the link above.

It is important to note that the necessary parameters for the iframe to function are:

  • Spin and/or URL encoded video
  • version: Should be set to 0.7 or 0.8 otherwise 0.6 is the default version.

If the version parameter is not set to 0.7 or 0.8, the 0.6 InstaVid360 Spin Player version is used by default.

Example:
https://static.instavid360.com/v/latest/player.html?version=0.7&spin=16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea

Please follow these steps when implementing the InstaVid360 spin player within an iframe:

  1. Insert the snippet on the page where the player is to be displayed. Like this example
  2. Add your parameters to the player.html URL. Like this example:
  3. An example of embedding video to a player loaded within an iframe. Note: the video URL must be URL encoded:
  4. The player loads the content for the referenced vehicle within the iframe. Like this example:
  5. Including function parameters in the URL to allow communication between the player and the parent site:
    1. Include window.top.postMessage within the encoded function. Example:
      function(e){window.top.postMessage("Loaded Successfully", "*")}
    2. Ensure that the function is URL encoded. Example:
      ...&onLoad=function%28e%29%7Bwindow.top.postMessage%28%27Loaded%20Successfully%20%27%2C%20%27%2A%27%29%7D
    3. To receive communication from the player on your parent site, use window.onmessage. Example:
      window.onmessage = function(e) {
        if (e.data){
          console.log(e.data);
        }        
      };
    4. Final output should look something like this example:
  6. If you would like the iframe's height to auto-adjust, you can include data-spin-resize="true" in the iframe element like the below example:
    <iframe
    src="https://static.instavid360.com/v/latest/player.html?spin=16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea&version=0.7" 
    allow="fullscreen"
    allowfullscreen
    data-spin-resize="true"
    width="1000px" height="700px">
    </iframe>

Spin player available settings:

Mandatory

Spin Code
Unique code for spin. Required
Field: data-spin

Customisation

Camera Angle
Show, hide the camera angle display
Field: data-cam-angles
Default: true (show)
Options: true, false
Camera Angle position
Set position of the camera angle display (defaults to a button in the control bar)
Field: data-angleDisplay
Default: false
Options: bottom
Controls Align
Set position of control buttons
Field: data-control-align
Default: bottom
Options: top, middle, bottom
Controls Hover
Enable, disable "Go inside/outside" hover buttons
Field: data-control-hover
Default: true
Options: true, false
Controls Scale
Enable, disable control button responsiveness
Field: data-control-scale
Default: true
Options: true, false
Controls Text
Enable, disable control text variation of certain buttons
Field: data-control-titles
Default: true
Options: true, false
Controls Titles
Enable, disable control button title tooltips
Field: data-control-titles
Default: true
Options: true, false
Cursor
Custom cursor set option
Field: data-cursor
Default: basic
Options: basic, none
Exterior Keyframes
Degree interval between exterior gallery frame images
Field: data-ekf
Default: 45
Options: range between 10 - 180
Fullscreen
Enable, disable full-screen feature
Field: data-fullscreen
Default: true
Options: true, false
Gallery
Enable, disable or hide gallery feature
Field: data-gallery
Default: true
Options: true, false, hide
Height
Number of pixels or percentage string of player height
Field: data-height
Hotspots
Enable, disable or hide hotspot feature
Field: data-hotspots
Default: true
Options: true, false, hide
Hotspot Types
Hide, show hotspots based on the hotspot type. Multiple types can be displayed if separated by commas.
Field: data-hotspotType
Default: all
Options: all, feature, warning, danger, none
Hotspot Animate
Enable, disable hotspot icon animation on hover
Field: data-hotspot-animate
Default: true
Options: true, false
Hotspot Color
Set color of hotspot icon
Field: data-hotspot-color
Default: orange
Options: green, blue, red, orange, white, black, grey
Hotspot Scale
Enable, disable hotspot icon scaling based relative position
Field: data-hotspot-scale
Default: true
Options: true, false
Hotspot Titles
Enable, disable hotspot title headers
Field: data-hotspot-titles
Default: true
Options: true, false
Initial Load
Forces the player to load either exterior, interior or video on first load
Field: data-initial
Default: exterior
Options: exterior, interior, video
Interior
Enable, disable interior feature
Field: data-interior
Default: true
Options: true, false
Interior Keyframes
Degree interval between interior gallery frame images
Field: data-ikf
Default: 90
Options: range between 10 - 180
Language
Language of player in ISO 639-1 code format
Field: data-lang
Default: en
Options: en, de, es, fr, it, zh, sk, nl, cz, ar, tr, fr-ca, pt
Preview
Spin preview type
Field: data-preview
Default: bounce
Options: spin, sway, bounce, none
Spin Start Angle
Spin start angle
Field: data-angle
Default: 0
Options: range between 0-360
Quality
Set spin content quality, options for h = high, m = medium, l = low
Field: data-quality
Default: m
Options: h, m, l
Smoothing
Set exterior frame smoothing value, a higher value results in more frames for a smoother spin and also consumes more data
Field: data-smoothing
Default: 5
Options: 1 - 10
Width
Number of pixels or percentage string of player width
Field: data-width
Default: 100%
Zoom
Enable, disable zoom feature
Field: data-zoom
Default: true
Options: true, false
Zoom Reset
Enable, disable zoom reset feature
Field: data-zoom-reset
Default: true
Options: true, false
Zoom on mobile
Enable, disable zoom feature on mobile
Field: data-zoom-mobile
Default: true
Options: true, false
Blur Interaction
Show, hide the blurred overlay displayed before the initial user interaction
Field: blur-interaction
Default: true
Options: true, false
Load Control Bar
Show, hide the control bar before the initial user interaction
Field: data-load-control-bar
Default: true (show)
Options: true, false
Load Hotspots
Show, hide hotspots before the initial user interaction
Field: data-load-hotspots
Default: true (show)
Options: true, false
Align Close Left
Specifies whether close buttons should be positioned to the left
Field: data-align-close-left
Default: false (positioned to the right)
Options: true, false
Radar
Show, hide the radar displayed on the top left
Field: data-radar
Default: true (show)
Options: true, false

White-label CDN:

The player can be customized to load data from an alternative source such as a third-party CDN or using the CloudFront domain

Override JS
Set the custom path to load spin player JavaScript from
Field: data-override-js
Example: https://dstfk5pujma2h.cloudfront.net/v/master/0.7.latest/js/spin360.min.js
Override CSS
Set the custom path to load spin player style sheet from
Field: data-override-css
Example: https://dstfk5pujma2h.cloudfront.net/v/master/0.7.latest/css/spin360.min.css
Override Images
Set the custom path to load spin image content from
Field: data-override-images
Example: https://dstfk5pujma2h.cloudfront.net/{spin_code}/

Parameters to collect information from the player:

From version 0.7 onwards, the InstaVid360 player provides front end developers with functions to detect player events and errors. These functions and their uses are described below.

metricsReturn function
The function to retrieve interaction events is the metricsReturn() function and it should be called as follows
Field: data-metricsReturn
Example:
                <!-- element -->
                <div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
                <!-- script -->
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"></script>
                <script>
                var spinplayer = loadSpin360("spin-div", {
                  spin:"16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                  smoothing: 5,
                  language:"en",
                  metricsReturn: function(eventType,eventName,metricsSession,playerVersion,portal,spinCode,timeStamp){
                    console.log(eventType+", "+eventName+", "+metricsSession+", "+playerVersion+", "+portal+", "+spinCode+", "+timeStamp);
                  }
                });
                </script>
              
Or:
              <div id="spin-div" style="max-width: 640px; margin: 0 auto;">
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"
                  data-spin="16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea" 
                  data-metricsReturn="function(eventType,eventName,metricsSession,playerVersion,portal,spinCode,timeStamp){
                  console.log(eventType+', '+eventName+', '+metricsSession+', '+playerVersion+', '+portal+', '+spinCode+', '+timeStamp);}">
                </script>
              </div>
            

The events returned for the metricsReturn() function are:

Control Bar Button Clicks
Event Type Event Name Description
button_click exterior The exterior button was clicked. The exterior spin is displayed
button_click interior The interior button was clicked. The interior spin is in focus
button_click video The video button was clicked. The stock video is played
button_click camAngles_toggle_on he default angles button was clicked to show the default angles grid
button_click camAngles_toggle_off The default angles button was clicked to hide the default angles grid
button_click gallery_toggle_on The gallery button in the control bar was clicked to show the hotspot gallery
button_click gallery_toggle_off The gallery grid was closed either by the clicking the gallery toggle button or the close button
button_click gyro_toggle_on The motion control button on the control bar was clicked (mobile only) to enable motion control panning of the 360° Spin
button_click gyro_toggle_off The motion control button on the control bar was clicked (mobile only) to disable motion control panning of the 360° Spin
button_click hotspot_toggle_on The hotspot label button in the control bar was clicked to display the hotspot text
button_click hotspot_toggle_off The hotspot label button in the control bar was clicked to hide the hotspot text
button_click zoom_in The zoom in button on the control bar was clicked. Zooming in on the spin
button_click zoom_out The zoom out button on the control bar was clicked. Zooming out on the spin.
button_click zoom_exit The zoom exit button on the control bar was clicked. Resetting the zoom of the spin
button_click fullscreen The fullscreen button on the control bar was clicked. Bringing the player to fullscreen
button_click fullscreen_exit The fullscreen exit button on the control bar was clicked. Returning the player to normal view
Hotspots and Floating Buttons Clicks
Event Type Event Name Description
button_click exterior_float The "Go Outside" hotspot was clicked on the spin. Exterior spin is displayed
button_click interior_float The "Go Inside" hotspot was clicked on the spin. Interior spin is displayed
button_click hotspot_view A hotspot or key frame was viewed
button_click hotspot_exit The close button on the hotspot was clicked. Closing the hotspot and returning to spin view
Other Events
Event Type Event Name Description
interior_view N/A Gets called when mode is set to Interior/Interior spin is displayed
spin_interaction N/A Gets called whenever there is any kind of interaction with the player (spin panning, switching modes, zooming, playing video etc.)
exterior_view N/A Gets called when mode is set to Exterior/Exterior spin is displayed
spin_loaded N/A Runs once at the start of the script
exterior_spin N/A Exterior spin is being panned
interior_spin N/A Interior spin is being panned
spin_ping N/A The player records the spin view duration
hotspot_view N/A Gets called when a hotspot is displayed on the screen
video N/A Gets called when mode is set to Video/Video is displayed
onLoad function
The function(s) stored in this parameter will be executed once the player has loaded successfully.
Field: data-onLoad
Example:
                <!-- element -->
                <div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
                <!-- script -->
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"></script>
                <script>
                var spinplayer = loadSpin360("spin-div", {
                  spin:"16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                  smoothing: 5,
                  language:"en",
                  onLoad: function(){
                    console.log("Loaded successfully!");
                  }
                });
                </script>
              
Or:
              <div id="spin-div" style="max-width: 640px; margin: 0 auto;">
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"
                  data-spin="16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea" 
                  data-onLoad="function(){
                  console.log('Loaded successfully!');}">
                </script>
              </div>
            
onError function
The function stored in this parameter will be executed once an error occurs within the player. It will also return a variable containing the exact error.
Field: data-onError
Example:
                <!-- element -->
                <div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
                <!-- script -->
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"></script>
                <script>
                var spinplayer = loadSpin360("spin-div", {
                  spin:"16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                  smoothing: 5,
                  language:"en",
                  onError: function(error){
                    console.log("Spin360 player failed to load - "+error);
                  }
                });
                </script>
              
Or:
              <div id="spin-div" style="max-width: 640px; margin: 0 auto;">
                <script src="https://static.instavid360.com/p/0.7.latest/spin360.lite.js"
                  data-spin="16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea" 
                  data-onError="function(error){
                  console.log('Spin360 player failed to load -'+error);}">
                </script>
              </div>
            

Functions that can be used outside of the player:

Note: the below functions require Spin360.getPlayer(0) to be assigned when referencing the player.

validSpin()

Returns true if a valid spin is found.

Example:
var player = Spin360.getPlayer(0);
var validSpin = player.validSpin();
validVideo()

Returns true if a valid video is found.

Example:
var player = Spin360.getPlayer(0);
var validVideo = player.validVideo();

The below functions are used to destroy the player and clear the spin container. Usage of Spin360.getPlayer(0) isn't a requirement for these.

Spin360.destroyAll()

Destroys the Spin360 array.

Example:
Spin360.destroyAll();
Spin360.emptyElement()

Clears the spin container/spin div.

Example:
Spin360.emptyElement(spindiv);

Video is available in 720p mp4 format. 3rd parties may display the video content in their own player.

InstaVid360 recommends either JW Player (https://www.jwplayer.com/) or Video.js (https://videojs.com/)

In order for 3rd parties to integrate InstaVid360 spin content on their websites, they will need to use the InstaVid360 javascript loader. The InstaVid360 javascript player can be customised to suit the context.

There are several variables which can be adjusted for web delivery.

  • Sizing is flexible although the spin and video content is served at an industry standard 16x9 aspect ratio
  • Spin resolutions available are: 360, 720 (recommended) and 1080
  • Spin frame rate per 360 spin available: 64 (recommended) up to max 200

Embed Spin

Example spin content:
https://static.instavid360.com/v/master/latest/lite.html

There are 2 ways to embed the player into your website, method 1 involves adding a lite loading script into the body of the element that you want the player to display and method 2 involves loading the external scripts and then loading the player manually.

Method 1 (Inline)
Add script into HTML where player should appear and using the format below.

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
    <script src="https://static.instavid360.com/p/latest/spin360.lite.js"
      data-spin="15432159961739_950f9940193e3f7da6e051037c142eb7fc11f24d31d6e4501">
    </script>
  </div>

Method 2 (Advanced)
Add element into HTML where player should appear and use loadSpin360 to load the player using format below.

<!-- element -->
  <div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
  <!-- script -->
  <script src="https://static.instavid360.com/p/latest/spin360.lite.js"></script>
  <script>
  var spinplayer = loadSpin360("spin-div", {
    "spin":"15432159961739_950f9940193e3f7da6e051037c142eb7fc11f24d31d6e4501",
  });
  </script>
Implementation instructions

Using the sample HTML script snippet your front-end developers will be able to insert the InstaVid360 spin player on the dealership front-page VDP. The script will attempt to use the spin code associated with the vehicle of and display the player which the user can interact with. The player will not display when the script fails to find the associated spin code for the vehicle.

The spin player only requires one of the vehicle fields: data-spin attribute on the script element.

Please follow these steps when implementing the InstaVid360 spin player:

  1. Insert script snippet on page where the player is to be displayed. Like this example
  2. On this script add the spin code value associated with the vehicle. Like this example
  3. The player loads the content for the referenced vehicle. Like this example
  4. You'll need to look out for these things
    1. position; displays in the specified area
    2. size; player inherits the size of the parent container
    3. styling; certain website elements might look different based on the website CSS
    4. interactivity; exterior and interior can be rotated
    5. content; hotspots, buttons and gallery items loaded for the player
    6. console errors
  5. Once you have something, send us a link
  6. We will review your implementation and do QA to make sure everything is 100%
  7. Using the InstaVid360 app you will be able to create a spin for your vehicle
  8. Once the spin is ready it will be available to display on your VDP

Spin player available settings:

Mandatory

Spin Code
Unique code for spin. Required
Field: data-spin

Customisation

Controls Align
Set position of control buttons
Field: data-control-align
Default: bottom
Options: top, middle, bottom
Controls Hover
Enable, disable "Go inside/outside" hover buttons
Field: data-control-hover
Default: true
Options: true, false
Controls Scale
Enable, disable control button responsiveness
Field: data-control-scale
Default: true
Options: true, false
Controls Shadow
Enable, disable control button outline shadow
Field: data-control-shadow
Default: true
Options: true, false
Controls Text
Enable, disable control text variation of certain buttons
Field: data-control-titles
Default: true
Options: true, false
Controls Titles
Enable, disable control button title tooltips
Field: data-control-titles
Default: true
Options: true, false
Cursor
Custom cursor set option
Field: data-cursor
Default: basic
Options: basic, none
Exterior Keyframes
Degree interval between exterior gallery frame images
Field: data-ekf
Default: 45
Options: range between 10 - 180
Fullscreen
Enable, disable full-screen feature
Field: data-fullscreen
Default: true
Options: true, false
Gallery
Enable, disable or hide gallery feature
Field: data-gallery
Default: true
Options: true, false, hide
Height
Number of pixels or percentage string of player height
Field: data-height
Hotspots
Enable, disable or hide hotspot feature
Field: data-hotspots
Default: true
Options: true, false, hide
Hotspot Animate
Enable, disable hotspot icon animation on hover
Field: data-hotspot-animate
Default: true
Options: true, false
Hotspot Color
Set color of hotspot icon
Field: data-hotspot-color
Default: green
Options: green, blue, red, orange, white, black, grey
Hotspot Scale
Enable, disable hotspot icon scaling based relative position
Field: data-hotspot-scale
Default: true
Options: true, false
Hotspot Shadow
Enable, disable hotspot icon background shadow
Field: data-hotspot-shadow
Default: true
Options: true, false
Hotspot Titles
Enable, disable hotspot title headers
Field: data-hotspot-titles
Default: true
Options: true, false
Icon set
Icon set for buttons
Field: data-icons
Default: basic
Options: basic, sparse
Interior
Enable, disable interior feature
Field: data-interior
Default: true
Options: true, false
Interior Keyframes
Degree interval between interior gallery frame images
Field: data-ikf
Default: 90
Options: range between 10 - 180
Language
Language of player in ISO 639-1 code format
Field: data-lang
Default: en
Options: en, de, es, fr, it, zh, sk, nl, cz, ar, tr, fr-ca, pt
Loading Icon
Set position of loading icon relative to loading text
Field: data-loading-icon
Default: above
Options: above, below
Loading Interior
Enable, disable loading interior icon
Field: data-loading-interior
Default: true
Options: true, false
Loading Progress
Enable, disable loading progress value
Field: data-loading-progress
Default: true
Options: true, false
Loading Scale
Enable, disable loading box responsive resizing
Field: data-loading-scale
Default: true
Options: true, false
Preview
Spin preview type
Field: data-preview
Default: bounce
Options: spin, sway, bounce, none
Spin Start Angle
Spin start angle
Field: data-angle
Default: 0
Options: range between 0-360
Quality
Set spin content quality, options for h = high, m = medium, l = low
Field: data-quality
Default: m
Options: h, m, l
Smoothing
Set exterior frame smoothing value, a higher value results in more frames for a smoother spin and also consumes more data
Field: data-smoothing
Default: 5
Options: 1 - 10
Theme
Theme for player
Field: data-theme
Default: basic
Options: basic, dark
Width
Number of pixels or percentage string of player width
Field: data-width
Default: 100%
Zoom
Enable, disable zoom feature
Field: data-zoom
Default: true
Options: true, false
Zoom Reset
Enable, disable zoom reset feature
Field: data-zoom-reset
Default: true
Options: true, false

White-label CDN:

The player can be customized to load data from an alternative source such as a third-party CDN or using the CloudFront domain

Override JS
Set the custom path to load spin player JavaScript from
Field: data-override-js
Example: https://dstfk5pujma2h.cloudfront.net/v/master/0.6.latest/js/spin360.min.js
Override CSS
Set the custom path to load spin player style sheet from
Field: data-override-css
Example: https://dstfk5pujma2h.cloudfront.net/v/master/0.6.latest/css/spin360.min.css
Override Images
Set the custom path to load spin image content from
Field: data-override-images
Example: https://dstfk5pujma2h.cloudfront.net/{spin_code}/

The steps below describe the steps for implementing version 0.8 of the InstaVid360 Spin Player.

Step 1:

Create the HTML spin div/spin including the required spin parameter (spin code) as illustrated in the examples below.

Inline method of implementation:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"></script>
</div>
 
Advanced method of implementation:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
});
</script>

Step 2:

Set up the player to display the desired hotspot type(s). Do so by using the hotspotType parameter and its possible values: all, feature, danger, warning, or none.The default is all

Inline method with hotspot types:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-hotspotType="feature"></script>
</div>
 
Advanced method with hotspot type:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "hotspotType":"feature"
});
</script>

Step 3:

Set the player to use additional customisations, for example:

a. Language: Language of player in ISO 639-1 code format.
Field: data-lang
Default: en
Options: en, es, pt


Inline method with language customisation:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-lang="en"></script>
</div>
 
Advanced method with language customisation:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "lang":"en"
});
</script>

b. Quality: Set spin content quality, options for h = high, m = medium, l = low.
Field: data-quality
Default: m
Options: h, m, l


Inline method with quality customisation:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-quality="m"></script>
</div>
 
Advanced method with quality customisation:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "quality":"m"
});
</script>

c. Angle: Set spin start angle in the player, options range between 0-360.
Field: data-angle
Default: 0
Options: 0-360


Inline method with starting angle customisation:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-angle="0"></script>
</div>
 
Advanced method with starting angle customisation:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "angle":"0"
});
</script>

d. Hotspot Colors

Icon Field Default Description Options
data-hotspot-color grey Set the color for the feature hotspot icon. green, blue, red, orange, white, black, grey
data-hotspot-warning-color orange Set the color for the warning hotspot icon.
data-hotspot-danger-color blue Set the color for the danger hotspot icon.
All data-hotspot-all-color - Set the same color for all types of hotspot icons.
* It overrides any other hotspot color setting.

Inline method with hotspot color customisation:
<div id='spin-div' style='max-width: 640px;'>
  <script src='https://static.instavid360.com/p/0.8.latest/spin360.lite.js'
          data-spin='16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340'
          data-hotspot-all-color='red'
          
    ></script>
</div>
          

Advanced method with hotspot color customisation:
<!-- element -->
<div id='spin-div' style='max-width: 640px; margin: 0 auto;'></div>
<!-- script -->
<script src='https://static.instavid360.com/p/0.8.latest/spin360.lite.js'></script>
<script>
var spinplayer = loadSpin360('spin-div', {
  'spin':'16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340', 
  'hotspot-warning-color':'blue'
});
</script>

Step 4:

Use the 360° Spin Player functions to detect player events and errors. :

a. onError Function:
The function stored in this parameter will be executed once an error occurs within the player. It will also return a variable containing the exact error.

Inline method with onError Function:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-onError="function(error){ console.log('Spin360 player failed to load -'+error); }"></script>
</div>
 
Advanced method with onError Function:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "onError":"function(error){ console.log('Spin360 player failed to load -'+error); }"
});
</script>

b. 360° Spin Player Events
The function to retrieve interaction events from the player is the metricsReturn() function, and it should be called as follows:

Inline method with metricsReturn function:

<div id="spin-div" style="max-width: 640px; margin: 0 auto;">
  <script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"
  data-spin="16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340"
  data-metricsReturn ="function(eventType,eventName,metricsSession,playerVersion,portal,spinCode,timeStamp){console.log(eventType+','+eventName+','+metricsSession+','+playerVersion+','+portal+','+spinCode+','+timeStamp);}">
  </script>
</div>
 
Advanced method with metricsReturn Function:
<!-- element -->
<div id="spin-div" style="max-width: 640px; margin: 0 auto;"></div>
<!-- script -->
<script src="https://static.instavid360.com/p/0.8.latest/spin360.lite.js"></script>
<script>
var spinplayer = loadSpin360("spin-div", {
  "spin":"16152148091156_f3bcba7002732736acdf08cf7d45efbade11622c52cb26340", 
  "metricsReturn":function(eventType,eventName,metricsSession,playerVersion,portal,spinCode,timeStamp){
    console.log(eventType+", "+eventName+", "+metricsSession+", "+playerVersion+", "+portal+", "+spinCode+", "+timeStamp);
                  }
});
</script>

The possible events are described in the following tables:

Control Bar Button Clicks
Event Type Event Name Description
button_click exterior The exterior button was clicked. The exterior spin is displayed
button_click interior The interior button was clicked. The interior spin is in focus
button_click video The video button was clicked. The stock video is played
button_click camAngles_toggle_on he default angles button was clicked to show the default angles grid
button_click camAngles_toggle_off The default angles button was clicked to hide the default angles grid
button_click gallery_toggle_on The gallery button in the control bar was clicked to show the hotspot gallery
button_click gallery_toggle_off The gallery grid was closed either by the clicking the gallery toggle button or the close button
button_click gyro_toggle_on The motion control button on the control bar was clicked (mobile only) to enable motion control panning of the 360° Spin
button_click gyro_toggle_off The motion control button on the control bar was clicked (mobile only) to disable motion control panning of the 360° Spin
button_click hotspot_toggle_on The hotspot label button in the control bar was clicked to display the hotspot text
button_click hotspot_toggle_off The hotspot label button in the control bar was clicked to hide the hotspot text
button_click zoom_in The zoom in button on the control bar was clicked. Zooming in on the spin
button_click zoom_out The zoom out button on the control bar was clicked. Zooming out on the spin.
button_click zoom_exit The zoom exit button on the control bar was clicked. Resetting the zoom of the spin
button_click fullscreen The fullscreen button on the control bar was clicked. Bringing the player to fullscreen
button_click fullscreen_exit The fullscreen exit button on the control bar was clicked. Returning the player to normal view
Hotspots and Floating Buttons Clicks
Event Type Event Name Description
button_click exterior_float The "Go Outside" hotspot was clicked on the spin. Exterior spin is displayed
button_click interior_float The "Go Inside" hotspot was clicked on the spin. Interior spin is displayed
button_click hotspot_view A hotspot or key frame was viewed
button_click hotspot_exit The close button on the hotspot was clicked. Closing the hotspot and returning to spin view
Other Events
Event Type Event Name Description
interior_view N/A Gets called when mode is set to Interior/Interior spin is displayed
spin_interaction N/A Gets called whenever there is any kind of interaction with the player (spin panning, switching modes, zooming, playing video etc.)
exterior_view N/A Gets called when mode is set to Exterior/Exterior spin is displayed
spin_loaded N/A Runs once at the start of the script
exterior_spin N/A Exterior spin is being panned
interior_spin N/A Interior spin is being panned
spin_ping N/A The player records the spin view duration
hotspot_view N/A Gets called when a hotspot is displayed on the screen
video N/A Gets called when mode is set to Video/Video is displayed

Reporting API

The reporting API returns statistics data in JSON format which your developers can work with.
InstaVid360 will provide access to these webservice endpoints after setup is completed.

Authenticating:
Requests to the reporting API endpoints require authentication using Bearer token authorization as an HTTP header e.g. HTTP_AUTHORIZATION = Bearer {token}

Retrieving sample data:
Include sample token: RsFrHL1ST8JBZKDD0gh89TJSPLihZ5nWcssWsdoDkmScA7nn0IIo7UlrRo5P

Set timezone: ( `timezone` default is UTC )
Use the `timezone` as a query string parameter to retrieve data for the required timezone e.g. timezone=Europe-Berlin

Set date range: ( `date_from` default is the first day the current month ⁄ `date_to` default is yesterday )
Use the `date_from` and `date_to` query string parameter(s) to set the date range for the data e.g. date_from=2021-08-01&date_to=2021-08-31

Example with filtered options:
https://reports.instavid360.com/api/v2/portal/sample/usage/group?date_from=2021-08-01&date_to=2021-08-31&timezone=Europe-London

Retrieving sample data

You will be able to test using the sample token provided and the endpoints below to pull sample data.

Dealer sample report:
GET: https://reports.instavid360.com/api/v2/portal/sample/usage/dealer?dealers=12345

Sample Request:

Headers: {
  "Authorization": "Bearer RsFrHL1ST8JBZKDD0gh89TJSPLihZ5nWcssWsdoDkmScA7nn0IIo7UlrRo5P",
  "Accept": "application/json"
}

Sample Response:

{
    "data": [
    {
      "dealer_id": "12345",
      "dealer_name": "Dealership A",
      "login_android": 0,
      "login_ios": 0,
      "login_total": 0,
      "message_viewed": 4,
      "message_shared": 5,
      "message_total": 5,
      "usage_spin": 107,
      "usage_spin_message": 0,
      "usage_spin_stock": 107,
      "usage_total": 148,
      "usage_video": 41,
      "usage_video_message": 5,
      "usage_video_stock": 36
    }
  ],
  "date_timestamp": {
      "date": "2021-11-01 00:00:00",
      "timezone_type": 3,
      "timezone": "UTC"
  },
  "date_ts": "2021-11-01T00:00:00+00:00",
  "dealer_count": 1,
  "period_end": "2021-11-01T23:59:59+00:00",
  "period_start": "2021-11-01T00:00:00+00:00",
  "status": "success",
  "success": true
}


Group sample report:
GET: https://reports.instavid360.com/api/v2/portal/sample/usage/group

Sample Request:

Headers: {
  "Authorization": "Bearer RsFrHL1ST8JBZKDD0gh89TJSPLihZ5nWcssWsdoDkmScA7nn0IIo7UlrRo5P",
  "Accept": "application/json"
}

Sample Response:

{
  "data": [
    {
      "dealer_id": "12345",
      "dealer_name": "Somewhere Motors",
      "login_android": 98,
      "login_ios": 89,
      "login_total": 187,
      "message_shared": 48,
      "message_total": 121,
      "message_viewed": 76,
      "usage_spin": 66,
      "usage_spin_message": 51,
      "usage_spin_stock": 15,
      "usage_total": 222,
      "usage_video": 156,
      "usage_video_message": 79,
      "usage_video_stock": 77
    },
    {
      "dealer_id": "123ABC",
      "dealer_name": "Dealership A",
      "login_android": 13,
      "login_ios": 88,
      "login_total": 101,
      "message_shared": 13,
      "message_total": 72,
      "message_viewed": 20,
      "usage_spin": 159,
      "usage_spin_message": 80,
      "usage_spin_stock": 79,
      "usage_total": 301,
      "usage_video": 142,
      "usage_video_message": 77,
      "usage_video_stock": 65
    },
    {
      "dealer_id": "1A2B_3C4d",
      "dealer_name": "Somewhere Trucks",
      "login_android": 56,
      "login_ios": 50,
      "login_total": 106,
      "message_shared": 70,
      "message_total": 200,
      "message_viewed": 86,
      "usage_spin": 95,
      "usage_spin_message": 10,
      "usage_spin_stock": 85,
      "usage_total": 241,
      "usage_video": 146,
      "usage_video_message": 87,
      "usage_video_stock": 59
    }
  ],
  "date_from": "2021-06-01T00:00:00+00:00",
  "date_timestamp": {
      "date": "2021-07-01 09:30:00",
      "timezone_type": 3,
      "timezone": "UTC"
  },
  "date_to": "2021-06-30T23:59:59+00:00",
  "date_ts": "2021-07-01T09:30:00+00:00",
  "dealer_count": 3,
  "status": "success",
  "total": {
    "login_android": 167,
    "login_ios": 227,
    "login_total": 394,
    "message_shared": 131,
    "message_total": 393,
    "message_viewed": 182,
    "usage_spin": 320,
    "usage_spin_message": 141,
    "usage_spin_stock": 179,
    "usage_total": 764,
    "usage_video": 444,
    "usage_video_message": 243,
    "usage_video_stock": 201
  }
}


Retrieving live data

Once you have an access token you will be able to pull data from the production system using the endpoints below. Group statistics

Group statistics:
GET: https://reports.instavid360.com/api/v2/portal/{partner_code}/usage/group

Sample Request:

Headers: {
  "Authorization": "Bearer {token}",
  "Accept": "application/json"
}

Sample Response:

{
    "data": [
      {
        "dealer_id": "10236",
        "dealer_name": "Dealership A"
        "login_android": 78,
        "login_ios": 5,
        "login_total": 83,
        "message_shared": 56,
        "message_total": 207,
        "message_viewed": 37,
        "usage_spin": 107,
        "usage_spin_message": 84,
        "usage_spin_stock": 23,
        "usage_total": 224,
        "usage_video": 117,
        "usage_video_message": 58,
        "usage_video_stock": 59
      },
      {
        "dealer_id": "10953",
        "dealer_name": "Dealership B"
        "login_android": 32,
        "login_ios": 2,
        "login_total": 34,
        "message_shared": 62,
        "message_total": 262,
        "message_viewed": 110,
        "usage_spin": 126,
        "usage_spin_message": 100,
        "usage_spin_stock": 26,
        "usage_total": 172,
        "usage_video": 46,
        "usage_video_message": 2,
        "usage_video_stock": 44
      },
      {
        "dealer_id": "10137",
        "dealer_name": "Dealership C"
        "login_android": 23,
        "login_ios": 25,
        "login_total": 48,
        "message_shared": 1,
        "message_total": 214,
        "message_viewed": 33,
        "usage_spin": 95,
        "usage_spin_message": 77,
        "usage_spin_stock": 18,
        "usage_total": 142,
        "usage_video": 47,
        "usage_video_message": 41,
        "usage_video_stock": 6
      }
    ],
    "date_from": "2021-07-01T00:00:00+00:00",
    "date_timestamp": {
      "date": "2021-09-09 07:58:19.979604",
      "timezone_type": 3,
      "timezone": "UTC"
    },
    "date_to": "2021-09-01T00:00:00+00:00",
    "date_ts": "2021-09-09T07:58:19+00:00",
    "dealer_count": 3,
    "status": "success",
    "success": true,
    "total": {
      "login_android": 133,
      "login_ios": 32,
      "login_total": 165,
      "message_shared": 119,
      "message_total": 683,
      "message_viewed": 180,
      "usage_spin": 328,
      "usage_spin_message": 261,
      "usage_spin_stock": 67,
      "usage_total": 538,
      "usage_video": 210,
      "usage_video_message": 101,
      "usage_video_stock": 109
    }
}

Response description:

Field name Description
dealer_id The dealer ID of the partner dealer
dealer_name The name of the partner dealer
login_android The total count of logins to the Android app during this period
login_ios The total count of logins to the iOS app during this period
login_total The total count of logins into apps during this period
message_viewed The total count of direct message content viewed during this period
message_shared The total count of direct message sent during this period
message_total The total count of direct message created during this period
usage_spin_message The total count of spin content created via direct message during this period
usage_spin_stock The total count of spin content created via stock item during this period
usage_spin The total count of spin content created during this period
usage_video_message The total count of video content created via direct message during this period
usage_video_stock The total count of video content created via stock item during this period
usage_video The total count of video content created during this period
usage_total The total count of content created during this period

Dealer statistics:
GET: https://reports.instavid360.com/api/v2/portal/{partner_code}/usage/dealer?dealers={partner_dealer_id}

Dealers field allows for comma separated list of dealers by id

Sample Request:

Headers: {
  "Authorization": "Bearer {token}",
  "Accept": "application/json"
}

Sample Response:

{
    "data": [
      {
        "dealer_id": "10236",
        "dealer_name": "Dealership A"
        "login_android": 78,
        "login_ios": 5,
        "login_total": 83,
        "message_sent": 167,
        "message_shared": 56,
        "message_total": 207,
        "message_viewed": 37,
        "usage_spin": 107,
        "usage_spin_message": 84,
        "usage_spin_stock": 23,
        "usage_total": 224,
        "usage_video": 117,
        "usage_video_message": 58,
        "usage_video_stock": 59
      },
    ]
    "date_from": "2021-07-01T00:00:00+00:00",
    "date_timestamp": {
      "date": "2021-09-03 11:25:01.326437",
      "timezone_type": 3,
      "timezone": "UTC"
    },
    "date_to": "2021-09-01T00:00:00+00:00",
    "date_ts": "2021-09-03T11:25:01+00:00",
    "dealer_count": 1,
    "status": "success",
    "success": true
}

Response description:

Field name Description
login_android The total count of logins to the Android app during this period
login_ios The total count of logins to the iOS app during this period
login_total The total count of logins into apps during this period
message_viewed The total count of direct message content viewed during this period
message_shared The total count of direct message sent during this period
message_total The total count of direct message created during this period
usage_spin_message The total count of spin content created via direct message during this period
usage_spin_stock The total count of spin content created via stock item during this period
usage_spin The total count of spin content created during this period
usage_video_message The total count of video content created via direct message during this period
usage_video_stock The total count of video content created via stock item during this period
usage_video The total count of video content created during this period
usage_total The total count of content created during this period

Group spin statistics:
GET: https://reports.instavid360.com/api/v2/portal/{partner_code}/stats/group

Request Option:

Field Description Example
period_type Type of stats return format, Y, M, D for year, month, and day respectively. Default is D Required
date_from The first date or time in period_type in format: 'Y-m-d H:i:s' Required
date_to End date of stats in format: 'Y-m-d H:i:s' Optional
group_by Stats data can be grouped by: "spin" or "dealer" Optional
timezone Timezone location eg Europe|London Optional

Sample Request:

Headers: {
  "Authorization": "Bearer {token}",
  "Accept": "application/json"
}

Sample Response:

        {
          "status": "success",
          "data": {
              "feedprovider": {
                  "name": "InstaVid360 Demo"
              },
              "stats": [{
                      "period_type": "M",
                      "period_start": "2021-01-01 00:00:00",
                      "sessions": 7,
                      "min_duration": 0,
                      "max_duration": 420648,
                      "avg_duration": 60912,
                      "spin_loaded": 6,
                      "exterior_view": 7,
                      "exterior_spin": 1,
                      "interior_view": 0,
                      "interior_spin": 0,
                      "hotspot_view": 1,
                      "gallery_scroll": 0,
                      "button_click": 11,
                      "spin_interaction": 40,
                      "spin_loaded_unique": 6,
                      "exterior_view_unique": 7,
                      "exterior_spin_unique": 1,
                      "interior_view_unique": 0,
                      "interior_spin_unique": 0,
                      "hotspot_view_unique": 1,
                      "gallery_scroll_unique": 0,
                      "button_click_unique": 3,
                      "spin_interaction_unique": 4,
                      "dealer": {
                          "name": "Dealership A",
                          "feed_identifier": "12345",
                          "instavid_id": 134,
                          "created_at": "2021-08-28 11:57:02",
                          "deleted_at": null
                      },
                      "spin": {
                          "spincode": "16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                          "manual_vehicle": false,
                          "feedprovider_reference": "9423312",
                          "meta": {
                              "stockcode": "1234",
                              "brand": "Mercedes-Benz®",
                              "range": "GT",
                              "derivative": "4.0 V8",
                              "year": null,
                              "reg": null,
                              "vin": null
                          }
                      }
                  },
                  {
                      "period_type": "M",
                      "period_start": "2021-02-01 00:00:00",
                      "sessions": 23,
                      "min_duration": 1,
                      "max_duration": 3578,
                      "avg_duration": 200,
                      "spin_loaded": 23,
                      "exterior_view": 23,
                      "exterior_spin": 0,
                      "interior_view": 0,
                      "interior_spin": 0,
                      "hotspot_view": 0,
                      "gallery_scroll": 0,
                      "button_click": 0,
                      "spin_interaction": 0,
                      "spin_loaded_unique": 23,
                      "exterior_view_unique": 23,
                      "exterior_spin_unique": 0,
                      "interior_view_unique": 0,
                      "interior_spin_unique": 0,
                      "hotspot_view_unique": 0,
                      "gallery_scroll_unique": 0,
                      "button_click_unique": 0,
                      "spin_interaction_unique": 0,
                      "dealer": {
                          "name": "Dealership B",
                          "feed_identifier": "987654",
                          "instavid_id": 704,
                          "created_at": "2020-10-09 11:38:58",
                          "deleted_at": null
                      },
                      "spin": {
                          "spincode": "16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                          "manual_vehicle": false,
                          "feedprovider_reference": "38",
                          "meta": {
                              "stockcode": "4321",
                              "brand": "Brand A",
                              "range": "Range B",
                              "derivative": "null",
                              "year": 2021,
                              "reg": "REG123",
                              "vin": "VIN987654321"
                          }
                      }
                  },
              ]
          },
          "total": 1,
          "per_page": 1000,
          "current_page": 1,
          "last_page": 1,
          "first_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/group?page=1",
          "last_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/group?page=1",
          "next_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/group?page=1",
          "prev_page_url": null,
          "from": 1,
          "to": 1
        }
        

Response description:

Field name Description
period_type This is the type of period to format stats data. The values are Y for year, M for month, or D for day.
period_start This is the start time/date period for stats.
sessions This is the count of instances where loading the spin player was attempted within the period.
min_duration This is the shortest duration (seconds) of all sessions within the period.
max_duration This is the longest duration (seconds) of all sessions within the period.
avg_duration This is the average duration (seconds) of all sessions within the period.
spin_loaded This is the count of times the spin player completed loading within the period.
exterior_view This is the count of events when the exterior spin came into focus. This could be by loading the exterior spin or toggling into the exterior from the interior
exterior_spin This is the count of times the exterior spin was rotated within the period.
interior_view This is the count of events when the interior spin came into focus. This could be by loading the interior spin or toggling into the interior spin from the exterior spin.
interior_spin This is the count of times the interior spin was rotated within the period.
hotspot_view This is the count of hotspot views for the spin within the period.
gallery_scroll This is the count of scrolls through the spin image gallery within the period.
button_click This is the count of button clicks for the spin within the period.
spin_interaction This is the count of spin interactions within the date period. A spin interaction is recorded for every click/tap and release event.
spin_loaded_unique This is the unique count of times the spin was loaded within the period.
exterior_view_unique This is the count of unique exterior_views.
exterior_spin_unique This is the count of unique events when the the exterior spin was rotated within the period.
interior_view_unique This is the count of unique interior_views.
interior_spin_unique This is the count of unique events when the the interior spin was rotated within the period.
hotspot_view_unique This is the count of unique hotspot views within the period.
gallery_scroll_unique This is the sum of unique scrolls in the spin image gallery within the period.
button_click_unique This is the count of unique button clicks for the spin within the period.
spin_interaction_unique This is the count of unique interactions with the spin within the period.

Dealer spin statistics:
GET: https://reports.instavid360.com/api/v2/portal/{partner_code}/stats/dealer

Request Option:

Field Description Example
dealers Partner dealer id. Allows for comma separated list of dealer ids Required
period_type Type of stats return format, Y, M, D for year, month, and day respectively. Default is D Required
date_from The first date or time in period_type in format: 'Y-m-d H:i:s' Required
date_to End date of stats in format: 'Y-m-d H:i:s' Optional
group_by Dealer Stats data can be grouped by: "spin". Optional
timezone Timezone location eg Europe|London Optional

Sample Request:

Headers: {
  "Authorization": "Bearer {token}",
  "Accept": "application/json"
}

Sample Response:

{
        "status": "success",
        "data": {
            "dealer": [{
                "name": "Dealership A",
                "feedprovider": "Instavid Demo",
                "feed_identifier": "12345",
                "instavid_id": 12345
            }],
            "stats": [{
                "period_type": "M",
                "period_start": "2021-01-01 00:00:00",
                "sessions": 80,
                "min_duration": 0,
                "max_duration": 1880,
                "avg_duration": 577,
                "spin_loaded": 35,
                "exterior_view": 94,
                "exterior_spin": 0,
                "interior_view": 0,
                "interior_spin": 0,
                "hotspot_view": 78,
                "gallery_scroll": 19,
                "button_click": 196,
                "spin_interaction": 203,
                "spin_loaded_unique": 35,
                "exterior_view_unique": 36,
                "exterior_spin_unique": 0,
                "interior_view_unique": 0,
                "interior_spin_unique": 0,
                "hotspot_view_unique": 15,
                "gallery_scroll_unique": 9,
                "button_click_unique": 19,
                "spin_interaction_unique": 23,
                "dealer": {
                    "name": "Dealership A",
                    "feed_identifier": "12345"
                },
                "spin": {
                    "spincode": "16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
                    "manual_vehicle": true,
                    "feedprovider_reference": "REF123",
                    "meta": {
                        "stockcode": "54321",
                        "brand": "Brand A",
                        "range": "Range B",
                        "derivative": null,
                        "year": 2021,
                        "reg": "REG123",
                        "vin": "VIN987654321"
                    }
                }
            }]
        },
        "total": 1,
        "per_page": 1000,
        "current_page": 1,
        "last_page": 1,
        "first_page_url": "https://reports.instavid360.com/api/v2/portal/sample/dealer?page=1",
        "last_page_url": "https://reports.instavid360.com/api/v2/portal/sample/dealer?page=1",
        "next_page_url": null,
        "prev_page_url": null,
        "from": 1,
        "to": 1
    }
}

Response description:

Field name Description
period_type This is the type of period to format stats data. The values are Y for year, M for month, or D for day.
period_start This is the start time/date period for stats.
sessions This is the count of instances where loading the spin player was attempted within the period.
min_duration This is the shortest duration (seconds) of all sessions within the period.
max_duration This is the longest duration (seconds) of all sessions within the period.
avg_duration This is the average duration (seconds) of all sessions within the period.
spin_loaded This is the count of times the spin player completed loading within the period.
exterior_view This is the count of events when the exterior spin came into focus. This could be by loading the exterior spin or toggling into the exterior from the interior
exterior_spin This is the count of times the exterior spin was rotated within the period.
interior_view This is the count of events when the interior spin came into focus. This could be by loading the interior spin or toggling into the interior spin from the exterior spin.
interior_spin This is the count of times the interior spin was rotated within the period.
hotspot_view This is the count of hotspot views for the spin within the period.
gallery_scroll This is the count of scrolls through the spin image gallery within the period.
button_click This is the count of button clicks for the spin within the period.
spin_interaction This is the count of spin interactions within the date period. A spin interaction is recorded for every click/tap and release event.
spin_loaded_unique This is the unique count of times the spin was loaded within the period.
exterior_view_unique This is the count of unique exterior_views.
exterior_spin_unique This is the count of unique events when the the exterior spin was rotated within the period.
interior_view_unique This is the count of unique interior_views.
interior_spin_unique This is the count of unique events when the the interior spin was rotated within the period.
hotspot_view_unique This is the count of unique hotspot views within the period.
gallery_scroll_unique This is the sum of unique scrolls in the spin image gallery within the period.
button_click_unique This is the count of unique button clicks for the spin within the period.
spin_interaction_unique This is the count of unique interactions with the spin within the period.

Vehicle Spin statistics:
GET: https://reports.instavid360.com/api/v2/portal/{partner_code}/stats/vehicle

Request Option:

Field Description Example
feedprovider_reference The unique vehicle identifier in the feed Required
period_type Type of stats return format, Y, M, D for year, month, and day respectively. Default is D Required
date_from The first date or time in period_type in format: 'Y-m-d H:i:s' Required
date_to End date of stats in format: 'Y-m-d H:i:s' Optional
timezone Timezone location eg Europe|London Optional

Sample Request:

Headers: {
  "Authorization": "Bearer {token}",
  "Accept": "application/json"
}

Sample Response:

    {
      "status": "success",
      "data": {
          "dealer": {
              "name": "Dealership A",
              "feedprovider": "InstaVid360 Demo",
              "feed_identifier": "12345",
              "instavid_id": 134
          },
          "spin": {
              "spincode": "16303531620341_5edd084cd02986cc88410dfa48eaeeb8ae70b6cf1b517b7ea",
              "manual_vehicle": false,
              "feedprovider_reference": "13973",
              "meta": {
                  "stockcode": "54321",
                  "brand": "Brand A",
                  "range": "Range B",
                  "derivative": "null",
                  "year": 2021,
                  "reg": "REG123",
                  "vin": "VIN987654321"
              }
          },
          "stats": {
              "current_page": 1,
              "data": [{
                  "id": "M-1609459200-53870-30-1541",
                  "period_type": "M",
                  "period_start": "2021-01-01 00:00:00",
                  "sessions": 1134,
                  "min_duration": 0,
                  "max_duration": 643057,
                  "avg_duration": 5407,
                  "spin_loaded": 1105,
                  "exterior_view": 1132,
                  "exterior_spin": 0,
                  "interior_view": 0,
                  "interior_spin": 0,
                  "hotspot_view": 0,
                  "gallery_scroll": 76,
                  "button_click": 213,
                  "spin_interaction": 420,
                  "spin_loaded_unique": 1105,
                  "exterior_view_unique": 1132,
                  "exterior_spin_unique": 0,
                  "interior_view_unique": 0,
                  "interior_spin_unique": 0,
                  "hotspot_view_unique": 0,
                  "gallery_scroll_unique": 19,
                  "button_click_unique": 28,
                  "spin_interaction_unique": 47
              }],
              "first_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/vehicle?page=1",
              "from": 1,
              "last_page": 1,
              "last_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/vehicle?page=1",
              "next_page_url": null,
              "path": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/vehicle",
              "per_page": 1000,
              "prev_page_url": null,
              "to": 1,
              "total": 1
          }
      },
      "total": 1,
      "per_page": 1000,
      "current_page": 1,
      "last_page": 1,
      "first_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/vehicle?page=1",
      "last_page_url": "https://reports.instavid360.com/api/v2/portal/{portal_code}/stats/vehicle?page=1",
      "next_page_url": null,
      "prev_page_url": null,
      "from": 1,
      "to": 1
  }
  

Response description:

Field name Description
period_type This is the type of period to format stats data. The values are Y for year, M for month, or D for day.
period_start This is the start time/date period for stats.
sessions This is the count of instances where loading the spin player was attempted within the period.
min_duration This is the shortest duration (seconds) of all sessions within the period.
max_duration This is the longest duration (seconds) of all sessions within the period.
avg_duration This is the average duration (seconds) of all sessions within the period.
spin_loaded This is the count of times the spin player completed loading within the period.
exterior_view This is the count of events when the exterior spin came into focus. This could be by loading the exterior spin or toggling into the exterior from the interior.
exterior_spin This is the count of times the exterior spin was rotated within the period.
interior_view This is the count of events when the interior spin came into focus. This could be by loading the interior spin or toggling into the interior spin from the exterior spin.
interior_spin This is the count of times the interior spin was rotated within the period.
hotspot_view This is the count of hotspot views for the spin within the period.
gallery_scroll This is the count of scrolls through the spin image gallery within the period.
button_click This is the count of button clicks for the spin within the period.
spin_interaction This is the count of spin interactions within the date period. A spin interaction is recorded for every click/tap and release event.
spin_loaded_unique This is the unique count that customer have loaded the spin during this date period.
exterior_view_unique This is the count of unique exterior_views.
exterior_spin_unique This is the count of unique events when the the exterior spin was rotated within the period.
interior_view_unique This is the count of unique interior_views.
interior_spin_unique This is the count of unique events when the the interior spin was rotated within the period.
hotspot_view_unique This is the count of unique hotspot views within the period.
gallery_scroll_unique This is the sum of unique scrolls in the spin image gallery within the period.
button_click_unique This is the count of unique button clicks for the spin within the period.
spin_interaction_unique This is the count of unique interactions with the spin within the period.