Active 9 Open API

You may retrieve information via GET requests to our API. There is no limit to the number of requests you can make.

API URL: http://www.active9.com/social/api.php

API VERSION: 1.0



User Query

Poll user data via JSON from a passed user name. The result set contains the members public information. Private information is hidden in this scope.

Params

Parameter Description Must Be Signed In
user JSON decoded response with total_message (total messages of user), followers, following, username, name (full name of user), pic (picture of user), bio, url (website of user), fb (facebook profile of user), tw (twitter profile of user), gp (google+ profile of user), location No

Call http://www.active9.com/social/api.php?user=example

Result:

{
	"data":{
		"total_message":"3",
		"followers":"1",
		"friends":"10",
		"following":"2",
		"username":"example",
		"name":"Lorem Ipsum",
		"pic":"http://www.active9.com/social/assets/pic/example.jpg",
		"bio":"lorem ipsum dolor sit amet",
		"url":"http://www.active9.com/social/",
		"fb":"example",
		"tw":"example",
		"gp":"example",
		"location":"Lipsum"
	}
}

PHP example

<?php
$api_call = file_get_contents("http://www.active9.com/social/api.php?user=admin");
print_r(json_decode($api_call));
?>

JQuery example

<div id="#user_data" />
<script>
$.getJSON('http://www.active9.com/social/api.php?user=admin', 
	function(data){
		content = '<p>' + data.username + '</p>';
		content += '<p>' + data.location + '</p>';
		content += '<img src="' + data.pic + '"/>';
		content += '<br/>';
		$(content).appendTo("#user_data");
});
</script>


Search Query

Poll social search data via JSON from a passed url. The result set contains a mixed data set of people and messages associated with the given search criteria.

Params

Parameter Description Must Be Signed In
search JSON decoded response with results (if any) No

Call http://www.active9.com/social/api.php?search=active9

Result:

{
	"data":[{
		"m_id":"9",
		"uid":"1",
		"message":"Just making a few finishing touches to the new rendition of Active9 Social. All users will need to re-register in order to use the new Active 9 Social.",
		"created":"2013-04-27 13:47:58",
		"username":"admin",
		"name":"Active9",
		"pic":"c18d414618b77eff9ed59bfc30fe1eab.png"
	}]
}

PHP example

<?php
$api_call = file_get_contents("http://www.active9.com/social/api.php?search=active9");
echo print_r(json_decode($api_call));
?>

JQuery example

<div id="#search_data" />
<script>
$.getJSON('http://www.active9.com/social/api.php?search=active9', 
	function(data){
		content = '<p>' + data + '</p>';
		$(content).appendTo("#search_data");
});
</script>


Love Button Query

Poll love button data via JSON from a passed url. The result set contains the number of loves associated with the given url.

Params

Parameter Description Must Be Signed In
love JSON decoded response with value (total value of loves) No

Call http://www.active9.com/social/api.php?love=http://www.active9.com/

Result:

{
	"data":{
		"lovers":"1"
	}
}

PHP example

<?php
$api_call = file_get_contents("http://www.active9.com/social/api.php?love=http://www.active9.com/");
echo print_r(json_decode($api_call));
?>

JQuery example

<div id="#love_button_data" />
<script>
$.getJSON('http://www.active9.com/social/api.php?love=http://www.active9.com/', 
	function(data){
		content = '<p>' + data.lovers + '</p>';
		$(content).appendTo("#love_button_data");
});
</script>


Verify Logged In Query

Poll logged in data via JSON. The result set contains a 1 if you are signed in or a 0 if you are not.

Params

Parameter Description Must Be Signed In
verify_logged_in JSON decoded response with a boolean of true or false No

Call http://www.active9.com/social/api.php?verify_logged_in=1

Result:

{
	"data":{
		"logged_in":"true"
	}
}

PHP example

<?php
$api_call = file_get_contents("http://www.active9.com/social/api.php?verify_logged_in=1");
echo print_r(json_decode($api_call));
?>

JQuery example

<div id="#verify_logged_in_data" />
<script>
$.getJSON('http://www.active9.com/social/api.php?verify_logged_in=1', 
	function(data){
		content = '<p>' + data.verify_logged_in + '</p>';
		$(content).appendTo("#verify_logged_in_data");
});
</script>