. * */ namespace Friendica\Module\Api\Mastodon; use Friendica\Core\Logger; use Friendica\Core\System; use Friendica\DI; use Friendica\Module\BaseApi; /** * Dummy class for all currently unimplemented endpoints */ class Unimplemented extends BaseApi { /** * @param array $parameters * @throws \Friendica\Network\HTTPException\InternalServerErrorException */ public static function rawContent(array $parameters = []) { $path = DI::args()->getQueryString(); Logger::info('Unimplemented API call', ['path' => $path]); $error = DI::l10n()->t('API endpoint "%s" is not implemented', $path); $error_description = DI::l10n()->t('The API endpoint is currently not implemented but might be in the future.');; $errorobj = new \Friendica\Object\Api\Mastodon\Error($error, $error_description); System::jsonError(501, $errorobj->toArray()); } }