internetdata-web 1.3.2 → 1.3.3

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
@@ -48,7 +48,7 @@ console.log(result.company.name); // who the address belongs to
48
48
 
49
49
  ### With an API key
50
50
 
51
- Where the key stays private (see above), every paid plan answers every field: `is_vpn`, `is_hosting`, `is_cdn` and the four proxy flags as well, city-level location, the whois records and the detail behind each flag. The plans differ only in how many lookups they include, and a free account tries every field, 100 lookups a day. Create a key in the [console](https://app.internetdata.io), then pass it in:
51
+ Where the key stays private (see above), every paid plan answers every field: `is_vpn`, `is_hosting`, `is_cdn` and the four proxy flags as well, city-level location, the whois records and the detail behind each flag. The plans differ only in how many lookups they include, and a free account tries every field. Create a key in the [console](https://app.internetdata.io), then pass it in:
52
52
 
53
53
  ```js
54
54
  const client = new InternetData({ apiKey: 'your-api-key' });
@@ -141,7 +141,7 @@ const client = new InternetData({ cache: { max: 50_000, ttlMs: 6 * 60 * 60 * 100
141
141
  const clientNoCache = new InternetData({ cache: false });
142
142
  ```
143
143
 
144
- An answer with `trialExpired` or `capReached` true is cached for a minute at most, in memory and in a `store`, so a new day's trial or a raised cap reaches you within a minute.
144
+ An answer with `trialExpired` or `capReached` true is cached for a minute at most, in memory and in a `store`, so a renewed trial or a raised cap reaches you within a minute.
145
145
 
146
146
  ### Keeping answers across a reload
147
147
 
@@ -263,12 +263,12 @@ The library is ES2022 and needs only what a browser has, `fetch` and, for PKCE,
263
263
 
264
264
  ### Absent is not false
265
265
 
266
- Unlimited leaves out `isVpn`, `isHosting`, `isCdn` and the four proxy flags, the detail behind them, and the paid members inside `location`, `asn`, `company` and `abuse`, such as `location.city`; a free-plan key's answer carries `trialExpired`, true once its daily trial is spent. A paid key's carries `capReached`, true once its organization's overage cap is reached, when the answer has Unlimited's fields and isn't billed. A field your key does not include is `undefined`, which means "not in your plan" rather than "checked, and no".
266
+ Unlimited leaves out `isVpn`, `isHosting`, `isCdn` and the four proxy flags, the detail behind them, and the paid members inside `location`, `asn`, `company` and `abuse`, such as `location.city`; a free-plan key's answer carries `trialExpired`, true once its trial is spent. A paid key's carries `capReached`, true once its organization's overage cap is reached, when the answer has Unlimited's fields and isn't billed. A field your key does not include is `undefined`, which means "not in your plan" rather than "checked, and no".
267
267
 
268
268
  ```js
269
269
  result.isVpn ?? false // when you only want the flag
270
270
  result.isVpn === undefined // on Unlimited: not in your plan
271
- result.trialExpired === true // a free-plan key's daily trial is spent
271
+ result.trialExpired === true // a free-plan key's trial is spent
272
272
  result.capReached === true // a paid key is past its overage cap
273
273
  ```
274
274
 
package/dist/client.d.ts CHANGED
@@ -21,8 +21,8 @@ export interface CacheOptions {
21
21
  }
22
22
  export interface Options {
23
23
  /**
24
- * Your API key. Without one a lookup is on Unlimited, the free plan, limited
25
- * per address per minute, and no `Authorization` header is sent at all. A
24
+ * Your API key. Without one a lookup is on Unlimited, the free plan, with no
25
+ * daily or monthly cap, and no `Authorization` header is sent at all. A
26
26
  * batch needs a key on a paid plan.
27
27
  * A key in a web page is readable by anyone who opens the page.
28
28
  */
@@ -271,7 +271,7 @@ export type LookupResponse = {
271
271
  rwhois?: Rwhois;
272
272
  hosted_domains?: HostedDomains;
273
273
  /**
274
- * On every answer to a key on the free plan, and on no other: `false` while the day's trial of every field lasts, `true` once the answer has Unlimited's fields.
274
+ * On every answer to a key on the free plan, and on no other: `false` while its organization's trial of every field lasts, `true` once the answer has Unlimited's fields.
275
275
  */
276
276
  trial_expired?: boolean;
277
277
  /**
@@ -693,11 +693,11 @@ export type Asn = {
693
693
  */
694
694
  prefix: string;
695
695
  /**
696
- * The country its registry assigned it to. Paid plans and the trial.
696
+ * The country its registry assigned it to.
697
697
  */
698
698
  country?: string;
699
699
  /**
700
- * The announcement's RPKI status. Paid plans and the trial.
700
+ * The announcement's RPKI status.
701
701
  */
702
702
  rpki_status?: string;
703
703
  };
@@ -955,7 +955,7 @@ export type AsnLookupResponse = {
955
955
  downstreams?: Array<number>;
956
956
  hosted_domains?: AsnHostedDomains;
957
957
  /**
958
- * On every answer to a key on the free plan, and on no other: `false` while the day's trial of every field lasts, `true` once the answer has Unlimited's fields.
958
+ * On every answer to a key on the free plan, and on no other: `false` while its organization's trial of every field lasts, `true` once the answer has Unlimited's fields.
959
959
  */
960
960
  trial_expired?: boolean;
961
961
  /**
@@ -1036,7 +1036,7 @@ export type DomainLookupResponse = {
1036
1036
  */
1037
1037
  disposable?: DisposableDetail;
1038
1038
  /**
1039
- * On every answer to a key on the free plan, and on no other: `false` while the day's trial of every field lasts, `true` once the answer has Unlimited's fields.
1039
+ * On every answer to a key on the free plan, and on no other: `false` while its organization's trial of every field lasts, `true` once the answer has Unlimited's fields.
1040
1040
  */
1041
1041
  trial_expired?: boolean;
1042
1042
  /**
@@ -1233,8 +1233,8 @@ export type EntitlementPlan = {
1233
1233
  /**
1234
1234
  * The plan the organization is on, as an identifier that is never
1235
1235
  * renamed or reused: `free` for the free plan, or a paid plan's key.
1236
- * Compare against it and show `name`. On `free`, usage counts the
1237
- * day's lookups answered with every field, its daily trial.
1236
+ * Compare against it and show `name`. On `free`, usage counts its
1237
+ * trial, the lookups answered with every field.
1238
1238
  *
1239
1239
  */
1240
1240
  key: string;
@@ -1376,9 +1376,9 @@ export type LookupIpErrors = {
1376
1376
  */
1377
1377
  403: LookupError;
1378
1378
  /**
1379
- * A rate limit, always with `Retry-After`: this API protecting itself, or Unlimited's
1380
- * per-minute limit. A paid plan's overage cap is never a `429`: it answers `200` with
1381
- * Unlimited's fields and `cap_reached` `true`.
1379
+ * A rate limit, always with `Retry-After`: this API protecting itself, or a burst of Unlimited
1380
+ * lookups. A paid plan's overage cap is never a `429`: it answers `200` with Unlimited's
1381
+ * fields and `cap_reached` `true`.
1382
1382
  *
1383
1383
  */
1384
1384
  429: LookupError;
@@ -1413,9 +1413,9 @@ export type LookupMyIpErrors = {
1413
1413
  */
1414
1414
  403: LookupError;
1415
1415
  /**
1416
- * A rate limit, always with `Retry-After`: this API protecting itself, or Unlimited's
1417
- * per-minute limit. A paid plan's overage cap is never a `429`: it answers `200` with
1418
- * Unlimited's fields and `cap_reached` `true`.
1416
+ * A rate limit, always with `Retry-After`: this API protecting itself, or a burst of Unlimited
1417
+ * lookups. A paid plan's overage cap is never a `429`: it answers `200` with Unlimited's
1418
+ * fields and `cap_reached` `true`.
1419
1419
  *
1420
1420
  */
1421
1421
  429: LookupError;
@@ -1459,9 +1459,9 @@ export type LookupAsnErrors = {
1459
1459
  */
1460
1460
  403: LookupError;
1461
1461
  /**
1462
- * A rate limit, always with `Retry-After`: this API protecting itself, or Unlimited's
1463
- * per-minute limit. A paid plan's overage cap is never a `429`: it answers `200` with
1464
- * Unlimited's fields and `cap_reached` `true`.
1462
+ * A rate limit, always with `Retry-After`: this API protecting itself, or a burst of Unlimited
1463
+ * lookups. A paid plan's overage cap is never a `429`: it answers `200` with Unlimited's
1464
+ * fields and `cap_reached` `true`.
1465
1465
  *
1466
1466
  */
1467
1467
  429: LookupError;
@@ -1505,9 +1505,9 @@ export type LookupDomainErrors = {
1505
1505
  */
1506
1506
  403: LookupError;
1507
1507
  /**
1508
- * A rate limit, always with `Retry-After`: this API protecting itself, or Unlimited's
1509
- * per-minute limit. A paid plan's overage cap is never a `429`: it answers `200` with
1510
- * Unlimited's fields and `cap_reached` `true`.
1508
+ * A rate limit, always with `Retry-After`: this API protecting itself, or a burst of Unlimited
1509
+ * lookups. A paid plan's overage cap is never a `429`: it answers `200` with Unlimited's
1510
+ * fields and `cap_reached` `true`.
1511
1511
  *
1512
1512
  */
1513
1513
  429: LookupError;
package/dist/types.d.ts CHANGED
@@ -36,8 +36,8 @@ export interface Result {
36
36
  isDnsResolver: boolean;
37
37
  isBittorrent: boolean;
38
38
  /**
39
- * On answers to a key on the free plan only: `false` while the day's trial of
40
- * every field lasts, `true` once the answer has Unlimited's.
39
+ * On answers to a key on the free plan only: `false` while its organization's
40
+ * trial of every field lasts, `true` once the answer has Unlimited's.
41
41
  */
42
42
  trialExpired?: boolean;
43
43
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "internetdata-web",
3
- "version": "1.3.2",
3
+ "version": "1.3.3",
4
4
  "description": "Official browser client library for the InternetData API. Look up IP addresses, ASNs and domains from a page or a browser extension.",
5
5
  "type": "module",
6
6
  "license": "MIT",