Skip to content
This repository was archived by the owner on Sep 4, 2024. It is now read-only.
This repository was 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

@JulioVianaDev

Description

@JulioVianaDev

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));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions