@parseapi/sdk 1.12.2 → 1.12.4

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.
package/README.md CHANGED
@@ -269,6 +269,10 @@ Source deep adds `standard_offset`, `standard_offset_seconds`, signed `dst_offse
269
269
 
270
270
  ## Place statistics and optional detail
271
271
 
272
+ Country Core contains the everyday reference: `name`, `name_full`, `name_local`, demonym and country codes, continent, region and subregion, currency, calling code, `flag`, language and timezone codes, borders, bloc memberships and `capital: { name, lat, lon }`. Paid Deep adds specialist detail, including population, total area and national statistics. `gdp_usd` and `gdp_per_capita_usd` are current US dollars; `population_growth_percent`, `urban_population_percent` and `internet_users_percent` use a 0–100 percent scale (growth can be negative or exceed 100). GDP per person and these three percentages round once to two decimals in the API response. `elevation_average` is average terrain elevation in meters; `lowest_point.elevation` and `highest_point.elevation` keep their point-specific meaning. Unknown stays null and a known zero stays zero. Country tax references are grouped once as `deep.tax: { name, rate }`; the rate remains a percentage. Read capital from the Core object and read the tax name and rate from the Deep tax object.
273
+
274
+ Read `name_full` from current responses. The older `full_name` type member remains available for earlier payloads; responses are returned as received, with null values preserved. Historical Deep fields remain readable in earlier responses; they are not added to the current wire result.
275
+
272
276
  Australian postal lookups include core `localities` with suburb choices (`city`, `state`, `state_name`) on every plan. Null or an omitted field means unknown, while `[]` means the reviewed reference has no eligible choices. `city` stays null when the source is ambiguous, even if there is only one eligible choice. Let the user select their suburb and keep manual entry available. These are geographic choices, not mailing-address verification. [G-NAF source, adaptations and licence](https://parseapi.com/legal/attribution#postal-au).
273
277
 
274
278
  Postal and District paid profiles include `deep.property_tax` where supported. It contains `annual_median`, `currency` and `period`: median annual property tax payable on owner-occupied homes in the statistical area. The amount is adjusted to the final year of the reporting period (`YYYY-YYYY`). This is an area statistic, not a rate or an individual property bill. Unsupported, missing and censored estimates are null.
@@ -406,15 +410,34 @@ const detail = await parse.time('America/New_York', { deep: true });
406
410
  console.log(basic.at, detail.deep?.next_dst);
407
411
  ```
408
412
 
413
+ ## Domain results with unknown availability
414
+
415
+ Use `domainResult` when deciding whether a domain is registered. It returns `available: true` for unregistered, `false` for registered, and `null` when the registry answer is unknown.
416
+
417
+ ```ts
418
+ const result = await parse.domainResult('example.com', { deep: true });
419
+ if (result.available === null) {
420
+ console.log('Registration could not be determined');
421
+ } else {
422
+ console.log(result.available ? 'Unregistered' : 'Registered');
423
+ }
424
+ ```
425
+
426
+ This makes one ordinary Domain lookup with the same options, authentication and retry policy. Registration detail may be partial. Missing or null `dnssec` is unknown, while `false` is a known negative. Missing or null `status` is unknown, while `[]` is a known empty list.
427
+
428
+ The existing `domain` method and `Domain` type keep their published interface. That older type declares `available` as a boolean even though the API can return null. Use `domainResult` for its accurate nullable type.
429
+
409
430
  ## Stack API
410
431
 
411
432
  ```typescript
412
- const result = await parse.stack("example.com");
433
+ import type { StackResult } from '@parseapi/sdk';
434
+
435
+ const result: StackResult = await parse.stack("example.com");
413
436
  ```
414
437
 
415
- Pass a public hostname without a scheme, path, port or IP address. Stack returns the checked URL and `checked_at` time, followed by `scope`, `pages` and `partial`. `scope` is `homepage` or `site`; `pages` counts successfully checked HTML pages. `partial` is true for homepage-only or incomplete bounded site checks. False means the known in-scope candidates were completed, not that every page on a website was visited. A homepage result has `scope: "homepage"`, `pages: 1` and `partial: true`.
438
+ Pass a public hostname without a scheme, path, port or IP address. Stack checks static homepage HTML and response headers. It returns the checked URL, original `checked_at` time and eight technology arrays. `StackResult` describes that current result. The existing `Stack` interface keeps its older required coverage members for source compatibility; the current response omits `scope`, `pages` and `partial`.
416
439
 
417
- `cms`, `servers`, `frameworks`, `ecommerce`, `analytics`, `chat`, `payments` and `hosting` are arrays because a site can use several technologies in each category. Each entry contains `technology`, `name` and nullable `version`. Technology codes are open strings. A successful check uses empty arrays for categories with no matches. When no HTML page could be checked, `checked_at` and all categories are null, `pages` is 0 and `partial` is null. Unknown or conflicting versions are null. Missing detections do not prove absence.
440
+ `cms`, `servers`, `frameworks`, `ecommerce`, `analytics`, `chat`, `payments` and `hosting` are arrays because a site can use several technologies in each category. Each entry contains `technology`, `name` and nullable `version`. Technology codes are open strings. A successful check uses empty arrays for categories with no matches. When no HTML page could be checked, `checked_at` and all categories are null. Unknown or conflicting versions are null. Missing detections do not prove absence.
418
441
 
419
442
  Successful checks may be reused for up to 24 hours. `pretty` optionally formats the wire JSON. Stack uses your plan's request allowance and API version 2.0.0 selected by this client.
420
443
 
package/dist/index.cjs CHANGED
@@ -448,7 +448,7 @@ var EmojiCatalog = class {
448
448
  };
449
449
 
450
450
  // src/index.ts
451
- var VERSION = "1.12.2";
451
+ var VERSION = "1.12.4";
452
452
  var API_VERSION = "2.0.0";
453
453
  var DEFAULT_BASE_URL = "https://api.parseapi.com";
