@chaosity/location-client 0.12.0 → 0.13.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/README.md +125 -36
  2. package/dist/adapters/GeoPlaces.d.ts +7 -1
  3. package/dist/adapters/GeoPlaces.js +11 -5
  4. package/dist/auth/TokenProvider.d.ts +22 -1
  5. package/dist/auth/TokenProvider.js +42 -2
  6. package/dist/auth/tokenHold.d.ts +14 -5
  7. package/dist/auth/tokenHold.js +70 -5
  8. package/dist/aws.d.ts +4 -0
  9. package/dist/aws.js +2 -0
  10. package/dist/cjs/adapters/GeoPlaces.d.ts +7 -1
  11. package/dist/cjs/adapters/GeoPlaces.js +10 -4
  12. package/dist/cjs/auth/TokenProvider.d.ts +22 -1
  13. package/dist/cjs/auth/TokenProvider.js +42 -2
  14. package/dist/cjs/auth/tokenHold.d.ts +14 -5
  15. package/dist/cjs/auth/tokenHold.js +71 -5
  16. package/dist/cjs/aws.d.ts +4 -0
  17. package/dist/cjs/aws.js +155 -0
  18. package/dist/cjs/client/GeoPlacesClient.d.ts +17 -1
  19. package/dist/cjs/client/GeoPlacesClient.js +18 -62
  20. package/dist/cjs/index.d.ts +4 -3
  21. package/dist/cjs/index.js +13 -8
  22. package/dist/cjs/maps/createTransformRequest.d.ts +25 -0
  23. package/dist/cjs/maps/createTransformRequest.js +1 -0
  24. package/dist/cjs/maps/mapPoi.d.ts +10 -5
  25. package/dist/cjs/maps/mapPoi.js +14 -5
  26. package/dist/cjs/maps/mapStyle.d.ts +9 -2
  27. package/dist/cjs/maps/mapStyle.js +16 -12
  28. package/dist/cjs/maps/mapToken.d.ts +87 -0
  29. package/dist/cjs/maps/mapToken.js +181 -0
  30. package/dist/cjs/maps/staticMap.d.ts +7 -3
  31. package/dist/cjs/maps/staticMap.js +13 -12
  32. package/dist/cjs/server/LocationServiceConnector.d.ts +18 -3
  33. package/dist/cjs/server/LocationServiceConnector.js +17 -58
  34. package/dist/cjs/server/getClientConfig.d.ts +7 -3
  35. package/dist/cjs/server/getClientConfig.js +9 -12
  36. package/dist/cjs/server/index.d.ts +1 -1
  37. package/dist/cjs/transport/http.d.ts +18 -0
  38. package/dist/cjs/transport/http.js +39 -1
  39. package/dist/cjs/types/index.d.ts +26 -0
  40. package/dist/client/GeoPlacesClient.d.ts +17 -1
  41. package/dist/client/GeoPlacesClient.js +21 -65
  42. package/dist/index.d.ts +4 -3
  43. package/dist/index.js +11 -7
  44. package/dist/maps/createTransformRequest.d.ts +25 -0
  45. package/dist/maps/createTransformRequest.js +1 -1
  46. package/dist/maps/mapPoi.d.ts +10 -5
  47. package/dist/maps/mapPoi.js +14 -5
  48. package/dist/maps/mapStyle.d.ts +9 -2
  49. package/dist/maps/mapStyle.js +17 -13
  50. package/dist/maps/mapToken.d.ts +87 -0
  51. package/dist/maps/mapToken.js +177 -0
  52. package/dist/maps/staticMap.d.ts +7 -3
  53. package/dist/maps/staticMap.js +14 -13
  54. package/dist/server/LocationServiceConnector.d.ts +18 -3
  55. package/dist/server/LocationServiceConnector.js +20 -61
  56. package/dist/server/getClientConfig.d.ts +7 -3
  57. package/dist/server/getClientConfig.js +9 -12
  58. package/dist/server/index.d.ts +1 -1
  59. package/dist/transport/http.d.ts +18 -0
  60. package/dist/transport/http.js +37 -1
  61. package/dist/types/index.d.ts +26 -0
  62. package/package.json +3 -3
@@ -71,6 +71,12 @@ function insideBox([x, y], bbox) {
71
71
  return minX <= maxX ? x >= minX && x <= maxX : x >= minX || x <= maxX;
72
72
  }
73
73
  class GeoPlaces {
74
+ /**
75
+ * @param client Anything with the client's `send` — the adapter calls
76
+ * nothing else (#65). `@chaosity/location-client-react`'s
77
+ * `useLocationClient()` hands out an interface, not a `GeoPlacesClient`,
78
+ * and a class with private fields admits no other object.
79
+ */
74
80
  constructor(client, map, options = {}) {
75
81
  this.client = client;
76
82
  this.map = map;
@@ -120,7 +126,7 @@ class GeoPlaces {
120
126
  : config.countries.split(','),
121
127
  };
122
128
  }
123
- const response = (await this.client.send(new commands_js_1.GeocodeCommand(commandInput)));
129
+ const response = await this.client.send(new commands_js_1.GeocodeCommand(commandInput));
124
130
  const converted = (0, amazon_location_utilities_datatypes_1.geocodeResponseToFeatureCollection)(response, {
125
131
  flattenProperties: true,
126
132
  });
@@ -148,7 +154,7 @@ class GeoPlaces {
148
154
  MaxResults: config.limit || 1,
149
155
  Language: this.normalizeLanguage(config.language),
150
156
  };
151
- const response = (await this.client.send(new commands_js_1.ReverseGeocodeCommand(commandInput)));
157
+ const response = await this.client.send(new commands_js_1.ReverseGeocodeCommand(commandInput));
152
158
  const converted = (0, amazon_location_utilities_datatypes_1.reverseGeocodeResponseToFeatureCollection)(response, {
153
159
  flattenProperties: true,
154
160
  });
@@ -206,7 +212,7 @@ class GeoPlaces {
206
212
  }
207
213
  : {}),
208
214
  };
209
- const response = (await this.client.send(new commands_js_1.SuggestCommand(commandInput)));
215
+ const response = await this.client.send(new commands_js_1.SuggestCommand(commandInput));
210
216
  const suggestions = { suggestions: [] };
211
217
  for (const item of response.ResultItems ?? []) {
212
218
  const text = item.Title;
@@ -229,7 +235,7 @@ class GeoPlaces {
229
235
  Language: this.normalizeLanguage(config.language),
230
236
  ...(additionalFeatures ? { AdditionalFeatures: additionalFeatures } : {}),
231
237
  });
