Skip to main content

Unofficial API WallpapersCraft (wallpaperscraft.com)

Project description

WallpapersCraftAPI

Unofficial API WallpapersCraft (wallpaperscraft.com)

external-install-basic-ui-elements-2.3-sbts2018-outline-color-sbts2018 Install

Install via GitHub:

pip3 install https://github.com/Den4ikSuperOstryyPer4ik/WallpapersCraftAPI/archive/main.zip --upgrade

Stable version from PyPi:

pip3 install wallpaperscraft

For Windows: pip3 > pip

Usage

from wallpaperscraft import WallpapersCraftAPI, TAG, CATALOG

api = WallpapersCraftAPI()

# get 15 pictures from first page with nature by size 1024x768
nature_pics = api.get_by_catalog(CATALOG.NATURE, resolution="1024x768")

# get 15 pictures from 5th(fifth) page with space by size 1920x1080
vectore_pics = api.get_by_catalog(CATALOG.SPACE, page=5, resolution="1920x1080")

# get 15 pictures from second(2) page with sky and different size
sky_pictures = api.get_by_tag(TAG.SKY, page=2)

# search pictures from first page with night city and different size
night_city_pics = api.search("night city")

# get 15 pictures from first page on `https://wallpaperscraft.com/all/` by different size
all_pics = api.all()

Async Usage

from wallpaperscraft import AsyncWallpapersCraftAPI, TAG, CATALOG
import asyncio

async def main():
    api = AsyncWallpapersCraftAPI()

    # get 15 pictures from first page with nature by size 1024x768
    nature_pics = await api.get_by_catalog(CATALOG.NATURE, resolution="1024x768")

    # get 15 pictures from 5th(fifth) page with space by size 1920x1080
    vectore_pics = await api.get_by_catalog(CATALOG.SPACE, page=5, resolution="1920x1080")

    # get 15 pictures from second(2) page with sky and different size
    sky_pictures = await api.get_by_tag(TAG.SKY, page=2)

    # search pictures from first page with night city and different size
    night_city_pics = await api.search("night city")

    # get 15 pictures from first page on `https://wallpaperscraft.com/all/` by different size
    all_pics = await api.all()

asyncio.run(main())

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

wallpaperscraft-1.0.0.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

wallpaperscraft-1.0.0-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file wallpaperscraft-1.0.0.tar.gz.

File metadata

  • Download URL: wallpaperscraft-1.0.0.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.11

File hashes

Hashes for wallpaperscraft-1.0.0.tar.gz
Algorithm Hash digest
SHA256 0f7ed40d44822cd3581af5d7a31279f20be3834b32eb07fd805e147cad9c66b6
MD5 727a5a62824cfa81bfc0afeebdddad9d
BLAKE2b-256 0198584cc6813a86a0ea2a539294f8d065200fe54a4669b699974f1a6b0e740f

See more details on using hashes here.

File details

Details for the file wallpaperscraft-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for wallpaperscraft-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ab3748415b5652a789421e8687b85dcdd2528e60aa911ea578f59c141526c65e
MD5 f2bc70c281db1c5026fc6238e32534e3
BLAKE2b-256 1ee00e5282698dec2e74c3d2eff0c8fb95f7cead5af1266e4c067c41120ccd2d

See more details on using hashes here.

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