Home/Answers/Notify when a price hits a target
Answer

How do I get a notification when a price hits my target?

Poll a price API from a small script and POST to Lert when it crosses your number. Download the app, copy your link, and let the script buzz your phone the moment the threshold is hit. No account, no API keys, no SDK.

This is purely a notification mechanism: a tiny script checks a number and, if it's past the level you set, sends you a push. You define what "hit my target" means; Lert just delivers the alert. Because your Lert link is the credential, there's nothing to register — you paste one URL and the script does the rest. (This is about the alert, not advice on what to do with it.)

The entire setup — under 30 seconds

  1. Download the app. Open it once. There's no account to create, and your private link is waiting on screen.
  2. Copy your link. One tap copies something like https://lert.dev/p/your-id.
  3. Run the polling script. Point it at any public price API, set your threshold, and let it POST to your link when the value crosses.

Then your phone buzzes — instantly, even locked in your pocket.

The polling script

python
import requests

LERT = "https://lert.dev/p/your-id"
TARGET = 2500          # the level you care about

# read a value from any public price API
price = requests.get("https://api.example.com/price").json()["usd"]

if price >= TARGET:
    requests.post(LERT, json={
        "title": "Target reached",
        "body": f"Price is {price} (target {TARGET})",
        "tag": "price"
    })

Run it every few minutes with cron or a scheduled task and it stays quiet until your number is crossed. Swap the API URL and JSON field for whatever public feed you're watching. To avoid repeat pings, have the script write a small flag file once it has fired.

Just the alert. Lert delivers the notification you asked for — it doesn't give financial advice or place any trades. What counts as your target, and what you do when it's reached, is entirely up to you.

Related things people automate

It's free for one channel and 50 notifications a day; Lert Pro is $2.99/month for unlimited. See the docs for the full API, or the answers index for more recipes.

Send your first one in 30 seconds.

Download Lert, copy your link, POST to it. Your phone buzzes.

Get the app iOS