GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - greenapes/python-blitline: Python client for blitline service

BranchesTags
Open more actions menu

Latest commit

 

History

12 Commits
12 Commits

Folders and files

NameName
Last commit message
Last commit date
blitline
blitline
 
 
tools
tools
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
setup.py
setup.py
 
 

Repository files navigation

python-blitline

# supported on python >= 3

Python client for blitline service. It is a thin wrapper over the JSON API.

Install with pip:

$ pip install python-blitline

Documentation

There is no formal documentation, but this is an example:

import blitline as b

# Your Application ID
BLITLINE_ID = "XXXXXXXXXXXXXXXXXXXX"

blitline_avatar = b.Job(
    b.ResizeToFit(
        width=165,
        height=165,
        save=b.S3Destination(
            bucket="my-s3-bucket",
            key='avatars/{username}.jpg',
            headers={
                'Content-Type': 'image/jpg',
            })))

for u in usernames:
    SRC_URL = "http://example.org/pics/{username}.jpg".format(username=u)
    res = blitline_avatar(BLITLINE_ID, SRC_URL, username=u)
    
    # You can do several things with a running job:
    
    # res.wait() -> wait for job end (default timeout: 5s)
    # res.open(DEST_IMAGE) -> open the specified destination image (streamed download)
    # res.download(DEST_IMAGE, output_file) -> download the specified image and write it to the output file
    # res.download_all(DIR) -> download all output images in the specified directory

About

Python client for blitline service

Resources

Readme
MIT license
Activity
Custom properties

Stars

0 stars

Watchers

6 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.