Use Stocktwits API Python
Maxime Dupré
Stocktwits Scraper
Use Stocktwits API Python in symbol mode for AAPL with maxMessagesPerTarget set to 25 to return up to 25 recent public Stocktwits message rows.
Input
Output fields
Sign up on Apify or log in
The Stocktwits Scraper Actor is ready to run with the inputs already set for "Use Stocktwits API Python". Sign up or log in and you'll land in Apify Console with a copy of this exact task.
Start the "Use Stocktwits API Python" task
The Stocktwits Scraper Actor will start running based on the input automatically. You can also change all the input fields, like result type, ticker symbols, and more, to match your specific use case.
Receive the "Use Stocktwits API Python" output
Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as result type, message id, matched input, and more.
Integrate into your workflow
The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also run the "Use Stocktwits API Python" task via API.

The Use Stocktwits API Python task returns up to 25 public Stocktwits messages for AAPL. Each row can hold the message ID, text, date, author, likes, cashtags, and the author's sentiment label.
The Use Stocktwits API Python task can keep only messages that the author marked Bullish or Bearish. Set sentiment to bullish or bearish. The value all keeps every message.
The Use Stocktwits API Python task returns only posts with a price target when you turn on onlyPriceTargets. Leave it off to get posts with or without a price target.
The Use Stocktwits API Python task can collect older messages with olderThanMessageId. It saves only messages with a lower ID. Use newerThanMessageId to get only messages that are newer than an ID.
The Use Stocktwits API Python task uses maxMessagesPerTarget, now set to 25. Change it to read more or fewer messages. Set 0 to read until the public feed has no more messages.
The Use Stocktwits API Python task charges once for each row saved to the dataset: $0.00045 on the Apify Free plan and $0.00005 on paid plans. Author like counts cost extra and are off by default.
The Use Stocktwits API Python task can run from the Apify API. Start the task with your Apify token, then read the results from its dataset as JSON.
The Use Stocktwits API Python task works with the Apify Python client. Call the task by its ID, wait for the run, and then read the dataset items in your Python code.
The Use Stocktwits API Python task can run on an Apify schedule, such as every hour or every day. Each run saves a new dataset.
The Use Stocktwits API Python task saves rows to an Apify dataset. You can download it as JSON, CSV, Excel, XML, or HTML.