Skip to navigation

A presigned URL is a normal web link to one file in a private bucket, with a built-in permission slip and an expiry time. Anyone who has the link can download that file (or upload it, if the link was made for uploading) until the link expires. After that, the link stops working. Nobody needs your keys, and the bucket stays private.

Think of it as a ticket: it is signed (by the IBEE API, or by you with your S3 credential), it is valid for the time chosen, and the storage checks the ticket every time someone uses it.

When to use a presigned URL

Buckets are private by default: only your S3 credentials can read or write them. There are three ways to let other people get at files:

You want to…UseHow long it works
Let one person download one private file, or upload one file into your bucketPresigned URL (this page)Until the time you choose: at most 30 minutes from the IBEE API, 7 days with your own S3 credential
Serve files that anyone may see — website images, public downloadsPublic Access on the bucket, with its Public Access URL or a custom domainForever, until you turn Public Access off. Every file in the bucket becomes public.
Let your own app or server read and write the bucketAn S3 credential in the app’s configurationUntil you revoke the credential

If you are unsure, use a presigned URL: it shares one file, for a limited time. A link you sign with your own S3 credential can be cut off by revoking that credential; a link from the IBEE API works until it expires.

How it works

  1. You create the link, either with the IBEE API and your API token, or with a tool or your code and your S3 credential. With your own S3 credential nothing is sent to IBEE at this point: the link is calculated on your computer.
  2. You give the link to the person or program that needs the file.
  3. They open the link. IBEE Object Storage checks the signature, the expiry time and the permissions of the key that signed it, then sends (or accepts) the file.

There are two ways to create a link:

IBEE APIYour own S3 credential
You needAn API token with Object Storage scopeAn S3 credential and the AWS CLI or an S3 SDK
Upload sizeOne file of at most 80,000,000 bytes (80 MB)Up to the S3 limits
Lifetime1 to 30 minutes (15 by default)1 second to 7 days
Cut off earlyWait for it to expireRevoke the credential that signed it

The IBEE portal has no “share link” button yet. Create presigned URLs with the IBEE API, the AWS CLI or an S3 SDK, as shown below.

The IBEE API creates the link for you, so you don’t need an S3 credential: an API token with object-storage.write (upload links) or object-storage.read (download links and metadata) is enough. The file itself never passes through the API. The link points at your bucket’s S3 endpoint, https://WORKSPACE-ID.blob.ibeestorage.com, and the file goes straight there.

Upload one file

An upload link is made for exactly one file: you send its size and its SHA-256 checksum, and the link accepts only that file. A different or changed file is refused.

1

Measure the file

Get the size in bytes and the base64-encoded SHA-256 checksum. The size must be between 1 and 80,000,000 bytes; upload larger files with an S3 tool, which sends them in parts.

FILE=report.pdf
SIZE=$(wc -c < "$FILE" | tr -d ' ')
SHA256=$(openssl dgst -sha256 -binary "$FILE" | base64)
3

Upload the file

Send the file in one PUT with exactly the headers from the answer:

curl -X PUT \
-H "x-amz-checksum-sha256: $SHA256" \
-H "Content-Type: application/pdf" \
--data-binary @"$FILE" \
"$(jq -r .url link.json)"

curl sets Content-Length from the file.

4

Check the result

curl -s "https://api.ibee.ai/v1/object-storage/buckets/my-bucket/objects/reports/report.pdf/metadata?workspace_id=$IBEE_WORKSPACE_ID" \
-H "Authorization: Bearer $IBEE_TOKEN"

The upload worked when size_bytes and checksum_sha256 match what you sent.

An upload through a link counts like any other upload: the file shows in the portal and in S3 listings, and in your bucket’s size and usage.

Download one file

curl -s -X POST \
"https://api.ibee.ai/v1/object-storage/buckets/my-bucket/objects/reports/report.pdf/download-link?workspace_id=$IBEE_WORKSPACE_ID" \
-H "Authorization: Bearer $IBEE_TOKEN" \
-H "Content-Type: application/json" \
-d '{"expires": 600, "disposition": "attachment"}'

The answer has a url that downloads the file with a GET, and expires_in. With "disposition": "attachment" a browser saves the file instead of opening it. The link is made even when no file has that key; the download then answers 404.

  • Anyone holding a link can use it until it expires. Treat it like a password. A link made by the API can’t be revoked early, so keep lifetimes short.
  • An upload replaces a file with the same key. Use a unique key if files must not overwrite each other.
  • The free storage allowance is checked when the file arrives. If your organization is verified only by the ₹1 payment and has used its free storage, the upload is refused with 403 free_storage_limit_reached, even through a link made earlier. Add funds to upload more. A 503 with a Retry-After header means the allowance could not be checked: try again after the given number of seconds.
  • Web pages: uploads from a browser need a CORS rule on the bucket that allows your site, PUT, and the Content-Type and x-amz-checksum-sha256 headers.

Before you begin

You need:

  • A bucket and the key (full name and path) of the file, for example reports/2026-05.pdf. Keys are case-sensitive. See Create a bucket.

  • An S3 credential for the bucket’s workspace, created under Organization → API Tokens → S3 Credentials. See API Credentials. Its permission level decides what links it can sign:

    Link typeMinimum permission level
    Download linksObject Read only
    Upload linksObject Read & Write

    If the credential is limited to specific buckets, it can only sign links for those buckets.

  • Your S3 endpoint: https://WORKSPACE-ID.blob.ibeestorage.com. It is shown as S3 Endpoint when you create the credential.

  • The AWS CLI (version 2) for the command-line steps, or Python (boto3) or Node.js for the code examples.

Every tool needs the same three settings for IBEE:

SettingValueWhy
Endpointhttps://WORKSPACE-ID.blob.ibeestorage.comSends requests to IBEE instead of AWS.
RegionautoIBEE accepts auto as the signing region. Tools that default to us-east-1 make links that fail with Invalid region scope.
Addressing stylepathKeeps the bucket name in the path (…/my-bucket/file), not in the hostname.

The rest of this page signs links with your own S3 credential.

1

Save your credential as a profile

Run these once. Replace the two keys with your S3 credential’s values.

aws configure set aws_access_key_id YOUR-ACCESS-KEY-ID --profile ibee
aws configure set aws_secret_access_key YOUR-SECRET-ACCESS-KEY --profile ibee
aws configure set region auto --profile ibee
aws configure set s3.addressing_style path --profile ibee
3

Test it

Open the link in a browser, or download it with curl. Keep the quotes: the link contains & characters that the shell would otherwise cut.

curl -o 2026-05.pdf "PASTE-THE-LINK-HERE"

aws s3 presign only makes download links. To make an upload link, use an SDK as shown in Upload links.

Create links on your server, where the secret key is safe — never in a browser or mobile app.

import boto3
from botocore.config import Config
s3 = boto3.client(
"s3",
endpoint_url="https://WORKSPACE-ID.blob.ibeestorage.com",
aws_access_key_id="YOUR-ACCESS-KEY-ID",
aws_secret_access_key="YOUR-SECRET-ACCESS-KEY",
region_name="auto",
config=Config(signature_version="s3v4", s3={"addressing_style": "path"}),
)
url = s3.generate_presigned_url(
"get_object",
Params={"Bucket": "my-bucket", "Key": "reports/2026-05.pdf"},
ExpiresIn=3600, # seconds: one hour
)
print(url)

An upload link lets someone put one file, at the key you chose, into your bucket without credentials — for example, a user uploading a profile picture straight from your web page.

IBEE Object Storage only accepts an upload link that was signed together with the file’s MD5 checksum, a short fingerprint of the file’s exact contents. This proves the file that arrives is the file you allowed. So:

  1. Get the file’s MD5 checksum before you create the link. In a web app, the browser calculates it and sends it to your server with the file name.
  2. Create the link with the checksum (ContentMD5).
  3. Upload with the same checksum in a Content-MD5 header.

Calculate the checksum (base64-encoded MD5):

openssl dgst -md5 -binary avatar.png | base64

Create the upload link:

url = s3.generate_presigned_url(
"put_object",
Params={
"Bucket": "my-bucket",
"Key": "uploads/avatar.png",
"ContentType": "image/png",
"ContentMD5": content_md5,
},
ExpiresIn=600, # seconds: ten minutes
)

The person with the link uploads the file in one request, sending the same content type and checksum:

curl -X PUT \
-H "Content-Type: image/png" \
-H "Content-MD5: THE-SAME-CHECKSUM" \
--data-binary @avatar.png \
"PASTE-THE-UPLOAD-LINK-HERE"

Before you hand out upload links:

  • The headers must match what was signed. The upload must send exactly the Content-Type and Content-MD5 the link was created with, or it fails with SignatureDoesNotMatch.
  • The file must match its checksum. A different or changed file fails with BadDigest. Create a new link for each file.
  • An upload replaces any file with the same key. Use a unique key per upload (for example, include a random ID) if files must not overwrite each other.
  • One link, one file. Each upload link is for one key.

Uploading from a web page

A browser only allows the upload if the bucket’s CORS rules allow your website. Add a rule that allows your site’s origin, the PUT method, and the Content-Type and Content-MD5 headers. See CORS.

Browser form uploads (presigned POST with an upload policy) are not supported. Use a presigned PUT link instead.

