GithubHelp home page GithubHelp logo

api_images's Introduction

Space Instagram

Scripts to download pics from SpaceX API and hubble API.

How to install

Python3 should be already installed. Then use pip (or pip3, if there is a conflict with Python2) to install dependencies:

pip install -r requirements.txt

Add instagram login, password and picture directory name to file .env:
login = %login%
password = %password%
directory = %directory%

How to use

To fetch images from SpaceX and Hubble library and upload them to your Instagram profile run script:

python3 instagram_upload.py

Command line interface is also available:

python3 instagram_upload.py --login %login% --password %password% --directory %directory%

Functions description

Function fetch_spacex_last_launch() from fetch_spacex.py returns image urls list of last SpaceX launch.
Function fetch_hubble_urls(collection) from fetch_hubble.py returns image urls list of collection from Hublle.
Function save_images(image_urls, directory) from tools.py saves urls to directory.
Function crop_files_in_folder(folder_name) from tools.py crops images to square format.
Function load_pics(login, password, folder_path) from instagram_upload.py loads pictures to Instagram from folder with square pics.

Project Goals

The code is written for educational purposes on online-course for web-developers dvmn.org.

api_images's People

Contributors

qdes avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.