Skip to content

HTTP Transfers

Operating Systems
Android
iOS
Windows

Shiny HTTP Transfers enables background uploads and downloads that continue even when your app is suspended. Transfers are managed by the OS and will resume after app restarts.

  • Background uploads and downloads
  • Multipart and raw upload support
  • Progress tracking with speed and ETA
  • Automatic resume after app restart
  • Metered/unmetered network control
  • Managed transfer list for UI binding
  • Cross-platform: iOS, Android, Windows
Shiny.Net.HttpNuGet package Shiny.Net.Http
Shiny.Hosting.MauiNuGet package Shiny.Hosting.Maui

Implement IHttpTransferDelegate to handle transfer completion and errors in the background.

public partial class MyTransferDelegate : IHttpTransferDelegate
{
readonly ILogger<MyTransferDelegate> logger;
public MyTransferDelegate(ILogger<MyTransferDelegate> logger)
{
this.logger = logger;
}
public Task OnCompleted(HttpTransferRequest request)
{
this.logger.LogInformation("Transfer completed: {Id}", request.Identifier);
return Task.CompletedTask;
}
public Task OnError(HttpTransferRequest request, int statusCode, Exception ex)
{
this.logger.LogError(ex, "Transfer failed: {Id}, Status: {Status}", request.Identifier, statusCode);
return Task.CompletedTask;
}
}

On Android, background transfers run as a foreground service. Customize the notification:

#if ANDROID
public partial class MyTransferDelegate : IAndroidForegroundServiceDelegate
{
public void Configure(AndroidX.Core.App.NotificationCompat.Builder builder)
{
builder
.SetContentTitle("My App")
.SetContentText("Transferring files...")
.SetSmallIcon(Resource.Mipmap.appicon);
}
}
#endif
services.AddHttpTransfers<MyTransferDelegate>();
claude plugin add github:shinyorg/skills/shiny-http-transfers
  1. Open the shiny-http-transfers skill file and copy its contents
  2. In your repository, create .github/copilot-instructions.md if it doesn't exist
  3. Paste the skill content into that file and save

Copilot will automatically pick up the instructions on your next chat or code completion. You can also use path-specific instructions by placing the file in .github/instructions/ with an applyTo frontmatter pattern.

View Skill