Our API allows you to retrieve informations from our website via GET request using the following GET parameters:
type
Defines the type of the query you want to run. This parameter is required and must be filled in.
Possible values:
username
Defines the username of the profile you want to retrieve information of. This parameter works with profile_data type parameter only. This parameter is not required if you're using profileid parameter instead, otherwise it must be filled in.
Allowed values: Username of a specific User or Page.
postid
Defines the ID of the post you want to retrieve information of. This parameter works with post_data type parameter only. This parameter must be filled in.
Allowed values: Numeric ID of a specific Post.
profileid
Defines the ID of the profile you want to retrieve information of. This parameter works with profile_data type parameter only. This parameter is not required if you're using username parameter instead, otherwise it must be filled in.
Allowed values: Numeric ID of a specific User or Page.
query
Defines the search keyword you want to run search on.
Allowed values: Alphabets A-Z and numbers 0-9.
limit
Defines the limit of the items you want to retrieve.
Allowed values: Numeric 0-9.
Default value: 5
Examples on how to make an API request:
To retrieve profile data of a User or Page:
http://www.satinalma.net/api/v1.0/?type=profile_data&username=USERNAME
To retrieve data of a Post/Story:
http://www.satinalma.net/api/v1.0/?type=post_data&postid=POST_ID
To retrieve list of posts/stories posted by a User or Page:
http://www.satinalma.net/api/v1.0/?type=profile_posts&profileid=PROFILE_ID
To retrieve list of Users or Pages based on your search query:
http://www.satinalma.net/api/v1.0/?type=search&query=QUERY&limit=LIMIT
Examples on how to decode API data:
PHP:
<?php
$json = file_get_contents("http://www.satinalma.net/api/v1.0/?type=profile_data&username=1");
$data = json_decode($json, true);
print_r($data);
?>
Javascript (with jQuery):
var url = 'http://www.satinalma.net/api/v1.0/?type=profile_data&username=1';
$.getJSON(url, function (json)
{
# your code
});