Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use Api.phone.ConfirmCall ? #290

Open
mathysRedTeam opened this issue Mar 24, 2022 · 6 comments
Open

How to use Api.phone.ConfirmCall ? #290

mathysRedTeam opened this issue Mar 24, 2022 · 6 comments

Comments

@mathysRedTeam
Copy link

I'm done a phone.RequestCall and so now i'm trying to exchange the encrypting keys with the confirmCall but when I try it return this error:

RPCError: 400: DH_G_A_INVALID (caused by phone.ConfirmCall)

here is the code:

 const resultB = await client.invoke(new Api.phone.ConfirmCall({
    peer: new Api.InputPhoneCall({
      id: result.phoneCall.id,
      accessHash: result.phoneCall.accessHash
    }),
    gA: Buffer.from("some byte"),
    keyFingerprint: 5673894314823,
    protocol: new Api.PhoneCallProtocol({
      minLayer: 93,
      maxLayer: 93,
      udpP2p:true,
      libraryVersions: ["2"],
    }),
    }));
console.log(resultB); // prints the result
@painor
Copy link
Member

painor commented Mar 25, 2022

What are you trying to do ?
if you are trying to do voice calls you'll need to use the tgcall library

@mathysRedTeam
Copy link
Author

mathysRedTeam commented Mar 25, 2022

What are you trying to do ? if you are trying to do voice calls you'll need to use the tgcall library

Ok, I'm trying to create a userbot (not a bot) who can call users in private, if it is possible can you send me a link to this library please ?

@rojvv
Copy link
Contributor

rojvv commented Mar 25, 2022

This issue is really out of the scope in my opinion. It is your job to investigate about those methods, maybe by reading the sources of official clients and libraries. You cannot get any help by opening an issue here.

@mathysRedTeam
Copy link
Author

This issue is really out of the scope in my opinion. It is your job to investigate about those methods, maybe by reading the sources of official clients and libraries. You cannot get any help by opening an issue here.

Ok but there is a method called phone.ConfirmCall in your code and when I try to use it I get this error

RPCError: 400: DH_G_A_INVALID (caused by phone.ConfirmCall)

So why is that happenning ?

@rojvv
Copy link
Contributor

rojvv commented Mar 25, 2022

@mathysdevnode Read #290 (comment). Sorry if I’m a bit awkward, but it’s the only thing I can say.

@mathysRedTeam
Copy link
Author

@mathysdevnode Read #290 (comment). Sorry if I’m a bit awkward, but it’s the only thing I can say.

You're not realy helping...

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

No branches or pull requests

3 participants