Hello,
I’m developing a NC App which provides several RESTful APIs, some are GET and others are POST.
I followed the developer documentation in https://docs.nextcloud.com/server/10/developer_manual/app/api.html.
I needed to add @CORS to my APIs since the client has different origin.
The requests to the API is sometimes extremely slow (almost 30 sec), and sometimes “magically” a matter of one second.
When I remove the @CORS annotation and use a local client then I get no such problem.
Here is my API Controller constructor:
public function __construct($appName, IRequest $request) { parent::__construct( $appName, $request, 'GET, POST', 'Authorization, Content-Type, Accept', 1728000); }
Any ideas?