<?php

/**
 * THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
 * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 *
 * @package clearFusionCMS
 * @copyright Copyright (c) 2016 clearFusionCMS. All rights reserved.
 * @link http://clearfusioncms.com
 */

/**
 * cfGetApiKey Class
 *
 * Helper class for accessing 3rd Party API keys.
 *
 * @package clearFusionCMS
 */
class cfGetApiKey {

	/**
	 * Get the facebook App ID.
	 *
	 * @return mixed The App ID or null.
	 */
	static function facebookAppID() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('facebook_appid');
	}

	/**
	 * Get the facebook App Secret.
	 *
	 * @return mixed The App Secret or null.
	 */
	static function facebookAppSecret() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('facebook_appsecret');
	}

	/**
	 * Get the Google maps API key.
	 *
	 * @return mixed The API Key or null.
	 */
	static function googleMaps() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('google_mapsapi');
	}

	/**
	 * Get the reCaptcha site key.
	 *
	 * @return mixed The API Key or null.
	 */
	static function recaptchaSiteKey() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('recaptcha_sitekey');
	}

	/**
	 * Get the reCaptcha secret key.
	 *
	 * @return mixed The API Key or null.
	 */
	static function recaptchaSecretKey() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('recaptcha_secretkey');
	}

	/**
	 * Get the twitter consumer key.
	 *
	 * @return mixed The API Key or null.
	 */
	static function twitterConsumerKey() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('twitter_consumer');
	}

	/**
	 * Get the twitter secret.
	 *
	 * @return mixed The API Key or null.
	 */
	static function twitterSecret() {
		$cfg = clearFusionCMS::getSiteConfig('cfSystemSocialAPI');
		return $cfg->get('twitter_secret');
	}
}
