Documentation
¶
Overview ¶
Package location implements API functions residing under /core/location.json. This path contains methods for querying existing locations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API interface { List(ctx context.Context, page, limit int, search string) ([]Location, error) Get(ctx context.Context, identifier string) (Location, error) GetByCode(ctx context.Context, code string) (Location, error) }
API contains methods for retrieving and listing locations.
type Location ¶
type Location struct { Code string `json:"code"` CityCode string `json:"city_code"` Country string `json:"country"` ID string `json:"identifier"` Latitude string `json:"lat"` Longitude string `json:"lon"` Name string `json:"name"` CountryName string `json:"country_name"` }
Location is the metadata of a single location.
Click to show internal directories.
Click to hide internal directories.