1
0
mirror of https://github.com/danog/MadelineProto.git synced 2024-12-15 14:46:54 +01:00
MadelineProto/docs/TD_docs/constructors/location.md

46 lines
868 B
Markdown
Raw Normal View History

---
title: location
description: Describes location on Earth
---
## Constructor: location
[Back to constructors index](index.md)
Describes location on Earth
### Attributes:
| Name | Type | Required | Description |
|----------|:-------------:|:--------:|------------:|
|latitude|[double](../types/double.md) | Yes|Latitude of location in degrees as defined by sender|
|longitude|[double](../types/double.md) | Yes|Longitude of location in degrees as defined by sender|
### Type: [Location](../types/Location.md)
### Example:
```
2017-07-23 16:33:46 +02:00
$location = ['_' => 'location', 'latitude' => double, 'longitude' => double];
```
2017-07-23 16:11:02 +02:00
[PWRTelegram](https://pwrtelegram.xyz) json-encoded version:
```
2017-07-23 16:33:46 +02:00
{"_": "location", "latitude": double, "longitude": double}
2017-07-23 16:11:02 +02:00
```
Or, if you're into Lua:
```
2017-07-23 16:33:46 +02:00
location={_='location', latitude=double, longitude=double}
```