@parseapi/sdk
Advanced tools
+9
-1
@@ -27,3 +27,3 @@ "use strict"; | ||
| module.exports = __toCommonJS(index_exports); | ||
| var VERSION = "0.1.3"; | ||
| var VERSION = "0.2.0"; | ||
| var DEFAULT_BASE_URL = "https://api.parseapi.com"; | ||
@@ -201,2 +201,3 @@ var DEFAULT_TIMEOUT_MS = 1e4; | ||
| iban: (iban, opts) => request(`/iban/${enc(iban)}`, { country: opts?.country }), | ||
| npi: (npi, opts) => request(`/npi/${enc(npi)}`, deepQuery(opts)), | ||
| phone: (number, opts) => request(`/phone/${enc(number)}`, { country: opts?.country, ...deepQuery(opts) }), | ||
@@ -209,2 +210,9 @@ carrier: (number, opts) => request(`/carrier/${enc(number)}`, { country: opts?.country }), | ||
| useragent: (ua, opts) => request("/useragent", deepQuery(opts), { "User-Agent": ua }), | ||
| vin: (vin, opts) => request(`/vin/${enc(vin)}`, deepQuery(opts)), | ||
| hts: Object.assign( | ||
| (code, opts) => request(`/hts/${enc(code)}`, { origin: opts?.origin, ...deepQuery(opts) }), | ||
| { | ||
| search: (q) => request("/hts", { q }) | ||
| } | ||
| ), | ||
| currency: Object.assign( | ||
@@ -211,0 +219,0 @@ (code) => request(`/currency/${enc(code)}`), |
+186
-29
@@ -111,2 +111,3 @@ /** | ||
| population: number | null; | ||
| /** Total area in km2. */ | ||
| area: number | null; | ||
@@ -145,3 +146,7 @@ timezone: string | null; | ||
| population: number | null; | ||
| /** Total area in km2 (land + water, or the official total). */ | ||
| area: number | null; | ||
| /** Land area in km2. Null when the source publishes total only. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null when the source publishes total only. */ | ||
| water_area: number | null; | ||
@@ -156,3 +161,4 @@ seat: string | null; | ||
| type: string | null; | ||
| capital: 'country' | 'state' | null; | ||
| /** What this city is the capital of: country, state, or null. */ | ||
| capital_of: 'country' | 'state' | null; | ||
| state: string | null; | ||
@@ -169,3 +175,7 @@ state_name: string | null; | ||
| population: number | null; | ||
| /** Total area in km2 (land + water, or the official total). */ | ||
| area: number | null; | ||
| /** Land area in km2. Null when the source publishes total only. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null when the source publishes total only. */ | ||
| water_area: number | null; | ||
@@ -212,3 +222,7 @@ timezone: string | null; | ||
| population: number | null; | ||
| /** Total area in km2. Null when the source has no water split. */ | ||
| area: number | null; | ||
| /** Land area in km2. Null where the source has none. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null where the source has none. */ | ||
| water_area: number | null; | ||
@@ -270,3 +284,4 @@ timezone: string | null; | ||
| consultation: string | null; | ||
| consulted: string | null; | ||
| /** Registry timestamp of this check, ISO. */ | ||
| consulted_at: string | null; | ||
| } | ||
@@ -294,13 +309,148 @@ interface Vat { | ||
| } | ||
| interface Npi { | ||
| /** Normalized 10-digit NPI. Invalid input still echoes the fold. */ | ||
| npi: string | null; | ||
| valid: boolean; | ||
| /** Exists in the CMS NPPES registry. */ | ||
| registered: boolean | null; | ||
| active: boolean | null; | ||
| /** On the OIG exclusion list. */ | ||
| excluded: boolean | null; | ||
| /** individual or organization. */ | ||
| type: string | null; | ||
| name: string | null; | ||
| first: string | null; | ||
| last: string | null; | ||
| credential: string | null; | ||
| specialty: string | null; | ||
| /** NUCC taxonomy code. */ | ||
| taxonomy: string | null; | ||
| address: string | null; | ||
| city: string | null; | ||
| state: string | null; | ||
| state_name: string | null; | ||
| postal: string | null; | ||
| country: string | null; | ||
| phone: string | null; | ||
| deep?: Deep<NpiDeep>; | ||
| } | ||
| interface NpiEnrollment { | ||
| /** part_a, part_b, practitioner, dme, order_refer, mdpp. Null when the code is unknown. */ | ||
| type: string | null; | ||
| specialty: string | null; | ||
| state: string | null; | ||
| } | ||
| interface NpiDeep { | ||
| /** In the published Medicare FFS enrollment extract. */ | ||
| medicare?: boolean | null; | ||
| /** On the CMS opt-out affidavit list. Matched by NPI only. */ | ||
| opt_out?: boolean | null; | ||
| /** Enrollment rows. [] when medicare is false. */ | ||
| enrollments?: NpiEnrollment[] | null; | ||
| } | ||
| interface HtsMeasure { | ||
| /** Chapter 99 heading, dotted (9903.01.24). */ | ||
| heading: string; | ||
| /** The measure text verbatim. */ | ||
| description: string; | ||
| /** The rate string verbatim ("The duty provided in the applicable subheading + 10%"). */ | ||
| rate: string | null; | ||
| /** Effective from, ISO YYYY-MM-DD. Null when the schedule states none. */ | ||
| from: string | null; | ||
| /** Expires, ISO YYYY-MM-DD. Null when open-ended. */ | ||
| until: string | null; | ||
| } | ||
| interface HtsDeep { | ||
| /** The origin country the measures were resolved for. */ | ||
| origin?: string | null; | ||
| /** Composed ad valorem percent. Null when the components do not compose cleanly. */ | ||
| effective_rate?: number | null; | ||
| /** Every Chapter 99 tariff measure that applies to this code from this origin. */ | ||
| measures?: HtsMeasure[] | null; | ||
| } | ||
| interface Hts { | ||
| /** Normalized code with dots (8471.30.01.00). */ | ||
| hts: string; | ||
| /** The schedule line verbatim. */ | ||
| description: string; | ||
| /** Parent descriptions from the schedule outline, outermost first. */ | ||
| lineage: string[]; | ||
| /** Units of quantity (No., kg). */ | ||
| units: string[]; | ||
| /** Column 1 general rate, verbatim. */ | ||
| general: string | null; | ||
| /** Column 1 special rate, verbatim. */ | ||
| special: string | null; | ||
| /** Column 2 rate, verbatim. */ | ||
| other: string | null; | ||
| /** The official release that answered (2026HTSRev17). */ | ||
| revision: string; | ||
| deep?: Deep<HtsDeep>; | ||
| } | ||
| interface HtsSearchHit { | ||
| hts: string; | ||
| description: string; | ||
| general: string | null; | ||
| } | ||
| interface HtsSearch { | ||
| q: string; | ||
| revision: string; | ||
| /** Up to 20 tariff lines, best match first. */ | ||
| lines: HtsSearchHit[]; | ||
| } | ||
| interface VinRecall { | ||
| /** Government campaign number. */ | ||
| campaign: string; | ||
| /** Report date, ISO YYYY-MM-DD. */ | ||
| date: string | null; | ||
| component: string | null; | ||
| /** The filed summary verbatim. */ | ||
| summary: string | null; | ||
| } | ||
| interface VinDeep { | ||
| /** Open recall campaigns for the decoded vehicle. [] when none, null when the registry did not answer. */ | ||
| recalls?: VinRecall[] | null; | ||
| } | ||
| interface Vin { | ||
| /** Normalized VIN, uppercase, no spaces. Invalid input still echoes the fold. */ | ||
| vin: string | null; | ||
| valid: boolean; | ||
| year: number | null; | ||
| make: string | null; | ||
| model: string | null; | ||
| trim: string | null; | ||
| series: string | null; | ||
| /** Body style (sedan, coupe, suv, pickup). */ | ||
| body: string | null; | ||
| /** Vehicle type (passenger car, truck, motorcycle, bus, trailer). */ | ||
| type: string | null; | ||
| doors: number | null; | ||
| cylinders: number | null; | ||
| /** Engine displacement in liters. */ | ||
| displacement: number | null; | ||
| fuel: string | null; | ||
| horsepower: number | null; | ||
| /** fwd, rwd, awd, 4wd. */ | ||
| drive: string | null; | ||
| /** automatic, manual, cvt. */ | ||
| transmission: string | null; | ||
| manufacturer: string | null; | ||
| plant_city: string | null; | ||
| plant_state: string | null; | ||
| plant_country: string | null; | ||
| /** Gross vehicle weight rating class as filed. */ | ||
| gvwr: string | null; | ||
| deep?: Deep<VinDeep>; | ||
| } | ||
| interface Phone { | ||
| phone: string | null; | ||
| valid: boolean; | ||
| /** What the numbering plan can see. Never voip (that is the carrier field's word). Present when valid. */ | ||
| type?: 'mobile' | 'landline' | 'toll_free' | 'unknown'; | ||
| /** NPA-derived state code (US/CA). Present when valid. */ | ||
| state?: string | null; | ||
| state_name?: string | null; | ||
| country: string | null; | ||
| national?: string | null; | ||
| international?: string | null; | ||
| /** What the numbering plan can see. Never voip (that is the carrier field's word). Null when invalid. */ | ||
| type: 'mobile' | 'landline' | 'toll_free' | 'unknown' | null; | ||
| /** NPA-derived state code (US/CA). */ | ||
| state: string | null; | ||
| state_name: string | null; | ||
| national: string | null; | ||
| international: string | null; | ||
| /** Always empty. The metered proves are their own endpoints: carrier, caller, hlr. */ | ||
@@ -313,12 +463,12 @@ deep?: Record<string, never>; | ||
| country: string | null; | ||
| /** The network's word, including voip. Present when valid. */ | ||
| type?: 'mobile' | 'landline' | 'voip' | 'toll_free' | 'unknown'; | ||
| /** The network's word, including voip. Null when invalid. */ | ||
| type: 'mobile' | 'landline' | 'voip' | 'toll_free' | 'unknown' | null; | ||
| /** Current carrier display name. Null when the probe had no answer. */ | ||
| carrier?: string | null; | ||
| carrier: string | null; | ||
| /** Carrier is a known burner number app. Null when carrier is unknown. */ | ||
| burner?: boolean | null; | ||
| burner: boolean | null; | ||
| /** Issuing rate-center city. */ | ||
| city?: string | null; | ||
| state?: string | null; | ||
| state_name?: string | null; | ||
| city: string | null; | ||
| state: string | null; | ||
| state_name: string | null; | ||
| } | ||
@@ -329,4 +479,4 @@ interface Caller { | ||
| country: string | null; | ||
| /** CNAM record verbatim (all-caps telco artifact). Null when no record or outside NANP. Present when valid. */ | ||
| caller?: string | null; | ||
| /** CNAM record verbatim (all-caps telco artifact). Null when no record, outside NANP, or invalid. */ | ||
| caller: string | null; | ||
| } | ||
@@ -337,16 +487,16 @@ interface Hlr { | ||
| country: string | null; | ||
| /** Assigned to a subscriber. Present when valid. */ | ||
| live?: boolean | null; | ||
| /** Assigned to a subscriber. Null when invalid. */ | ||
| live: boolean | null; | ||
| /** Handset reachable right now. Null means unconfirmed, never no. */ | ||
| connected?: boolean | null; | ||
| connected: boolean | null; | ||
| /** The six network extras fill on live HLR dips only. Null elsewhere (NANP, failover). */ | ||
| roaming?: boolean | null; | ||
| roaming_network?: string | null; | ||
| roaming: boolean | null; | ||
| roaming_network: string | null; | ||
| /** ISO2, uppercase. */ | ||
| roaming_country?: string | null; | ||
| roaming_country: string | null; | ||
| /** Current serving network name. */ | ||
| network?: string | null; | ||
| original_network?: string | null; | ||
| mcc?: string | null; | ||
| mnc?: string | null; | ||
| network: string | null; | ||
| original_network: string | null; | ||
| mcc: string | null; | ||
| mnc: string | null; | ||
| } | ||
@@ -822,2 +972,3 @@ interface MxRecord { | ||
| }) => Promise<Iban>; | ||
| npi: (npi: string, opts?: DeepOption) => Promise<Npi>; | ||
| phone: (number: string, opts?: { | ||
@@ -838,2 +989,8 @@ country?: string; | ||
| useragent: (ua: string, opts?: DeepOption) => Promise<Useragent>; | ||
| vin: (vin: string, opts?: DeepOption) => Promise<Vin>; | ||
| hts: ((code: string, opts?: { | ||
| origin?: string; | ||
| } & DeepOption) => Promise<Hts>) & { | ||
| search: (q: string) => Promise<HtsSearch>; | ||
| }; | ||
| currency: ((code: string) => Promise<Currency>) & { | ||
@@ -882,2 +1039,2 @@ rate: (base: string, quote: string, opts?: { | ||
| export { type Bloc, type BlocCountries, type BlocCountryItem, type Caller, type Carrier, type City, type CityNearby, type CityNearest, type CitySearch, type Continent, type ContinentCountries, type ContinentCountryItem, type Country, type CountryStateItem, type CountryStates, type Currency, type CurrencyRate, type DateInfo, type Deep, type District, type Domain, type DomainDeep, type DomainRegistration, type Elevation, type Email, type EmailDeep, type Emoji, type EmojiSearch, type EmojiSkin, type Hlr, type Holiday, type HolidayDate, type HolidayYear, type Iban, type Ip, type IpDeep, type Language, type Mx, type MxRecord, type Name, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type Point, type PointDeep, type Postal, type PostalDistance, type PostalDistanceEnd, type PostalNearby, type PostalNearbyItem, type State, type StateDistrictItem, type StateDistricts, type Timezone, type TimezoneConversionTarget, type TimezoneNextDst, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOsDeep, type Vat, type VatAddress, type VatDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherSource, type WeatherStation, parseAPI }; | ||
| export { type Bloc, type BlocCountries, type BlocCountryItem, type Caller, type Carrier, type City, type CityNearby, type CityNearest, type CitySearch, type Continent, type ContinentCountries, type ContinentCountryItem, type Country, type CountryStateItem, type CountryStates, type Currency, type CurrencyRate, type DateInfo, type Deep, type District, type Domain, type DomainDeep, type DomainRegistration, type Elevation, type Email, type EmailDeep, type Emoji, type EmojiSearch, type EmojiSkin, type Hlr, type Holiday, type HolidayDate, type HolidayYear, type Hts, type HtsDeep, type HtsMeasure, type HtsSearch, type HtsSearchHit, type Iban, type Ip, type IpDeep, type Language, type Mx, type MxRecord, type Name, type Npi, type NpiDeep, type NpiEnrollment, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type Point, type PointDeep, type Postal, type PostalDistance, type PostalDistanceEnd, type PostalNearby, type PostalNearbyItem, type State, type StateDistrictItem, type StateDistricts, type Timezone, type TimezoneConversionTarget, type TimezoneNextDst, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOsDeep, type Vat, type VatAddress, type VatDeep, type Vin, type VinDeep, type VinRecall, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherSource, type WeatherStation, parseAPI }; |
+186
-29
@@ -111,2 +111,3 @@ /** | ||
| population: number | null; | ||
| /** Total area in km2. */ | ||
| area: number | null; | ||
@@ -145,3 +146,7 @@ timezone: string | null; | ||
| population: number | null; | ||
| /** Total area in km2 (land + water, or the official total). */ | ||
| area: number | null; | ||
| /** Land area in km2. Null when the source publishes total only. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null when the source publishes total only. */ | ||
| water_area: number | null; | ||
@@ -156,3 +161,4 @@ seat: string | null; | ||
| type: string | null; | ||
| capital: 'country' | 'state' | null; | ||
| /** What this city is the capital of: country, state, or null. */ | ||
| capital_of: 'country' | 'state' | null; | ||
| state: string | null; | ||
@@ -169,3 +175,7 @@ state_name: string | null; | ||
| population: number | null; | ||
| /** Total area in km2 (land + water, or the official total). */ | ||
| area: number | null; | ||
| /** Land area in km2. Null when the source publishes total only. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null when the source publishes total only. */ | ||
| water_area: number | null; | ||
@@ -212,3 +222,7 @@ timezone: string | null; | ||
| population: number | null; | ||
| /** Total area in km2. Null when the source has no water split. */ | ||
| area: number | null; | ||
| /** Land area in km2. Null where the source has none. */ | ||
| land_area: number | null; | ||
| /** Water area in km2. Null where the source has none. */ | ||
| water_area: number | null; | ||
@@ -270,3 +284,4 @@ timezone: string | null; | ||
| consultation: string | null; | ||
| consulted: string | null; | ||
| /** Registry timestamp of this check, ISO. */ | ||
| consulted_at: string | null; | ||
| } | ||
@@ -294,13 +309,148 @@ interface Vat { | ||
| } | ||
| interface Npi { | ||
| /** Normalized 10-digit NPI. Invalid input still echoes the fold. */ | ||
| npi: string | null; | ||
| valid: boolean; | ||
| /** Exists in the CMS NPPES registry. */ | ||
| registered: boolean | null; | ||
| active: boolean | null; | ||
| /** On the OIG exclusion list. */ | ||
| excluded: boolean | null; | ||
| /** individual or organization. */ | ||
| type: string | null; | ||
| name: string | null; | ||
| first: string | null; | ||
| last: string | null; | ||
| credential: string | null; | ||
| specialty: string | null; | ||
| /** NUCC taxonomy code. */ | ||
| taxonomy: string | null; | ||
| address: string | null; | ||
| city: string | null; | ||
| state: string | null; | ||
| state_name: string | null; | ||
| postal: string | null; | ||
| country: string | null; | ||
| phone: string | null; | ||
| deep?: Deep<NpiDeep>; | ||
| } | ||
| interface NpiEnrollment { | ||
| /** part_a, part_b, practitioner, dme, order_refer, mdpp. Null when the code is unknown. */ | ||
| type: string | null; | ||
| specialty: string | null; | ||
| state: string | null; | ||
| } | ||
| interface NpiDeep { | ||
| /** In the published Medicare FFS enrollment extract. */ | ||
| medicare?: boolean | null; | ||
| /** On the CMS opt-out affidavit list. Matched by NPI only. */ | ||
| opt_out?: boolean | null; | ||
| /** Enrollment rows. [] when medicare is false. */ | ||
| enrollments?: NpiEnrollment[] | null; | ||
| } | ||
| interface HtsMeasure { | ||
| /** Chapter 99 heading, dotted (9903.01.24). */ | ||
| heading: string; | ||
| /** The measure text verbatim. */ | ||
| description: string; | ||
| /** The rate string verbatim ("The duty provided in the applicable subheading + 10%"). */ | ||
| rate: string | null; | ||
| /** Effective from, ISO YYYY-MM-DD. Null when the schedule states none. */ | ||
| from: string | null; | ||
| /** Expires, ISO YYYY-MM-DD. Null when open-ended. */ | ||
| until: string | null; | ||
| } | ||
| interface HtsDeep { | ||
| /** The origin country the measures were resolved for. */ | ||
| origin?: string | null; | ||
| /** Composed ad valorem percent. Null when the components do not compose cleanly. */ | ||
| effective_rate?: number | null; | ||
| /** Every Chapter 99 tariff measure that applies to this code from this origin. */ | ||
| measures?: HtsMeasure[] | null; | ||
| } | ||
| interface Hts { | ||
| /** Normalized code with dots (8471.30.01.00). */ | ||
| hts: string; | ||
| /** The schedule line verbatim. */ | ||
| description: string; | ||
| /** Parent descriptions from the schedule outline, outermost first. */ | ||
| lineage: string[]; | ||
| /** Units of quantity (No., kg). */ | ||
| units: string[]; | ||
| /** Column 1 general rate, verbatim. */ | ||
| general: string | null; | ||
| /** Column 1 special rate, verbatim. */ | ||
| special: string | null; | ||
| /** Column 2 rate, verbatim. */ | ||
| other: string | null; | ||
| /** The official release that answered (2026HTSRev17). */ | ||
| revision: string; | ||
| deep?: Deep<HtsDeep>; | ||
| } | ||
| interface HtsSearchHit { | ||
| hts: string; | ||
| description: string; | ||
| general: string | null; | ||
| } | ||
| interface HtsSearch { | ||
| q: string; | ||
| revision: string; | ||
| /** Up to 20 tariff lines, best match first. */ | ||
| lines: HtsSearchHit[]; | ||
| } | ||
| interface VinRecall { | ||
| /** Government campaign number. */ | ||
| campaign: string; | ||
| /** Report date, ISO YYYY-MM-DD. */ | ||
| date: string | null; | ||
| component: string | null; | ||
| /** The filed summary verbatim. */ | ||
| summary: string | null; | ||
| } | ||
| interface VinDeep { | ||
| /** Open recall campaigns for the decoded vehicle. [] when none, null when the registry did not answer. */ | ||
| recalls?: VinRecall[] | null; | ||
| } | ||
| interface Vin { | ||
| /** Normalized VIN, uppercase, no spaces. Invalid input still echoes the fold. */ | ||
| vin: string | null; | ||
| valid: boolean; | ||
| year: number | null; | ||
| make: string | null; | ||
| model: string | null; | ||
| trim: string | null; | ||
| series: string | null; | ||
| /** Body style (sedan, coupe, suv, pickup). */ | ||
| body: string | null; | ||
| /** Vehicle type (passenger car, truck, motorcycle, bus, trailer). */ | ||
| type: string | null; | ||
| doors: number | null; | ||
| cylinders: number | null; | ||
| /** Engine displacement in liters. */ | ||
| displacement: number | null; | ||
| fuel: string | null; | ||
| horsepower: number | null; | ||
| /** fwd, rwd, awd, 4wd. */ | ||
| drive: string | null; | ||
| /** automatic, manual, cvt. */ | ||
| transmission: string | null; | ||
| manufacturer: string | null; | ||
| plant_city: string | null; | ||
| plant_state: string | null; | ||
| plant_country: string | null; | ||
| /** Gross vehicle weight rating class as filed. */ | ||
| gvwr: string | null; | ||
| deep?: Deep<VinDeep>; | ||
| } | ||
| interface Phone { | ||
| phone: string | null; | ||
| valid: boolean; | ||
| /** What the numbering plan can see. Never voip (that is the carrier field's word). Present when valid. */ | ||
| type?: 'mobile' | 'landline' | 'toll_free' | 'unknown'; | ||
| /** NPA-derived state code (US/CA). Present when valid. */ | ||
| state?: string | null; | ||
| state_name?: string | null; | ||
| country: string | null; | ||
| national?: string | null; | ||
| international?: string | null; | ||
| /** What the numbering plan can see. Never voip (that is the carrier field's word). Null when invalid. */ | ||
| type: 'mobile' | 'landline' | 'toll_free' | 'unknown' | null; | ||
| /** NPA-derived state code (US/CA). */ | ||
| state: string | null; | ||
| state_name: string | null; | ||
| national: string | null; | ||
| international: string | null; | ||
| /** Always empty. The metered proves are their own endpoints: carrier, caller, hlr. */ | ||
@@ -313,12 +463,12 @@ deep?: Record<string, never>; | ||
| country: string | null; | ||
| /** The network's word, including voip. Present when valid. */ | ||
| type?: 'mobile' | 'landline' | 'voip' | 'toll_free' | 'unknown'; | ||
| /** The network's word, including voip. Null when invalid. */ | ||
| type: 'mobile' | 'landline' | 'voip' | 'toll_free' | 'unknown' | null; | ||
| /** Current carrier display name. Null when the probe had no answer. */ | ||
| carrier?: string | null; | ||
| carrier: string | null; | ||
| /** Carrier is a known burner number app. Null when carrier is unknown. */ | ||
| burner?: boolean | null; | ||
| burner: boolean | null; | ||
| /** Issuing rate-center city. */ | ||
| city?: string | null; | ||
| state?: string | null; | ||
| state_name?: string | null; | ||
| city: string | null; | ||
| state: string | null; | ||
| state_name: string | null; | ||
| } | ||
@@ -329,4 +479,4 @@ interface Caller { | ||
| country: string | null; | ||
| /** CNAM record verbatim (all-caps telco artifact). Null when no record or outside NANP. Present when valid. */ | ||
| caller?: string | null; | ||
| /** CNAM record verbatim (all-caps telco artifact). Null when no record, outside NANP, or invalid. */ | ||
| caller: string | null; | ||
| } | ||
@@ -337,16 +487,16 @@ interface Hlr { | ||
| country: string | null; | ||
| /** Assigned to a subscriber. Present when valid. */ | ||
| live?: boolean | null; | ||
| /** Assigned to a subscriber. Null when invalid. */ | ||
| live: boolean | null; | ||
| /** Handset reachable right now. Null means unconfirmed, never no. */ | ||
| connected?: boolean | null; | ||
| connected: boolean | null; | ||
| /** The six network extras fill on live HLR dips only. Null elsewhere (NANP, failover). */ | ||
| roaming?: boolean | null; | ||
| roaming_network?: string | null; | ||
| roaming: boolean | null; | ||
| roaming_network: string | null; | ||
| /** ISO2, uppercase. */ | ||
| roaming_country?: string | null; | ||
| roaming_country: string | null; | ||
| /** Current serving network name. */ | ||
| network?: string | null; | ||
| original_network?: string | null; | ||
| mcc?: string | null; | ||
| mnc?: string | null; | ||
| network: string | null; | ||
| original_network: string | null; | ||
| mcc: string | null; | ||
| mnc: string | null; | ||
| } | ||
@@ -822,2 +972,3 @@ interface MxRecord { | ||
| }) => Promise<Iban>; | ||
| npi: (npi: string, opts?: DeepOption) => Promise<Npi>; | ||
| phone: (number: string, opts?: { | ||
@@ -838,2 +989,8 @@ country?: string; | ||
| useragent: (ua: string, opts?: DeepOption) => Promise<Useragent>; | ||
| vin: (vin: string, opts?: DeepOption) => Promise<Vin>; | ||
| hts: ((code: string, opts?: { | ||
| origin?: string; | ||
| } & DeepOption) => Promise<Hts>) & { | ||
| search: (q: string) => Promise<HtsSearch>; | ||
| }; | ||
| currency: ((code: string) => Promise<Currency>) & { | ||
@@ -882,2 +1039,2 @@ rate: (base: string, quote: string, opts?: { | ||
| export { type Bloc, type BlocCountries, type BlocCountryItem, type Caller, type Carrier, type City, type CityNearby, type CityNearest, type CitySearch, type Continent, type ContinentCountries, type ContinentCountryItem, type Country, type CountryStateItem, type CountryStates, type Currency, type CurrencyRate, type DateInfo, type Deep, type District, type Domain, type DomainDeep, type DomainRegistration, type Elevation, type Email, type EmailDeep, type Emoji, type EmojiSearch, type EmojiSkin, type Hlr, type Holiday, type HolidayDate, type HolidayYear, type Iban, type Ip, type IpDeep, type Language, type Mx, type MxRecord, type Name, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type Point, type PointDeep, type Postal, type PostalDistance, type PostalDistanceEnd, type PostalNearby, type PostalNearbyItem, type State, type StateDistrictItem, type StateDistricts, type Timezone, type TimezoneConversionTarget, type TimezoneNextDst, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOsDeep, type Vat, type VatAddress, type VatDeep, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherSource, type WeatherStation, parseAPI }; | ||
| export { type Bloc, type BlocCountries, type BlocCountryItem, type Caller, type Carrier, type City, type CityNearby, type CityNearest, type CitySearch, type Continent, type ContinentCountries, type ContinentCountryItem, type Country, type CountryStateItem, type CountryStates, type Currency, type CurrencyRate, type DateInfo, type Deep, type District, type Domain, type DomainDeep, type DomainRegistration, type Elevation, type Email, type EmailDeep, type Emoji, type EmojiSearch, type EmojiSkin, type Hlr, type Holiday, type HolidayDate, type HolidayYear, type Hts, type HtsDeep, type HtsMeasure, type HtsSearch, type HtsSearchHit, type Iban, type Ip, type IpDeep, type Language, type Mx, type MxRecord, type Name, type Npi, type NpiDeep, type NpiEnrollment, type ParseAPIClient, ParseAPIError, type ParseAPIOptions, type Phone, type Point, type PointDeep, type Postal, type PostalDistance, type PostalDistanceEnd, type PostalNearby, type PostalNearbyItem, type State, type StateDistrictItem, type StateDistricts, type Timezone, type TimezoneConversionTarget, type TimezoneNextDst, type Useragent, type UseragentBrowserBrand, type UseragentBrowserDeep, type UseragentDeep, type UseragentDeviceDeep, type UseragentEngineDeep, type UseragentOsDeep, type Vat, type VatAddress, type VatDeep, type Vin, type VinDeep, type VinRecall, type Weather, type WeatherAir, type WeatherAlert, type WeatherCurrent, type WeatherDay, type WeatherDeep, type WeatherForecastPeriod, type WeatherHistory, type WeatherHour, type WeatherMinute, type WeatherSource, type WeatherStation, parseAPI }; |
+9
-1
| // src/index.ts | ||
| var VERSION = "0.1.3"; | ||
| var VERSION = "0.2.0"; | ||
| var DEFAULT_BASE_URL = "https://api.parseapi.com"; | ||
@@ -175,2 +175,3 @@ var DEFAULT_TIMEOUT_MS = 1e4; | ||
| iban: (iban, opts) => request(`/iban/${enc(iban)}`, { country: opts?.country }), | ||
| npi: (npi, opts) => request(`/npi/${enc(npi)}`, deepQuery(opts)), | ||
| phone: (number, opts) => request(`/phone/${enc(number)}`, { country: opts?.country, ...deepQuery(opts) }), | ||
@@ -183,2 +184,9 @@ carrier: (number, opts) => request(`/carrier/${enc(number)}`, { country: opts?.country }), | ||
| useragent: (ua, opts) => request("/useragent", deepQuery(opts), { "User-Agent": ua }), | ||
| vin: (vin, opts) => request(`/vin/${enc(vin)}`, deepQuery(opts)), | ||
| hts: Object.assign( | ||
| (code, opts) => request(`/hts/${enc(code)}`, { origin: opts?.origin, ...deepQuery(opts) }), | ||
| { | ||
| search: (q) => request("/hts", { q }) | ||
| } | ||
| ), | ||
| currency: Object.assign( | ||
@@ -185,0 +193,0 @@ (code) => request(`/currency/${enc(code)}`), |
+1
-1
| { | ||
| "name": "@parseapi/sdk", | ||
| "version": "0.1.3", | ||
| "version": "0.2.0", | ||
| "description": "Official parseAPI client for Node and TypeScript. One key, minimal JSON, fast.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
+2
-0
@@ -28,2 +28,3 @@ # @parseapi/sdk | ||
| await parse.iban('DE89370400440532013000'); | ||
| await parse.npi('1881018208'); | ||
| await parse.phone('+14155552671'); | ||
@@ -65,2 +66,3 @@ await parse.carrier('+14155552671'); | ||
| await parse.useragent(uaString); | ||
| await parse.vin('1HGCM82633A004352'); | ||
| await parse.emoji('rocket'); | ||
@@ -67,0 +69,0 @@ await parse.emoji.search('fire'); |
85729
16.33%1511
13.01%111
1.83%