telegram api method · layer 229 · #d348bc44
contacts.getLocated
Get users and geochats near you, see here » for more info.
definition
contacts.getLocated#d348bc44 flags:# background:flags.1?true geo_point:InputGeoPoint self_expires:flags.0?int = Updates;
parameters
| name | type | description |
|---|---|---|
flags | # | Flags, see TL conditional fields |
background | true | While the geolocation of the current user is public, clients should update it in the background every half-an-hour or so, while setting this flag. Do this only if the new location is more than 1 KM away from the previous one, or if the previous location is unknown. |
geo_point | InputGeoPoint | Geolocation |
self_expires | int | If set, the geolocation of the current user will be public for the specified number of seconds; pass 0x7fffffff to disable expiry, 0 to make the current geolocation private; if the flag isn't set, no changes will be applied. |
returns
errors (7)
| code | error | description |
|---|---|---|
| 400 | BUSINESS_CONNECTION_NOT_ALLOWED | This method was invoked over a business connection using invokeWithBusinessConnection, but either (1) we're a user, and users cannot invoke methods over a business connection; (2) we're a bot, but business mode was disabled in @botfather or (3); we're a bot, but this method cannot be invoked over a business connection. |
| 400 | GEO_POINT_INVALID | Invalid geoposition provided. |
| 400 | USERPIC_UPLOAD_REQUIRED | You must have a profile picture to publish your geolocation. |
| 401 | AUTH_KEY_UNREGISTERED | The specified authorization key is not registered in the system (for example, a PFS temporary key has expired). |
| 406 | BUSINESS_ADDRESS_ACTIVE | The user is currently advertising a Business Location, the location may only be changed (or removed) using account.updateBusinessLocation ». . |
| 406 | USERPIC_PRIVACY_REQUIRED | You need to disable privacy settings for your profile picture in order to make your geolocation public. |
| 406 | USERPIC_UPLOAD_REQUIRED | You must have a profile picture to publish your geolocation. |
history
present in layers 102–229 · constructor id changed 1×
| id | layers |
|---|---|
| #0a356056 | 102–109 |
| #d348bc44 | 110–229 |