py3-pinterest v2.0.0 - The Comeback Release
py3-pinterest is back. This is the biggest release since the project started — nearly every core feature has been updated/fixed, modernized, or rewritten. If you gave up on py3-pinterest because uploads were broken, pagination was unreliable, or login kept failing.
Thank you so much to everybody who contributed to this release!
@alglez, @anonymustard, @Ashad001, @bahrmichaelj, @CapofWeird, @edersonff, @elmissouri16, @erenalpt, @evezus, @fratamico, @Gmanicus, @imgVOID, @kruvatz, @magicaltoast, @marcosfelt, @mfhassan22, @Nviard,
@RKuttruff, @VeemPees, @victorviro, @vladradishevsky, @vriadlee, @vtni, @yaonur
Pip is published too
pip install py3-pinterest
What's New
Video Pin Uploads
You can now upload video pins (Story Pins / Idea Pins) to Pinterest. The new upload_video_pin() method handles the entire flow — video registration, S3 upload, cover image extraction, and story pin creation.
Requires ffmpeg/ffprobe on PATH for automatic video probing, or pass duration_ms, width, height, and cover_image_file manually.
pinterest.upload_video_pin(
video_file="my_video.mov",
board_id="123456789",
title="My Video Pin",
description="Uploaded with py3-pinterest!"
)
Image Uploads Completely Rewritten
The old /upload-image/ endpoint has been dead for a long time. upload_pin() now uses Pinterest's current S3-based upload flow — register media, upload to S3, poll for completion, then create the pin with the image signature. It actually works now.
pinterest.upload_pin(
board_id="123456789",
image_file="photo.jpg",
title="My Pin",
description="Uploaded from a local file"
)
Closes #204, #207, #188, #184, #148, #178, #176, #175, #174, #137, #136
Board Management
New delete_board() method: pinterest.delete_board(board_id="123456789")
Board Sections Now Support page_size
get_board_sections() now accepts a page_size parameter (default: 100, up from the hardcoded 25). Boards with 25+ sections are no longer truncated.
Closes #187
Bug Fixes
Pagination Fixed Across All Methods
Every paginated method had a bug where calling with reset_bookmark=True after reaching the end would return an empty list instead of resetting and fetching fresh data. You'd need to call the method twice to get results again. This has been fixed in all 12 paginated methods:
boards, get_user_pins, get_following, get_user_followers, get_comments, visual_search, search, board_recommendations, home_feed, board_feed, get_board_sections, get_section_pins
load_pin() Fixed
No longer parses HTML looking for PWS_DATA or v3GetPinQuery keys. Uses the PinResource/get API endpoint directly.
Login Improvements
- Cookie consent banner: Automatically dismissed for users in EU/GDPR regions where it blocked the login form (#219, #108)
- Language-independent login: Submit button is now found via button[type="submit"] instead of searching for English "Log in" text (#193)
- Browser cleanup: driver.quit() in a finally block ensures Chrome is always closed, even on login failure
- Credentials actually persist: Registry no longer calls shutil.rmtree on initialization, which could delete your data/ directory (#139) or prevent cookies from being stored (#156)
Closes #219, #193, #108, #156, #139
403 Forbidden Errors Resolved
All API endpoints use the current /resource/ URL pattern. The old /_ngjs/resource/ prefix that caused 403 errors everywhere is gone.
Dependency Updates
- selenium>=4.0.0 — Fixes the Timeout value connect was crash caused by selenium 3.x + urllib3 2.x incompatibility (#202)
- webdriver-manager>=4.0.0 — Fixes ChromeDriver download failures after Google restructured their download URLs (#195, #191)
- New GitHub Actions workflow for manual PyPI publishing
CI/CD
Integration Tests
This release is backed by a full integration test suite — 38 tests covering boards, pins, uploads, search, user operations, follows, comments, conversations, and login. All passing against the live Pinterest API.