Videos Integration examples (NEW)

External ID usage

When using the external ID to request for a clip, you should also provide, in the URL request, the identity of the customer in our system because the external ids may not be unique. The whole url will look like that:

https://api.immoviewer.com/rest/v1/video?identity={IDENTITY}&externalID={EXTERNAL_ID} 

In order to integrate videos into a website, there 2 main solutions:


1 - Pop-up clipnow Integration

  • Replace {EXTERNAL_ID} with the external object ID for your expose. You could alternatively provide the objectID instead (the internal ID from the portals Immobilienscout24, Immonet or Immowelt). Provide it using the following url: https://api.immoviewer.com/rest/v1/video?objectID={OBJECT_ID} 
  • Replace {IDENTITY} with the identity of the customer in Clipnow.

    code
    <html>
    	<head>
    		<!-- Insert this code in the <head> tag -->
    		<script type="text/javascript" src="https://code.jquery.com/jquery-latest.min.js"></script>
    		<!-- Colorbox is used for the pop-Up -->
    		<script type="text/javascript" src="https://assets-immobilien.s3.amazonaws.com/colorbox/jquery.colorbox-min.js"></script>
         	<!-- you can choose between  the style colorbox5.css, colorbox2.css and colorbox6.css -->
    		<link rel="stylesheet" href="https://assets-immobilien.s3.amazonaws.com/colorbox/colorbox6.css" type="text/css" media="screen" />
    		<!-- Finished insertion -->	
    	</head>
    	<body>
    		<!-- Insert this part wherever (inside the body tag) you want to show the link -->
        	<a id="{EXTERNAL_ID}" class='iframe' style="display : none;" href="">Play Video</a>	
    		<!-- Finished insertion -->	
     
    <!-- Insert this script in the end -->
    <script type='text/javascript'>            
    $(document).ready(function(){
    	$(".iframe").colorbox({iframe:true, width:670, height:422});
    	$.ajax({
    		url: 'https://api.immoviewer.com/rest/v1/video?identity={IDENTITY}&externalID={EXTERNAL_ID}',
    		dataType: 'jsonp',
    		success: function(data){
    			if(data['iframe'] != null && data['iframe'] != ""){
    				$('#{EXTERNAL_ID}').attr('href',data['iframe']);
    				$('#{EXTERNAL_ID}').show()
    			}
    		}
    	});
    })
    </script>
    <!-- Finished insertion -->	
    	</body>
    </html>
    


2 - Direct youtube Integration

  • Replace {EXTERNAL_ID} with the external object ID for your expose. You could alternatively provide the objectID instead (the internal ID from the portals Immobilienscout24, Immonet or Immowelt). Provide it using the following url: https://clip-api2.clipnow.com/rest/v1/video?objectID={EXTERNAL_ID} 
  • Replace {IDENTITY} with the identity of the customer in Clipnow.
code
<html>
	<head>
		<!-- Insert this code in the <head> tag -->
		<script type="text/javascript" src="https://code.jquery.com/jquery-latest.min.js"></script>
		<!-- Finished insertion -->	
	</head>
	<body>
		<!-- Insert this part wherever (inside the body tag) you want to show the iframe -->
    	<iframe id="{EXTERNAL_ID}" type="text/html" width="640" height="360" frameborder="0" allowfullscreen></iframe>		
		<!-- Finished insertion -->	
 
<!-- Insert this script in the end-->
<script type='text/javascript'>            
$(document).ready(function(){
	$.ajax({
		url: 'https://api.immoviewer.com/rest/v1/video?identity={IDENTITY}&externalID={EXTERNAL_ID}',
		dataType: 'jsonp',
		success: function(data){
			$('#{EXTERNAL_ID}').attr('src',"https://www.youtube.com/embed/"+data['youtube'] + "?modestbranding=1&rel=0&color=white&theme=light");
		}
	});
})
</script>
<!-- Finished insertion -->	
	</body>
</html>


Full URL request information (advanced)

URLhttps://clip-api2.clipnow.com/rest/v1/video 

Method: GET

Request Query parameters:

Parameter
Meaning
identityClipnow user identity
externalIDitem's external ID (usually the ID of the CRM software)
objectIDitem's internal ID (the internal ID of the portal: Immobilienscout24, Immonet, Immowelt...)
serviceIDthe customer number or customer name of the portal (Autoscout, Mobile)
scope

Specify what do you want to be returned in the response,

portalType
String containig the name of the Portal/CRM

 All methods are optional, however either the objectID has to be present or a combination of externalID and identity/serviceID.

Return Type:

Parameter
Meaning
mp4Direct link to the mp4 file
youtubeThe youtube ID (when the clip has been uploaded to Youtube).
iframeA blank website which only contains a video player (useful for iframe integration in your own website)
thumbnailThe thumbnail image link of the video