modern typescript library for mtproto. supports browsers, node/bun, deno and more! github mirror: https://github.com/mtcute/mtcute
Find a file
2023-10-29 09:14:48 +03:00
.github/workflows docs: updated typedoc, added ci, fixed some docs 2023-10-27 14:25:21 +03:00
.husky build: use lint-staged + pre-commit prettier and type checking 2023-06-10 01:43:52 +03:00
e2e ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
packages fix(tl): cross-schema conflict resolution leading to missing references 2023-10-29 09:14:48 +03:00
scripts fix: pnpm install 2023-10-29 08:35:44 +03:00
.dockerignore ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
.editorconfig feat: tl reference web application 2021-04-14 18:08:53 +03:00
.eslintignore chore: code quality improvements 2023-06-05 00:30:48 +00:00
.eslintrc.ci.js ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
.eslintrc.js feat: new package to automatically scaffold bots 2023-10-22 20:18:12 +03:00
.gitattributes Initial commit 2021-04-08 12:19:38 +03:00
.gitignore docs: updated typedoc, added ci, fixed some docs 2023-10-27 14:25:21 +03:00
.lintstagedrc.cjs refactor: initial support for esm 2023-10-11 08:42:37 +03:00
.mocharc.json ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
.npmrc ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
.nvmrc chore: better dependencies management 2023-06-04 17:00:33 +00:00
.prettierignore refactor: prettier-ed code, rearranged imports, fixed tests 2022-06-30 16:32:56 +03:00
.prettierrc chore: changed prettier width to 120 2023-09-24 01:32:22 +03:00
commitlint.config.js chore: code quality improvements 2023-06-05 00:30:48 +00:00
LICENSE chore: change license to MIT 2023-10-12 07:26:26 +03:00
package.json docs: updated typedoc, added ci, fixed some docs 2023-10-27 14:25:21 +03:00
pnpm-lock.yaml fix: pnpm install 2023-10-29 08:35:44 +03:00
pnpm-workspace.yaml ESM + end-to-end tests (#11) 2023-10-16 19:23:53 +03:00
README.md added CI badge 2023-09-21 03:07:34 +03:00
tsconfig.json fix: stop using tsconfig paths 2023-10-29 00:51:31 +03:00
typedoc.base.cjs docs: updated typedoc, added ci, fixed some docs 2023-10-27 14:25:21 +03:00
typedoc.cjs docs: updated typedoc, added ci, fixed some docs 2023-10-27 14:25:21 +03:00

mtcute

CI badge

PROJECT IS IN A HIATUS

not really, but that's probably the best way to describe it

If anyone would like to take over it, feel free to DM me.
Meanwhile, check out other MTProto libraries in JS, or, better yet, use TDLib for god's sake.

I'm currently not sure what I want to do with mtcute.
I may or may not continue working on it in the future, no promises. I still try to devote some time to it, but it's just not enough, considering the amount of work that needs to be done.

I really would like to at least release this, since there are simply no good enough MTProto libraries in TS, but I'm not sure if I have enough time and motivation to do so.

Like, I'm not saying other TS libraries are bad, but they just aren't good enough for me. I want to have a library that provides the most friendly, convenient and type-safe API possible, while also being fast and reliable, and also hackable to the core.
I'm a perfectionist, and that's exactly why I keep postponing the release of this library, and why I'm not sure if I'll ever release it at all. I could just release it as it is and work from feedback, but I kinda feel like it's not the right way to do it.

Alright, enough of my stupid rambling. If you're still interested, here's the readme:


🗒️ Kanban board Backlog, ideas, improvements, etc.

📚 Documentation Early prototype and is probably outdated in many places, but it's still better than nothing.

💬 Telegram chat TBA, no point in creating it now.

Installation

Currently, target TypeScript major is 5.1, target Node major is 18.

mtcute is currently only published in my private NPM registry.

Note

: versions may (and will) be overwritten, so at one point your build might just break because of integrity checks.
Please don't use this in production, or at least download a tarball and install it from there.

It is currently used for my peronal testing purposes, and I do host a few small bots with it, but I can't guarantee that it will work for you.

ik that my devops are not the best, but im trying, alright?!!

You have been warned.

You can install it by running:

npm config set --location project @mtcute:registry https://npm.tei.su

npm install @mtcute/node # or any other package

Setting up for development:

git clone https://github.com/mtcute/mtcute
fnm use # or `nvm use`
cd mtcute
pnpm install --frozen-lockfile

# generate code from tl schema
pnpm -C packages/tl run gen-code

cat in a readme 🐈

cat

Acknowledgements

Some parts were based on code from these projects: