mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-12 13:29:04 +00:00
Generate a presigned GET URL for an S3 object 🟩
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
ba13300ee1
commit
da3e0cd4b4
1 changed files with 6 additions and 1 deletions
|
|
@ -25,4 +25,9 @@ class S3Client:
|
|||
"""A time-limited URL that lets the holder GET this object without AWS
|
||||
credentials (ADR-0060 — how a Download Package link is delivered).
|
||||
``expires_in`` is the validity window in seconds."""
|
||||
raise NotImplementedError
|
||||
url: str = self._client.generate_presigned_url(
|
||||
"get_object",
|
||||
Params={"Bucket": self._bucket, "Key": key},
|
||||
ExpiresIn=expires_in,
|
||||
)
|
||||
return url
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue