# Storj DCS S3 gateway and HTTP endpoint

**URL:** <https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216>\
**Category:** Product Discussions\
**Created:** [November 8, 2022, 3:22pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216 "2022-11-08T15:22:23Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![odarriba](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/odarriba/32/1131_2.png) [@odarriba](https://forum.storj.io/u/odarriba)\
**Post date:** [November 8, 2022, 3:22pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/1 "2022-11-08T15:22:24Z")

</div>

Hi!

I was looking into using Storj DCS as an S3 replacement for a service I plan to host publicly (on [fly.io](http://fly.io)) but I cannot see any way of using it as the services requires the objects stored remotely to be accessed via a URL.

The only option I can see is using the `uplink` to generate a HTTP endpoint and put it behind a reverse proxy for SSL.

I there anything already hosted by Storj DCS for this? Like the S3 gateway (which I love) but for HTTPS serving of content.

Thanks in advance!

(Btw, I didn’t knew where to put this topic because there is no Help section for DCS questions 😅 )

---

<div class="post-metadata">

**Author:** ![Stob](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/stob/32/1137_2.png) [@Stob](https://forum.storj.io/u/Stob)\
**Post date:** [November 8, 2022, 3:45pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/2 "2022-11-08T15:45:08Z")

</div>

I may be misunderstanding (and don’t know [fly.io](http://fly.io)) but the link share service could be what you’re after. Files can be linked to (and downloaded) directly with SSL support, just not using your own domain name - [Linksharing Service - Storj DCS Docs](https://docs.storj.io/dcs/api-reference/linksharing-service)

Presigned URLs could also be what you’re looking for - [Using presigned URLs - Storj DCS Docs](https://docs.storj.io/dcs/api-reference/s3-compatible-gateway/using-presigned-urls/)

---

<div class="post-metadata">

**Author:** ![odarriba](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/odarriba/32/1131_2.png) [@odarriba](https://forum.storj.io/u/odarriba)\
**Post date:** [November 8, 2022, 4:11pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/3 "2022-11-08T16:11:48Z")

</div>

> [@Stob](#):
>
> Presigned URLs could also be what you’re looking for - [Using presigned URLs - Storj DCS Docs](https://docs.storj.io/dcs/api-reference/s3-compatible-gateway/using-presigned-urls/)

This is exactly what I was looking for 🙂 Being able to store an image and return a valid URL for the frontend to embed it, for example.

Thanks!

---

<div class="post-metadata">

**Author:** ![odarriba](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/odarriba/32/1131_2.png) [@odarriba](https://forum.storj.io/u/odarriba)\
**Post date:** [November 9, 2022, 11:39am UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/4 "2022-11-09T11:39:21Z")

</div>

As an extra point and future improvement suggestion, it would be nice to have a way to generate a passphrase that can be used to be able to download files through the gateway without signing them.

That way we can serve static content while adding a CDN in front of it for custom domain name + cache.

That is a very common use case of S3 and its competitors and not all of them have this option!

---

<div class="post-metadata">

**Author:** ![Stob](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/stob/32/1137_2.png) [@Stob](https://forum.storj.io/u/Stob)\
**Post date:** [November 9, 2022, 12:23pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/5 "2022-11-09T12:23:01Z")

</div>

> [@odarriba](#):
>
> it would be nice to have a way to generate a passphrase that can be used to be able to download files through the gateway without signing them.

Isn’t this the linksharing service I linked to above? Like this - [How to bulk get the browser links of a folder? - #2 by Stob](https://forum.storj.io/t/how-to-bulk-get-the-browser-links-of-a-folder/20086/2)

---

<div class="post-metadata">

**Author:** ![odarriba](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/odarriba/32/1131_2.png) [@odarriba](https://forum.storj.io/u/odarriba)\
**Post date:** [November 9, 2022, 12:36pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/6 "2022-11-09T12:36:46Z")

</div>

Woops! It looks like. I misread about it yesterday and I thought it was only for manually share indivual objects. It may work then!

I will try this afternoon putting it behind Cloudflare and lets see 🙂

---

<div class="post-metadata">

**Author:** ![odarriba](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/odarriba/32/1131_2.png) [@odarriba](https://forum.storj.io/u/odarriba)\
**Post date:** [November 9, 2022, 7:53pm UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/7 "2022-11-09T19:53:34Z")

</div>

I think it doesnt’ work as I expected 😕

When I generate a sharing link I can see that:

- If it is a link share for the bucket it shows the whole bucket, which is confussing as anyone can see all files and directories - not good when you are storing avatars for example, it is easy to be able to download all of them.
- If I share (or build from the bucket URL) an object URL, it shows me a full web page with information about Storj and a button to actually download the file.

It is nice for casual file sharing, but my use case is different, like when you expose an S3 bucket over HTTP or a DigitalOcean Space over CDN:

You can build a URL and the file downloads directly, but you cannot traverse directories (at least by default), and no “intermediate” page is shown, so the links can be used to put in HTML elements attributes like `<img>`.

**Edit:** loking a bit deeper in the docs I found this: [Host a Static Website with the Uplink CLI and Linksharing Service - Storj DCS Docs](https://docs.storj.io/dcs/how-tos/host-a-static-website/host-a-static-website-with-the-cli-and-linksharing-service) . Will investigate.

---

<div class="post-metadata">

**Author:** ![Stob](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/stob/32/1137_2.png) [@Stob](https://forum.storj.io/u/Stob)\
**Post date:** [November 10, 2022, 12:37am UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/8 "2022-11-10T00:37:41Z")

</div>

I’ll be honest I hadn’t checked those pages in a while and the recent updates have removed a lot of the helpful detail. You need this section on this page - [share - Storj Docs](https://docs.storj.io/dcs/api-reference/uplink-cli/share-command#f-jKX)

“To download content directly, use /raw/ in Linkshare URL”

You can use a raw link directly in an IMG tag!

> [@Uplink: Invalid access grant format shown](https://forum.storj.io/t/uplink-invalid-access-grant-format-shown/19304/18):
>
> So an example is from @jtolio’s website… http://link.storjshare.io/raw/jxb3xcosji3cqehkiw7kyfipw5eq/oliosite/jtolio/images/ice.jpg (also just realised you probably want raw not s) Access token = jxb3xcosji3cqehkiw7kyfipw5eq Bucket/prefix = oliosite/jtolio Path to file = images/ice.jpg

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [November 10, 2022, 7:47am UTC](https://forum.storj.io/t/storj-dcs-s3-gateway-and-http-endpoint/20216/9 "2022-11-10T07:47:53Z")

</div>

You can also host your content as a static web site: [Host a Static Website with the Uplink CLI and Linksharing Service - Storj DCS Docs](https://docs.storj.io/dcs/how-tos/host-a-static-website/host-a-static-website-with-the-cli-and-linksharing-service) (but https is not supported yet, so if you need to have https, you need to use either your own hosted proxy or [self-hosted S3 Gateway in web-site mode](https://docs.storj.io/dcs/api-reference/s3-gateway/gateway-st-advanced-usage#3tB66) and proxy with https support or CDN services like [Fastly](https://docs.storj.io/dcs/how-tos/fastly-integration)).
