Skip to main content
Squeek
Product tourFeaturesAtmospherePlatformsPrivacyBots
UAEN
Download
Product tourFeaturesAtmospherePlatformsPrivacyBotsDownloads
Back home

For developers

Bots in Squeek

A bot is an account that a program answers for. It shows up in search, you can message it, and you can add it to a group or a channel. Here is how to create one from your phone and get it running in a few minutes.

On this page

  1. Create a bot in the app
  2. Run the bot on Node.js
  3. Post to a channel without the library

1Create a bot in the app

  1. Open “Profile” → “My bots”.
  2. Tap “Create bot”. Enter a name — this is how the bot appears in chats, for example Weather — and a username: Latin letters only, and it must end with bot, for example weather_bot.
  3. Tap “Create”. A dialog shows the token — a long string like 7:a91f…:3c0d…. Tap “Share” and send it to yourself (Saved messages, email, anywhere) or long-press to copy it.

The token is shown once

It is the bot’s password: whoever has the token can write as the bot. Do not publish it and do not commit it to git.

The bot now exists: it appears in search as @weather_bot with a “bot” badge, you can message it, and you can add it to a group or a channel.

No “My bots” button? Update the app — bots arrived in the latest builds.

2Run the bot on Node.js

The program that answers for the bot runs on your computer or server. You need Node.js and the squeek-bot library.

bash
mkdir my-bot && cd my-bot && npm init -y && npm install squeek-bot

Create bot.js:

bot.js
const { SqueekBot } = require('squeek-bot');

const bot = new SqueekBot('7:a91f…:3c0d…'); // the token from the app

bot.on('message', async (msg) => {
  console.log(msg.from.name, ':', msg.text);
  if (msg.text === '/hi') await msg.reply('Hi! 🐀');
});

bot.on('connected', () => console.log('bot is online'));

bot.start();
bash
node bot.js

Now send /hi to the bot from the app — it replies.

  • message — an incoming message. msg.from.name is the sender, msg.text is the text, and msg.reply(text) answers in the same chat.
  • connected — the bot has connected to the server.
  • bot.start() — opens the connection and starts receiving messages.

3Post to a channel without the library

If the bot only posts to a channel, you do not need the library at all. Make the bot a channel admin and send two HTTP requests from any language.

The token has three colon-separated parts: botId:…:secret. Signing in takes the first (botId) and the third (secret).

Get an accessToken
curl https://api.squeek.net/auth/bot \
  -H 'content-type: application/json' \
  -d '{"botId":7,"secret":"3c0d…"}'

The response contains accessToken. Then post to the channel, where chatId is the channel’s id:

Send a message
curl https://api.squeek.net/messages \
  -H "authorization: Bearer <accessToken>" \
  -H 'content-type: application/json' \
  -d '{"chatId":17,"content":"Hello, channel"}'
Squeek

A warm messenger for close conversations and quiet evenings.

Product

DownloadsFeaturesBots

Legal

PrivacyTerms

Contact us

[email protected]
UAEN

© 2026 Squeek. All rights reserved.

Made with warmth from the burrow.