File Transfers
Send-FilesFile uploads local files, or bytes from a stream, to Files.com. Receive-FilesFile downloads a file to a local file or into a stream. Both use the current connection, accept -WhatIf and -Confirm, and take -Connection and -WorkspaceScope like the other commands.
Transfers tune themselves. Uploads choose settings for the destination and send parts in parallel when supported. Downloads use parallel parts where storage supports ranges and reliable version checks; otherwise, they fetch the whole file in one response. Temporary failures are retried within the configured limit. Start with the paths; most scripts need no concurrency or retry settings.
Downloads use the .NET SDK's timestamp checks: a valid
Last-Modified date is reused in If-Unmodified-Since on later requests when no stronger If-Match condition
applies. A detected source change stops that attempt; like any source change, it then starts the download again from
the file's first byte, within -MaxNetworkRetries, unless bytes were already written to -OutputStream. These checks can miss same-second edits, preserved
modification times and changes during one response; they do not establish a version or enable parallel parts.
Timestamp checks are enabled by default. Use -CheckDownloadModificationTime:$false with Connect-FilesAccount
to change the connection default, or with Receive-FilesFile for one download, including -OutputStream.
The download keeps its initial choice. Disabling timestamp checks leaves size and stronger version checks in place,
but permits changes detectable only by modification time.
Both cmdlets show PowerShell's progress bar when your host and $ProgressPreference allow it. Small transfers can
finish before the bar appears.
Uploading a File
This uploads report.csv, creating the reports/2026 folders if they are missing.
To upload every file in a folder, pipe the files to Send-FilesFile:
-PassThru writes each completed upload.
Downloading a File
This writes report.csv and fails if the file already exists. Add -Force to replace it.
To download every file in a remote folder into a local folder, create the local folder first. Receive-FilesFile saves files into a local folder only when that folder already exists:
Upload Startup
Omit -AggressiveStartup to keep the default startup, which probes eligible connections before increasing
parallelism. On a known high-throughput network, enable the switch to skip those initial probes; it takes no value:
The switch applies only where the transfer engine selects its scaled parallel-upload policy. Other destinations,
including Agents, keep their own starting settings. Both startups use the same adaptive behavior, limits, retries
and backoff; the default can reach the same concurrency ceiling. -MaxConcurrency still caps the transfer.
For Send-FilesFile, do not enable -AggressiveStartup with static concurrency, -PerformanceProfile or
-AutomaticConcurrency, which choose their own start. Send-FilesDirectory also accepts -AggressiveStartup and
shares that startup across its files. Downloads have no upload-startup switch.
More Transfer Options
The Send-FilesFile and Receive-FilesFile references, also shown by Get-Help Send-FilesFile -Full and Get-Help Receive-FilesFile -Full, describe concurrency, part sizing, transfer limits, and checkpoints, which let a stopped transfer continue when you run the same command again. The module also includes Send-FilesDirectory and Receive-FilesDirectory for whole folders.