Skip to content

Add put_object_with_headers method to bucket #425

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

yoozzeek
Copy link

@yoozzeek yoozzeek commented May 22, 2025

Add two new methods to support uploading objects with custom HTTP headers on a per-request basis:

  • put_object_with_content_type_and_headers: upload with explicit content-type and custom headers.
  • put_object_with_headers: uploads an object with optional custom headers; uses "application/octet-stream" as the default Content-Type.

Custom headers are attached to the PUT request via the headers method in the request trait. Following the same design approach as the existing put_object and put_object_with_content_type methods.

Use Case:
Enable per-upload customization of HTTP headers such as Cache-Control, allowing control over caching.


This change is Reviewable

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