@internetdata/internetdata 2.17.0 → 2.19.0
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 +24 -8
- package/dist/client.d.ts +35 -15
- package/dist/client.js +98 -24
- package/dist/client.js.map +1 -1
- package/dist/generated/types.gen.d.ts +97 -92
- package/dist/generated/version.d.ts +1 -1
- package/dist/generated/version.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/middleware/condition.d.ts +1 -1
- package/dist/middleware/condition.js +11 -3
- package/dist/middleware/condition.js.map +1 -1
- package/dist/middleware/core.d.ts +21 -3
- package/dist/middleware/core.js +31 -6
- package/dist/middleware/core.js.map +1 -1
- package/dist/middleware/index.d.ts +1 -1
- package/dist/shapes.d.ts +4 -2
- package/dist/shapes.js +23 -15
- package/dist/shapes.js.map +1 -1
- package/dist/types.d.ts +27 -7
- package/dist/types.js +14 -1
- package/dist/types.js.map +1 -1
- package/package.json +3 -3
|
@@ -537,7 +537,7 @@ export type LookupResponse = {
|
|
|
537
537
|
*/
|
|
538
538
|
is_bogon: boolean;
|
|
539
539
|
/**
|
|
540
|
-
* In VPN IP: a VPN service's server.
|
|
540
|
+
* In VPN IP: a VPN service's server. On a paid plan or the trial.
|
|
541
541
|
*/
|
|
542
542
|
is_vpn?: boolean;
|
|
543
543
|
/**
|
|
@@ -549,67 +549,67 @@ export type LookupResponse = {
|
|
|
549
549
|
*/
|
|
550
550
|
is_relay: boolean;
|
|
551
551
|
/**
|
|
552
|
-
* In Residential Proxy IP's 90-day window: a residential proxy exit.
|
|
552
|
+
* In Residential Proxy IP's 90-day window: a residential proxy exit. On a paid plan or the trial.
|
|
553
553
|
*/
|
|
554
554
|
is_resproxy?: boolean;
|
|
555
555
|
/**
|
|
556
|
-
* In Datacenter Proxy IP's 90-day window.
|
|
556
|
+
* In Datacenter Proxy IP's 90-day window. On a paid plan or the trial.
|
|
557
557
|
*/
|
|
558
558
|
is_dcproxy?: boolean;
|
|
559
559
|
/**
|
|
560
|
-
* In Mobile Proxy IP's 90-day window.
|
|
560
|
+
* In Mobile Proxy IP's 90-day window. On a paid plan or the trial.
|
|
561
561
|
*/
|
|
562
562
|
is_mobproxy?: boolean;
|
|
563
563
|
/**
|
|
564
|
-
* In Public Proxy IP: a public proxy listens here, or its traffic left from here.
|
|
564
|
+
* In Public Proxy IP: a public proxy listens here, or its traffic left from here. On a paid plan or the trial.
|
|
565
565
|
*/
|
|
566
566
|
is_pubproxy?: boolean;
|
|
567
567
|
/**
|
|
568
|
-
* In Hosting IP: a hosting or cloud network.
|
|
568
|
+
* In Hosting IP: a hosting or cloud network. On a paid plan or the trial.
|
|
569
569
|
*/
|
|
570
570
|
is_hosting?: boolean;
|
|
571
571
|
/**
|
|
572
|
-
* In CDN IP: a content delivery network.
|
|
572
|
+
* In CDN IP: a content delivery network. On a paid plan or the trial.
|
|
573
573
|
*/
|
|
574
574
|
is_cdn?: boolean;
|
|
575
575
|
/**
|
|
576
|
-
* In Bot IP: an automated client's address, such as a search engine's or an AI company's crawler, an uptime monitor, an internet scanner or a webhook sender. `bot` says whose, what it does and whether its operator vouches for the address.
|
|
576
|
+
* In Bot IP: an automated client's address, such as a search engine's or an AI company's crawler, an uptime monitor, an internet scanner or a webhook sender. `bot` says whose, what it does and whether its operator vouches for the address. On a paid plan or the trial.
|
|
577
577
|
*/
|
|
578
|
-
is_bot
|
|
578
|
+
is_bot?: boolean;
|
|
579
579
|
/**
|
|
580
580
|
* In Anycast IP: announced from many places at once.
|
|
581
581
|
*/
|
|
582
582
|
is_anycast: boolean;
|
|
583
583
|
/**
|
|
584
|
-
* In Carrier IP: a mobile carrier's address space.
|
|
584
|
+
* In Carrier IP: a mobile carrier's address space. On a paid plan or the trial.
|
|
585
585
|
*/
|
|
586
|
-
is_carrier
|
|
586
|
+
is_carrier?: boolean;
|
|
587
587
|
/**
|
|
588
|
-
* In Satellite IP: a satellite operator's address space.
|
|
588
|
+
* In Satellite IP: a satellite operator's address space. On a paid plan or the trial.
|
|
589
589
|
*/
|
|
590
|
-
is_satellite
|
|
590
|
+
is_satellite?: boolean;
|
|
591
591
|
/**
|
|
592
|
-
* In SSH IP: an SSH server answered here.
|
|
592
|
+
* In SSH IP: an SSH server answered here. On a paid plan or the trial.
|
|
593
593
|
*/
|
|
594
|
-
is_ssh
|
|
594
|
+
is_ssh?: boolean;
|
|
595
595
|
/**
|
|
596
|
-
* In SMTP IP: a mail server answered here.
|
|
596
|
+
* In SMTP IP: a mail server answered here. On a paid plan or the trial.
|
|
597
597
|
*/
|
|
598
|
-
is_smtp
|
|
598
|
+
is_smtp?: boolean;
|
|
599
599
|
/**
|
|
600
|
-
* In Web IP: a web server answered here on port 80 or 443.
|
|
600
|
+
* In Web IP: a web server answered here on port 80 or 443. On a paid plan or the trial.
|
|
601
601
|
*/
|
|
602
|
-
is_web
|
|
602
|
+
is_web?: boolean;
|
|
603
603
|
/**
|
|
604
|
-
* In DNS Resolver IP: an open DNS resolver answered here.
|
|
604
|
+
* In DNS Resolver IP: an open DNS resolver answered here. On a paid plan or the trial.
|
|
605
605
|
*/
|
|
606
|
-
is_dns_resolver
|
|
606
|
+
is_dns_resolver?: boolean;
|
|
607
607
|
/**
|
|
608
|
-
* In BitTorrent IP: a BitTorrent client was seen here in the last 90 days.
|
|
608
|
+
* In BitTorrent IP: a BitTorrent client was seen here in the last 90 days. On a paid plan or the trial.
|
|
609
609
|
*/
|
|
610
|
-
is_bittorrent
|
|
610
|
+
is_bittorrent?: boolean;
|
|
611
611
|
/**
|
|
612
|
-
* VPN IP's row, `{}` when `is_vpn` is false.
|
|
612
|
+
* VPN IP's row, `{}` when `is_vpn` is false. On a paid plan or the trial.
|
|
613
613
|
*/
|
|
614
614
|
vpn?: ClassDetail;
|
|
615
615
|
/**
|
|
@@ -621,59 +621,59 @@ export type LookupResponse = {
|
|
|
621
621
|
*/
|
|
622
622
|
relay: ClassDetail;
|
|
623
623
|
/**
|
|
624
|
-
* `{}` when `is_resproxy` is false.
|
|
624
|
+
* `{}` when `is_resproxy` is false. On a paid plan or the trial.
|
|
625
625
|
*/
|
|
626
626
|
resproxy?: ProxyDetail;
|
|
627
627
|
/**
|
|
628
|
-
* `{}` when `is_dcproxy` is false.
|
|
628
|
+
* `{}` when `is_dcproxy` is false. On a paid plan or the trial.
|
|
629
629
|
*/
|
|
630
630
|
dcproxy?: ProxyDetail;
|
|
631
631
|
/**
|
|
632
|
-
* `{}` when `is_mobproxy` is false.
|
|
632
|
+
* `{}` when `is_mobproxy` is false. On a paid plan or the trial.
|
|
633
633
|
*/
|
|
634
634
|
mobproxy?: ProxyDetail;
|
|
635
635
|
/**
|
|
636
|
-
* `{}` when `is_pubproxy` is false.
|
|
636
|
+
* `{}` when `is_pubproxy` is false. On a paid plan or the trial.
|
|
637
637
|
*/
|
|
638
638
|
pubproxy?: PubproxyDetail;
|
|
639
639
|
/**
|
|
640
|
-
* `{}` when `is_hosting` is false.
|
|
640
|
+
* `{}` when `is_hosting` is false. On a paid plan or the trial.
|
|
641
641
|
*/
|
|
642
642
|
hosting?: ClassDetail;
|
|
643
643
|
/**
|
|
644
|
-
* `{}` when `is_cdn` is false.
|
|
644
|
+
* `{}` when `is_cdn` is false. On a paid plan or the trial.
|
|
645
645
|
*/
|
|
646
646
|
cdn?: ClassDetail;
|
|
647
647
|
/**
|
|
648
|
-
* `{}` when `is_bot` is false.
|
|
648
|
+
* `{}` when `is_bot` is false. On a paid plan or the trial.
|
|
649
649
|
*/
|
|
650
650
|
bot?: BotDetail;
|
|
651
651
|
/**
|
|
652
|
-
* `{}` when `is_carrier` is false.
|
|
652
|
+
* `{}` when `is_carrier` is false. On a paid plan or the trial.
|
|
653
653
|
*/
|
|
654
654
|
carrier?: CarrierDetail;
|
|
655
655
|
/**
|
|
656
|
-
* `{}` when `is_satellite` is false.
|
|
656
|
+
* `{}` when `is_satellite` is false. On a paid plan or the trial.
|
|
657
657
|
*/
|
|
658
658
|
satellite?: SatelliteDetail;
|
|
659
659
|
/**
|
|
660
|
-
* `{}` when `is_ssh` is false.
|
|
660
|
+
* `{}` when `is_ssh` is false. On a paid plan or the trial.
|
|
661
661
|
*/
|
|
662
662
|
ssh?: SshDetail;
|
|
663
663
|
/**
|
|
664
|
-
* `{}` when `is_smtp` is false.
|
|
664
|
+
* `{}` when `is_smtp` is false. On a paid plan or the trial.
|
|
665
665
|
*/
|
|
666
666
|
smtp?: SmtpDetail;
|
|
667
667
|
/**
|
|
668
|
-
* A row per port that answered, lowest first; `[]` when `is_web` is false.
|
|
668
|
+
* A row per port that answered, lowest first; `[]` when `is_web` is false. On a paid plan or the trial.
|
|
669
669
|
*/
|
|
670
670
|
web?: Array<WebDetail>;
|
|
671
671
|
/**
|
|
672
|
-
* `{}` when `is_dns_resolver` is false.
|
|
672
|
+
* `{}` when `is_dns_resolver` is false. On a paid plan or the trial.
|
|
673
673
|
*/
|
|
674
674
|
dns_resolver?: DnsResolverDetail;
|
|
675
675
|
/**
|
|
676
|
-
* `{}` when `is_bittorrent` is false.
|
|
676
|
+
* `{}` when `is_bittorrent` is false. On a paid plan or the trial.
|
|
677
677
|
*/
|
|
678
678
|
bittorrent?: BitTorrentDetail;
|
|
679
679
|
location: Location;
|
|
@@ -1105,43 +1105,43 @@ export type Location = {
|
|
|
1105
1105
|
*/
|
|
1106
1106
|
flag_unicode: string;
|
|
1107
1107
|
/**
|
|
1108
|
-
* Region (state or province).
|
|
1108
|
+
* Region (state or province). On a paid plan or the trial.
|
|
1109
1109
|
*/
|
|
1110
1110
|
region?: string;
|
|
1111
1111
|
/**
|
|
1112
|
-
* ISO 3166-2 region code.
|
|
1112
|
+
* ISO 3166-2 region code. On a paid plan or the trial.
|
|
1113
1113
|
*/
|
|
1114
1114
|
region_code?: string;
|
|
1115
1115
|
/**
|
|
1116
|
-
* City.
|
|
1116
|
+
* City. On a paid plan or the trial.
|
|
1117
1117
|
*/
|
|
1118
1118
|
city?: string;
|
|
1119
1119
|
/**
|
|
1120
|
-
* Postal code.
|
|
1120
|
+
* Postal code. On a paid plan or the trial.
|
|
1121
1121
|
*/
|
|
1122
1122
|
postal_code?: string;
|
|
1123
1123
|
/**
|
|
1124
|
-
* Latitude of the city.
|
|
1124
|
+
* Latitude of the city. On a paid plan or the trial.
|
|
1125
1125
|
*/
|
|
1126
1126
|
latitude?: number;
|
|
1127
1127
|
/**
|
|
1128
|
-
* Longitude of the city.
|
|
1128
|
+
* Longitude of the city. On a paid plan or the trial.
|
|
1129
1129
|
*/
|
|
1130
1130
|
longitude?: number;
|
|
1131
1131
|
/**
|
|
1132
|
-
* Radius in km holding the true location with 67% confidence.
|
|
1132
|
+
* Radius in km holding the true location with 67% confidence. On a paid plan or the trial.
|
|
1133
1133
|
*/
|
|
1134
1134
|
accuracy_radius?: number;
|
|
1135
1135
|
/**
|
|
1136
|
-
* GeoNames ID of the city.
|
|
1136
|
+
* GeoNames ID of the city. On a paid plan or the trial.
|
|
1137
1137
|
*/
|
|
1138
1138
|
geoname_id?: string;
|
|
1139
1139
|
/**
|
|
1140
|
-
* US TV market (DMA) code.
|
|
1140
|
+
* US TV market (DMA) code. On a paid plan or the trial.
|
|
1141
1141
|
*/
|
|
1142
1142
|
dma_code?: string;
|
|
1143
1143
|
/**
|
|
1144
|
-
* The day the range's location last changed.
|
|
1144
|
+
* The day the range's location last changed. On a paid plan or the trial.
|
|
1145
1145
|
*/
|
|
1146
1146
|
last_changed?: string;
|
|
1147
1147
|
};
|
|
@@ -1162,9 +1162,9 @@ export type Asn = {
|
|
|
1162
1162
|
*/
|
|
1163
1163
|
domain: string;
|
|
1164
1164
|
/**
|
|
1165
|
-
* The kind of network it runs.
|
|
1165
|
+
* The kind of network it runs. On a paid plan or the trial.
|
|
1166
1166
|
*/
|
|
1167
|
-
type
|
|
1167
|
+
type?: string;
|
|
1168
1168
|
/**
|
|
1169
1169
|
* The announced prefix covering the address.
|
|
1170
1170
|
*/
|
|
@@ -1191,11 +1191,11 @@ export type Company = {
|
|
|
1191
1191
|
*/
|
|
1192
1192
|
domain: string;
|
|
1193
1193
|
/**
|
|
1194
|
-
* What kind of organization: hosting, isp, business, education, government.
|
|
1194
|
+
* What kind of organization: hosting, isp, business, education, government. On a paid plan or the trial.
|
|
1195
1195
|
*/
|
|
1196
1196
|
type?: string;
|
|
1197
1197
|
/**
|
|
1198
|
-
* ISO 3166 country code.
|
|
1198
|
+
* ISO 3166 country code. On a paid plan or the trial.
|
|
1199
1199
|
*/
|
|
1200
1200
|
country?: string;
|
|
1201
1201
|
};
|
|
@@ -1208,36 +1208,36 @@ export type AbuseContact = {
|
|
|
1208
1208
|
*/
|
|
1209
1209
|
email: string;
|
|
1210
1210
|
/**
|
|
1211
|
-
* The contact.
|
|
1211
|
+
* The contact. On a paid plan or the trial.
|
|
1212
1212
|
*/
|
|
1213
1213
|
name?: string;
|
|
1214
1214
|
/**
|
|
1215
|
-
* Its phone number.
|
|
1215
|
+
* Its phone number. On a paid plan or the trial.
|
|
1216
1216
|
*/
|
|
1217
1217
|
phone?: string;
|
|
1218
1218
|
/**
|
|
1219
|
-
* Its postal address.
|
|
1219
|
+
* Its postal address. On a paid plan or the trial.
|
|
1220
1220
|
*/
|
|
1221
1221
|
address?: string;
|
|
1222
1222
|
/**
|
|
1223
|
-
* ISO 3166 country code.
|
|
1223
|
+
* ISO 3166 country code. On a paid plan or the trial.
|
|
1224
1224
|
*/
|
|
1225
1225
|
country?: string;
|
|
1226
1226
|
/**
|
|
1227
|
-
* The registry block it was derived from.
|
|
1227
|
+
* The registry block it was derived from. On a paid plan or the trial.
|
|
1228
1228
|
*/
|
|
1229
1229
|
network?: string;
|
|
1230
1230
|
/**
|
|
1231
|
-
* ARIN reports the contact answered its yearly validation.
|
|
1231
|
+
* ARIN reports the contact answered its yearly validation. On a paid plan or the trial.
|
|
1232
1232
|
*/
|
|
1233
1233
|
validated?: boolean;
|
|
1234
1234
|
/**
|
|
1235
|
-
* Since when it has not.
|
|
1235
|
+
* Since when it has not. On a paid plan or the trial.
|
|
1236
1236
|
*/
|
|
1237
1237
|
unvalidated_since?: string;
|
|
1238
1238
|
};
|
|
1239
1239
|
/**
|
|
1240
|
-
* IP Whois's most specific record covering the address.
|
|
1240
|
+
* IP Whois's most specific record covering the address. On a paid plan or the trial.
|
|
1241
1241
|
*/
|
|
1242
1242
|
export type Whois = {
|
|
1243
1243
|
/**
|
|
@@ -1278,7 +1278,7 @@ export type Whois = {
|
|
|
1278
1278
|
asn: number;
|
|
1279
1279
|
};
|
|
1280
1280
|
/**
|
|
1281
|
-
* IP RWHOIS's most specific network covering the address.
|
|
1281
|
+
* IP RWHOIS's most specific network covering the address. On a paid plan or the trial.
|
|
1282
1282
|
*/
|
|
1283
1283
|
export type Rwhois = {
|
|
1284
1284
|
/**
|
|
@@ -1307,7 +1307,7 @@ export type Rwhois = {
|
|
|
1307
1307
|
abuse_email: string;
|
|
1308
1308
|
};
|
|
1309
1309
|
/**
|
|
1310
|
-
* From IP Hosted Domains: how many registered domains resolve to the address, and the 10 most popular. Its database lists up to 1,000 an address.
|
|
1310
|
+
* From IP Hosted Domains: how many registered domains resolve to the address, and the 10 most popular. Its database lists up to 1,000 an address. On a paid plan or the trial.
|
|
1311
1311
|
*/
|
|
1312
1312
|
export type HostedDomains = {
|
|
1313
1313
|
/**
|
|
@@ -1320,7 +1320,7 @@ export type HostedDomains = {
|
|
|
1320
1320
|
domains?: Array<string>;
|
|
1321
1321
|
};
|
|
1322
1322
|
/**
|
|
1323
|
-
* From ASN Hosted Domains: how many registered domains the AS hosts, and the 10 most popular. Its database lists up to 1,000 an AS.
|
|
1323
|
+
* From ASN Hosted Domains: how many registered domains the AS hosts, and the 10 most popular. Its database lists up to 1,000 an AS. On a paid plan or the trial.
|
|
1324
1324
|
*/
|
|
1325
1325
|
export type AsnHostedDomains = {
|
|
1326
1326
|
/**
|
|
@@ -1361,73 +1361,73 @@ export type AsnLookupResponse = {
|
|
|
1361
1361
|
*/
|
|
1362
1362
|
domain: string;
|
|
1363
1363
|
/**
|
|
1364
|
-
* The kind of network it runs.
|
|
1364
|
+
* The kind of network it runs. On a paid plan or the trial.
|
|
1365
1365
|
*/
|
|
1366
1366
|
type?: string;
|
|
1367
1367
|
/**
|
|
1368
|
-
* IPv4 addresses it announces.
|
|
1368
|
+
* IPv4 addresses it announces. On a paid plan or the trial.
|
|
1369
1369
|
*/
|
|
1370
1370
|
num_ips?: number;
|
|
1371
1371
|
/**
|
|
1372
|
-
* IPv4 prefixes it announces.
|
|
1372
|
+
* IPv4 prefixes it announces. On a paid plan or the trial.
|
|
1373
1373
|
*/
|
|
1374
1374
|
num_prefixes4?: number;
|
|
1375
1375
|
/**
|
|
1376
|
-
* IPv6 prefixes it announces.
|
|
1376
|
+
* IPv6 prefixes it announces. On a paid plan or the trial.
|
|
1377
1377
|
*/
|
|
1378
1378
|
num_prefixes6?: number;
|
|
1379
1379
|
/**
|
|
1380
|
-
* Its announcements RPKI calls valid.
|
|
1380
|
+
* Its announcements RPKI calls valid. On a paid plan or the trial.
|
|
1381
1381
|
*/
|
|
1382
1382
|
rpki_valid?: number;
|
|
1383
1383
|
/**
|
|
1384
|
-
* Invalid.
|
|
1384
|
+
* Invalid. On a paid plan or the trial.
|
|
1385
1385
|
*/
|
|
1386
1386
|
rpki_invalid?: number;
|
|
1387
1387
|
/**
|
|
1388
|
-
* With no RPKI record.
|
|
1388
|
+
* With no RPKI record. On a paid plan or the trial.
|
|
1389
1389
|
*/
|
|
1390
1390
|
rpki_not_found?: number;
|
|
1391
1391
|
/**
|
|
1392
|
-
* Its ASN Whois record, every column, empty where the registry states nothing.
|
|
1392
|
+
* Its ASN Whois record, every column, empty where the registry states nothing. On a paid plan or the trial.
|
|
1393
1393
|
*/
|
|
1394
1394
|
whois?: {
|
|
1395
1395
|
[key: string]: string;
|
|
1396
1396
|
};
|
|
1397
1397
|
/**
|
|
1398
|
-
* What it announces, IPv4 then IPv6, up to 20000 a family.
|
|
1398
|
+
* What it announces, IPv4 then IPv6, up to 20000 a family. On a paid plan or the trial.
|
|
1399
1399
|
*/
|
|
1400
1400
|
prefixes?: Array<AsnPrefix>;
|
|
1401
1401
|
/**
|
|
1402
|
-
* Its rank in ASN Extended, by customer cone, 1 the largest; `0` for an AS seen in no AS path.
|
|
1402
|
+
* Its rank in ASN Extended, by customer cone, 1 the largest; `0` for an AS seen in no AS path. On a paid plan or the trial.
|
|
1403
1403
|
*/
|
|
1404
1404
|
rank?: number;
|
|
1405
1405
|
/**
|
|
1406
|
-
* Whether it is one of the transit-free networks at the top of the hierarchy, which get transit from no one and peer with each other.
|
|
1406
|
+
* Whether it is one of the transit-free networks at the top of the hierarchy, which get transit from no one and peer with each other. On a paid plan or the trial.
|
|
1407
1407
|
*/
|
|
1408
1408
|
tier1?: boolean;
|
|
1409
1409
|
/**
|
|
1410
|
-
* How many AS numbers it gets transit from.
|
|
1410
|
+
* How many AS numbers it gets transit from. On a paid plan or the trial.
|
|
1411
1411
|
*/
|
|
1412
1412
|
num_upstreams?: number;
|
|
1413
1413
|
/**
|
|
1414
|
-
* Those AS numbers, ascending, up to 20000.
|
|
1414
|
+
* Those AS numbers, ascending, up to 20000. On a paid plan or the trial.
|
|
1415
1415
|
*/
|
|
1416
1416
|
upstreams?: Array<number>;
|
|
1417
1417
|
/**
|
|
1418
|
-
* How many AS numbers it exchanges its own and its customers' routes with.
|
|
1418
|
+
* How many AS numbers it exchanges its own and its customers' routes with. On a paid plan or the trial.
|
|
1419
1419
|
*/
|
|
1420
1420
|
num_peers?: number;
|
|
1421
1421
|
/**
|
|
1422
|
-
* Those AS numbers, ascending, up to 20000.
|
|
1422
|
+
* Those AS numbers, ascending, up to 20000. On a paid plan or the trial.
|
|
1423
1423
|
*/
|
|
1424
1424
|
peers?: Array<number>;
|
|
1425
1425
|
/**
|
|
1426
|
-
* How many AS numbers it provides transit to.
|
|
1426
|
+
* How many AS numbers it provides transit to. On a paid plan or the trial.
|
|
1427
1427
|
*/
|
|
1428
1428
|
num_downstreams?: number;
|
|
1429
1429
|
/**
|
|
1430
|
-
* Those AS numbers, ascending, up to 20000.
|
|
1430
|
+
* Those AS numbers, ascending, up to 20000. On a paid plan or the trial.
|
|
1431
1431
|
*/
|
|
1432
1432
|
downstreams?: Array<number>;
|
|
1433
1433
|
hosted_domains?: AsnHostedDomains;
|
|
@@ -1483,7 +1483,7 @@ export type DomainLookupResponse = {
|
|
|
1483
1483
|
*/
|
|
1484
1484
|
is_registered: boolean;
|
|
1485
1485
|
/**
|
|
1486
|
-
* In Disposable Domain.
|
|
1486
|
+
* In Disposable Domain. On a paid plan or the trial.
|
|
1487
1487
|
*/
|
|
1488
1488
|
is_disposable?: boolean;
|
|
1489
1489
|
/**
|
|
@@ -1508,13 +1508,13 @@ export type DomainLookupResponse = {
|
|
|
1508
1508
|
has_cname: boolean;
|
|
1509
1509
|
dns?: DomainDns;
|
|
1510
1510
|
/**
|
|
1511
|
-
* The network announcing each address in `dns.a` and then `dns.aaaa`, from IP ASN; `[]` where it resolves to none.
|
|
1511
|
+
* The network announcing each address in `dns.a` and then `dns.aaaa`, from IP ASN; `[]` where it resolves to none. On a paid plan or the trial.
|
|
1512
1512
|
*/
|
|
1513
1513
|
hosting?: Array<DomainHost>;
|
|
1514
1514
|
cohosted_domains?: CohostedDomains;
|
|
1515
1515
|
ip_ranges?: DomainIpRanges;
|
|
1516
1516
|
/**
|
|
1517
|
-
* `{}` when `is_disposable` is false.
|
|
1517
|
+
* `{}` when `is_disposable` is false. On a paid plan or the trial.
|
|
1518
1518
|
*/
|
|
1519
1519
|
disposable?: DisposableDetail;
|
|
1520
1520
|
web?: DomainWeb;
|
|
@@ -1543,7 +1543,7 @@ export type DomainHost = {
|
|
|
1543
1543
|
asn: Asn;
|
|
1544
1544
|
};
|
|
1545
1545
|
/**
|
|
1546
|
-
* From IP Hosted Domains: the other registered domains on the domain's first IPv4 address, how many and the 10 most popular.
|
|
1546
|
+
* From IP Hosted Domains: the other registered domains on the domain's first IPv4 address, how many and the 10 most popular. On a paid plan or the trial.
|
|
1547
1547
|
*/
|
|
1548
1548
|
export type CohostedDomains = {
|
|
1549
1549
|
/**
|
|
@@ -1560,7 +1560,7 @@ export type CohostedDomains = {
|
|
|
1560
1560
|
domains: Array<string>;
|
|
1561
1561
|
};
|
|
1562
1562
|
/**
|
|
1563
|
-
* What our crawl last read of the domain's own home page, every member empty where it holds none.
|
|
1563
|
+
* What our crawl last read of the domain's own home page, every member empty where it holds none. On a paid plan or the trial.
|
|
1564
1564
|
*/
|
|
1565
1565
|
export type DomainWeb = {
|
|
1566
1566
|
/**
|
|
@@ -1595,7 +1595,7 @@ export type DomainWebLinks = {
|
|
|
1595
1595
|
hosts: Array<string>;
|
|
1596
1596
|
};
|
|
1597
1597
|
/**
|
|
1598
|
-
* The registered domains whose home page redirects to this one, how many and the 10 most popular.
|
|
1598
|
+
* The registered domains whose home page redirects to this one, how many and the 10 most popular. On a paid plan or the trial.
|
|
1599
1599
|
*/
|
|
1600
1600
|
export type DomainRedirects = {
|
|
1601
1601
|
/**
|
|
@@ -1608,7 +1608,7 @@ export type DomainRedirects = {
|
|
|
1608
1608
|
domains: Array<string>;
|
|
1609
1609
|
};
|
|
1610
1610
|
/**
|
|
1611
|
-
* The registered domains whose home page links to this one, how many and the 10 most popular.
|
|
1611
|
+
* The registered domains whose home page links to this one, how many and the 10 most popular. On a paid plan or the trial.
|
|
1612
1612
|
*/
|
|
1613
1613
|
export type DomainBacklinks = {
|
|
1614
1614
|
/**
|
|
@@ -1621,7 +1621,7 @@ export type DomainBacklinks = {
|
|
|
1621
1621
|
domains: Array<string>;
|
|
1622
1622
|
};
|
|
1623
1623
|
/**
|
|
1624
|
-
* Its records in Domain DNS, up to 100 a type.
|
|
1624
|
+
* Its records in Domain DNS, up to 100 a type. On a paid plan or the trial.
|
|
1625
1625
|
*/
|
|
1626
1626
|
export type DomainDns = {
|
|
1627
1627
|
a: Array<DnsAddressRecord>;
|
|
@@ -1675,7 +1675,7 @@ export type DnsCnameRecord = {
|
|
|
1675
1675
|
last_seen: string;
|
|
1676
1676
|
};
|
|
1677
1677
|
/**
|
|
1678
|
-
* The organization's IP ranges, from Domain IP Ranges.
|
|
1678
|
+
* The organization's IP ranges, from Domain IP Ranges. On a paid plan or the trial.
|
|
1679
1679
|
*/
|
|
1680
1680
|
export type DomainIpRanges = {
|
|
1681
1681
|
/**
|
|
@@ -1816,7 +1816,8 @@ export type EntitlementPlan = {
|
|
|
1816
1816
|
* The plan the organization is on, as an identifier that is never
|
|
1817
1817
|
* renamed or reused: `free` for the free plan, or a paid plan's key.
|
|
1818
1818
|
* Compare against it and show `name`. On `free`, usage counts its
|
|
1819
|
-
* trial, the lookups answered with every field.
|
|
1819
|
+
* trial, the lookups answered with every field. The Data plan is a key
|
|
1820
|
+
* per quota, `data_1` to `data_7`, each named Data.
|
|
1820
1821
|
*
|
|
1821
1822
|
*/
|
|
1822
1823
|
key: string;
|
|
@@ -1859,11 +1860,15 @@ export type EntitlementUsage = {
|
|
|
1859
1860
|
*/
|
|
1860
1861
|
hard_limit: number | null;
|
|
1861
1862
|
/**
|
|
1862
|
-
* When the current allowance period began.
|
|
1863
|
+
* When the current allowance period began. On the free plan, when
|
|
1864
|
+
* its trial began, or now before a first lookup starts it.
|
|
1865
|
+
*
|
|
1863
1866
|
*/
|
|
1864
1867
|
window_start: string;
|
|
1865
1868
|
/**
|
|
1866
|
-
* When the allowance next resets.
|
|
1869
|
+
* When the allowance next resets. On the free plan, when its trial
|
|
1870
|
+
* ends, which it does once.
|
|
1871
|
+
*
|
|
1867
1872
|
*/
|
|
1868
1873
|
window_end: string;
|
|
1869
1874
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "2.
|
|
1
|
+
export declare const VERSION = "2.19.0";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '2.
|
|
1
|
+
export const VERSION = '2.19.0';
|
|
2
2
|
//# sourceMappingURL=version.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { InternetData, DatabaseApi, DEFAULT_BASE_URL } from './client.js';
|
|
2
|
-
export type { BatchOptions, CacheOptions, DownloadDestination, DownloadOptions, DownloadsOptions, DownloadUrlOptions, LookupOptions, Options, } from './client.js';
|
|
2
|
+
export type { BatchOptions, CacheOptions, CallOptions, DownloadDestination, DownloadOptions, DownloadsOptions, DownloadUrlOptions, LookupOptions, Options, } from './client.js';
|
|
3
3
|
export { OauthApi } from './oauth.js';
|
|
4
4
|
export type { OauthOptions, DeviceAuthorizationOptions, PollDeviceTokenOptions, AuthorizationUrlOptions, RegisterOptions, OauthMetadata, DeviceAuthorization, TokenResponse, Pkce, ClientRegistration, } from './oauth.js';
|
|
5
5
|
export { isBogon } from './bogon.js';
|
|
@@ -7,4 +7,4 @@ export { InternetDataError, OauthError, OauthAccessDeniedError, OauthExpiredToke
|
|
|
7
7
|
export type { ErrorKind } from './errors.js';
|
|
8
8
|
export { DATABASE_FORMATS, DATASET_FORMATS, LICENSE_TYPES, STANDINGS } from './types.js';
|
|
9
9
|
export type { Database, DatabaseFormat, DatabaseMetadata, DatabaseMetadataColumn, DatabaseVersion, DatasetFormat, DbChecksums, Download, LicenseType, Standing, } from './types.js';
|
|
10
|
-
export type { Result, AsnResult, DomainResult, LookupResponse, AsnLookupResponse, DomainLookupResponse, ClassDetail, ProxyDetail, PubproxyDetail, CarrierDetail, SatelliteDetail, SshDetail, SmtpDetail, WebDetail, DnsResolverDetail, BitTorrentDetail, Location, Asn, Company, AbuseContact, Whois, Rwhois, HostedDomains, AsnPrefix, DomainDns, DnsAddressRecord, DnsMxRecord, DnsNsRecord, DnsCnameRecord, DomainIpRanges, DomainIpRange, DisposableDetail, DomainHost, CohostedDomains, DomainWeb, DomainWebLinks, DomainRedirects, DomainBacklinks, Entitlement, EntitlementApikey, EntitlementPlan, EntitlementUsage, } from './types.js';
|
|
10
|
+
export type { Result, AsnResult, DomainResult, LookupResponse, AsnLookupResponse, DomainLookupResponse, ClassDetail, ProxyDetail, PubproxyDetail, CarrierDetail, SatelliteDetail, SshDetail, SmtpDetail, WebDetail, DnsResolverDetail, BitTorrentDetail, BotDetail, UserAgentVerdict, Location, Asn, Company, AbuseContact, Whois, Rwhois, HostedDomains, AsnPrefix, DomainDns, DnsAddressRecord, DnsMxRecord, DnsNsRecord, DnsCnameRecord, DomainIpRanges, DomainIpRange, DisposableDetail, DomainHost, CohostedDomains, DomainWeb, DomainWebLinks, DomainRedirects, DomainBacklinks, Entitlement, EntitlementApikey, EntitlementPlan, EntitlementUsage, } from './types.js';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { HELD_FLAGS } from '../types.js';
|
|
1
2
|
/** Whether an answer satisfies the condition, and should therefore be blocked. */
|
|
2
3
|
export function matchesCondition(condition, result) {
|
|
3
4
|
const any = Array.isArray(condition) ? condition : [condition];
|
|
@@ -23,8 +24,11 @@ export function matchesCondition(condition, result) {
|
|
|
23
24
|
export function missingMembers(condition, result) {
|
|
24
25
|
const any = Array.isArray(condition) ? condition : [condition];
|
|
25
26
|
const missing = new Set();
|
|
27
|
+
const answer = result;
|
|
28
|
+
// A held flag reads false when the API did not send it, so its presence is the wire answer's.
|
|
29
|
+
const wire = isRecord(answer['raw']) ? answer['raw'] : undefined;
|
|
26
30
|
for (const one of any) {
|
|
27
|
-
collectMissing(one,
|
|
31
|
+
collectMissing(one, answer, '', missing, wire);
|
|
28
32
|
}
|
|
29
33
|
return [...missing];
|
|
30
34
|
}
|
|
@@ -51,13 +55,13 @@ export function constraintCount(condition) {
|
|
|
51
55
|
}
|
|
52
56
|
return 1;
|
|
53
57
|
}
|
|
54
|
-
function collectMissing(condition, value, prefix, missing) {
|
|
58
|
+
function collectMissing(condition, value, prefix, missing, wire) {
|
|
55
59
|
for (const [member, want] of Object.entries(condition)) {
|
|
56
60
|
if (constraintCount(want) === 0) {
|
|
57
61
|
continue;
|
|
58
62
|
}
|
|
59
63
|
const path = `${prefix}${member}`;
|
|
60
|
-
if (!(member in value)) {
|
|
64
|
+
if (!(member in value) || notSent(member, wire)) {
|
|
61
65
|
missing.add(path);
|
|
62
66
|
continue;
|
|
63
67
|
}
|
|
@@ -67,6 +71,10 @@ function collectMissing(condition, value, prefix, missing) {
|
|
|
67
71
|
}
|
|
68
72
|
}
|
|
69
73
|
}
|
|
74
|
+
// The wire is given for the top level alone, where the held flags are.
|
|
75
|
+
function notSent(member, wire) {
|
|
76
|
+
return wire !== undefined && Object.hasOwn(HELD_FLAGS, member) && !(HELD_FLAGS[member] in wire);
|
|
77
|
+
}
|
|
70
78
|
function matchesObject(condition, value) {
|
|
71
79
|
for (const [key, want] of Object.entries(condition)) {
|
|
72
80
|
if (constraintCount(want) === 0) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"condition.js","sourceRoot":"","sources":["../../src/middleware/condition.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"condition.js","sourceRoot":"","sources":["../../src/middleware/condition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAe,MAAM,aAAa,CAAC;AAmDtD,kFAAkF;AAClF,MAAM,UAAU,gBAAgB,CAC5B,SAA4C,EAAE,MAAc;IAE5D,MAAM,GAAG,GAAG,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IAC/D,OAAO,GAAG,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,aAAa,CAClC,GAA8B,EAAE,MAA4C,CAC/E,CAAC,CAAC;AACP,CAAC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,UAAU,cAAc,CAC1B,SAA4C,EAAE,MAAc;IAE5D,MAAM,GAAG,GAAG,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IAC/D,MAAM,OAAO,GAAG,IAAI,GAAG,EAAU,CAAC;IAClC,MAAM,M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