AI agents
Paste one prompt into Cursor, Claude Code or any coding agent and it adds Tinyping notifications to your project.
An AI coding agent can add Tinyping for you. Paste the prompt below into Cursor, Claude Code or any other agent.
Before you start, create a project and a token. Add TINYPING_TOKEN to your .env file. See the quickstart.
The prompt
Add Tinyping push notifications to this project.
1. Read TINYPING_TOKEN from an environment variable and add it to the env example file. I copy it from my project page in Tinyping.
2. Create a notify(event) helper that sends a POST request to https://api.tinyping.app/v1/events with the headers "Authorization: Bearer TINYPING_TOKEN" and "Content-Type: application/json".
3. The JSON body has a required title (up to 120 characters) and an optional body (up to 2000), url, priority (one of low, normal, high), kind (up to 40) and tags (up to 8).
4. Call notify on new sign-ups, successful payments and unhandled server errors, with a short title and the key detail in the body.
5. notify must never break the app: use a 5 second timeout, catch errors and return true or false.
6. Show me where you added the calls, then send one test event.What the agent does
- It adds a small
notifyhelper to your code. - It reads your token from an environment variable.
- It sends alerts for sign-ups, payments and errors.
- It sends one test event so you can check your phone.
Warning
Never paste your token into the chat. Keep it in your .env file. Add the file name to
.gitignore.
Change what it alerts on
Edit step 4 of the prompt. For example, ask for alerts on failed jobs or deploys instead. The recipes page has ideas.