Value
Shortest1 second
Longest7 days (604800 seconds). Longer requests are refused.
AWS CLI default1 hour (3600 seconds)
Clock tolerance15 minutes. If your computer’s clock is off by more than that, new links may fail with Request has expired.

A link stops working before its expiry time if the S3 credential that signed it is revoked or deleted. This takes effect immediately, for every link that credential signed.

A download link points to a key, not to one copy of the file: if the file is replaced, the link returns the new file; if it is deleted, the link returns NoSuchKey. The expiry is checked when a request starts, so a download that started before the expiry time finishes.

Choosing an expiry

UseSuggested lifetime
A link your app creates for a user who is about to click it5–15 minutes
An upload link for a form on your website10–15 minutes
A link you email to someone1–24 hours
The longest possible7 days — after that, create a new link

Shorter is safer: anyone who gets hold of the link can use it until it expires.

What’s in a presigned URL

PartMeaning
https://WORKSPACE-ID.blob.ibeestorage.com/my-bucket/reports/2026-05.pdfYour endpoint, the bucket, and the file’s key
X-Amz-Algorithm=AWS4-HMAC-SHA256The signing method (AWS Signature Version 4)
X-Amz-Credential=…/auto/s3/aws4_requestYour Access Key ID (not the secret), the date and the region auto
X-Amz-Date=20261030T101500ZWhen the link was created (UTC)
X-Amz-Expires=3600How many seconds after X-Amz-Date the link works
X-Amz-SignedHeaders=hostWhich request headers are part of the signature
X-Amz-Signature=…The signature. Changing any part of the link breaks it.

Your secret key is never part of the link.

Security tips

  • Treat a link like a password. Anyone who has it can use it until it expires. Don’t post it publicly or write it to logs.
  • Use the shortest expiry that works, and create a fresh link for each request instead of reusing one.
  • Sign with a narrow credential: use Object Read only for download links and limit the credential to the buckets it needs.
  • Create links on a server. Never put an S3 secret key in a web page, mobile app or public repository.
  • To cut off every link at once, revoke the credential that signed them, then create a new credential for your app.

Troubleshooting

Errors come back as XML with a Code and a Message. Look up the message:

You seeWhat it meansWhat to do
403 AccessDenied — Request has expiredThe link is past its expiry time, or the computer that created it had a clock more than 15 minutes offCreate a new link. If new links fail straight away, sync the computer’s clock.
403 SignatureDoesNotMatchThe request doesn’t match what was signed: the link was changed or cut, the upload sent a different Content-Type, or the secret key is wrongCopy the whole link and put it in quotes. Send the same Content-Type that was signed. Check the secret key.
403 AccessDenied — Unsigned payload requires a signed checksumThe upload link was created without the file’s checksum, or the upload didn’t send the Content-MD5 headerCreate the link with ContentMD5 and send the same value in a Content-MD5 header. See Upload links.
400 BadDigestThe uploaded file doesn’t match the checksum in the linkCalculate the checksum of the exact file you upload, and create a new link with it.
403 AccessDenied — Invalid region scopeThe link was signed with a region other than auto, usually the tool’s default us-east-1Set the region to auto and create the link again.
403 AccessDenied — Invalid access key or Access key is not activeThe credential that signed the link was deleted or revokedCreate the link with an active credential.
403 AccessDenied — Access key does not belong to this workspaceThe link uses another workspace’s endpointUse the endpoint shown with the credential (https://WORKSPACE-ID.blob.ibeestorage.com).
403 AccessDenied (no other message)The credential is not allowed this action or bucket — for example, a read-only credential signed an upload linkUse a credential with the right permission level and bucket scope.
404 NoSuchKey or NoSuchBucketThe file or bucket name is wrong. Names are case-sensitive.Check the bucket name and the full key.
”Could not resolve host” for my-bucket.WORKSPACE-ID.blob.ibeestorage.comThe tool put the bucket name in the hostnameSet the addressing style to path.
413 — the upload is larger than the link allowsAn API upload link was used for more than 80,000,000 bytesUpload large files with an S3 tool, which sends them in parts.
403 free_storage_limit_reachedYour organization has used its free storage and is verified only by the ₹1 paymentAdd funds, then upload again.
503 with Retry-After on an API link uploadThe free storage allowance could not be checkedWait the number of seconds in Retry-After, then send the same request again.
A CORS error in the browser consoleThe bucket’s CORS rules don’t allow your website, method or headerAdd a CORS rule for your origin, PUT or GET, and the Content-Type and Content-MD5 headers. See CORS.
  • API Credentials: create and revoke S3 credentials
  • Bucket Policies: public access and permission levels
  • CORS: allow uploads and downloads from a web page
  • Objects: upload and download with your own credentials