i.marcusj.tech

Available on PyPi


            import imj

            res = imj.upload_file("Pictures\\widepeepohappy.png")
            print(
                res.viewer, # viewer url
                res.image, # image url
                res.shorten(), # shortened url
            )

            # you can upload raw data with imj.upload(bytedata)
        

Pure python example


            import requests

            r = requests.post("https://i.marcusj.tech/upload", files={'image': open('widepeepohappy.png', 'rb')})

            print(r.url) # this is the viewing url
            img_id = r.url.split('/')[-1]
            shortlink = requests.get(f'https://i.marcusj.tech/shorten/{img_id}').url # this is the shortlink directly to the image

            print(r.url.replace('view','image')) # this is the long link, directly to the image