The "GET " endpoint should always be served at the root path of the domain. so if it was file.nostrmedia.com then the endpoint should be file.nostrmedia.com/

generally its also good to have the /upload endpoint on the same domain because clients wont be able to easily know about both domains. and when users select a the blossom server in a client they would be only setting one of the domains

Reply to this note

Please Login to reply.

Discussion

Hmm that might not work for a lot of folks who use object storage providers... including our friends at nostr.build if they end up wanting to also support Blossom, as their media is on various subdomains too.

So, maybe the default could be / but allow fallback upon upload the clients could also use the returned URL?

Or, am I completely misunderstanding this and the GET to / is only used for clients to list the uploaded files and not for when they add their respective URLs returned from /upload to inject in note content? Thanks!

Client can and probably will use the "url" field returned from the /upload endpoint when composing kind 1 notes. although the GET / serves a different purpose

Take this note for example nostr:nevent1qvzqqqqqqypzqfngzhsvjggdlgeycm96x4emzjlwf8dyyzdfg4hefp89zpkdgz99qyghwumn8ghj7mn0wd68ytnhd9hx2tcpzfmhxue69uhkummnw3e82efwvdhk6tcprfmhxue69uhhq7tjv9kkjepwve5kzar2v9nzucm0d5hsqgp40020uraxgjhz7qlaspnvwfu782qgulw7vrqqe2q45su6kqywkss9rclp

If my main server cdn.hzrd149.com went down or the image was removed from it. clients could lookup my preferred list of blossom servers (kind 10063 event) and start going down the list asking each one for the exact same blob (without needing to know how the server works)

1.

2.

Thats the point of requiring the "GET /" endpoint to be in the exact same location on every server. so its super easy for clients to quickly fallback and check other servers

Ah gotcha! Ok, thanks for explaining that 👍