Developers

Build on Engaz

Bots that answer, sell and serve; an API that connects your business to your systems; verification codes that reach your customers’ accounts; and “Sign in with Engaz” for your website. All on the Engaz network only. What we’re building next for companies is on the business platform page.

Getting started

From the app to your first request in three steps

1

Open “Developers”

In Engaz Business: Business tab → “Developers”. Developer tools are for the account owner only, not for employees.

2

Create a bot or a key

A bot with a username ending in bot and a token <botId>:<secret>, or a Business API key ebk_… with the scopes you choose. The token is shown only once.

3

Call the API

Plain HTTPS requests with JSON to the Engaz server. Field names are camelCase; snake_case is accepted too.

Bot API

A bot that talks with people in chats and groups

A bot is a special account with no phone number, owned by a person or a business, that speaks only through its token. People find it by username and tap “Start”.

  • Every message type: text, photos, files, polls, location and product cards
  • Buttons under a message, reply keyboards, and commands shown when typing /
  • Updates by long polling with getUpdates, or by webhook
  • Mini apps: a web page that opens inside the app with signed data
  • Inline bots called with @botname in any chat
  • “No-code replies”: simple rules that answer at once, even without a server
  • Connect a bot to a business account to answer customers in its name
# Send a message with buttons from a bot
TOKEN='<botId>:<secret>'
curl -s "https://www.engaz.net/bot/$TOKEN/sendMessage" \
  -H 'content-type: application/json' -d '{
  "conversationId": "CONV_ID",
  "text": "Pick a size",
  "replyMarkup": {"inlineKeyboard": [[
    {"text": "Small", "callbackData": "size:s"},
    {"text": "Large", "callbackData": "size:l"}
  ]]}}'

# Answer the button press
curl -s "https://www.engaz.net/bot/$TOKEN/answerCallbackQuery" \
  -H 'content-type: application/json' \
  -d '{"callbackQueryId": "CQ_ID", "text": "Large it is"}'

Every answer is { "ok": true, "result": … } or { "ok": false, "error": "…", "message": "…" }.

Business API

Connect your business account to your systems

Send order confirmations and delivery updates from your system, read chats and the customer list, and ask a customer for permission to call, then call them.

ScopeAllows
messages:sendSend a message in a chat with a customer
messages:readChats, their messages, and marking them read
customers:readThe customer list
verifySend and check verification codes
callsAsk permission to call, start and follow calls
# Base: https://www.engaz.net/biz-api/v1   Authorization: Bearer ebk_…
KEY='ebk_…'
curl -s "https://www.engaz.net/biz-api/v1/messages" \
  -H "authorization: Bearer $KEY" \
  -H 'content-type: application/json' -d '{
  "phone": "+201001234567",
  "text": "Your order is on its way 🚚",
  "replyMarkup": {"inlineKeyboard": [[
    {"text": "Track order", "url": "https://example.com/t/42"}
  ]]}}'

Messages go only into existing chats: the customer has to message your business first.

Webhooks

Every event, the moment it happens

Add an https URL and choose your events. Each event is a signed POST, retried on failure after 5 seconds, 30 seconds, 2 minutes, 10 and 30 minutes.

  • message.received, message.reply and message.sent
  • button.pressed when a customer taps a button on an API message
  • member.joined and member.left in your business’s groups
  • call.ringing, call.answered, call.ended and call.missed
  • A “Test event” button in the app to try the connection with automation tools
// Node.js: check the signature before accepting an event
import { createHmac, timingSafeEqual } from 'node:crypto';

const ts = req.headers['x-engaz-timestamp'];
const want = 'sha256=' + createHmac('sha256', SECRET)
  .update(`${ts}.${rawBody}`).digest('hex');
const got = String(req.headers['x-engaz-signature'] ?? '');
const fresh = Math.abs(Date.now() / 1000 - Number(ts)) < 300;
if (!fresh || want.length !== got.length ||
    !timingSafeEqual(Buffer.from(want), Buffer.from(got))) {
  return res.status(401).end();
}
res.status(200).end(); // answer 2xx within 10 seconds

Sign in with Engaz and verification codes

“Sign in with Engaz”

Add a sign-in button to your website or app: OAuth 2.0 authorization code flow with PKCE (S256) always required. The person approves in the Engaz app, and you get their name and photo — and their number if they allow it.

Verification codes

Send a one-time code to your customer’s Engaz account instead of an SMS. It arrives in their chat with your business as a card with a copy button, and you check it with one request.

curl -s "https://www.engaz.net/biz-api/v1/verify/send" \
  -H "authorization: Bearer $KEY" \
  -H 'content-type: application/json' \
  -d '{"phone":"+201001234567","ttlSeconds":120}'

curl -s "https://www.engaz.net/biz-api/v1/verify/check" \
  -H "authorization: Bearer $KEY" \
  -H 'content-type: application/json' \
  -d '{"requestId":"REQ_ID","code":"482913"}'
Limits and security

Clear rules that protect everyone

ItemLimit or rule
Bot messages30 a second per bot, 60 a minute per one-to-one chat, 20 a minute per group
Business API120 requests a minute per key, 30 messages a minute per business
Verification codes5 codes an hour per number from the same business, 200 an hour per business, 5 wrong tries per code
CallsOnly after the customer agrees to “Allow calls”; 20 new calls a minute per business
Tokens and keysShown once, stored only as a hash, and you can create a new one at any time
Webhookshttps URLs to public addresses only, signed with HMAC-SHA256 and a timestamp
Pictures in cardsOnly files uploaded to Engaz, so people’s phones never load links from other sites

Need the full reference, or help with your integration?

We’ll send you the complete API reference with every method, field and event.

Message the developer team