List Shares

nextcloud.list_shares
ActionFiles & storageconnection required

Calls the Nextcloud API with the connection's credentials.

List the shares the connection's account owns. Give a path to list only the shares on that file or folder.

Connection

Required
Yes — the node will not save without one
Auth type
Username & password
Providers
Nextcloud
Secret shape
{"username": "…", "password": "<app password>"}
Config it needs
base_url
Resolved by
config.connection_id, else node.connection_id

Configuration

3 fields, none required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.

FieldTypeRequiredDefaultConstraintsExample
path
Only list shares on this file or folder; blank lists every share.
stringNo———
reshares
Include shares other people made of this resource, not just your own.
booleanConditionalfalseonly with path—
subfiles
List the shares on the items inside the folder named by path.
booleanConditionalfalseonly with path—

Example configuration

Every value below is the contract’s own example or default — nothing invented.

{
  "reshares": false,
  "subfiles": false
}

Output

One shape.

result

FieldTypeExample
items[].id
The share id, used by get, update and delete.
string42
items[].share_type
The numeric shareType Nextcloud recorded.
number—
items[].uid_owner
The account that owns the shared item.
string—
items[].share_with
The recipient; empty for a public link.
string—
items[].path
The shared path.
string/Documents/report.pdf
items[].item_type
'file' or 'folder'.
stringfile
items[].permissions
The permission bitmask on the share.
number—
items[].url
The public link URL, for a link or email share.
string—
items[].token
The public link token, for a link or email share.
string—
items[].expiration
When the share expires, or empty.
string—
count
How many shares were returned.
number—
status
Nextcloud's OCS status word.
stringok
status_code
The OCS meta statuscode: 100 on v1, 200 on v2.
number—
message
The OCS meta message, when the server set one.
string—
total_items
Total matching items, when the endpoint reports it.
string—
items_per_page
Page size, when the endpoint reports it.
string—
{
  "count": 0,
  "items": [
    {
      "expiration": "",
      "id": "42",
      "item_type": "file",
      "path": "/Documents/report.pdf",
      "permissions": 0,
      "share_type": 0,
      "share_with": "",
      "token": "",
      "uid_owner": "",
      "url": ""
    }
  ],
  "items_per_page": "",
  "message": "",
  "status": "ok",
  "status_code": 0,
  "total_items": ""
}

See List Shares run in a workflow.

In a technical demo we add the Nextcloud connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.