Add location, venue and user profile photos type documentation

bot-api-6.1
Ilya Kaznacheev 2020-10-24 16:30:45 +03:00
parent 1b845170c1
commit 2497684181
No known key found for this signature in database
GPG Key ID: 7E2C1D8A4AB37D50
1 changed files with 16 additions and 7 deletions

View File

@ -613,22 +613,31 @@ type Contact struct {
// Location contains information about a place. // Location contains information about a place.
type Location struct { type Location struct {
// Longitude as defined by sender
Longitude float64 `json:"longitude"` Longitude float64 `json:"longitude"`
Latitude float64 `json:"latitude"` // Latitude as defined by sender
Latitude float64 `json:"latitude"`
} }
// Venue contains information about a venue, including its Location. // Venue contains information about a venue, including its Location.
type Venue struct { type Venue struct {
Location Location `json:"location"` // Location venue location
Title string `json:"title"` Location Location `json:"location"`
Address string `json:"address"` // Title name of the venue
FoursquareID string `json:"foursquare_id"` // optional Title string `json:"title"`
// Address of the venue
Address string `json:"address"`
// FoursquareID foursquare identifier of the venue
// optional
FoursquareID string `json:"foursquare_id"`
} }
// UserProfilePhotos contains a set of user profile photos. // UserProfilePhotos contains a set of user profile photos.
type UserProfilePhotos struct { type UserProfilePhotos struct {
TotalCount int `json:"total_count"` // TotalCount total number of profile pictures the target user has
Photos [][]PhotoSize `json:"photos"` TotalCount int `json:"total_count"`
// Photos requested profile pictures (in up to 4 sizes each)
Photos [][]PhotoSize `json:"photos"`
} }
// File contains information about a file to download from Telegram. // File contains information about a file to download from Telegram.