454
454
  var DEFAULT_TIMEOUT_MS = 1e4;
@@ -754,6 +754,8 @@ function parseAPI(apiKey, options = {}) {
754
754
  stack: (domain, opts) => request(`/stack/${enc(domain)}`, { ...deepQuery(opts), pretty: opts?.pretty }, void 0, opts),
755
755
  /** Check whether a domain is registered. Deep adds registration dates, registrar, status and DNSSEC on paid plans. */
756
756
  domain: (domain, opts) => request(`/domain/${enc(domain)}`, deepQuery(opts), void 0, opts),
757
+ /** Check domain registration while preserving unknown availability and partial detail. */
758
+ domainResult: (domain, opts) => request(`/domain/${enc(domain)}`, deepQuery(opts), void 0, opts),
757
759
  asn: (asn, opts) => request(`/asn/${enc(asn)}`, void 0, void 0, opts),
758
760
  /** Look up a 2-11 digit card prefix. Keep leading zeros in the input string. */
759
761
  card: async (bin, opts) => {
package/dist/index.d.cts CHANGED
@@ -17,6 +17,12 @@ interface IpDeep {
17
17
  tor: boolean;
18
18
  vpn: boolean;
19
19
  provider: string;
20
+ /** Present only when a district is supported, with the response country. */
21
+ district?: string | null;
22
+ district_name?: string | null;
23
+ /** U.S. Census geography, when independently supported. */
24
+ census_division?: string | null;
25
+ census_region?: string | null;
20
26
  }
21
27
  interface Ip {
22
28
  ip: string;
@@ -41,6 +47,8 @@ interface Continent {
41
47
  interface ContinentCountryItem {
42
48
  country: string;
43
49
  name: string;
50
+ flag?: string | null;
51
+ /** @deprecated Present only in earlier compact response payloads. */
44
52
  emoji?: string | null;
45
53
  calling_code?: string | null;
46
54
  }
@@ -57,11 +65,36 @@ interface Country {
57
65
  currency_name: string | null;
58
66
  currency_symbol: string | null;
59
67
  calling_code: string | null;
60
- emoji: string | null;
61
- languages: string[];
68
+ flag: string | null;
69
+ /** @deprecated Present only in earlier response payloads. */
70
+ emoji?: string | null;
71
+ languages: string[] | null;
62
72
  deep?: Deep<CountryDeep>;
63
73
  /** IANA timezones used by the country. */
64
74
  timezones: string[] | null;
75
+ iso3?: string | null;
76
+ numeric?: number | null;
77
+ /** Official long name. */
78
+ name_full?: string | null;
79
+ /** @deprecated Legacy wire spelling; retained for earlier responses. */
80
+ full_name?: string | null;
81
+ demonym?: string | null;
82
+ region?: string | null;
83
+ subregion?: string | null;
84
+ capital?: CountryCapital | null;
85
+ capital_lat?: number | null;
86
+ capital_lon?: number | null;
87
+ borders?: string[] | null;
88
+ blocs?: string[] | null;
89
+ }
90
+ interface CountryCapital {
91
+ name: string | null;
92
+ lat: number | null;
93
+ lon: number | null;
94
+ }
95
+ interface CountryTax {
96
+ name: string | null;
97
+ rate: number | null;
65
98
  }
66
99
  interface CountryStateItem {
67
100
  state: string;
@@ -1181,12 +1214,12 @@ interface CountryDeep {
1181
1214
  highest_point?: CountryElevationPoint | null;
1182
1215
  tld: string | null;
1183
1216
  /** Levy name, such as VAT, GST or sales tax. Null when unknown or not applicable. */
1184
- tax?: string | null;
1185
- /** Standard country reference rate in percent (19 means 19%). Null is unknown, zero is known zero. */
1217
+ tax?: CountryTax | null;
1218
+ /** @deprecated Historical flat field; current responses use tax.rate. */
1186
1219
  tax_rate?: number | null;
1187
- /** Tax registration number mask (9 is a digit, A is a letter). Describes format only. */
1220
+ /** @deprecated Historical flat field; no longer returned. */
1188
1221
  tax_id_format?: string | null;
1189
- /** Anchored tax registration number format regex. A match does not establish registration. */
1222
+ /** @deprecated Historical flat field; no longer returned. */
1190
1223
  tax_id_regex?: string | null;
1191
1224
  borders: string[];
1192
1225
  /** Bloc memberships (EU, SCHENGEN, NATO, ...). Empty when none. */
@@ -1203,6 +1236,13 @@ interface CountryDeep {
1203
1236
  ioc: string | null;
1204
1237
  fifa: string | null;
1205
1238
  plate: string | null;
1239
+ gdp_usd?: number | null;
1240
+ gdp_per_capita_usd?: number | null;
1241
+ population_growth_percent?: number | null;
1242
+ urban_population_percent?: number | null;
1243
+ internet_users_percent?: number | null;
1244
+ /** Average terrain elevation in meters above sea level. */
1245
+ elevation_average?: number | null;
1206
1246
  }
1207
1247
  interface CountryElevationPoint {
1208
1248
  name: string | null;
@@ -1811,6 +1851,29 @@ interface AgentTaskResult<T = unknown> {
1811
1851
  };
1812
1852
  }
1813
1853
 
1854
+ /** Registration detail from the same observation. Missing or null means unknown. */
1855
+ interface DomainRegistrationResult {
1856
+ registered?: boolean | null;
1857
+ created?: string | null;
1858
+ updated?: string | null;
1859
+ expires?: string | null;
1860
+ registrar?: string | null;
1861
+ status?: string[] | null;
1862
+ dnssec?: boolean | null;
1863
+ }
1864
+ interface DomainResultDeep {
1865
+ registration: DomainRegistrationResult | null;
1866
+ }
1867
+ /** Domain availability with an explicit unknown result. */
1868
+ interface DomainResult {
1869
+ domain: string;
1870
+ /** true means unregistered, false means registered, null means unknown. */
1871
+ available: boolean | null;
1872
+ deep?: Deep<DomainResultDeep>;
1873
+ }
1874
+ /** The current eleven-field Stack response, without obsolete coverage members. */
1875
+ type StackResult = Omit<Stack, 'scope' | 'pages' | 'partial'>;
1876
+
1814
1877
  interface EmojiCatalogLookupOptions {
1815
1878
  deep?: boolean;
1816
1879
  shortcodeSource?: string;
@@ -2218,6 +2281,8 @@ declare function parseAPI(apiKey?: string, options?: ParseAPIOptions): {
2218
2281
  stack: (domain: string, opts?: StackOptions) => Promise<Stack>;
2219
2282
  /** Check whether a domain is registered. Deep adds registration dates, registrar, status and DNSSEC on paid plans. */
2220
2283
  domain: (domain: string, opts?: DomainOptions) => Promise<Domain>;
2284
+ /** Check domain registration while preserving unknown availability and partial detail. */
2285
+ domainResult: (domain: string, opts?: DomainOptions) => Promise<DomainResult>;
2221
2286
  asn: (asn: string, opts?: AsnOptions) => Promise<Asn>;
2222
2287
  /** Look up a 2-11 digit card prefix. Keep leading zeros in the input string. */
2223
2288
  card: (bin: string, opts?: CardOptions) => Promise<Card>;
@@ -2364,4 +2429,4 @@ interface CityNearbyCall {
2364
2429
  (name: string, opts: CityNearbyOptions): Promise<CityNearby | CityCollection>;
2365
2430
  }
2366
2431
 
2367
- export { type Address, type AddressOptions, type AddressSearch, type AddressSearchOptions, type AddressSuggestion, type AgentTask, type AgentTaskInput, type AgentTaskLookupInput, type AgentTaskResult, type Asn, type AsnOptions, BULK_CHECKS, type Bin, type BinOptions, ParseAPIError as BulkAPIError, type BulkClient, type BulkClientOptions, type BulkJob, type BulkPreview, type BulkPreviewInput, type BulkQuote, type BulkRequestOptions, type BulkResult, type BulkStartInput, type BulkStatus, type BulkUpload, type BulkUploadInput, type Caller, type CallerOptions, type Card, type CardDeep, type CardOptions, type Carrier, type CarrierDeep, type CarrierOptions, type City, type CityAmbiguityCandidate, type CityAncestorsOptions, type CityCollection, type CityCollectionFilters, type CityDeep, type CityDistance, type CityDistanceOptions, type CityGrain, type CityIdCall, type CityIdOptions, type CityList, type CityListOptions, type CityLookupCall, type CityMatch, type CityNearby, type CityNearbyCall, type CityNearbyCoordinates, type CityNearbyCoordinatesOptions, type CityNearbyOptions, type CityNearest, type CityNearestCall, type CityNearestOptions, type CityOptions, type CityPagingOptions, type CityParent, type CityRelations, type CityRelationsOptions, type CityResource, type CityResponseOptions, type CityScopeOptions, type CitySearch, type CitySearchCall, type CitySearchOptions, type CitySort, type Company, type CompanyCandidate, type CompanyCountry, type CompanyCoverage, type CompanyCoverageOptions, type CompanyDeep, type CompanyEmailAddress, type CompanyIdOptions, type CompanyMatch, type CompanyOptions, type CompanyPhoneNumber, type CompanyProfile, type CompanyProfileAddress, type CompanyProfileDeep, type CompanyProfileDomain, type CompanyProfileEmail, type CompanyProfileEmployees, type CompanyProfileFounding, type CompanyProfileIdentifier, type CompanyProfileIndustry, type CompanyProfileJurisdiction, type CompanyProfileListing, type CompanyProfilePhone, type CompanyProfileRegistration, type CompanyProfileRegistrationAddress, type CompanyProfileRegistrationLegalForm, type CompanyProfileSource, type CompanyProfileWebsite, type CompanySearch, type CompanySearchOptions, type CompanySocialProfile, type Continent, type ContinentCountries, type ContinentCountriesOptions, type ContinentCountryItem, type ContinentOptions, type Country, type CountryDeep, type CountryElevationPoint, type CountryEmergency, type CountryOptions, type CountryStateItem, type CountryStates, type CountryStatesOptions, type DateInfo, type DateInfoDeep, type DateOptions, type DateTodayOptions, type Deep, type District, type DistrictDeep, type DistrictOptions, type Dns, type DnsOptions, type DnsRecord, type Domain, type DomainDeep, type DomainOptions, type DomainRegistration, type Elevation, type ElevationLocations, type ElevationOptions, type Email, type EmailDeep, type EmailOptions, type Emoji, type EmojiArtwork, type EmojiArtworkSource, type EmojiBrowse, type EmojiBrowseOptions, EmojiCatalog, type EmojiCatalogConvertOptions, type EmojiCatalogData, EmojiCatalogError, type EmojiCatalogLocalization, type EmojiCatalogLookupOptions, type EmojiCatalogOptions, type EmojiCatalogParseOptions, type EmojiCatalogRegexOptions, type EmojiCatalogScope, type EmojiCatalogSearchFacts, type EmojiCatalogSearchOptions, type EmojiCategories, type EmojiCategory, type EmojiConversion, type EmojiConvertOptions, type EmojiDeep, type EmojiMetadata, type EmojiNativeSearchFacts, type EmojiNotice, type EmojiOptions, type EmojiParse, type EmojiParseOptions, type EmojiPosition, type EmojiSearch, type EmojiSearchOptions, type EmojiShortcodeSourceMetadata, type EmojiSkin, type EmojiSource, type EmojiUnresolved, type EmojiVariant, type Hlr, type HlrDeep, type HlrOptions, type Holiday, type HolidayDate, type HolidayDateOptions, type HolidayOptions, type HolidayYear, type Industry, type IndustryChild, type IndustryCorrection, type IndustryDeep, type IndustryExclusion, type IndustryMatch, type IndustryOptions, type IndustrySearch, type IndustrySearchItem, type IndustrySearchOptions, type Ip, type IpDeep, type IpOptions, type IpSelfOptions, type Language, type LanguageDeep, type LanguageOption, type LanguageOptions, type Mx, type MxOptions, type MxRecord, type Naics, type NaicsChild, type NaicsCorrection, type NaicsDeep, type NaicsExclusion, type NaicsMatch, type NaicsOptions, type NaicsSearch, type NaicsSearchItem, type NaicsSearchOptions, type Name, type NameDeep, type NameOptions, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type PhoneDeep, type PhoneOptions, type Point, type PointCity, type PointDeep, type PointOptions, type Postal, type PostalDeep, type PostalDistance, type PostalDistanceEnd, type PostalDistanceOptions, type PostalLocality, type PostalMetro, type PostalMetrosDeep, type PostalNearby, type PostalNearbyItem, type PostalNearbyOptions, type PostalOptions, type Preflight, type PreflightCost, type PreflightEmailCapacity, type PreflightOperation, type PreflightOperationEstimate, type PreflightPooledCapacity, type PreflightSpendCapacity, type PreflightTask, type PropertyTax, type RequestOptions, type Stack, type StackOptions, type StackTechnology, type State, type StateDeep, type StateDistrictDeep, type StateDistrictItem, type StateDistricts, type StateDistrictsOptions, type StateOptions, type Time, type TimeAtOptions, type TimeLocation, type TimeLocationCandidate, type TimeLocationInput, type TimeOptions, type TimeResolution, type TimeResolutionAlternative, type TimeSeason, type TimeTransition, type TimeTransitionState, type TimeZoneEntry, type TimeZones, type TimeZonesOptions, type Timezone, type TimezoneAtOptions, type TimezoneConversionTarget, type TimezoneConversionTargetDeep, type TimezoneDeep, type TimezoneNextDst, type TimezoneOptions, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOptions, type UseragentOsDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherCurrentDeep, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherOptions, type WeatherStation, createBulkClient, parseAPI };
2432
+ export { type Address, type AddressOptions, type AddressSearch, type AddressSearchOptions, type AddressSuggestion, type AgentTask, type AgentTaskInput, type AgentTaskLookupInput, type AgentTaskResult, type Asn, type AsnOptions, BULK_CHECKS, type Bin, type BinOptions, ParseAPIError as BulkAPIError, type BulkClient, type BulkClientOptions, type BulkJob, type BulkPreview, type BulkPreviewInput, type BulkQuote, type BulkRequestOptions, type BulkResult, type BulkStartInput, type BulkStatus, type BulkUpload, type BulkUploadInput, type Caller, type CallerOptions, type Card, type CardDeep, type CardOptions, type Carrier, type CarrierDeep, type CarrierOptions, type City, type CityAmbiguityCandidate, type CityAncestorsOptions, type CityCollection, type CityCollectionFilters, type CityDeep, type CityDistance, type CityDistanceOptions, type CityGrain, type CityIdCall, type CityIdOptions, type CityList, type CityListOptions, type CityLookupCall, type CityMatch, type CityNearby, type CityNearbyCall, type CityNearbyCoordinates, type CityNearbyCoordinatesOptions, type CityNearbyOptions, type CityNearest, type CityNearestCall, type CityNearestOptions, type CityOptions, type CityPagingOptions, type CityParent, type CityRelations, type CityRelationsOptions, type CityResource, type CityResponseOptions, type CityScopeOptions, type CitySearch, type CitySearchCall, type CitySearchOptions, type CitySort, type Company, type CompanyCandidate, type CompanyCountry, type CompanyCoverage, type CompanyCoverageOptions, type CompanyDeep, type CompanyEmailAddress, type CompanyIdOptions, type CompanyMatch, type CompanyOptions, type CompanyPhoneNumber, type CompanyProfile, type CompanyProfileAddress, type CompanyProfileDeep, type CompanyProfileDomain, type CompanyProfileEmail, type CompanyProfileEmployees, type CompanyProfileFounding, type CompanyProfileIdentifier, type CompanyProfileIndustry, type CompanyProfileJurisdiction, type CompanyProfileListing, type CompanyProfilePhone, type CompanyProfileRegistration, type CompanyProfileRegistrationAddress, type CompanyProfileRegistrationLegalForm, type CompanyProfileSource, type CompanyProfileWebsite, type CompanySearch, type CompanySearchOptions, type CompanySocialProfile, type Continent, type ContinentCountries, type ContinentCountriesOptions, type ContinentCountryItem, type ContinentOptions, type Country, type CountryCapital, type CountryDeep, type CountryElevationPoint, type CountryEmergency, type CountryOptions, type CountryStateItem, type CountryStates, type CountryStatesOptions, type CountryTax, type DateInfo, type DateInfoDeep, type DateOptions, type DateTodayOptions, type Deep, type District, type DistrictDeep, type DistrictOptions, type Dns, type DnsOptions, type DnsRecord, type Domain, type DomainDeep, type DomainOptions, type DomainRegistration, type DomainRegistrationResult, type DomainResult, type DomainResultDeep, type Elevation, type ElevationLocations, type ElevationOptions, type Email, type EmailDeep, type EmailOptions, type Emoji, type EmojiArtwork, type EmojiArtworkSource, type EmojiBrowse, type EmojiBrowseOptions, EmojiCatalog, type EmojiCatalogConvertOptions, type EmojiCatalogData, EmojiCatalogError, type EmojiCatalogLocalization, type EmojiCatalogLookupOptions, type EmojiCatalogOptions, type EmojiCatalogParseOptions, type EmojiCatalogRegexOptions, type EmojiCatalogScope, type EmojiCatalogSearchFacts, type EmojiCatalogSearchOptions, type EmojiCategories, type EmojiCategory, type EmojiConversion, type EmojiConvertOptions, type EmojiDeep, type EmojiMetadata, type EmojiNativeSearchFacts, type EmojiNotice, type EmojiOptions, type EmojiParse, type EmojiParseOptions, type EmojiPosition, type EmojiSearch, type EmojiSearchOptions, type EmojiShortcodeSourceMetadata, type EmojiSkin, type EmojiSource, type EmojiUnresolved, type EmojiVariant, type Hlr, type HlrDeep, type HlrOptions, type Holiday, type HolidayDate, type HolidayDateOptions, type HolidayOptions, type HolidayYear, type Industry, type IndustryChild, type IndustryCorrection, type IndustryDeep, type IndustryExclusion, type IndustryMatch, type IndustryOptions, type IndustrySearch, type IndustrySearchItem, type IndustrySearchOptions, type Ip, type IpDeep, type IpOptions, type IpSelfOptions, type Language, type LanguageDeep, type LanguageOption, type LanguageOptions, type Mx, type MxOptions, type MxRecord, type Naics, type NaicsChild, type NaicsCorrection, type NaicsDeep, type NaicsExclusion, type NaicsMatch, type NaicsOptions, type NaicsSearch, type NaicsSearchItem, type NaicsSearchOptions, type Name, type NameDeep, type NameOptions, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type PhoneDeep, type PhoneOptions, type Point, type PointCity, type PointDeep, type PointOptions, type Postal, type PostalDeep, type PostalDistance, type PostalDistanceEnd, type PostalDistanceOptions, type PostalLocality, type PostalMetro, type PostalMetrosDeep, type PostalNearby, type PostalNearbyItem, type PostalNearbyOptions, type PostalOptions, type Preflight, type PreflightCost, type PreflightEmailCapacity, type PreflightOperation, type PreflightOperationEstimate, type PreflightPooledCapacity, type PreflightSpendCapacity, type PreflightTask, type PropertyTax, type RequestOptions, type Stack, type StackOptions, type StackResult, type StackTechnology, type State, type StateDeep, type StateDistrictDeep, type StateDistrictItem, type StateDistricts, type StateDistrictsOptions, type StateOptions, type Time, type TimeAtOptions, type TimeLocation, type TimeLocationCandidate, type TimeLocationInput, type TimeOptions, type TimeResolution, type TimeResolutionAlternative, type TimeSeason, type TimeTransition, type TimeTransitionState, type TimeZoneEntry, type TimeZones, type TimeZonesOptions, type Timezone, type TimezoneAtOptions, type TimezoneConversionTarget, type TimezoneConversionTargetDeep, type TimezoneDeep, type TimezoneNextDst, type TimezoneOptions, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOptions, type UseragentOsDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherCurrentDeep, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherOptions, type WeatherStation, createBulkClient, parseAPI };
package/dist/index.d.ts CHANGED
@@ -17,6 +17,12 @@ interface IpDeep {
17
17
  tor: boolean;
18
18
  vpn: boolean;
19
19
  provider: string;
20
+ /** Present only when a district is supported, with the response country. */
21
+ district?: string | null;
22
+ district_name?: string | null;
23
+ /** U.S. Census geography, when independently supported. */
24
+ census_division?: string | null;
25
+ census_region?: string | null;
20
26
  }
21
27
  interface Ip {
22
28
  ip: string;
@@ -41,6 +47,8 @@ interface Continent {
41
47
  interface ContinentCountryItem {
42
48
  country: string;
43
49
  name: string;
50
+ flag?: string | null;
51
+ /** @deprecated Present only in earlier compact response payloads. */
44
52
  emoji?: string | null;
45
53
  calling_code?: string | null;
46
54
  }
@@ -57,11 +65,36 @@ interface Country {
57
65
  currency_name: string | null;
58
66
  currency_symbol: string | null;
59
67
  calling_code: string | null;
60
- emoji: string | null;
61
- languages: string[];
68
+ flag: string | null;
69
+ /** @deprecated Present only in earlier response payloads. */
70
+ emoji?: string | null;
71
+ languages: string[] | null;
62
72
  deep?: Deep<CountryDeep>;
63
73
  /** IANA timezones used by the country. */
64
74
  timezones: string[] | null;
75
+ iso3?: string | null;
76
+ numeric?: number | null;
77
+ /** Official long name. */
78
+ name_full?: string | null;
79
+ /** @deprecated Legacy wire spelling; retained for earlier responses. */
80
+ full_name?: string | null;
81
+ demonym?: string | null;
82
+ region?: string | null;
83
+ subregion?: string | null;
84
+ capital?: CountryCapital | null;
85
+ capital_lat?: number | null;
86
+ capital_lon?: number | null;
87
+ borders?: string[] | null;
88
+ blocs?: string[] | null;
89
+ }
90
+ interface CountryCapital {
91
+ name: string | null;
92
+ lat: number | null;
93
+ lon: number | null;
94
+ }
95
+ interface CountryTax {
96
+ name: string | null;
97
+ rate: number | null;
65
98
  }
66
99
  interface CountryStateItem {
67
100
  state: string;
@@ -1181,12 +1214,12 @@ interface CountryDeep {
1181
1214
  highest_point?: CountryElevationPoint | null;
1182
1215
  tld: string | null;
1183
1216
  /** Levy name, such as VAT, GST or sales tax. Null when unknown or not applicable. */
1184
- tax?: string | null;
1185
- /** Standard country reference rate in percent (19 means 19%). Null is unknown, zero is known zero. */
1217
+ tax?: CountryTax | null;
1218
+ /** @deprecated Historical flat field; current responses use tax.rate. */
1186
1219
  tax_rate?: number | null;
1187
- /** Tax registration number mask (9 is a digit, A is a letter). Describes format only. */
1220
+ /** @deprecated Historical flat field; no longer returned. */
1188
1221
  tax_id_format?: string | null;
1189
- /** Anchored tax registration number format regex. A match does not establish registration. */
1222
+ /** @deprecated Historical flat field; no longer returned. */
1190
1223
  tax_id_regex?: string | null;
1191
1224
  borders: string[];
1192
1225
  /** Bloc memberships (EU, SCHENGEN, NATO, ...). Empty when none. */
@@ -1203,6 +1236,13 @@ interface CountryDeep {
1203
1236
  ioc: string | null;
1204
1237
  fifa: string | null;
1205
1238
  plate: string | null;
1239
+ gdp_usd?: number | null;
1240
+ gdp_per_capita_usd?: number | null;
1241
+ population_growth_percent?: number | null;
1242
+ urban_population_percent?: number | null;
1243
+ internet_users_percent?: number | null;
1244
+ /** Average terrain elevation in meters above sea level. */
1245
+ elevation_average?: number | null;
1206
1246
  }
1207
1247
  interface CountryElevationPoint {
1208
1248
  name: string | null;
@@ -1811,6 +1851,29 @@ interface AgentTaskResult<T = unknown> {
1811
1851
  };
1812
1852
  }
1813
1853
 
1854
+ /** Registration detail from the same observation. Missing or null means unknown. */
1855
+ interface DomainRegistrationResult {
1856
+ registered?: boolean | null;
1857
+ created?: string | null;
1858
+ updated?: string | null;
1859
+ expires?: string | null;
1860
+ registrar?: string | null;
1861
+ status?: string[] | null;
1862
+ dnssec?: boolean | null;
1863
+ }
1864
+ interface DomainResultDeep {
1865
+ registration: DomainRegistrationResult | null;
1866
+ }
1867
+ /** Domain availability with an explicit unknown result. */
1868
+ interface DomainResult {
1869
+ domain: string;
1870
+ /** true means unregistered, false means registered, null means unknown. */
1871
+ available: boolean | null;
1872
+ deep?: Deep<DomainResultDeep>;
1873
+ }
1874
+ /** The current eleven-field Stack response, without obsolete coverage members. */
1875
+ type StackResult = Omit<Stack, 'scope' | 'pages' | 'partial'>;
1876
+
1814
1877
  interface EmojiCatalogLookupOptions {
1815
1878
  deep?: boolean;
1816
1879
  shortcodeSource?: string;
@@ -2218,6 +2281,8 @@ declare function parseAPI(apiKey?: string, options?: ParseAPIOptions): {
2218
2281
  stack: (domain: string, opts?: StackOptions) => Promise<Stack>;
2219
2282
  /** Check whether a domain is registered. Deep adds registration dates, registrar, status and DNSSEC on paid plans. */
2220
2283
  domain: (domain: string, opts?: DomainOptions) => Promise<Domain>;
2284
+ /** Check domain registration while preserving unknown availability and partial detail. */
2285
+ domainResult: (domain: string, opts?: DomainOptions) => Promise<DomainResult>;
2221
2286
  asn: (asn: string, opts?: AsnOptions) => Promise<Asn>;
2222
2287
  /** Look up a 2-11 digit card prefix. Keep leading zeros in the input string. */
2223
2288
  card: (bin: string, opts?: CardOptions) => Promise<Card>;
@@ -2364,4 +2429,4 @@ interface CityNearbyCall {
2364
2429
  (name: string, opts: CityNearbyOptions): Promise<CityNearby | CityCollection>;
2365
2430
  }
2366
2431
 
2367
- export { type Address, type AddressOptions, type AddressSearch, type AddressSearchOptions, type AddressSuggestion, type AgentTask, type AgentTaskInput, type AgentTaskLookupInput, type AgentTaskResult, type Asn, type AsnOptions, BULK_CHECKS, type Bin, type BinOptions, ParseAPIError as BulkAPIError, type BulkClient, type BulkClientOptions, type BulkJob, type BulkPreview, type BulkPreviewInput, type BulkQuote, type BulkRequestOptions, type BulkResult, type BulkStartInput, type BulkStatus, type BulkUpload, type BulkUploadInput, type Caller, type CallerOptions, type Card, type CardDeep, type CardOptions, type Carrier, type CarrierDeep, type CarrierOptions, type City, type CityAmbiguityCandidate, type CityAncestorsOptions, type CityCollection, type CityCollectionFilters, type CityDeep, type CityDistance, type CityDistanceOptions, type CityGrain, type CityIdCall, type CityIdOptions, type CityList, type CityListOptions, type CityLookupCall, type CityMatch, type CityNearby, type CityNearbyCall, type CityNearbyCoordinates, type CityNearbyCoordinatesOptions, type CityNearbyOptions, type CityNearest, type CityNearestCall, type CityNearestOptions, type CityOptions, type CityPagingOptions, type CityParent, type CityRelations, type CityRelationsOptions, type CityResource, type CityResponseOptions, type CityScopeOptions, type CitySearch, type CitySearchCall, type CitySearchOptions, type CitySort, type Company, type CompanyCandidate, type CompanyCountry, type CompanyCoverage, type CompanyCoverageOptions, type CompanyDeep, type CompanyEmailAddress, type CompanyIdOptions, type CompanyMatch, type CompanyOptions, type CompanyPhoneNumber, type CompanyProfile, type CompanyProfileAddress, type CompanyProfileDeep, type CompanyProfileDomain, type CompanyProfileEmail, type CompanyProfileEmployees, type CompanyProfileFounding, type CompanyProfileIdentifier, type CompanyProfileIndustry, type CompanyProfileJurisdiction, type CompanyProfileListing, type CompanyProfilePhone, type CompanyProfileRegistration, type CompanyProfileRegistrationAddress, type CompanyProfileRegistrationLegalForm, type CompanyProfileSource, type CompanyProfileWebsite, type CompanySearch, type CompanySearchOptions, type CompanySocialProfile, type Continent, type ContinentCountries, type ContinentCountriesOptions, type ContinentCountryItem, type ContinentOptions, type Country, type CountryDeep, type CountryElevationPoint, type CountryEmergency, type CountryOptions, type CountryStateItem, type CountryStates, type CountryStatesOptions, type DateInfo, type DateInfoDeep, type DateOptions, type DateTodayOptions, type Deep, type District, type DistrictDeep, type DistrictOptions, type Dns, type DnsOptions, type DnsRecord, type Domain, type DomainDeep, type DomainOptions, type DomainRegistration, type Elevation, type ElevationLocations, type ElevationOptions, type Email, type EmailDeep, type EmailOptions, type Emoji, type EmojiArtwork, type EmojiArtworkSource, type EmojiBrowse, type EmojiBrowseOptions, EmojiCatalog, type EmojiCatalogConvertOptions, type EmojiCatalogData, EmojiCatalogError, type EmojiCatalogLocalization, type EmojiCatalogLookupOptions, type EmojiCatalogOptions, type EmojiCatalogParseOptions, type EmojiCatalogRegexOptions, type EmojiCatalogScope, type EmojiCatalogSearchFacts, type EmojiCatalogSearchOptions, type EmojiCategories, type EmojiCategory, type EmojiConversion, type EmojiConvertOptions, type EmojiDeep, type EmojiMetadata, type EmojiNativeSearchFacts, type EmojiNotice, type EmojiOptions, type EmojiParse, type EmojiParseOptions, type EmojiPosition, type EmojiSearch, type EmojiSearchOptions, type EmojiShortcodeSourceMetadata, type EmojiSkin, type EmojiSource, type EmojiUnresolved, type EmojiVariant, type Hlr, type HlrDeep, type HlrOptions, type Holiday, type HolidayDate, type HolidayDateOptions, type HolidayOptions, type HolidayYear, type Industry, type IndustryChild, type IndustryCorrection, type IndustryDeep, type IndustryExclusion, type IndustryMatch, type IndustryOptions, type IndustrySearch, type IndustrySearchItem, type IndustrySearchOptions, type Ip, type IpDeep, type IpOptions, type IpSelfOptions, type Language, type LanguageDeep, type LanguageOption, type LanguageOptions, type Mx, type MxOptions, type MxRecord, type Naics, type NaicsChild, type NaicsCorrection, type NaicsDeep, type NaicsExclusion, type NaicsMatch, type NaicsOptions, type NaicsSearch, type NaicsSearchItem, type NaicsSearchOptions, type Name, type NameDeep, type NameOptions, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type PhoneDeep, type PhoneOptions, type Point, type PointCity, type PointDeep, type PointOptions, type Postal, type PostalDeep, type PostalDistance, type PostalDistanceEnd, type PostalDistanceOptions, type PostalLocality, type PostalMetro, type PostalMetrosDeep, type PostalNearby, type PostalNearbyItem, type PostalNearbyOptions, type PostalOptions, type Preflight, type PreflightCost, type PreflightEmailCapacity, type PreflightOperation, type PreflightOperationEstimate, type PreflightPooledCapacity, type PreflightSpendCapacity, type PreflightTask, type PropertyTax, type RequestOptions, type Stack, type StackOptions, type StackTechnology, type State, type StateDeep, type StateDistrictDeep, type StateDistrictItem, type StateDistricts, type StateDistrictsOptions, type StateOptions, type Time, type TimeAtOptions, type TimeLocation, type TimeLocationCandidate, type TimeLocationInput, type TimeOptions, type TimeResolution, type TimeResolutionAlternative, type TimeSeason, type TimeTransition, type TimeTransitionState, type TimeZoneEntry, type TimeZones, type TimeZonesOptions, type Timezone, type TimezoneAtOptions, type TimezoneConversionTarget, type TimezoneConversionTargetDeep, type TimezoneDeep, type TimezoneNextDst, type TimezoneOptions, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOptions, type UseragentOsDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherCurrentDeep, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherOptions, type WeatherStation, createBulkClient, parseAPI };
2432
+ export { type Address, type AddressOptions, type AddressSearch, type AddressSearchOptions, type AddressSuggestion, type AgentTask, type AgentTaskInput, type AgentTaskLookupInput, type AgentTaskResult, type Asn, type AsnOptions, BULK_CHECKS, type Bin, type BinOptions, ParseAPIError as BulkAPIError, type BulkClient, type BulkClientOptions, type BulkJob, type BulkPreview, type BulkPreviewInput, type BulkQuote, type BulkRequestOptions, type BulkResult, type BulkStartInput, type BulkStatus, type BulkUpload, type BulkUploadInput, type Caller, type CallerOptions, type Card, type CardDeep, type CardOptions, type Carrier, type CarrierDeep, type CarrierOptions, type City, type CityAmbiguityCandidate, type CityAncestorsOptions, type CityCollection, type CityCollectionFilters, type CityDeep, type CityDistance, type CityDistanceOptions, type CityGrain, type CityIdCall, type CityIdOptions, type CityList, type CityListOptions, type CityLookupCall, type CityMatch, type CityNearby, type CityNearbyCall, type CityNearbyCoordinates, type CityNearbyCoordinatesOptions, type CityNearbyOptions, type CityNearest, type CityNearestCall, type CityNearestOptions, type CityOptions, type CityPagingOptions, type CityParent, type CityRelations, type CityRelationsOptions, type CityResource, type CityResponseOptions, type CityScopeOptions, type CitySearch, type CitySearchCall, type CitySearchOptions, type CitySort, type Company, type CompanyCandidate, type CompanyCountry, type CompanyCoverage, type CompanyCoverageOptions, type CompanyDeep, type CompanyEmailAddress, type CompanyIdOptions, type CompanyMatch, type CompanyOptions, type CompanyPhoneNumber, type CompanyProfile, type CompanyProfileAddress, type CompanyProfileDeep, type CompanyProfileDomain, type CompanyProfileEmail, type CompanyProfileEmployees, type CompanyProfileFounding, type CompanyProfileIdentifier, type CompanyProfileIndustry, type CompanyProfileJurisdiction, type CompanyProfileListing, type CompanyProfilePhone, type CompanyProfileRegistration, type CompanyProfileRegistrationAddress, type CompanyProfileRegistrationLegalForm, type CompanyProfileSource, type CompanyProfileWebsite, type CompanySearch, type CompanySearchOptions, type CompanySocialProfile, type Continent, type ContinentCountries, type ContinentCountriesOptions, type ContinentCountryItem, type ContinentOptions, type Country, type CountryCapital, type CountryDeep, type CountryElevationPoint, type CountryEmergency, type CountryOptions, type CountryStateItem, type CountryStates, type CountryStatesOptions, type CountryTax, type DateInfo, type DateInfoDeep, type DateOptions, type DateTodayOptions, type Deep, type District, type DistrictDeep, type DistrictOptions, type Dns, type DnsOptions, type DnsRecord, type Domain, type DomainDeep, type DomainOptions, type DomainRegistration, type DomainRegistrationResult, type DomainResult, type DomainResultDeep, type Elevation, type ElevationLocations, type ElevationOptions, type Email, type EmailDeep, type EmailOptions, type Emoji, type EmojiArtwork, type EmojiArtworkSource, type EmojiBrowse, type EmojiBrowseOptions, EmojiCatalog, type EmojiCatalogConvertOptions, type EmojiCatalogData, EmojiCatalogError, type EmojiCatalogLocalization, type EmojiCatalogLookupOptions, type EmojiCatalogOptions, type EmojiCatalogParseOptions, type EmojiCatalogRegexOptions, type EmojiCatalogScope, type EmojiCatalogSearchFacts, type EmojiCatalogSearchOptions, type EmojiCategories, type EmojiCategory, type EmojiConversion, type EmojiConvertOptions, type EmojiDeep, type EmojiMetadata, type EmojiNativeSearchFacts, type EmojiNotice, type EmojiOptions, type EmojiParse, type EmojiParseOptions, type EmojiPosition, type EmojiSearch, type EmojiSearchOptions, type EmojiShortcodeSourceMetadata, type EmojiSkin, type EmojiSource, type EmojiUnresolved, type EmojiVariant, type Hlr, type HlrDeep, type HlrOptions, type Holiday, type HolidayDate, type HolidayDateOptions, type HolidayOptions, type HolidayYear, type Industry, type IndustryChild, type IndustryCorrection, type IndustryDeep, type IndustryExclusion, type IndustryMatch, type IndustryOptions, type IndustrySearch, type IndustrySearchItem, type IndustrySearchOptions, type Ip, type IpDeep, type IpOptions, type IpSelfOptions, type Language, type LanguageDeep, type LanguageOption, type LanguageOptions, type Mx, type MxOptions, type MxRecord, type Naics, type NaicsChild, type NaicsCorrection, type NaicsDeep, type NaicsExclusion, type NaicsMatch, type NaicsOptions, type NaicsSearch, type NaicsSearchItem, type NaicsSearchOptions, type Name, type NameDeep, type NameOptions, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type PhoneDeep, type PhoneOptions, type Point, type PointCity, type PointDeep, type PointOptions, type Postal, type PostalDeep, type PostalDistance, type PostalDistanceEnd, type PostalDistanceOptions, type PostalLocality, type PostalMetro, type PostalMetrosDeep, type PostalNearby, type PostalNearbyItem, type PostalNearbyOptions, type PostalOptions, type Preflight, type PreflightCost, type PreflightEmailCapacity, type PreflightOperation, type PreflightOperationEstimate, type PreflightPooledCapacity, type PreflightSpendCapacity, type PreflightTask, type PropertyTax, type RequestOptions, type Stack, type StackOptions, type StackResult, type StackTechnology, type State, type StateDeep, type StateDistrictDeep, type StateDistrictItem, type StateDistricts, type StateDistrictsOptions, type StateOptions, type Time, type TimeAtOptions, type TimeLocation, type TimeLocationCandidate, type TimeLocationInput, type TimeOptions, type TimeResolution, type TimeResolutionAlternative, type TimeSeason, type TimeTransition, type TimeTransitionState, type TimeZoneEntry, type TimeZones, type TimeZonesOptions, type Timezone, type TimezoneAtOptions, type TimezoneConversionTarget, type TimezoneConversionTargetDeep, type TimezoneDeep, type TimezoneNextDst, type TimezoneOptions, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOptions, type UseragentOsDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherCurrentDeep, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherOptions, type WeatherStation, createBulkClient, parseAPI };
package/dist/index.js CHANGED
@@ -416,7 +416,7 @@ var EmojiCatalog = class {
416
416
  };
417
417
 
418
418
  // src/index.ts
419
- var VERSION = "1.12.2";
419
+ var VERSION = "1.12.4";
420
420
  var API_VERSION = "2.0.0";
421
421
  var DEFAULT_BASE_URL = "https://api.parseapi.com";
422
422
  var DEFAULT_TIMEOUT_MS = 1e4;
@@ -722,6 +722,8 @@ function parseAPI(apiKey, options = {}) {
722
722
  stack: (domain, opts) => request(`/stack/${enc(domain)}`, { ...deepQuery(opts), pretty: opts?.pretty }, void 0, opts),
723
723
  /** Check whether a domain is registered. Deep adds registration dates, registrar, status and DNSSEC on paid plans. */
724
724
  domain: (domain, opts) => request(`/domain/${enc(domain)}`, deepQuery(opts), void 0, opts),
725
+ /** Check domain registration while preserving unknown availability and partial detail. */
726
+ domainResult: (domain, opts) => request(`/domain/${enc(domain)}`, deepQuery(opts), void 0, opts),
725
727
  asn: (asn, opts) => request(`/asn/${enc(asn)}`, void 0, void 0, opts),
726
728
  /** Look up a 2-11 digit card prefix. Keep leading zeros in the input string. */
727
729
  card: async (bin, opts) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parseapi/sdk",
3
- "version": "1.12.2",
3
+ "version": "1.12.4",
4
4
  "description": "Official ParseAPI client for Node and TypeScript. One key, minimal JSON, fast.",
5
5
  "keywords": [
6
6
  "parseapi",