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

[Question] Bot c#: How can I get user location and time zone on the device from the bot #2626

Closed
msBot1111 opened this issue Apr 20, 2017 · 9 comments

Comments

@msBot1111
Copy link

I need to get user location from bot without asking the user to writes address and also how can I get time zone of the users device to get the local time. My idea is when user says hi or hello bot to respond with good morning or good evening according to the time of the day. And for location, I want to use GPS from users phone to get me the location so I can suggest nearby places to user.

@nwhitmont
Copy link
Contributor

@msBot1111 what channel are you using with your Bot? Eg. Slack, Telegram, Facebook Messenger, Kik?
Depending on the channel, the capabilities and corresponding instructions will be different. Most likely you will find the answer in the API docs for your specific channel.

@nwhitmont nwhitmont changed the title Bot c#: How can I get user location and time zone on the device from the bot [Question] Bot c#: How can I get user location and time zone on the device from the bot Apr 20, 2017
@msBot1111
Copy link
Author

@nwhitmont I am using Skype and I've integrated my bot in xamarin app

@alokraj68
Copy link

@nwhitmont Is it possible in any platform to get user location and time zone?

@msBot1111
Copy link
Author

Is there a way I can get gps location from users device in bot? My bot is integrated in skype channel and in the xamarin app. When I try to get the location from skype it returns null. I saw this link for messenger, but in skype it doesn't work. https://github.com/Microsoft/BotBuilder/blob/master/CSharp/Samples/EchoBot/EchoLocationDialog.cs#L110

@alokraj68
Copy link

@msBot1111 It's all platform specific and hence its hard. you can ask the user to give his location and resolve it using google places.

@JasonSowers
Copy link
Contributor

@msBot1111 can you try looking at these and see if they help for location. The data is not stored by the framework itself though. I am going to close this because it is not exactly a bot framework issue, but a question on geolocation and time zones per device. Feel free to continue the discussion here if you feel so inclined, we can always reopen.

https://stackoverflow.com/questions/38054783/get-user-location-for-bot-framework

https://stackoverflow.com/questions/42904014/reverse-geocoding-with-botframework-location/42913084#42913084

@nwhitmont nwhitmont moved this from To Do to Done in Open Issues - .NET SDK May 26, 2017
@karun-r
Copy link

karun-r commented Oct 10, 2017

@JasonSowers Any plan to integrate this into the framework itself in near future?

@artemious7
Copy link
Contributor

artemious7 commented Jan 30, 2018

How about the time zone?!
I'm always getting the UTC time through DateTime.Now, but no way to determine the time zone!

@Chaitanya1010
Copy link

So are we able to get the latitude and longitude of the user in Skype Channel by asking whenever we need it?

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

No branches or pull requests

7 participants