Guides

Sharing Files

Learn how to share files and folders with others.

Sharing Methods

ZeroDrive supports two types of sharing:

MethodAccessAuthenticationBest For
User SharingSpecific usersRequiredTeam collaboration
Public LinksAnyone with linkNot requiredExternal sharing

User-to-User Sharing

Share files with specific users who must authenticate to access them.

Share a File

Request

Parameters

ParameterTypeRequiredDescription
emailsarrayYesList of email addresses to share with
rolestringYesPermission level: viewer, editor, or owner
canSharebooleanNoAllow recipients to re-share (default: false)
messagestringNoOptional message sent with share notification

Response

Permission Roles

RoleViewDownloadEditDeleteManage Permissions
viewer
editor
owner

Share a Folder

Share an entire folder including its contents:

Folder permissions automatically apply to all files and subfolders within.

Managing Permissions

List File Permissions

Response

Update Permission

Remove Permission

Create public links that anyone can access without authentication.

Response

Public links expire after 30 days by default.

Access Public File

Anyone can access public files via the link:

No authentication required!

Response

After revoking, the public link immediately stops working.

Public Folder Sharing

View Public Folder Contents

Response

Download Public Folder as ZIP

Save Public Folder to Own Drive

Authenticated users can save a public folder to their own drive:

Email Notifications

When sharing files, recipients receive email notifications:

  • Existing users: Email + in-app notification
  • Non-users: Email invitation to sign up

The email includes:

  • File/folder name
  • Sharer's name
  • Assigned role
  • Direct link to access
  • Custom message (if provided)

Code Examples

JavaScript: Share and Track

Python: Bulk Sharing

Security Considerations

  1. Principle of Least Privilege

    • Start with viewer role and upgrade as needed
    • Disable canShare unless necessary
  2. Public Links

    • Remember: Anyone with the link can access
    • Revoke links when no longer needed
    • Don't share sensitive data via public links
  3. Audit Access

    • Regularly review who has access to important files
    • Remove access for former team members
  4. Expiration

    • Public links auto-expire after 30 days
    • User shares persist until manually revoked

Error Handling

User Not Found

Already Shared

Cannot Share (No Permission)