Skip to content
This repository has been archived by the owner on Sep 4, 2024. It is now read-only.

I want create one flux using this lib, but i dont know if this lib can make this #294

Open
JulioVianaDev opened this issue Nov 1, 2023 · 0 comments

Comments

@JulioVianaDev
Copy link

I want create this flux , with my api_id and api_hash, automatically create one bot, and channel, and make the bot is admin of channel, but i dont know how make this my code in this moment stay liked this:

const mtproto = new MTProto({
api_id,
api_hash,

storageOptions: {
path: path.resolve(__dirname, './data/1.json'),
},
});

// 2. Print the user country code
// mtproto.call('help.getNearestDc').then(result => {
// console.log('', result);
// });

mtproto.call('channels.createChannel',{
title: "my first channel",
}).then(result=>{
console.log(result)
}).catch(error=>console.log("error: ",error));

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant