Transfer API
  • Transfer API Documentation
  • API Overview
  • Task Submission
  • Task Management
  • File Operations
  • Endpoints and Collections
  • Globus Connect Personal Management
  • Endpoint and Collection Search
  • Roles
  • Collection Bookmarks
  • Guest Collection Permission Management
  • Advanced Collection Management
  • Transfer Action Providers
    • Migrating Transfer Action Providers
    • Transfer Action Provider: Transfer
    • Transfer Action Provider: Delete
    • Transfer Action Provider: Manage Permission
    • Transfer Action Provider: List Directory Contents
    • Transfer Action Provider: Stat File or Directory
    • Transfer Action Provider: Make Directory
    • Transfer Action Provider: Collection Info
    • Transfer Action Provider: Create GCP Guest Collection
    • Transfer Action Provider: Create GCSv5 Guest Collection
Skip to main content
Globus Docs
  • APIs
    Auth Flows Groups Search Timers Transfer Globus Connect Server Compute Helper Pages
  • Applications
    Globus Connect Personal Globus Connect Server Premium Storage Connectors Compute Command Line Interface Python SDK JavaScript SDK
  • Guides
  • Support
    FAQs Mailing Lists Contact Us Check Support Tickets
  1. Home
  2. Globus Services
  3. Transfer API Documentation
  4. Transfer Action Providers
  5. Transfer Action Provider: List Directory Contents

Transfer Action Provider: List Directory Contents

URL: https://transfer.actions.globus.org/ls

Synchronous / Asynchronous: Synchronous

The List Directory action provider uses the Globus Transfer API’s directory listing resource to retrieve a listing of contents from an (endpoint, path) pair. Although providing a path is optional, the default path used depends on endpoint type, and it is best to explicitly set a path.

{
  "endpoint_id": "6c54cade-bde5-45c1-bdea-f4bd71dba2cc",
  "path": "/home/share/godata/"
}
{
  "action_id": "FJmGKabcdefgh",
  "completion_time": "2023-06-28 15:23:00.269995+00:00",
  "creator_id": "urn:globus:auth:identity:12341234-abcd-abcd-abcd-123412341234",
  "details": {
    "DATA": [
      {
        "DATA_TYPE": "file",
        "group": "tutorial",
        "last_modified": "2022-01-06 16:23:33+00:00",
        "link_group": null,
        "link_last_modified": null,
        "link_size": null,
        "link_target": null,
        "link_user": null,
        "name": "foo.txt",
        "permissions": "0644",
        "size": 220,
        "type": "file",
        "user": "u_abcd"
      }
    ],
    "DATA_TYPE": "file_list",
    "absolute_path": null,
    "endpoint": "6c54cade-bde5-45c1-bdea-f4bd71dba2cc",
    "length": 1,
    "path": "/share/godata/",
    "rename_supported": true,
    "symlink_supported": false,
    "total": 1
  },
  "display_status": "SUCCEEDED",
  "label": null,
  "manage_by": [],
  "monitor_by": [],
  "release_after": "P30D",
  "start_time": "2023-06-28 15:22:58.772247+00:00",
  "status": "SUCCEEDED"
}
{
  "__COMMENT": "The ls output list will be `$.ls_result.details.DATA`",
  "ls": {
    "Type": "Action",
    "ActionUrl": "https://transfer.actions.globus.org/ls",
    "Parameters": {
      "endpoint_id.$": "$.endpoint_id",
      "path.$": "$.path"
    },
    "ResultPath": "$.ls_result"
  }
}

This action provider supports many of the filtering capabilities of the API. At present, operators can only be combined using the AND syntax.

{
  "__COMMENT": "Always excludes folders, hidden files, empty files, and commonly ignored items. The ls output list will be `$.ls_result.details.DATA`",
  "ls": {
    "Type": "Action",
    "ActionUrl": "https://transfer.actions.globus.org/ls",
    "Parameters": {
      "endpoint_id.$": "$.endpoint_id",
      "path.$": "$.path",
      "show_hidden": false,
      "filter": "name:!.DS_STORE/name:!Thumbs.db/name:!desktop.ini/name:!~*.pyc/size:!0/type:file"
    },
    "ResultPath": "$.ls_result"
  }
}
  • Transfer API Documentation
  • API Overview
  • Task Submission
  • Task Management
  • File Operations
  • Endpoints and Collections
  • Globus Connect Personal Management
  • Endpoint and Collection Search
  • Roles
  • Collection Bookmarks
  • Guest Collection Permission Management
  • Advanced Collection Management
  • Transfer Action Providers
    • Migrating Transfer Action Providers
    • Transfer Action Provider: Transfer
    • Transfer Action Provider: Delete
    • Transfer Action Provider: Manage Permission
    • Transfer Action Provider: List Directory Contents
    • Transfer Action Provider: Stat File or Directory
    • Transfer Action Provider: Make Directory
    • Transfer Action Provider: Collection Info
    • Transfer Action Provider: Create GCP Guest Collection
    • Transfer Action Provider: Create GCSv5 Guest Collection
© 2010- The University of Chicago Legal Privacy Accessibility