3 namespace Friendica\Capabilities;
5 use Friendica\Network\HTTPException\InternalServerErrorException;
7 interface ICanCreateResponses extends IRespondToRequests
10 * Adds a header entry to the module response
12 * @param string $header
13 * @param string|null $key
15 public function setHeader(string $header, ?string $key = null): void;
18 * Adds output content to the module response
20 * @param mixed $content
22 public function addContent($content): void;
25 * Sets the response type of the current request
28 * @param string|null $content_type (optional) overrides the direct content_type, otherwise set the default one
30 * @throws InternalServerErrorException
32 public function setType(string $type, ?string $content_type = null): void;