| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- <?php
- namespace Models {
- class APIKey {
- //
- private $apiKey;
- /**
- *
- */
- public function __construct() {
- }
- /**
- * Make sure origin is allowed to use the API.
- */
- public function verifyKey($apiKey, $origin) {
- $this->apiKey = $apiKey;
- return true;
- }
- /**
- * Check API permissions using the API key, an endpoint and a method.
- */
- public function isGranted($endpoint, $method) {
- return true;
- }
- /**
- *
- */
- public function get() {
- return $apiKey;
- }
- }
- }
- ?>
|