diff --git a/.htaccess b/.htaccess
index db4f32a1fbb4a..0e3a079576c9a 100644
--- a/.htaccess
+++ b/.htaccess
@@ -199,3 +199,29 @@
AddDefaultCharset utf-8
Options -Indexes
+#### DO NOT CHANGE ANYTHING ABOVE THIS LINE ####
+
+ErrorDocument 403 //index.php/error/403
+ErrorDocument 404 //index.php/error/404
+
+ Options -MultiViews
+ RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1]
+ RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1]
+ RewriteCond %{REQUEST_FILENAME} !\.(css|js|mjs|svg|gif|ico|jpg|jpeg|png|webp|html|otf|ttf|woff2?|map|webm|mp4|mp3|ogg|wav|flac|wasm|tflite)$
+ RewriteCond %{REQUEST_FILENAME} !/core/ajax/update\.php
+ RewriteCond %{REQUEST_FILENAME} !/core/img/(favicon\.ico|manifest\.json)$
+ RewriteCond %{REQUEST_FILENAME} !/(cron|public|remote|status)\.php
+ RewriteCond %{REQUEST_FILENAME} !/ocs/v(1|2)\.php
+ RewriteCond %{REQUEST_FILENAME} !/robots\.txt
+ RewriteCond %{REQUEST_FILENAME} !/(ocs-provider|updater)/
+ RewriteCond %{REQUEST_URI} !^/\.well-known/(acme-challenge|pki-validation)/.*
+ RewriteCond %{REQUEST_FILENAME} !/richdocumentscode(_arm64)?/proxy.php$
+ RewriteRule . index.php [PT,E=PATH_INFO:$1]
+ RewriteBase /
+
+ SetEnv front_controller_active true
+
+ DirectorySlash off
+
+
+
diff --git a/apps/webhook_listeners/lib/Service/TokenService.php b/apps/webhook_listeners/lib/Service/TokenService.php
index dce6a56f03f35..40780956299e2 100644
--- a/apps/webhook_listeners/lib/Service/TokenService.php
+++ b/apps/webhook_listeners/lib/Service/TokenService.php
@@ -65,7 +65,7 @@ public function __construct(
*
* @param WebhookListener $webhookListener
* @param ?string $triggerUserId the user that triggered the webhook call
- * @return array{user_ids?:array,user_roles?:array{owner?:array,trigger?:array}}
+ * @return array{user_ids?:array,owner?:array{userId:string, token: string, baseUrl: string},trigger?:array{userId:string, token: string, baseUrl: string}}
*/
public function getTokens(WebhookListener $webhookListener, ?string $triggerUserId): array {
$tokens = [];