232
- const response = (await this.client.send(command));
238
+ const response = await this.client.send(command);
233
239
  const result = (0, amazon_location_utilities_datatypes_1.getPlaceResponseToFeatureCollection)(response, {
234
240
  flattenProperties: true,
235
241
  });
@@ -4,6 +4,21 @@ export interface TokenResponse {
4
4
  expiresAt?: number;
5
5
  error?: string;
6
6
  }
7
+ export interface GetTokenOptions {
8
+ /**
9
+ * When a refresh fails with an error that waiting can fix — a 429 or 503
10
+ * from `/auth/token`, a network fault, or the `Retry-After` such a failure
11
+ * left standing — return the cached token instead, while it is before its
12
+ * own `exp` (#63). A refusal (401 or 403) still clears the cache and throws,
13
+ * and a forced refresh never falls back: it is asked for because the API
14
+ * refused the cached token.
15
+ *
16
+ * For server-side dispatch only. Never set it where the token is handed to
17
+ * a browser: a token inside `TOKEN_REFRESH_BUFFER_SECONDS` is one the React
18
+ * provider asks to replace at once, so `getClientConfig` does not.
19
+ */
20
+ cachedUntilExpiry?: boolean;
21
+ }
7
22
  export interface TokenProviderConfig {
8
23
  apiUrl: string;
9
24
  clientId: string;
@@ -45,7 +60,7 @@ export declare class TokenProvider {
45
60
  /** A refusal or a Retry-After from `/auth/token`, until it lapses (#38). */
46
61
  private readonly hold;
47
62
  constructor(config: TokenProviderConfig);
48
- getToken(forceRefresh?: boolean): Promise<TokenResponse>;
63
+ getToken(forceRefresh?: boolean, options?: GetTokenOptions): Promise<TokenResponse>;
49
64
  /**
50
65
  * Fetch a token, distinguishing transient failure from terminal (#9).
51
66
  *
@@ -61,6 +76,12 @@ export declare class TokenProvider {
61
76
  * with `success: false`, so a stale token can never be used by accident.
62
77
  */
63
78
  private fetchToken;
79
+ /**
80
+ * #63: the cached token, when the caller asked for it and the failure is one
81
+ * that waiting fixes. A refusal has already cleared the cache in fetchToken,
82
+ * so it can never be the cached token handed back here.
83
+ */
84
+ private fallback;
64
85
  private isExpired;
65
86
  clearCache(): void;
66
87
  }
@@ -10,6 +10,11 @@ const http_js_1 = require("../transport/http.js");
10
10
  const tokenHold_js_1 = require("./tokenHold.js");
11
11
  const tokenRefresh_js_1 = require("./tokenRefresh.js");
12
12
  const log = (0, debug_1.default)('location-client:auth');
13
+ /**
14
+ * #63: how close to its own `exp` a cached token may still be sent when a
15
+ * refresh fails. A margin for the clocks of this host and the API to disagree.
16
+ */
17
+ const EXPIRY_SKEW_MS = 5000;
13
18
  /**
14
19
  * TokenProvider - SERVER-SIDE ONLY
15
20
  *
@@ -51,7 +56,7 @@ class TokenProvider {
51
56
  log('Initializing TokenProvider for %s', config.apiUrl);
52
57
  this.config = config;
53
58
  }
54
- async getToken(forceRefresh = false) {
59
+ async getToken(forceRefresh = false, options = {}) {
55
60
  if (!forceRefresh && this.cachedToken && !this.isExpired()) {
56
61
  const expiresIn = this.cachedExpiresAt
57
62
  ? Math.floor((this.cachedExpiresAt - Date.now()) / 1000)
@@ -70,12 +75,20 @@ class TokenProvider {
70
75
  const held = this.hold.check()?.error;
71
76
  if (held) {
72
77
  log('Token request held: %s', held.message);
78
+ const fallback = this.fallback(forceRefresh, options, held);
79
+ if (fallback)
80
+ return fallback;
73
81
  throw held;
74
82
  }
75
83
  // If token fetch is already in progress, wait for it
76
84
  if (this.tokenPromise) {
77
85
  log('Token fetch in progress, waiting for existing request...');
78
- return this.tokenPromise;
86
+ return this.tokenPromise.catch((error) => {
87
+ const fallback = this.fallback(forceRefresh, options, error);
88
+ if (fallback)
89
+ return fallback;
90
+ throw error;
91
+ });
79
92
  }
80
93
  // Start new token fetch
81
94
  const reason = forceRefresh
@@ -89,6 +102,12 @@ class TokenProvider {
89
102
  const result = await this.tokenPromise;
90
103
  return result;
91
104
  }
105
+ catch (error) {
106
+ const fallback = this.fallback(forceRefresh, options, error);
107
+ if (fallback)
108
+ return fallback;
109
+ throw error;
110
+ }
92
111
  finally {
93
112
  // Clear promise after completion (success or failure)
94
113
  this.tokenPromise = undefined;
@@ -160,6 +179,27 @@ class TokenProvider {
160
179
  expiresAt: this.cachedExpiresAt,
161
180
  };
162
181
  }
182
+ /**
183
+ * #63: the cached token, when the caller asked for it and the failure is one
184
+ * that waiting fixes. A refusal has already cleared the cache in fetchToken,
185
+ * so it can never be the cached token handed back here.
186
+ */
187
+ fallback(forceRefresh, options, error) {
188
+ if (forceRefresh || !options.cachedUntilExpiry)
189
+ return undefined;
190
+ if ((0, tokenHold_js_1.isTokenRefusal)(error))
191
+ return undefined;
192
+ if (!this.cachedToken || !this.cachedExpiresAt)
193
+ return undefined;
194
+ if (Date.now() >= this.cachedExpiresAt - EXPIRY_SKEW_MS)
195
+ return undefined;
196
+ log('Refresh failed (%s); the cached token is valid for %ds more, sending it', error instanceof Error ? error.message : String(error), Math.floor((this.cachedExpiresAt - Date.now()) / 1000));
197
+ return {
198
+ success: true,
199
+ token: this.cachedToken,
200
+ expiresAt: this.cachedExpiresAt,
201
+ };
202
+ }
163
203
  isExpired(bufferSeconds = tokenRefresh_js_1.TOKEN_REFRESH_BUFFER_SECONDS) {
164
204
  if (!this.cachedExpiresAt)
165
205
  return true;
@@ -9,11 +9,11 @@ import { LocationServiceException } from '../errors/LocationServiceException.js'
9
9
  * served paid for a doomed data request and a doomed token request, all
10
10
  * against the application's own token-route throttle.
11
11
  *
12
- * Thirty seconds bounds how long an application that has just been made
13
- * active again waits for this side to notice: long enough to turn a request
14
- * rate into a trickle, short enough to be a pause rather than an outage. It is
15
- * also about how long a newly created application is refused while it goes
16
- * live, which is the one refusal that clears itself.
12
+ * Thirty seconds is short beside the API's own waits: it accepts a
13
+ * reactivated application again within five minutes, and refuses a newly
14
+ * created or reactivated one for up to about thirty seconds while its key goes
15
+ * live. So this side adds at most thirty seconds to either, and turns a
16
+ * request rate into a trickle meanwhile.
17
17
  */
18
18
  export declare const TOKEN_REFUSAL_HOLD_MS = 30000;
19
19
  /**
@@ -70,3 +70,12 @@ export declare class TokenHold {
70
70
  } | undefined;
71
71
  forget(): void;
72
72
  }
73
+ /**
74
+ * Send with `token`, and after a 401 once more with `refresh()`'s token when it
75
+ * is a DIFFERENT one, remembering on `hold` what the API and the source said,
76
+ * against the token it concerns (#38).
77
+ *
78
+ * The one copy of the 401 retry: both send paths and the two map fetches (#72)
79
+ * call it, so when to ask again is decided here and nowhere else.
80
+ */
81
+ export declare function sendRetryingOnce<T>(hold: TokenHold, token: string, send: (token: string) => Promise<T>, refresh: () => Promise<string | undefined>, onRetry?: () => void): Promise<T>;
@@ -3,7 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.TokenHold = exports.TOKEN_REFUSAL_HOLD_MS = void 0;
4
4
  exports.isTokenRefusal = isTokenRefusal;
5
5
  exports.holdFor = holdFor;
6
+ exports.sendRetryingOnce = sendRetryingOnce;
6
7
  const LocationServiceException_js_1 = require("../errors/LocationServiceException.js");
8
+ const errors_js_1 = require("../transport/errors.js");
7
9
  /**
8
10
  * How long a refusal is remembered: a token the API refused, or a token
9
11
  * request `/auth/token` refused (#38).
@@ -14,11 +16,11 @@ const LocationServiceException_js_1 = require("../errors/LocationServiceExceptio
14
16
  * served paid for a doomed data request and a doomed token request, all
15
17
  * against the application's own token-route throttle.
16
18
  *
17
- * Thirty seconds bounds how long an application that has just been made
18
- * active again waits for this side to notice: long enough to turn a request
19
- * rate into a trickle, short enough to be a pause rather than an outage. It is
20
- * also about how long a newly created application is refused while it goes
21
- * live, which is the one refusal that clears itself.
19
+ * Thirty seconds is short beside the API's own waits: it accepts a
20
+ * reactivated application again within five minutes, and refuses a newly
21
+ * created or reactivated one for up to about thirty seconds while its key goes
22
+ * live. So this side adds at most thirty seconds to either, and turns a
23
+ * request rate into a trickle meanwhile.
22
24
  */
23
25
  exports.TOKEN_REFUSAL_HOLD_MS = 30000;
24
26
  /**
@@ -113,3 +115,67 @@ class TokenHold {
113
115
  }
114
116
  }
115
117
  exports.TokenHold = TokenHold;
118
+ /**
119
+ * Send with `token`, and after a 401 once more with `refresh()`'s token when it
120
+ * is a DIFFERENT one, remembering on `hold` what the API and the source said,
121
+ * against the token it concerns (#38).
122
+ *
123
+ * The one copy of the 401 retry: both send paths and the two map fetches (#72)
124
+ * call it, so when to ask again is decided here and nowhere else.
125
+ */
126
+ async function sendRetryingOnce(hold, token, send, refresh, onRetry) {
127
+ // This token was refused a moment ago and nothing has replaced it: answer
128
+ // with that refusal rather than send it, and ask the source again. A
129
+ // different token ends the hold. When the refresh that followed said nothing
130
+ // about when to ask again, it is asked now — but the refused token is still
131
+ // not sent.
132
+ const held = hold.check(token);
133
+ if (held && !held.askAgain)
134
+ throw held.error;
135
+ let rejected = held?.error;
136
+ if (!held) {
137
+ try {
138
+ return await send(token);
139
+ }
140
+ catch (err) {
141
+ if (!(0, errors_js_1.isTokenRejected)(err))
142
+ throw err;
143
+ rejected = err;
144
+ }
145
+ }
146
+ // One retry, and only when the replacement is genuinely a different token.
147
+ // That single comparison covers every source: a fixed `token` string, a
148
+ // `getToken` that ignores `forceRefresh`, a `refreshToken` that hands back
149
+ // what it had, and a cached token the API has revoked before its `exp` —
150
+ // re-sending any of them is a second doomed request for the same answer.
151
+ let fresh;
152
+ try {
153
+ fresh = await refresh();
154
+ }
155
+ catch (refusal) {
156
+ // A rotated secret's token route refuses the refresh as the data route
157
+ // refused its token. Without this, every send asked again. A refusal that
158
+ // says nothing — a network fault, or a Server Action's error without its
159
+ // fields — leaves the source to be asked again, but not the token sent.
160
+ if (holdFor(refusal) > 0)
161
+ hold.remember(refusal, token);
162
+ // Only when no hold stands: one already standing keeps its own end, so
163
+ // the refused token is tried again once per hold rather than never.
164
+ else if (!held)
165
+ hold.remember(rejected, token, { askAgain: true });
166
+ throw refusal;
167
+ }
168
+ if (!fresh || fresh === token) {
169
+ hold.remember(rejected, token);
170
+ throw rejected;
171
+ }
172
+ onRetry?.();
173
+ try {
174
+ return await send(fresh);
175
+ }
176
+ catch (again) {
177
+ if ((0, errors_js_1.isTokenRejected)(again))
178
+ hold.remember(again, fresh);
179
+ throw again;
180
+ }
181
+ }
@@ -0,0 +1,4 @@
1
+ export type * from '@aws-sdk/client-geo-places';
2
+ export { $Command, AccessDeniedException, AccessDeniedException$, AccessPoint$, AccessPointType, AccessRestriction$, Address$, AddressComponentMatchScores$, AddressComponentPhonemes$, AddressTranslationComponent, AdminNames$, AdminNamesPreference, Autocomplete$, AutocompleteAdditionalFeature, AutocompleteAddressHighlights$, AutocompleteFilter$, AutocompleteFilterPlaceType, AutocompleteHighlights$, AutocompleteIntendedUse, AutocompleteRequest$, AutocompleteResponse$, AutocompleteResultItem$, BusinessChain$, Category$, ComponentMatchScores$, ContactDetails$, Contacts$, Country$, CountryHighlights$, CrossReference$, FilterCircle$, FoodType$, GeoPlacesServiceException, GeoPlacesServiceException$, Geocode$, GeocodeAdditionalFeature, GeocodeAddressNamesMode, GeocodeFilter$, GeocodeFilterPlaceType, GeocodeIntendedUse, GeocodeParsedQuery$, GeocodeParsedQueryAddressComponents$, GeocodeQueryComponents$, GeocodeRequest$, GeocodeResponse$, GeocodeResultItem$, GetPlace$, GetPlaceAdditionalFeature, GetPlaceAddressNamesMode, GetPlaceIntendedUse, GetPlaceRequest$, GetPlaceResponse$, Highlight$, InternalServerException, InternalServerException$, Intersection$, MatchScoreDetails$, OpeningHours$, OpeningHoursComponents$, ParsedQueryComponent$, ParsedQuerySecondaryAddressComponent$, PhonemeDetails$, PhonemeTranscription$, PlaceAttribute, PlaceType, PostalAuthority, PostalCodeDetails$, PostalCodeMode, PostalCodeType, QueryRefinement$, QueryType, RecordTypeCode, Region$, RegionHighlights$, RelatedPlace$, ReverseGeocode$, ReverseGeocodeAdditionalFeature, ReverseGeocodeAddressNamesMode, ReverseGeocodeFilter$, ReverseGeocodeFilterPlaceType, ReverseGeocodeIntendedUse, ReverseGeocodeRequest$, ReverseGeocodeResponse$, ReverseGeocodeResultItem$, SearchNearby$, SearchNearbyAdditionalFeature, SearchNearbyFilter$, SearchNearbyIntendedUse, SearchNearbyRequest$, SearchNearbyResponse$, SearchNearbyResultItem$, SearchText$, SearchTextAdditionalFeature, SearchTextFilter$, SearchTextIntendedUse, SearchTextRequest$, SearchTextResponse$, SearchTextResultItem$, SearchTextTravelMode, SecondaryAddressComponent$, SecondaryAddressComponentMatchScore$, StreetComponents$, SubRegion$, SubRegionHighlights$, Suggest$, SuggestAdditionalFeature, SuggestAddressHighlights$, SuggestFilter$, SuggestHighlights$, SuggestIntendedUse, SuggestPlaceResult$, SuggestQueryResult$, SuggestRequest$, SuggestResponse$, SuggestResultItem$, SuggestResultItemType, SuggestTravelMode, ThrottlingException, ThrottlingException$, TimeZone$, TranslationDetails$, TranslationName$, TranslationNameType, TypePlacement, UspsZip$, UspsZipPlus4$, ValidationException, ValidationException$, ValidationExceptionField$, ValidationExceptionReason, ZipClassificationCode, __Client, errorTypeRegistries, } from '@aws-sdk/client-geo-places';
3
+ export type * from '@aws/amazon-location-utilities-datatypes';
4
+ export { calculateIsolinesResponseToFeatureCollection, calculateRoutesResponseToFeatureCollections, devicePositionsToFeatureCollection, featureCollectionToGeofence, geocodeResponseToFeatureCollection, geofencesToFeatureCollection, getPlaceResponseToFeatureCollection, optimizeWaypointsResponseToFeatureCollection, placeToFeatureCollection, reverseGeocodeResponseToFeatureCollection, routeToFeatureCollection, searchNearbyResponseToFeatureCollection, searchTextResponseToFeatureCollection, snapToRoadsResponseToFeatureCollection, suggestResponseToFeatureCollection, } from '@aws/amazon-location-utilities-datatypes';
@@ -0,0 +1,155 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetPlaceIntendedUse = exports.GetPlaceAddressNamesMode = exports.GetPlaceAdditionalFeature = exports.GetPlace$ = exports.GeocodeResultItem$ = exports.GeocodeResponse$ = exports.GeocodeRequest$ = exports.GeocodeQueryComponents$ = exports.GeocodeParsedQueryAddressComponents$ = exports.GeocodeParsedQuery$ = exports.GeocodeIntendedUse = exports.GeocodeFilterPlaceType = exports.GeocodeFilter$ = exports.GeocodeAddressNamesMode = exports.GeocodeAdditionalFeature = exports.Geocode$ = exports.GeoPlacesServiceException$ = exports.GeoPlacesServiceException = exports.FoodType$ = exports.FilterCircle$ = exports.CrossReference$ = exports.CountryHighlights$ = exports.Country$ = exports.Contacts$ = exports.ContactDetails$ = exports.ComponentMatchScores$ = exports.Category$ = exports.BusinessChain$ = exports.AutocompleteResultItem$ = exports.AutocompleteResponse$ = exports.AutocompleteRequest$ = exports.AutocompleteIntendedUse = exports.AutocompleteHighlights$ = exports.AutocompleteFilterPlaceType = exports.AutocompleteFilter$ = exports.AutocompleteAddressHighlights$ = exports.AutocompleteAdditionalFeature = exports.Autocomplete$ = exports.AdminNamesPreference = exports.AdminNames$ = exports.AddressTranslationComponent = exports.AddressComponentPhonemes$ = exports.AddressComponentMatchScores$ = exports.Address$ = exports.AccessRestriction$ = exports.AccessPointType = exports.AccessPoint$ = exports.AccessDeniedException$ = exports.AccessDeniedException = exports.$Command = void 0;
4
+ exports.SecondaryAddressComponent$ = exports.SearchTextTravelMode = exports.SearchTextResultItem$ = exports.SearchTextResponse$ = exports.SearchTextRequest$ = exports.SearchTextIntendedUse = exports.SearchTextFilter$ = exports.SearchTextAdditionalFeature = exports.SearchText$ = exports.SearchNearbyResultItem$ = exports.SearchNearbyResponse$ = exports.SearchNearbyRequest$ = exports.SearchNearbyIntendedUse = exports.SearchNearbyFilter$ = exports.SearchNearbyAdditionalFeature = exports.SearchNearby$ = exports.ReverseGeocodeResultItem$ = exports.ReverseGeocodeResponse$ = exports.ReverseGeocodeRequest$ = exports.ReverseGeocodeIntendedUse = exports.ReverseGeocodeFilterPlaceType = exports.ReverseGeocodeFilter$ = exports.ReverseGeocodeAddressNamesMode = exports.ReverseGeocodeAdditionalFeature = exports.ReverseGeocode$ = exports.RelatedPlace$ = exports.RegionHighlights$ = exports.Region$ = exports.RecordTypeCode = exports.QueryType = exports.QueryRefinement$ = exports.PostalCodeType = exports.PostalCodeMode = exports.PostalCodeDetails$ = exports.PostalAuthority = exports.PlaceType = exports.PlaceAttribute = exports.PhonemeTranscription$ = exports.PhonemeDetails$ = exports.ParsedQuerySecondaryAddressComponent$ = exports.ParsedQueryComponent$ = exports.OpeningHoursComponents$ = exports.OpeningHours$ = exports.MatchScoreDetails$ = exports.Intersection$ = exports.InternalServerException$ = exports.InternalServerException = exports.Highlight$ = exports.GetPlaceResponse$ = exports.GetPlaceRequest$ = void 0;
5
+ exports.suggestResponseToFeatureCollection = exports.snapToRoadsResponseToFeatureCollection = exports.searchTextResponseToFeatureCollection = exports.searchNearbyResponseToFeatureCollection = exports.routeToFeatureCollection = exports.reverseGeocodeResponseToFeatureCollection = exports.placeToFeatureCollection = exports.optimizeWaypointsResponseToFeatureCollection = exports.getPlaceResponseToFeatureCollection = exports.geofencesToFeatureCollection = exports.geocodeResponseToFeatureCollection = exports.featureCollectionToGeofence = exports.devicePositionsToFeatureCollection = exports.calculateRoutesResponseToFeatureCollections = exports.calculateIsolinesResponseToFeatureCollection = exports.errorTypeRegistries = exports.__Client = exports.ZipClassificationCode = exports.ValidationExceptionReason = exports.ValidationExceptionField$ = exports.ValidationException$ = exports.ValidationException = exports.UspsZipPlus4$ = exports.UspsZip$ = exports.TypePlacement = exports.TranslationNameType = exports.TranslationName$ = exports.TranslationDetails$ = exports.TimeZone$ = exports.ThrottlingException$ = exports.ThrottlingException = exports.SuggestTravelMode = exports.SuggestResultItemType = exports.SuggestResultItem$ = exports.SuggestResponse$ = exports.SuggestRequest$ = exports.SuggestQueryResult$ = exports.SuggestPlaceResult$ = exports.SuggestIntendedUse = exports.SuggestHighlights$ = exports.SuggestFilter$ = exports.SuggestAddressHighlights$ = exports.SuggestAdditionalFeature = exports.Suggest$ = exports.SubRegionHighlights$ = exports.SubRegion$ = exports.StreetComponents$ = exports.SecondaryAddressComponentMatchScore$ = void 0;
6
+ var client_geo_places_1 = require("@aws-sdk/client-geo-places");
7
+ Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_geo_places_1.$Command; } });
8
+ Object.defineProperty(exports, "AccessDeniedException", { enumerable: true, get: function () { return client_geo_places_1.AccessDeniedException; } });
9
+ Object.defineProperty(exports, "AccessDeniedException$", { enumerable: true, get: function () { return client_geo_places_1.AccessDeniedException$; } });
10
+ Object.defineProperty(exports, "AccessPoint$", { enumerable: true, get: function () { return client_geo_places_1.AccessPoint$; } });
11
+ Object.defineProperty(exports, "AccessPointType", { enumerable: true, get: function () { return client_geo_places_1.AccessPointType; } });
12
+ Object.defineProperty(exports, "AccessRestriction$", { enumerable: true, get: function () { return client_geo_places_1.AccessRestriction$; } });
13
+ Object.defineProperty(exports, "Address$", { enumerable: true, get: function () { return client_geo_places_1.Address$; } });
14
+ Object.defineProperty(exports, "AddressComponentMatchScores$", { enumerable: true, get: function () { return client_geo_places_1.AddressComponentMatchScores$; } });
15
+ Object.defineProperty(exports, "AddressComponentPhonemes$", { enumerable: true, get: function () { return client_geo_places_1.AddressComponentPhonemes$; } });
16
+ Object.defineProperty(exports, "AddressTranslationComponent", { enumerable: true, get: function () { return client_geo_places_1.AddressTranslationComponent; } });
17
+ Object.defineProperty(exports, "AdminNames$", { enumerable: true, get: function () { return client_geo_places_1.AdminNames$; } });
18
+ Object.defineProperty(exports, "AdminNamesPreference", { enumerable: true, get: function () { return client_geo_places_1.AdminNamesPreference; } });
19
+ Object.defineProperty(exports, "Autocomplete$", { enumerable: true, get: function () { return client_geo_places_1.Autocomplete$; } });
20
+ Object.defineProperty(exports, "AutocompleteAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteAdditionalFeature; } });
21
+ Object.defineProperty(exports, "AutocompleteAddressHighlights$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteAddressHighlights$; } });
22
+ Object.defineProperty(exports, "AutocompleteFilter$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteFilter$; } });
23
+ Object.defineProperty(exports, "AutocompleteFilterPlaceType", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteFilterPlaceType; } });
24
+ Object.defineProperty(exports, "AutocompleteHighlights$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteHighlights$; } });
25
+ Object.defineProperty(exports, "AutocompleteIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteIntendedUse; } });
26
+ Object.defineProperty(exports, "AutocompleteRequest$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteRequest$; } });
27
+ Object.defineProperty(exports, "AutocompleteResponse$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteResponse$; } });
28
+ Object.defineProperty(exports, "AutocompleteResultItem$", { enumerable: true, get: function () { return client_geo_places_1.AutocompleteResultItem$; } });
29
+ Object.defineProperty(exports, "BusinessChain$", { enumerable: true, get: function () { return client_geo_places_1.BusinessChain$; } });
30
+ Object.defineProperty(exports, "Category$", { enumerable: true, get: function () { return client_geo_places_1.Category$; } });
31
+ Object.defineProperty(exports, "ComponentMatchScores$", { enumerable: true, get: function () { return client_geo_places_1.ComponentMatchScores$; } });
32
+ Object.defineProperty(exports, "ContactDetails$", { enumerable: true, get: function () { return client_geo_places_1.ContactDetails$; } });
33
+ Object.defineProperty(exports, "Contacts$", { enumerable: true, get: function () { return client_geo_places_1.Contacts$; } });
34
+ Object.defineProperty(exports, "Country$", { enumerable: true, get: function () { return client_geo_places_1.Country$; } });
35
+ Object.defineProperty(exports, "CountryHighlights$", { enumerable: true, get: function () { return client_geo_places_1.CountryHighlights$; } });
36
+ Object.defineProperty(exports, "CrossReference$", { enumerable: true, get: function () { return client_geo_places_1.CrossReference$; } });
37
+ Object.defineProperty(exports, "FilterCircle$", { enumerable: true, get: function () { return client_geo_places_1.FilterCircle$; } });
38
+ Object.defineProperty(exports, "FoodType$", { enumerable: true, get: function () { return client_geo_places_1.FoodType$; } });
39
+ Object.defineProperty(exports, "GeoPlacesServiceException", { enumerable: true, get: function () { return client_geo_places_1.GeoPlacesServiceException; } });
40
+ Object.defineProperty(exports, "GeoPlacesServiceException$", { enumerable: true, get: function () { return client_geo_places_1.GeoPlacesServiceException$; } });
41
+ Object.defineProperty(exports, "Geocode$", { enumerable: true, get: function () { return client_geo_places_1.Geocode$; } });
42
+ Object.defineProperty(exports, "GeocodeAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.GeocodeAdditionalFeature; } });
43
+ Object.defineProperty(exports, "GeocodeAddressNamesMode", { enumerable: true, get: function () { return client_geo_places_1.GeocodeAddressNamesMode; } });
44
+ Object.defineProperty(exports, "GeocodeFilter$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeFilter$; } });
45
+ Object.defineProperty(exports, "GeocodeFilterPlaceType", { enumerable: true, get: function () { return client_geo_places_1.GeocodeFilterPlaceType; } });
46
+ Object.defineProperty(exports, "GeocodeIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.GeocodeIntendedUse; } });
47
+ Object.defineProperty(exports, "GeocodeParsedQuery$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeParsedQuery$; } });
48
+ Object.defineProperty(exports, "GeocodeParsedQueryAddressComponents$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeParsedQueryAddressComponents$; } });
49
+ Object.defineProperty(exports, "GeocodeQueryComponents$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeQueryComponents$; } });
50
+ Object.defineProperty(exports, "GeocodeRequest$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeRequest$; } });
51
+ Object.defineProperty(exports, "GeocodeResponse$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeResponse$; } });
52
+ Object.defineProperty(exports, "GeocodeResultItem$", { enumerable: true, get: function () { return client_geo_places_1.GeocodeResultItem$; } });
53
+ Object.defineProperty(exports, "GetPlace$", { enumerable: true, get: function () { return client_geo_places_1.GetPlace$; } });
54
+ Object.defineProperty(exports, "GetPlaceAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.GetPlaceAdditionalFeature; } });
55
+ Object.defineProperty(exports, "GetPlaceAddressNamesMode", { enumerable: true, get: function () { return client_geo_places_1.GetPlaceAddressNamesMode; } });
56
+ Object.defineProperty(exports, "GetPlaceIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.GetPlaceIntendedUse; } });
57
+ Object.defineProperty(exports, "GetPlaceRequest$", { enumerable: true, get: function () { return client_geo_places_1.GetPlaceRequest$; } });
58
+ Object.defineProperty(exports, "GetPlaceResponse$", { enumerable: true, get: function () { return client_geo_places_1.GetPlaceResponse$; } });
59
+ Object.defineProperty(exports, "Highlight$", { enumerable: true, get: function () { return client_geo_places_1.Highlight$; } });
60
+ Object.defineProperty(exports, "InternalServerException", { enumerable: true, get: function () { return client_geo_places_1.InternalServerException; } });
61
+ Object.defineProperty(exports, "InternalServerException$", { enumerable: true, get: function () { return client_geo_places_1.InternalServerException$; } });
62
+ Object.defineProperty(exports, "Intersection$", { enumerable: true, get: function () { return client_geo_places_1.Intersection$; } });
63
+ Object.defineProperty(exports, "MatchScoreDetails$", { enumerable: true, get: function () { return client_geo_places_1.MatchScoreDetails$; } });
64
+ Object.defineProperty(exports, "OpeningHours$", { enumerable: true, get: function () { return client_geo_places_1.OpeningHours$; } });
65
+ Object.defineProperty(exports, "OpeningHoursComponents$", { enumerable: true, get: function () { return client_geo_places_1.OpeningHoursComponents$; } });
66
+ Object.defineProperty(exports, "ParsedQueryComponent$", { enumerable: true, get: function () { return client_geo_places_1.ParsedQueryComponent$; } });
67
+ Object.defineProperty(exports, "ParsedQuerySecondaryAddressComponent$", { enumerable: true, get: function () { return client_geo_places_1.ParsedQuerySecondaryAddressComponent$; } });
68
+ Object.defineProperty(exports, "PhonemeDetails$", { enumerable: true, get: function () { return client_geo_places_1.PhonemeDetails$; } });
69
+ Object.defineProperty(exports, "PhonemeTranscription$", { enumerable: true, get: function () { return client_geo_places_1.PhonemeTranscription$; } });
70
+ Object.defineProperty(exports, "PlaceAttribute", { enumerable: true, get: function () { return client_geo_places_1.PlaceAttribute; } });
71
+ Object.defineProperty(exports, "PlaceType", { enumerable: true, get: function () { return client_geo_places_1.PlaceType; } });
72
+ Object.defineProperty(exports, "PostalAuthority", { enumerable: true, get: function () { return client_geo_places_1.PostalAuthority; } });
73
+ Object.defineProperty(exports, "PostalCodeDetails$", { enumerable: true, get: function () { return client_geo_places_1.PostalCodeDetails$; } });
74
+ Object.defineProperty(exports, "PostalCodeMode", { enumerable: true, get: function () { return client_geo_places_1.PostalCodeMode; } });
75
+ Object.defineProperty(exports, "PostalCodeType", { enumerable: true, get: function () { return client_geo_places_1.PostalCodeType; } });
76
+ Object.defineProperty(exports, "QueryRefinement$", { enumerable: true, get: function () { return client_geo_places_1.QueryRefinement$; } });
77
+ Object.defineProperty(exports, "QueryType", { enumerable: true, get: function () { return client_geo_places_1.QueryType; } });
78
+ Object.defineProperty(exports, "RecordTypeCode", { enumerable: true, get: function () { return client_geo_places_1.RecordTypeCode; } });
79
+ Object.defineProperty(exports, "Region$", { enumerable: true, get: function () { return client_geo_places_1.Region$; } });
80
+ Object.defineProperty(exports, "RegionHighlights$", { enumerable: true, get: function () { return client_geo_places_1.RegionHighlights$; } });
81
+ Object.defineProperty(exports, "RelatedPlace$", { enumerable: true, get: function () { return client_geo_places_1.RelatedPlace$; } });
82
+ Object.defineProperty(exports, "ReverseGeocode$", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocode$; } });
83
+ Object.defineProperty(exports, "ReverseGeocodeAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeAdditionalFeature; } });
84
+ Object.defineProperty(exports, "ReverseGeocodeAddressNamesMode", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeAddressNamesMode; } });
85
+ Object.defineProperty(exports, "ReverseGeocodeFilter$", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeFilter$; } });
86
+ Object.defineProperty(exports, "ReverseGeocodeFilterPlaceType", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeFilterPlaceType; } });
87
+ Object.defineProperty(exports, "ReverseGeocodeIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeIntendedUse; } });
88
+ Object.defineProperty(exports, "ReverseGeocodeRequest$", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeRequest$; } });
89
+ Object.defineProperty(exports, "ReverseGeocodeResponse$", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeResponse$; } });
90
+ Object.defineProperty(exports, "ReverseGeocodeResultItem$", { enumerable: true, get: function () { return client_geo_places_1.ReverseGeocodeResultItem$; } });
91
+ Object.defineProperty(exports, "SearchNearby$", { enumerable: true, get: function () { return client_geo_places_1.SearchNearby$; } });
92
+ Object.defineProperty(exports, "SearchNearbyAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyAdditionalFeature; } });
93
+ Object.defineProperty(exports, "SearchNearbyFilter$", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyFilter$; } });
94
+ Object.defineProperty(exports, "SearchNearbyIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyIntendedUse; } });
95
+ Object.defineProperty(exports, "SearchNearbyRequest$", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyRequest$; } });
96
+ Object.defineProperty(exports, "SearchNearbyResponse$", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyResponse$; } });
97
+ Object.defineProperty(exports, "SearchNearbyResultItem$", { enumerable: true, get: function () { return client_geo_places_1.SearchNearbyResultItem$; } });
98
+ Object.defineProperty(exports, "SearchText$", { enumerable: true, get: function () { return client_geo_places_1.SearchText$; } });
99
+ Object.defineProperty(exports, "SearchTextAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.SearchTextAdditionalFeature; } });
100
+ Object.defineProperty(exports, "SearchTextFilter$", { enumerable: true, get: function () { return client_geo_places_1.SearchTextFilter$; } });
101
+ Object.defineProperty(exports, "SearchTextIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.SearchTextIntendedUse; } });
102
+ Object.defineProperty(exports, "SearchTextRequest$", { enumerable: true, get: function () { return client_geo_places_1.SearchTextRequest$; } });
103
+ Object.defineProperty(exports, "SearchTextResponse$", { enumerable: true, get: function () { return client_geo_places_1.SearchTextResponse$; } });
104
+ Object.defineProperty(exports, "SearchTextResultItem$", { enumerable: true, get: function () { return client_geo_places_1.SearchTextResultItem$; } });
105
+ Object.defineProperty(exports, "SearchTextTravelMode", { enumerable: true, get: function () { return client_geo_places_1.SearchTextTravelMode; } });
106
+ Object.defineProperty(exports, "SecondaryAddressComponent$", { enumerable: true, get: function () { return client_geo_places_1.SecondaryAddressComponent$; } });
107
+ Object.defineProperty(exports, "SecondaryAddressComponentMatchScore$", { enumerable: true, get: function () { return client_geo_places_1.SecondaryAddressComponentMatchScore$; } });
108
+ Object.defineProperty(exports, "StreetComponents$", { enumerable: true, get: function () { return client_geo_places_1.StreetComponents$; } });
109
+ Object.defineProperty(exports, "SubRegion$", { enumerable: true, get: function () { return client_geo_places_1.SubRegion$; } });
110
+ Object.defineProperty(exports, "SubRegionHighlights$", { enumerable: true, get: function () { return client_geo_places_1.SubRegionHighlights$; } });
111
+ Object.defineProperty(exports, "Suggest$", { enumerable: true, get: function () { return client_geo_places_1.Suggest$; } });
112
+ Object.defineProperty(exports, "SuggestAdditionalFeature", { enumerable: true, get: function () { return client_geo_places_1.SuggestAdditionalFeature; } });
113
+ Object.defineProperty(exports, "SuggestAddressHighlights$", { enumerable: true, get: function () { return client_geo_places_1.SuggestAddressHighlights$; } });
114
+ Object.defineProperty(exports, "SuggestFilter$", { enumerable: true, get: function () { return client_geo_places_1.SuggestFilter$; } });
115
+ Object.defineProperty(exports, "SuggestHighlights$", { enumerable: true, get: function () { return client_geo_places_1.SuggestHighlights$; } });
116
+ Object.defineProperty(exports, "SuggestIntendedUse", { enumerable: true, get: function () { return client_geo_places_1.SuggestIntendedUse; } });
117
+ Object.defineProperty(exports, "SuggestPlaceResult$", { enumerable: true, get: function () { return client_geo_places_1.SuggestPlaceResult$; } });
118
+ Object.defineProperty(exports, "SuggestQueryResult$", { enumerable: true, get: function () { return client_geo_places_1.SuggestQueryResult$; } });
119
+ Object.defineProperty(exports, "SuggestRequest$", { enumerable: true, get: function () { return client_geo_places_1.SuggestRequest$; } });
120
+ Object.defineProperty(exports, "SuggestResponse$", { enumerable: true, get: function () { return client_geo_places_1.SuggestResponse$; } });
121
+ Object.defineProperty(exports, "SuggestResultItem$", { enumerable: true, get: function () { return client_geo_places_1.SuggestResultItem$; } });
122
+ Object.defineProperty(exports, "SuggestResultItemType", { enumerable: true, get: function () { return client_geo_places_1.SuggestResultItemType; } });
123
+ Object.defineProperty(exports, "SuggestTravelMode", { enumerable: true, get: function () { return client_geo_places_1.SuggestTravelMode; } });
124
+ Object.defineProperty(exports, "ThrottlingException", { enumerable: true, get: function () { return client_geo_places_1.ThrottlingException; } });
125
+ Object.defineProperty(exports, "ThrottlingException$", { enumerable: true, get: function () { return client_geo_places_1.ThrottlingException$; } });
126
+ Object.defineProperty(exports, "TimeZone$", { enumerable: true, get: function () { return client_geo_places_1.TimeZone$; } });
127
+ Object.defineProperty(exports, "TranslationDetails$", { enumerable: true, get: function () { return client_geo_places_1.TranslationDetails$; } });
128
+ Object.defineProperty(exports, "TranslationName$", { enumerable: true, get: function () { return client_geo_places_1.TranslationName$; } });
129
+ Object.defineProperty(exports, "TranslationNameType", { enumerable: true, get: function () { return client_geo_places_1.TranslationNameType; } });
130
+ Object.defineProperty(exports, "TypePlacement", { enumerable: true, get: function () { return client_geo_places_1.TypePlacement; } });
131
+ Object.defineProperty(exports, "UspsZip$", { enumerable: true, get: function () { return client_geo_places_1.UspsZip$; } });
132
+ Object.defineProperty(exports, "UspsZipPlus4$", { enumerable: true, get: function () { return client_geo_places_1.UspsZipPlus4$; } });
133
+ Object.defineProperty(exports, "ValidationException", { enumerable: true, get: function () { return client_geo_places_1.ValidationException; } });
134
+ Object.defineProperty(exports, "ValidationException$", { enumerable: true, get: function () { return client_geo_places_1.ValidationException$; } });
135
+ Object.defineProperty(exports, "ValidationExceptionField$", { enumerable: true, get: function () { return client_geo_places_1.ValidationExceptionField$; } });
136
+ Object.defineProperty(exports, "ValidationExceptionReason", { enumerable: true, get: function () { return client_geo_places_1.ValidationExceptionReason; } });
137
+ Object.defineProperty(exports, "ZipClassificationCode", { enumerable: true, get: function () { return client_geo_places_1.ZipClassificationCode; } });
138
+ Object.defineProperty(exports, "__Client", { enumerable: true, get: function () { return client_geo_places_1.__Client; } });
139
+ Object.defineProperty(exports, "errorTypeRegistries", { enumerable: true, get: function () { return client_geo_places_1.errorTypeRegistries; } });
140
+ var amazon_location_utilities_datatypes_1 = require("@aws/amazon-location-utilities-datatypes");
141
+ Object.defineProperty(exports, "calculateIsolinesResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.calculateIsolinesResponseToFeatureCollection; } });
142
+ Object.defineProperty(exports, "calculateRoutesResponseToFeatureCollections", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.calculateRoutesResponseToFeatureCollections; } });
143
+ Object.defineProperty(exports, "devicePositionsToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.devicePositionsToFeatureCollection; } });
144
+ Object.defineProperty(exports, "featureCollectionToGeofence", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.featureCollectionToGeofence; } });
145
+ Object.defineProperty(exports, "geocodeResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.geocodeResponseToFeatureCollection; } });
146
+ Object.defineProperty(exports, "geofencesToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.geofencesToFeatureCollection; } });
147
+ Object.defineProperty(exports, "getPlaceResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.getPlaceResponseToFeatureCollection; } });
148
+ Object.defineProperty(exports, "optimizeWaypointsResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.optimizeWaypointsResponseToFeatureCollection; } });
149
+ Object.defineProperty(exports, "placeToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.placeToFeatureCollection; } });
150
+ Object.defineProperty(exports, "reverseGeocodeResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.reverseGeocodeResponseToFeatureCollection; } });
151
+ Object.defineProperty(exports, "routeToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.routeToFeatureCollection; } });
152
+ Object.defineProperty(exports, "searchNearbyResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.searchNearbyResponseToFeatureCollection; } });
153
+ Object.defineProperty(exports, "searchTextResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.searchTextResponseToFeatureCollection; } });
154
+ Object.defineProperty(exports, "snapToRoadsResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.snapToRoadsResponseToFeatureCollection; } });
155
+ Object.defineProperty(exports, "suggestResponseToFeatureCollection", { enumerable: true, get: function () { return amazon_location_utilities_datatypes_1.suggestResponseToFeatureCollection; } });
@@ -1,5 +1,5 @@
1
1
  import type { RequestOptions } from '../transport/http.js';
2
- import type { ClientConfig } from '../types/index.js';
2
+ import type { ClientConfig, CommandOutput, CommandWithOutput } from '../types/index.js';
3
3
  import type { AppConfigClaims } from '../utils/tokenClaims.js';
4
4
  import type { VerifyAddressResponse } from './commands.js';
5
5
  export type SendOptions = RequestOptions;
@@ -40,6 +40,11 @@ export declare class GeoPlacesClient {
40
40
  getAppConfig(): AppConfigClaims;
41
41
  /** Prefer the getToken callback (live ref) over a static token string. */
42
42
  private currentToken;
43
+ /**
44
+ * `refreshToken`, held to the caller's signal and deadline (#62). A slow or
45
+ * stuck callback used to hold `send` past both.
46
+ */
47
+ private askRefreshToken;
43
48
  /**
44
49
  * A token to send, or a refusal — never `undefined`.
45
50
  *
@@ -48,10 +53,21 @@ export declare class GeoPlacesClient {
48
53
  */
49
54
  private ensureToken;
50
55
  /**
56
+ * Send a command, and resolve with its output:
57
+ * `await client.send(new AutocompleteCommand(…))` is an
58
+ * `AutocompleteCommandOutput`, with nothing to annotate (#68).
59
+ *
51
60
  * @param options `signal` to cancel, `timeoutMs` per attempt,
52
61
  * `overallTimeoutMs` for the whole call, `retry: false` to disable the
53
62
  * retry loop. Every failure throws LocationServiceException.
54
63
  */
64
+ send<C extends CommandWithOutput>(command: C, options?: SendOptions): Promise<CommandOutput<C>>;
65
+ /**
66
+ * The signature `send` had before it inferred its output (#68). It stays
67
+ * so that a call naming both type arguments, and a client typed by a
68
+ * structural `send<TInput, TOutput>` — as `@chaosity/address-form` types
69
+ * its client — still compile.
70
+ */
55
71
  send<TInput, TOutput>(command: TInput, options?: SendOptions): Promise<TOutput>;
56
72
  /**
57
73
  * Verify a PlaceId: `send(new VerifyAddressCommand({ PlaceId }))`, typed