Zellias/balejs ? reverse-engineered prompt
Reverse engineered prompt
Build me a TypeScript library for Node.js that makes it easy to use Bale from code.
I want it to support both a real Bale user account and the official Bale Bot API, so I can log in with a phone number or reuse a saved session, then send and receive messages, handle commands, work with groups and chats, and react to updates in real time. It should also have a bot client with long polling, common message helpers like send, edit, delete, forward, and copy, plus support for things like photos, documents, payments, callbacks, and invoices.
Please include simple examples for an echo bot and a user session bot, basic error handling, and a clean README style setup so someone can install it, run checks, and build it without much trouble. If you need to look up current Bale docs online while wiring up the API details, go ahead.
Are you gonna build this?
make sure you review the code using coderabbit