Skip to main content clone uploader

Project description

# uploader made in Python3.5+.

This script makes it so you can upload to any site, only requiring the url of the site. The script is also small enough to be taken wherever you need it to go, only taking up a single file. This script also needs `requests` but seeing as thats such a widely installed module, i dont think anyone DOESNT have it installed!

## Getting started
To get started with first you must have Python 3.5 or higher as it makes use of asyncio. There is a non-async version you can download in the Github if you want to use it on anything below Python3.5.


import pomf
# select a host via get_host.
host = pomf.get_host('mixtape')

# you dont need anything other than a file
# to upload to the host
ret = host.upload(open('hearts.png', 'rb'))
# {'hash': 'f6bb5ef07fe63759ecfac1c81193c5912b96c45b', 'name': 'hearts.png', 'url': '', 'size': 25553}

# if you want to add a host:
new_host = pomf.add_host('mixtape2', '')


### Asyncio Support
If you want to use with asyncio, you can add a `_async` to the upload that will return a coroutine:
await host.upload_async(open('hearts.png', 'rb'))
# {'hash': 'f6bb5ef07fe63759ecfac1c81193c5912b96c45b', 'name': 'hearts.png', 'url': '', 'size': 25553}

### Pre-installed Hosts
Here are the hosts that are ready to be used with the script out of the box.
# mixtape -
# safe -
# void -

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pomf-0.6.tar.gz (3.1 kB view hashes)

Uploaded source

Built Distribution

pomf-0.6-py3-none-any.whl (6.6 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page