From 9da3091b2efa9c3a6ff99891d75a416242475a5f Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 30 Dec 2008 15:20:19 -0500 Subject: Laconica-specific extensions for Twitter API darcs-hash:20081230202019-84dde-0aab26044f990fc1039c669cd36860b5389fab64.gz --- actions/twitapilaconica.php | 111 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 actions/twitapilaconica.php (limited to 'actions') diff --git a/actions/twitapilaconica.php b/actions/twitapilaconica.php new file mode 100644 index 000000000..092f9e7d1 --- /dev/null +++ b/actions/twitapilaconica.php @@ -0,0 +1,111 @@ +. + * + * @category Twitter + * @package Laconica + * @author Evan Prodromou + * @copyright 2008 Control Yourself, Inc. + * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 + * @link http://laconi.ca/ + */ + +if (!defined('LACONICA')) { + exit(1); +} + +require_once INSTALLDIR.'/lib/twitterapi.php'; + +/** + * Laconica-specific API methods + * + * This class handles all /laconica/ API methods. + * + * @category Twitter + * @package Laconica + * @author Evan Prodromou + * @copyright 2008 Control Yourself, Inc. + * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 + * @link http://laconi.ca/ + */ + +class TwitapilaconicaAction extends TwitterapiAction +{ + /** + * A version stamp for the API + * + * Returns a version number for this version of Laconica, which + * should make things a bit easier for upgrades. + * + * @param array $args Web arguments + * @param array $apidata Twitter API data + * + * @return void + * + * @see ApiAction::process_command() + */ + + function version($args, $apidata) + { + parent::handle($args); + common_server_error(_('API method under construction.'), 501); + } + + /** + * Dump of configuration variables + * + * Gives a full dump of configuration variables for this instance + * of Laconica, minus variables that may be security-sensitive (like + * passwords). + * + * @param array $args Web arguments + * @param array $apidata Twitter API data + * + * @return void + * + * @see ApiAction::process_command() + */ + + function config($args, $apidata) + { + parent::handle($args); + common_server_error(_('API method under construction.'), 501); + } + + /** + * WADL description of the API + * + * Gives a WADL description of the API provided by this version of the + * software. + * + * @param array $args Web arguments + * @param array $apidata Twitter API data + * + * @return void + * + * @see ApiAction::process_command() + */ + + function wadl($args, $apidata) + { + parent::handle($args); + common_server_error(_('API method under construction.'), 501); + } +} -- cgit v1.2.3-54-g00ecf