PoshmarkNursery is a bot that shares available items from one's own Poshmark closet to his/her followers on a schedule. It can also be configured to share back items from people who shared your items or share items from a given list of closets. Poshmark is an online reselling platform, and sharing one's own items helps to promote sales.
I started reselling some of my clothes on Poshmark in the summer of 2019 and quickly learned that regularly sharing my own items is essential for sales. The act of sharing is tedious, so I wrote this script to automate it.
Over time, I experimented with sharing back and sharing other users' closets. I found that these actions did not meaningfully increase likes or sales. In one case, I was even blocked by a seller for sharing her closet too frequently. As a result, I have not used those features in several years. They are included for completeness but are not actively maintained and may not work with the current Poshmark UI. For best results, use the script to share your own closet only.
- Python 3.7.3+
- Selenium 3.141.0+
- Firefox browser (latest version recommended)
- geckodriver (must be in your PATH)
Clone the source locally:
git clone https://github.com/xzhou13/PoshmarkNursery
Modify the "config.py" file to contain your Poshmark login and password within the "".
username = r"username"
password = r"password"
Run in terminal with the following options:
Default mode (self-share once every 30 minutes while checking for captcha, preserving order via "order.txt", not sharing/following back, not sharing closets from file):
python posh_nursery.py
Poshmark now requires 2FA for most accounts. The script automatically detects the verification prompt after login, asks for the code on the command line, and submits it for you. Simply enter the code sent to your phone and hit "Enter" via command line when prompted.
Example output:
Logging in Poshmark as username...
2FA verification required. Please enter the code sent to your phone.
Enter verification code: 123456
2FA code submitted.
Logged into poshmark
Four optional command line arguments in this order:
python posh_nursery.py {integerNumberOfSeconds} {Y|N} {Y|N} {Y|N}
-
{integerNumberOfSeconds}– Number of seconds to wait between sharing cycles. Default1800(30 minutes). -
{Y|N}– Check for captcha while sharing. DefaultY.
WhenN, the script will not pause for captcha solving; it may get stuck but will continue trying. Useful for unattended runs. -
{Y|N}– Share closets listed inclosetsToShare.txt. DefaultN.
⚠️ Note: This feature is not actively maintained and may not work with the latest Poshmark UI. Use at your own risk. WhenY, the program shares only those closets (once) and then exits. -
{Y|N}– Preserve closet order usingorder.txt. DefaultY.
Items are shared in the order listed inorder.txt. New items are added to the top; sold/removed items are deleted from the file.
⚠️ Important: This feature requires that all available items have unique names. If you have duplicate item titles (e.g., two identical listings with the same name), the script cannot tell them apart and the ordering will fail. Consider editing your listing titles to make them distinct if you use this feature.
Debugging Tip: Consider sharing with "headless" mode turned off. This will show the selenium driven Firefox window. To turn off headless mode, comment out this line in the "posh_nursery.py" file:
self.firefoxoptions.add_argument("-headless")
- Captcha: This will get caught by captcha. In the default mode, when this happens, the script detects it, enters into the debugger mode, pauses sharing, and waits for the user to manually solve the captcha. After solving the captcha, type 'c' or 'continue' in the debugger to continue the sharing.
Captcha detected, please solve
> /Users/username/Projects/posh_nursery/posh_nursery.py(400)checkAndWaitForCaptchaSolve()
-> self.driver.minimize_window()
(Pdb) c
I recommend logging into your Poshmark account on a new web browser (not the selenium driven chromedriver window), and then share an item there. This will reduce the number of captchas you'll have to solve. If you're going to be away from your computer, you can run it with checking for captcha turned off (1st optional parameter, read more about optional parameters here), and remotely check in occasionally to solve for captchas.
- If you continuously see the message "Timed out while waiting for share modal to disappear..clicking second share again" on the stdout, that might mean you've hit a sharing threshold Poshmark set, which could prohibit you from sharing for a number of hours. Consider sharing less frequently in this case. I've only hit this limit when I shared with this script non-stop for a few hours.
- geckodriver: Update geckodriver when Firefox updates to a new major version.
- UI updates: Poshmark occasionally changes its HTML/CSS. If the script stops finding share buttons or item names, you may need to update the XPaths in posh_nursery.py (look for firstShareXPath, itemNameXPath, etc.).
