Skip to main content

Pinterest data extractor library

Project description

pinterest-downloader v3

Pinterest data extractor. No API key required. No dependencies.

Install

pip install pinterest-downloader

Quick Start

from pinterest_downloader import Pinterest

p = Pinterest()

# Auto-detect URL type
result = p.get("https://pin.it/xxxxx")
# {"type": "pin", "data": {...}}

# Get pin data (image / video / gif)
pin = p.get_pin("https://www.pinterest.com/pin/123456/")

# Get user profile + boards
user = p.get_user("https://www.pinterest.com/username/")

# Get board info
board = p.get_board("https://www.pinterest.com/username/board-name/")

# Search
results = p.search("cute cats")

Pin Types

Type Fields
image default_image, images
video default_video, default_image, videos, images
gif gif_url, default_image, images

Pin Response

{
    "pin_id": "123456",
    "type": "video",
    "title": "...",
    "description": "...",
    "created_at": "...",
    "domain": "...",
    "dominant_color": "#hex",
    "repin_count": 100,
    "total_saves": 500,
    "categories": ["Art"],
    "visual_annotations": ["..."],
    "creator": {"name": "...", "username": "...", "entity_id": "...", "image": "..."},
    "pinner": {"name": "...", "username": "...", "entity_id": "...", "image": "..."},
    "board": {"name": "...", "url": "...", "entity_id": "..."},
    "default_image": "https://...",
    "default_video": "https://...",
    "gif_url": "https://...",
    "images": {"236x": "...", "474x": "...", "736x": "...", "orig": "..."},
    "videos": [{"quality": "v720P", "url": "...", "width": 720, "height": 720, "duration_ms": 9000}],
}

User Response

{
    "user_id": "...",
    "username": "...",
    "full_name": "...",
    "about": "...",
    "follower_count": 100,
    "following_count": 50,
    "pin_count": 200,
    "board_count": 5,
    "created_at": "...",
    "profile_images": {"small": "...", "medium": "...", "large": "..."},
    "profile_cover": {"originals": "...", "736x": "..."},
    "boards": [{"name": "...", "pin_count": 10, "url": "..."}],
}

Board Response

{
    "board_id": "...",
    "name": "...",
    "url": "...",
    "pin_count": 23,
    "follower_count": 100,
    "cover_images": {"200x150": "..."},
    "preview_images": ["...", "..."],
    "owner": {"name": "...", "username": "..."},
}

Exceptions

from pinterest_downloader import (
    PinterestError,
    PinNotFoundError,
    UserNotFoundError,
    BoardNotFoundError,
    SearchError,
    InvalidURLError,
)

Supported URLs

  • https://pin.it/xxxxx
  • https://www.pinterest.com/pin/123456/
  • https://www.pinterest.com/username/
  • https://www.pinterest.com/username/board-name/
  • https://www.pinterest.com/search/pins/?q=query

License

MIT — Ahmed Nagm

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

pinterest_downloader-3.0.0.tar.gz (6.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pinterest_downloader-3.0.0-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file pinterest_downloader-3.0.0.tar.gz.

File metadata

  • Download URL: pinterest_downloader-3.0.0.tar.gz
  • Upload date:
  • Size: 6.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pinterest_downloader-3.0.0.tar.gz
Algorithm Hash digest
SHA256 d1900d44b0aa7bd4932a4c53bf995311f16b47d684d6cfee4d974ea5a93668de
MD5 a6d426263e02a2284ac57b4255f0fab8
BLAKE2b-256 6b4116b79b408a13da60fa63540555d19912e7a6bf399d3ae3772b96dcad09af

See more details on using hashes here.

File details

Details for the file pinterest_downloader-3.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for pinterest_downloader-3.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 250d049ec007aa25ae620c0e27383117556e3cde52bcc93693a4f8b3521b0e6c
MD5 3c1d6549f30ead9261dd91de64e86d0c
BLAKE2b-256 cd61d349a7fe814af413fba699e3a4ca690a7d64ceaa8b92916bbff2bf90c5bc

See more details on using hashes here.

Supported by

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