{"action":"created","issue":{"url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/155","repository_url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk","labels_url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/155/labels{/name}","comments_url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/155/comments","events_url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/155/events","html_url":"https://github.com/irazasyed/telegram-bot-sdk/issues/155","id":150531937,"number":155,"title":"get webhook information","user":{"login":"moeinrahimi","id":13715024,"avatar_url":"https://avatars.githubusercontent.com/u/13715024?v=3","gravatar_id":"","url":"https://api.github.com/users/moeinrahimi","html_url":"https://github.com/moeinrahimi","followers_url":"https://api.github.com/users/moeinrahimi/followers","following_url":"https://api.github.com/users/moeinrahimi/following{/other_user}","gists_url":"https://api.github.com/users/moeinrahimi/gists{/gist_id}","starred_url":"https://api.github.com/users/moeinrahimi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moeinrahimi/subscriptions","organizations_url":"https://api.github.com/users/moeinrahimi/orgs","repos_url":"https://api.github.com/users/moeinrahimi/repos","events_url":"https://api.github.com/users/moeinrahimi/events{/privacy}","received_events_url":"https://api.github.com/users/moeinrahimi/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-04-23T08:19:42Z","updated_at":"2016-04-24T07:10:24Z","closed_at":"2016-04-24T07:10:24Z","body":"hi\r\nit may be stupid but i don't know how to retrieve information sent from webhook or getupdates()\r\nshould i use this $telegram->getUpdates()->getMessage()->getChat() ?\r\nit's not working ofcourse, can anyone make a example of how access updates information such as chatid or text"},"comment":{"url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/comments/213906590","html_url":"https://github.com/irazasyed/telegram-bot-sdk/issues/155#issuecomment-213906590","issue_url":"https://api.github.com/repos/irazasyed/telegram-bot-sdk/issues/155","id":213906590,"user":{"login":"irazasyed","id":1915268,"avatar_url":"https://avatars.githubusercontent.com/u/1915268?v=3","gravatar_id":"","url":"https://api.github.com/users/irazasyed","html_url":"https://github.com/irazasyed","followers_url":"https://api.github.com/users/irazasyed/followers","following_url":"https://api.github.com/users/irazasyed/following{/other_user}","gists_url":"https://api.github.com/users/irazasyed/gists{/gist_id}","starred_url":"https://api.github.com/users/irazasyed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/irazasyed/subscriptions","organizations_url":"https://api.github.com/users/irazasyed/orgs","repos_url":"https://api.github.com/users/irazasyed/repos","events_url":"https://api.github.com/users/irazasyed/events{/privacy}","received_events_url":"https://api.github.com/users/irazasyed/received_events","type":"User","site_admin":false},"created_at":"2016-04-24T07:10:24Z","updated_at":"2016-04-24T07:10:24Z","body":"Please refer the docs here: https://telegram-bot-sdk.readme.io/docs/webhook-updates\r\n\r\nAlso, If you don't have the outgoing webhook setup. Only then you can use the `getUpdates()` method.\r\n\r\nSo taking getUpdates as an example, it would be:\r\n\r\n```php\r\n$updates = $telegram->getUpdates();\r\n\r\n// Get's the last update, since the $updates is an array of several update objects.\r\n$update = $updates->recentMessage(); \r\n\r\n$message = $update->getMessage();\r\n$id = $message->getMessageId();\r\n$chat = $message->getChat();\r\n```\r\n\r\nHope that helps. Please go through the docs as well as the collections API of laravel to get an understanding of how things work and the useful methods it offers."}}