smsgateway/gatewayBackend.php

61 lines
1.5 KiB
PHP
Raw Normal View History

2011-09-29 16:09:59 +00:00
<?php
interface gatewayBackend
{
/**
*
* @param String $username
* @param String $password
* @param String $ip
* @param String $sessionId
* @return String $token
*/
2011-09-29 16:50:21 +00:00
public function getToken($username, $password, $ip, $sessionId);
/**
*
* @param String $token
* @param String $sessionId
* @param String $ip
* @return Boolean
*/
public function checkToken($token, $sessionId, $ip);
/**
* removeToken() Remove a logged out user's token
*
* @param String $token
*/
public function removeToken($token);
2011-09-29 16:09:59 +00:00
/**
2011-09-29 16:50:21 +00:00
* sendSMS()
*
* Send SMS message to recipient's phone number
* @param String $token
* @param String $recipient
* @param String $message
* @param Array $passwordLocations
* @return Boolean
2011-09-29 16:09:59 +00:00
*/
2011-09-29 16:50:21 +00:00
public function sendSMS($token, $recipient, $message, $passwordLocations);
/**
* auditLog() Log audit messages
*
* @param String $ip
* @param String $event
* @param String $message
*/
public function auditLog($ip, $event, $message);
/**
* messageLog() Log sent messages
*
* @param String $recipient
* @param String $message
* @param String $ip
*/
public function messageLog($recipient, $message, $ip);
2011-09-29 16:09:59 +00:00
}