Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion types/create-torrent/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"private": true,
"name": "@types/create-torrent",
"type": "module",
"version": "6.0.9999",
"version": "6.1.9999",
"projects": [
"https://github.com/webtorrent/create-torrent#readme"
],
Expand Down
227 changes: 189 additions & 38 deletions types/woosmap.map/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1198,6 +1198,16 @@ declare namespace woosmap.map {
* Contains methods related to retrieving autocomplete predictions, geocoding for localities and retrieving details
*/
class LocalitiesService {
/**
* To better track autocomplete sessions and get more accurate and performant results, provide a common uuid to all
* autocomplete session requests and the details request. sessionId must be reset when autocomplete input is emptied
* and when a details is successful.
*/
_sessionId: string;
/**
* Public getter to allow reading the value
*/
sessionId: string;
/**
* Contains methods related to retrieving autocomplete predictions, geocoding for localities and retrieving details
*/
Expand Down Expand Up @@ -1233,9 +1243,6 @@ declare namespace woosmap.map {
request: woosmap.map.localities.LocalitiesNearbyRequest,
): Promise<woosmap.map.localities.LocalitiesNearbyResponse>;

/**
* Search results based on a text-based input.
*/
search(
request: woosmap.map.localities.LocalitiesSearchRequest,
): Promise<woosmap.map.localities.LocalitiesSearchResponse>;
Expand Down Expand Up @@ -2957,6 +2964,11 @@ declare namespace woosmap.map.localities {
* To open suggestions to worldwide postal codes in addition to postal codes for Western Europe.
*/
data?: woosmap.map.localities.LocalitiesRequestData;
/**
* The types of suggestion to exclude. Multiple types can be passed using the pipe character (|) as a separator.
* Example: excluded_types=`suburb|quarter|neighbourhood`
*/
excluded_types?: string | string[];
/**
* If set, this parameter allows a refined search over locality names that bears the same postal code.
* possible value is `extended=postal_code`
Expand Down Expand Up @@ -2988,8 +3000,8 @@ declare namespace woosmap.map.localities {
/**
* The types of predictions to be returned.
* By default, suggestions return types `locality` and `postal_code`.
* can be either a single type or a list of `LocalitiesTypes`
* see [https://developers.woosmap.com/products/localities/autocomplete/#types](https://developers.woosmap.com/products/localities/autocomplete/#types)
* can be either a single type or a list of `LocalitiesTypes|LocalitiesTypesPoi|LocalitiesTypesPoiAlias`
* see [https://developers.woosmap.com/products/localities/concepts/locality-types/](https://developers.woosmap.com/products/localities/concepts/locality-types/)
*/
types?: string | string[];
}
Expand Down Expand Up @@ -3018,6 +3030,11 @@ declare namespace woosmap.map.localities {
* Whether to retrieve suggestions to worldwide postal codes in addition to postal codes for Western Europe.
*/
data?: woosmap.map.localities.LocalitiesRequestData;
/**
* The types of suggestion to exclude. Multiple types can be passed using the pipe character (|) as a separator.
* Example: excluded_types=`suburb|quarter|neighbourhood`
*/
excluded_types?: string | string[];
/**
* If set, it will limit the content of responses to the specified fields.
* This parameter can be any combination of geometry, address_components or shape (defaults to geometry|address_components).
Expand All @@ -3041,8 +3058,8 @@ declare namespace woosmap.map.localities {
/**
* The types of geocoding responses to be returned.
* By default, suggestions return types `locality`, `postal_code` and `address`
* can be either a single type or a list of `LocalitiesTypes`
* see [https://developers.woosmap.com/products/localities/geocode/#types](https://developers.woosmap.com/products/localities/geocode/#types)
* can be either a single type or a list of `LocalitiesTypes|LocalitiesTypesPoi|LocalitiesTypesPoiAlias`
* see [https://developers.woosmap.com/products/localities/concepts/locality-types/](https://developers.woosmap.com/products/localities/concepts/locality-types/)
*/
types?: string | string[];
}
Expand Down Expand Up @@ -3082,10 +3099,10 @@ declare namespace woosmap.map.localities {
interface LocalitiesNearbyRequest {
categories?: string | string[];
/**
* The language code, using ISO 3166-1 Alpha-2 country codes,
* indicating in which language the results should be returned, if possible.
* If language is not supplied, the Localities service will use english as default language.
* POI types to exclude from results
* Example: `business.food_and_drinks.fast_food|business.food_and_drinks.pub`
*/
excluded_types?: string | string[];
language?: string;
/**
* Limit of results per page. (Default is 10, max is 30)
Expand All @@ -3105,16 +3122,14 @@ declare namespace woosmap.map.localities {
*/
radius?: number;
/**
* Types of targeted items.
* The only available value for now is `point_of_interest`.
* POI types to include (pipe-separated).
* Example: `business.shop|medical.pharmacy|bank`.
* To check common POI types refer [https://developers.woosmap.com/products/localities/features/nearby/#common-poi-types](https://developers.woosmap.com/products/localities/features/nearby/#common-poi-types)
*/
types?: string | string[];
types: string | string[];
}
}
declare namespace woosmap.map.localities {
/**
* A Localities Search request to be sent to `LocalitiesService.search`
*/
interface LocalitiesSearchRequest {
/**
* The categories of points of interest to return. Multiple categories can be passed as an array of comma separated strings.
Expand Down Expand Up @@ -3232,9 +3247,9 @@ declare namespace woosmap.map.localities {
*/
address_components?: woosmap.map.localities.AddressComponents[];
/**
* An array containing the categories of the result, only for points of interests.
* Only available for admin_level suggestions, this contains the local english name of the administration level ("department" for France or "federal_state" for Germany).
*/
categories?: string[];
administrative_area_label?: string;
/**
* Contains the readable text description of the result.
*/
Expand All @@ -3259,7 +3274,11 @@ declare namespace woosmap.map.localities {
/**
* available localities types
*/
types: woosmap.map.localities.LocalitiesTypes[];
types: Array<
| woosmap.map.localities.LocalitiesTypes
| woosmap.map.localities.LocalitiesTypesPoi
| woosmap.map.localities.LocalitiesTypesPoiAlias
>;
}
}
declare namespace woosmap.map.localities {
Expand Down Expand Up @@ -3291,6 +3310,16 @@ declare namespace woosmap.map.localities {
public_id: string;
}
}
declare namespace woosmap.map.localities {
/**
* For each component (street_name, postal_code, and locality), it indicates the degree of correspondence with the original query. This value ranges from 0 to 1, with 0 indicating no match with the original query, and enables you to assess the quality of the Geocode’s result.
*/
interface LocalitiesScoresPerComponent {
locality: number;
postal_code: number;
street_name: number;
}
}
declare namespace woosmap.map.localities {
/**
* Represents a single locality prediction
Expand Down Expand Up @@ -3321,10 +3350,15 @@ declare namespace woosmap.map.localities {
* Contains the related information for the prediction.
*/
related?: woosmap.map.localities.LocalitiesRelated;
type?: woosmap.map.localities.LocalitiesTypes;
/**
* Contains the type of the Localities prediction.
* An array containing the types of the result.
*/
type?: woosmap.map.localities.LocalitiesTypes;
types?: Array<
| woosmap.map.localities.LocalitiesTypes
| woosmap.map.localities.LocalitiesTypesPoi
| woosmap.map.localities.LocalitiesTypesPoiAlias
>;
}
}
declare namespace woosmap.map.localities {
Expand All @@ -3336,6 +3370,14 @@ declare namespace woosmap.map.localities {
* An array containing Address Components with additional information
*/
address_components?: woosmap.map.localities.AddressComponents[];
/**
* Only available for admin_level suggestions, this contains the local english name of the administration level ("department" for France or "federal_state" for Germany).
*/
administrative_area_label?: string;
/**
* When reverse geocoding, this field represents the distance (in meters) to the requested latlng
*/
distance?: number;
/**
* Contains the readable text description of the result.
*/
Expand All @@ -3349,6 +3391,10 @@ declare namespace woosmap.map.localities {
* Contains a unique ID for geocoded locality.
*/
public_id: string;
/**
* For each component (street_name, postal_code, and locality), it indicates the degree of correspondence with the original query. This value ranges from 0 to 1, with 0 indicating no match with the original query, and enables you to assess the quality of the Geocode’s result.
*/
scores_per_components?: woosmap.map.localities.LocalitiesScoresPerComponent;
/**
* This optional field is only available for UK addresses referenced as not yey built.
*/
Expand All @@ -3360,31 +3406,142 @@ declare namespace woosmap.map.localities {
/**
* available localities types
*/
types: woosmap.map.localities.LocalitiesTypes[];
types:
| woosmap.map.localities.LocalitiesTypes[]
| woosmap.map.localities.LocalitiesTypesPoi[]
| woosmap.map.localities.LocalitiesTypesPoiAlias[];
}
}
declare namespace woosmap.map.localities {
type DeprecatedLocalitiesTypes =
| "airport"
| "amusement_park"
| "art_gallery"
| "metro_station"
| "museum"
| "shopping"
| "tourist_attraction"
| "train_station"
| "zoo"
| "point_of_interest";
}
declare namespace woosmap.map.localities {
/**
* The types of suggestion to return.
* By default, suggestions return types `locality` and `postal_code`.
* Check [full list of supported types](https://developers.woosmap.com/products/localities/autocomplete/#types)
*/
type LocalitiesTypes =
| woosmap.map.localities.DeprecatedLocalitiesTypes
| "country"
| "admin_level"
| "postal_code"
| "address"
| "route"
| "locality"
| "admin_level"
| "city"
| "town"
| "village"
| "hamlet"
| "borough"
| "suburb"
| "quarter"
| "neighbourhood";
}
declare namespace woosmap.map.localities {
/**
* Categories of points of interest (POI) supported for detailed classification in geographic data queries.
* Refer [supported POI types][https://developers.woosmap.com/products/localities/concepts/locality-types/#point-of-interest-types](https://developers.woosmap.com/products/localities/concepts/locality-types/#point-of-interest-types)
*/
type LocalitiesTypesPoi =
| "point_of_interest"
| "transit.station"
| "transit.station.airport"
| "transit.station.rail"
| "beach"
| "business"
| "business.car_repair"
| "business.car_rental"
| "business.cinema"
| "business.conference_centre"
| "business.exhibition_centre"
| "business.theatre"
| "business.nightclub"
| "business.finance"
| "business.finance.bank"
| "business.fuel"
| "business.parking"
| "business.mall"
| "business.food_and_drinks"
| "business.food_and_drinks.bar"
| "business.food_and_drinks.biergarten"
| "business.food_and_drinks.cafe"
| "business.food_and_drinks.fast_food"
| "business.food_and_drinks.pub"
| "business.food_and_drinks.restaurant"
| "business.food_and_drinks.food_court"
| "business.shop"
| "business.shop.mall"
| "business.shop.bakery"
| "business.shop.butcher"
| "business.shop.library"
| "business.shop.grocery"
| "business.shop.sports"
| "business.shop.toys"
| "business.shop.clothes"
| "business.shop.furniture"
| "business.shop.electronics"
| "business.shop.doityourself"
| "business.shop.craft"
| "education"
| "education.school"
| "education.kindergarten"
| "education.university"
| "education.college"
| "education.library"
| "hospitality"
| "hospitality.hotel"
| "hospitality.hostel"
| "hospitality.guest_house"
| "hospitality.bed_and_breakfast"
| "hospitality.motel"
| "medical"
| "medical.hospital"
| "medical.pharmacy"
| "medical.clinic"
| "tourism"
| "tourism.attraction"
| "tourism.attraction.amusement_park"
| "tourism.attraction.zoo"
| "tourism.attraction.aquarium"
| "tourism.monument"
| "tourism.monument.castle"
| "tourism.museum"
| "government"
| "park"
| "park.national"
| "place_of_worship"
| "police"
| "post_office"
| "sports"
| "sports.golf"
| "sports.winter";
}
declare namespace woosmap.map.localities {
/**
* POI aliases
*/
type LocalitiesTypesPoiAlias =
| "airport"
| "amusement_park"
| "art_gallery"
| "country"
| "train_station"
| "transit.station"
| "metro_station"
| "museum"
| "postal_code"
| "shopping"
| "tourist_attraction"
| "train_station"
| "museum"
| "zoo"
| "point_of_interest";
| "amusement_park"
| "art_gallery"
| "tourist_attraction";
}
declare namespace woosmap.map.localities {
/**
Expand Down Expand Up @@ -3459,9 +3616,6 @@ declare namespace woosmap.map.localities {
}
}
declare namespace woosmap.map.localities {
/**
* The types of result returned by nearby search.
*/
type LocalitiesNearbyTypes = "point_of_interest";
}
declare namespace woosmap.map.localities {
Expand All @@ -3473,9 +3627,6 @@ declare namespace woosmap.map.localities {
* An array containing Address Components with additional information
*/
address_components: woosmap.map.localities.AddressComponents[];
/**
* An array containing the categories of the result.
*/
categories: string[];
/**
* The location of the result, in latitude and longitude, eventually associated with a Viewport.
Expand All @@ -3492,7 +3643,7 @@ declare namespace woosmap.map.localities {
/**
* An array containing the types of the result.
*/
types: woosmap.map.localities.LocalitiesNearbyTypes[];
types: Array<woosmap.map.localities.LocalitiesNearbyTypes | woosmap.map.localities.LocalitiesTypesPoi>;
}
}
declare namespace woosmap.map.localities {
Expand Down
Loading