Groups | Search | Server Info | Login | Register
Groups > comp.infosystems.www.misc > #189
| Message-ID | <649cf877@news.ausics.net> (permalink) |
|---|---|
| From | Computer Nerd Kev <not@telling.you.invalid> |
| Subject | Re: imgur / image-upload API specs |
| Newsgroups | comp.infosystems.www.misc, comp.misc |
| References | <86mt0kmf9j.fsf@building-m.net> <649cbeeb@news.ausics.net> <86ilb7m41f.fsf@building-m.net> |
| Date | 2023-06-29 13:20 +1000 |
| Organization | Ausics - https://www.ausics.net |
Cross-posted to 2 groups.
In comp.misc John <john@building-m.simplistic-anti-spam-measure.net> wrote: > not@telling.you.invalid (Computer Nerd Kev) writes: > >> In comp.misc John <john@building-m.simplistic-anti-spam-measure.net> wrote: >>> The recent decision by imgur to delete non-account-associated uploads >>> got me thinking about WWW resource persistence and self-hosting yet >>> again. People used imgur because it was convenient and free; uploading >>> an image and sending a link was a simple process. >> >> It wasn't convenient for me receiving those links. Links to Imgur >> images don't work without Javascript, so not in my preferred >> lightweight web browsers, and even in Firefox it takes ages to load, >> and (with my configuration, at least) sometimes a few page reloads. >> 99% of the time I just ignore Imgur links, and for the other 1% it >> usually turns out that it wasn't worth the effort. >> > The people sending you the links were screwing up, then. What you do is > upload the image, then right-click the image on the resulting page and > copy the image link. No JS, it's just a JPG. Ah, great! I see that sometimes simply adding ".jpg" to the end of an Imgur link is enough to get past the usual "please enable JS to make Imgur work" barrier. I never thought it might be that easy. >>> Is anyone aware of open-source servers which implement an >>> Imgur-compatible API, or of efforts to define a "standard" set of >>> endpoints for image uploading and retrieval? >> >> Why does it need to be a standard? HTTP makes this very easy to >> build from scratch, it's a typical HTML form example task. If Imgur >> makes it so complicated that it could be its own standard, that's >> their problem. Rip all that out and put in something sensible >> instead! > > If a variety of different self-hosted options accept POST requests to > /imageapi/upload, then it's easy to use them interchangeably. That's the > advantage of a standard API. Making it Imgur-compatible strikes me as having little benefit. Existing programs will be hard-coded to use imgur.com, so they won't work as-is, and yet when Imgur change their API on a whim, your site/s have to change as well to stay compatible. I guess the only way it might work is if you plan to play tricks with what the imgur.com domain resolves to. On Linux you might be able to get the image uploader program to use a different network namespace with its own hosts file pointing imgur.com to somewhere else. >> Even better, set up an SFTP (FTPS, FTP) server and allow people to >> use that for uploading photos without a clunky web interface. Bulk >> uploads are _far_ easier using SFTP than via web interfaces, and >> photos are often uploaded in large numbers. Heck that's probably >> why those API applications get used instead of the Imgur website >> in the first place. Use SFTP and you've got lots of wonderfully >> easy to use FTP clients available already. Just write a script that >> post-processes them for displaying in HTML after they've been >> uploaded. HTTP is the wrong route from the get-go, if you ask me. > > The reason you use HTTP is because basically every device can access > it. Damn near every firewall lets port 443 out. I love non-HTTP > protocols on a philosophical level, but I don't suggest "oh well > obviously the best way to let my mom share a picture is to have her > mount a 9P filesystem via FUSE..." > > If there's a common/standard way to throw images at a backend service, > that means you can interface with it via curl, via a little HTML+JS > application you hack up, or from basically any program written in any > application which supports HTTP. My experience with hacking up over-complicated, semi-documented, HTTPS APIs with Curl is that many hours and error messages could be saved had an FTP-like protocol been used instead. Of course there's no reason why using one protocol excludes also offering the other. -- __ __ #_ < |\| |< _#
Back to comp.infosystems.www.misc | Previous | Next — Previous in thread | Next in thread | Find similar
imgur / image-upload API specs John <john@building-m.simplistic-anti-spam-measure.net> - 2023-06-28 03:34 +0000
Re: imgur / image-upload API specs not@telling.you.invalid (Computer Nerd Kev) - 2023-06-29 09:14 +1000
Re: imgur / image-upload API specs John <john@building-m.simplistic-anti-spam-measure.net> - 2023-06-29 01:49 +0000
Re: imgur / image-upload API specs Computer Nerd Kev <not@telling.you.invalid> - 2023-06-29 13:20 +1000
Re: imgur / image-upload API specs Ivan Shmakov <ivan@siamics.netNOSPAM.invalid> - 2023-06-29 08:12 +0000
Re: imgur / image-upload API specs Eli the Bearded <*@eli.users.panix.com> - 2023-07-03 01:47 +0000
csiph-web