PHP Classes
elePHPant
Icontem

jApi RPC : Handle client and server API calls

Recommend this page to a friend!
  Info   View files View files (15)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2013-09-27 (3 years ago) RSS 2.0 feedNot yet rated by the usersTotal: 296 All time: 7,010 This week: 889Up
Version License PHP version Categories
japi-rpc 1.0Freely Distributable5PHP 5, User Management, Web services
Description Author

This package can handle client and server API calls.

The server classes can handle remote calls to an API implemented by custom classes.

The server classes can forward the calls to the API classes with the names as call parameters along with the functions being called.

API calls are available to establish authenticated user session management storing the user session data in files associated to cookies.

A client class is also made available to obtain access authorization from the server and keep it as a session token.

Picture of Bijaya Kumar  Behera
Name: Bijaya Kumar Behera <contact>
Classes: 6 packages by
Country: India India
Innovation award
Innovation award
Nominee: 1x

Winner: 1x

Details
How to setup a jApi severver

1. open the jApi_config.php
2. create a new auth token id ,ie in example "jApi-12-4858"
3. $jApi_rules['jApi-12-4858'], $jApi_rules['jApi-12-4859'] ....
4. assign auth api user IP in 'auth_ip' from where api session request will sent to jAPi server
5. assign auth verify user url 
6. create api method 
    create a folder i,e jApi_server/jApi_accounts/jApi-12-4858/classes
    then create a file jApi_default_class.php
    code : 
    <?php
		class default_jApi_class extends jApi_class
		{
			static function function1 ($userid, $sess_data) {

			}
		}
	?>



How to setup a jApi cleint
1. open the jApi_config.php
2. // assign ur jApi JSON Api server 

define('jApi_auth_token', 'jApi-12-4858');

define('jApi_uri', 'http://localhost/jApi_server/pull.php');


3.  on client html javascript
   jApi.doApiCall('function1');
    or 
   jApi.doApiCall('default.function1');


   jApi.doApiCall('<class>.<method>');
  Files folder image Files  
File Role Description
Files folder imagejApi_client (4 files, 2 directories)
Files folder imagejApi_server (4 files, 3 directories)
Accessible without login Plain text file readme.txt Doc. example file

 Version Control Unique User Downloads Download Rankings  
 0%
Total:296
This week:0
All time:7,010
This week:889Up