forked from grumpydevelop/federator
31 lines
688 B
PHP
31 lines
688 B
PHP
<?php
|
|
/**
|
|
* SPDX-FileCopyrightText: 2024 Sascha Nitsch (grumpydeveloper) https://contentnation.net/@grumpydevelop
|
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
|
*
|
|
* @author Sascha Nitsch (grumpydeveloper)
|
|
**/
|
|
|
|
namespace Federator\Api;
|
|
|
|
/**
|
|
* API interface
|
|
*/
|
|
interface APIInterface
|
|
{
|
|
/**
|
|
* run given url path
|
|
*
|
|
* @param array<string> $paths path array split by /
|
|
*
|
|
* @param \Federator\Data\User|false $user user who is calling us
|
|
* @return bool true on success
|
|
*/
|
|
public function exec($paths, $user);
|
|
|
|
/**
|
|
* get internal represenation as json string
|
|
* @return string json string or html
|
|
*/
|
|
public function toJson();
|
|
}
|