Skip to main content

Nextcloud — Files & WebDAV

The umbrella Nextcloud integration. Backs all file operations the assistant performs against your Nextcloud.

Integration IDnextcloud
AuthNC session (when embedded) or OAuth Bearer (standalone) or Basic + app password (fallback)
Required scopeFILES, DAV
Sourceserver/integrations/nextcloudTools.js (54 KB, comprehensive)

Tools exposed

ToolPurpose
nextcloud_list_filesList files in a folder.
nextcloud_search_filesFull-text search.
nextcloud_read_fileFetch the contents of a file.
nextcloud_upload_fileUpload a new file or overwrite.
nextcloud_create_folderCreate a folder.
nextcloud_share_fileCreate an internal share or a public link.
nextcloud_move_fileMove / rename.
nextcloud_copy_fileCopy.
nextcloud_delete_fileDelete (moves to trashbin).
nextcloud_get_file_versionsBrowse the version history.
nextcloud_restore_file_versionRestore a previous version.

All tools take paths relative to the user's root (/Documents/Foo.pdf, not /remote.php/dav/files/<uid>/Documents/Foo.pdf).

Auth details

Embedded in Nextcloud (preferred)

Through the connector's HMAC /nc/* proxy. The Bee Flow service signs the call with the tenant key; the connector forwards it to NC with EX-APP-USER-ID: <yourUid>. AppAPI switches the request context server-side. No password ever leaves Nextcloud.

Standalone (no connector)

OAuth 2.0 with Nextcloud:

OAUTH_NEXTCLOUD_CLIENT_ID=<app-id>
OAUTH_NEXTCLOUD_CLIENT_SECRET=<secret>
OAUTH_NEXTCLOUD_BASE_URL=https://nc.example.com

Register the OAuth client in NC at Administration → Security → OAuth 2.0 clients. Redirect URI: https://your-host/auth/nextcloud/callback.

Basic + app password (fallback)

For users who didn't connect via OAuth. The user sets it in Settings → Account → Integrations → Nextcloud → Add app password. NC generates the password and stores it AES-encrypted in Postgres (BEEFLOW_ENCRYPTION_KEY).

Scopes & permissions

All tools run under the calling user's NC permissions. The assistant cannot access other users' files; sharing tools require the user's existing share permissions.

Privacy Shield interaction

File contents pulled via nextcloud_read_file are scanned by the Privacy Shield before injection into the prompt. If DLP is in block mode, prompts referencing file contents with sensitive categories are refused.

Common errors

ErrorCauseFix
401 UnauthorizedApp password rotatedRe-add in user settings.
403 Forbidden on shareUser lacks share permissionNC admin grants the share role.
404 Not FoundPath typoUse absolute paths from user root.
Quota exceededNC quotaFree up space or raise quota in NC.

Group-level disable

Org admins can disable nextcloud at the org or per-group level. Disabling for a group removes all 11 file tools from that group's users. See Admin → NC integrations.