Skip to content

Allow specifying a download request body#18

Open
Erdragh wants to merge 1 commit intoionic-team:mainfrom
Erdragh:feature/download-body
Open

Allow specifying a download request body#18
Erdragh wants to merge 1 commit intoionic-team:mainfrom
Erdragh:feature/download-body

Conversation

@Erdragh
Copy link
Copy Markdown

@Erdragh Erdragh commented Feb 9, 2026

Description

Adds an optional parameter body to the downloadFile function, which takes Data?. This is then set as the request body.

Additionally, the headers of the IONFLTRHttpOptions are now public, to allow accessing them and modifying them in capacitor-file-transfer.

Context

This is part of a trifecta of PRs with which I intend to fix these two issues:

This PR specifically adjusts the ios native transfer lib to support sending a request body on download requests.

Type of changes

  • Fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Refactor (cosmetic changes)
  • Breaking change (change that would cause existing functionality to not work as expected)

Tests

I have tested it together with my PR to the capacitor file transfer plugin on an actual iPhone 12 where I download a blob from our backend which is identified via a protobuf request body.

Checklist

  • Changes require an update to the documentation
    • Documentation has been updated accordingly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant