telegram-s / telegram-api-old

Telegram Api library for java
MIT License
139 stars 64 forks source link

Get auth_key _id #33

Open anttorval opened 9 years ago

anttorval commented 9 years ago

Hello, All methods that do not require authentication as sendCode, checkPhone, signIn, signUp return successfull but others methods return timeoutexception. I used implementation of AbsApiState from telegram-bot (https://github.com/ex3ndr/telegram-bot/blob/master/app/src/main/java/org/telegram/bot/engine/MemoryApiState.java). I think that using this method: public synchronized void putAuthKey(int dcId, byte[] key) { keys.put(dcId, key); } The others methods return successfull but the parameter "key" is not how to get it.

In conclusion, I want to know how to get and save the authentication of a user so he can send messages etc ...

I'm sorry for my limeted English.

Raakh commented 9 years ago

Hello, can you send me complete working example? My email is ghayel@gmail.com

Chaki1306 commented 7 years ago

annttorval, how to save authorization?