internetdata 2.14.3 → 2.16.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.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/internetdata/api/database_v2_api.rb +1 -1
- data/lib/internetdata/api_client.rb +1 -1
- data/lib/internetdata/api_error.rb +1 -1
- data/lib/internetdata/api_model_base.rb +1 -1
- data/lib/internetdata/cache.rb +3 -3
- data/lib/internetdata/configuration.rb +1 -1
- data/lib/internetdata/domain_result.rb +38 -1
- data/lib/internetdata/models/abuse_contact.rb +1 -1
- data/lib/internetdata/models/asn.rb +35 -1
- data/lib/internetdata/models/asn_hosted_domains.rb +1 -1
- data/lib/internetdata/models/asn_lookup_response.rb +1 -1
- data/lib/internetdata/models/asn_prefix.rb +1 -1
- data/lib/internetdata/models/batch_lookup_error.rb +1 -1
- data/lib/internetdata/models/bit_torrent_detail.rb +1 -1
- data/lib/internetdata/models/bot_detail.rb +242 -0
- data/lib/internetdata/models/carrier_detail.rb +1 -1
- data/lib/internetdata/models/class_detail.rb +1 -1
- data/lib/internetdata/models/client_registration.rb +1 -1
- data/lib/internetdata/models/cohosted_domains.rb +222 -0
- data/lib/internetdata/models/company.rb +1 -1
- data/lib/internetdata/models/database.rb +1 -1
- data/lib/internetdata/models/database_checksums_response.rb +1 -1
- data/lib/internetdata/models/database_format.rb +1 -1
- data/lib/internetdata/models/database_list.rb +1 -1
- data/lib/internetdata/models/database_metadata.rb +1 -1
- data/lib/internetdata/models/database_metadata_column.rb +1 -1
- data/lib/internetdata/models/database_version.rb +1 -1
- data/lib/internetdata/models/db_checksums.rb +1 -1
- data/lib/internetdata/models/device_authorization.rb +1 -1
- data/lib/internetdata/models/disposable_detail.rb +1 -1
- data/lib/internetdata/models/dns_address_record.rb +1 -1
- data/lib/internetdata/models/dns_cname_record.rb +1 -1
- data/lib/internetdata/models/dns_mx_record.rb +1 -1
- data/lib/internetdata/models/dns_ns_record.rb +1 -1
- data/lib/internetdata/models/dns_resolver_detail.rb +1 -1
- data/lib/internetdata/models/domain_backlinks.rb +195 -0
- data/lib/internetdata/models/domain_dns.rb +1 -1
- data/lib/internetdata/models/domain_host.rb +193 -0
- data/lib/internetdata/models/domain_ip_range.rb +1 -1
- data/lib/internetdata/models/domain_ip_ranges.rb +1 -1
- data/lib/internetdata/models/domain_lookup_response.rb +50 -2
- data/lib/internetdata/models/domain_redirects.rb +195 -0
- data/lib/internetdata/models/domain_web.rb +273 -0
- data/lib/internetdata/models/domain_web_links.rb +195 -0
- data/lib/internetdata/models/download.rb +1 -1
- data/lib/internetdata/models/download_list.rb +1 -1
- data/lib/internetdata/models/entitlement.rb +1 -1
- data/lib/internetdata/models/entitlement_apikey.rb +1 -1
- data/lib/internetdata/models/entitlement_plan.rb +1 -1
- data/lib/internetdata/models/entitlement_usage.rb +1 -1
- data/lib/internetdata/models/error_envelope.rb +1 -1
- data/lib/internetdata/models/hosted_domains.rb +1 -1
- data/lib/internetdata/models/location.rb +1 -1
- data/lib/internetdata/models/lookup_response.rb +49 -2
- data/lib/internetdata/models/oauth_metadata.rb +1 -1
- data/lib/internetdata/models/proxy_detail.rb +1 -1
- data/lib/internetdata/models/pubproxy_detail.rb +1 -1
- data/lib/internetdata/models/rwhois.rb +1 -1
- data/lib/internetdata/models/satellite_detail.rb +1 -1
- data/lib/internetdata/models/smtp_detail.rb +1 -1
- data/lib/internetdata/models/ssh_detail.rb +1 -1
- data/lib/internetdata/models/standing.rb +1 -1
- data/lib/internetdata/models/token_response.rb +1 -1
- data/lib/internetdata/models/user_agent_verdict.rb +243 -0
- data/lib/internetdata/models/web_detail.rb +1 -1
- data/lib/internetdata/models/whois.rb +1 -1
- data/lib/internetdata/result.rb +24 -4
- data/lib/internetdata/transport.rb +12 -3
- data/lib/internetdata/version.rb +1 -1
- metadata +9 -1
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -49,6 +49,9 @@ module InternetData
|
|
|
49
49
|
# In CDN IP: a content delivery network. Paid plans and the trial.
|
|
50
50
|
attr_accessor :is_cdn
|
|
51
51
|
|
|
52
|
+
# 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.
|
|
53
|
+
attr_accessor :is_bot
|
|
54
|
+
|
|
52
55
|
# In Anycast IP: announced from many places at once.
|
|
53
56
|
attr_accessor :is_anycast
|
|
54
57
|
|
|
@@ -100,6 +103,9 @@ module InternetData
|
|
|
100
103
|
# `{}` when `is_cdn` is false. Paid plans and the trial.
|
|
101
104
|
attr_accessor :cdn
|
|
102
105
|
|
|
106
|
+
# `{}` when `is_bot` is false. Paid plans and the trial.
|
|
107
|
+
attr_accessor :bot
|
|
108
|
+
|
|
103
109
|
# `{}` when `is_carrier` is false. Paid plans and the trial.
|
|
104
110
|
attr_accessor :carrier
|
|
105
111
|
|
|
@@ -138,6 +144,9 @@ module InternetData
|
|
|
138
144
|
|
|
139
145
|
attr_accessor :hosted_domains
|
|
140
146
|
|
|
147
|
+
# When the request sent `user_agent`, with every field, the agent it names and whether this address bears it out. Absent otherwise.
|
|
148
|
+
attr_accessor :user_agent
|
|
149
|
+
|
|
141
150
|
# 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.
|
|
142
151
|
attr_accessor :trial_expired
|
|
143
152
|
|
|
@@ -158,6 +167,7 @@ module InternetData
|
|
|
158
167
|
:'is_pubproxy' => :'is_pubproxy',
|
|
159
168
|
:'is_hosting' => :'is_hosting',
|
|
160
169
|
:'is_cdn' => :'is_cdn',
|
|
170
|
+
:'is_bot' => :'is_bot',
|
|
161
171
|
:'is_anycast' => :'is_anycast',
|
|
162
172
|
:'is_carrier' => :'is_carrier',
|
|
163
173
|
:'is_satellite' => :'is_satellite',
|
|
@@ -175,6 +185,7 @@ module InternetData
|
|
|
175
185
|
:'pubproxy' => :'pubproxy',
|
|
176
186
|
:'hosting' => :'hosting',
|
|
177
187
|
:'cdn' => :'cdn',
|
|
188
|
+
:'bot' => :'bot',
|
|
178
189
|
:'carrier' => :'carrier',
|
|
179
190
|
:'satellite' => :'satellite',
|
|
180
191
|
:'ssh' => :'ssh',
|
|
@@ -190,6 +201,7 @@ module InternetData
|
|
|
190
201
|
:'whois' => :'whois',
|
|
191
202
|
:'rwhois' => :'rwhois',
|
|
192
203
|
:'hosted_domains' => :'hosted_domains',
|
|
204
|
+
:'user_agent' => :'user_agent',
|
|
193
205
|
:'trial_expired' => :'trial_expired',
|
|
194
206
|
:'cap_reached' => :'cap_reached'
|
|
195
207
|
}
|
|
@@ -219,6 +231,7 @@ module InternetData
|
|
|
219
231
|
:'is_pubproxy' => :'Boolean',
|
|
220
232
|
:'is_hosting' => :'Boolean',
|
|
221
233
|
:'is_cdn' => :'Boolean',
|
|
234
|
+
:'is_bot' => :'Boolean',
|
|
222
235
|
:'is_anycast' => :'Boolean',
|
|
223
236
|
:'is_carrier' => :'Boolean',
|
|
224
237
|
:'is_satellite' => :'Boolean',
|
|
@@ -236,6 +249,7 @@ module InternetData
|
|
|
236
249
|
:'pubproxy' => :'PubproxyDetail',
|
|
237
250
|
:'hosting' => :'ClassDetail',
|
|
238
251
|
:'cdn' => :'ClassDetail',
|
|
252
|
+
:'bot' => :'BotDetail',
|
|
239
253
|
:'carrier' => :'CarrierDetail',
|
|
240
254
|
:'satellite' => :'SatelliteDetail',
|
|
241
255
|
:'ssh' => :'SshDetail',
|
|
@@ -251,6 +265,7 @@ module InternetData
|
|
|
251
265
|
:'whois' => :'Whois',
|
|
252
266
|
:'rwhois' => :'Rwhois',
|
|
253
267
|
:'hosted_domains' => :'HostedDomains',
|
|
268
|
+
:'user_agent' => :'UserAgentVerdict',
|
|
254
269
|
:'trial_expired' => :'Boolean',
|
|
255
270
|
:'cap_reached' => :'Boolean'
|
|
256
271
|
}
|
|
@@ -330,6 +345,12 @@ module InternetData
|
|
|
330
345
|
self.is_cdn = attributes[:'is_cdn']
|
|
331
346
|
end
|
|
332
347
|
|
|
348
|
+
if attributes.key?(:'is_bot')
|
|
349
|
+
self.is_bot = attributes[:'is_bot']
|
|
350
|
+
else
|
|
351
|
+
self.is_bot = nil
|
|
352
|
+
end
|
|
353
|
+
|
|
333
354
|
if attributes.key?(:'is_anycast')
|
|
334
355
|
self.is_anycast = attributes[:'is_anycast']
|
|
335
356
|
else
|
|
@@ -418,6 +439,10 @@ module InternetData
|
|
|
418
439
|
self.cdn = attributes[:'cdn']
|
|
419
440
|
end
|
|
420
441
|
|
|
442
|
+
if attributes.key?(:'bot')
|
|
443
|
+
self.bot = attributes[:'bot']
|
|
444
|
+
end
|
|
445
|
+
|
|
421
446
|
if attributes.key?(:'carrier')
|
|
422
447
|
self.carrier = attributes[:'carrier']
|
|
423
448
|
end
|
|
@@ -490,6 +515,10 @@ module InternetData
|
|
|
490
515
|
self.hosted_domains = attributes[:'hosted_domains']
|
|
491
516
|
end
|
|
492
517
|
|
|
518
|
+
if attributes.key?(:'user_agent')
|
|
519
|
+
self.user_agent = attributes[:'user_agent']
|
|
520
|
+
end
|
|
521
|
+
|
|
493
522
|
if attributes.key?(:'trial_expired')
|
|
494
523
|
self.trial_expired = attributes[:'trial_expired']
|
|
495
524
|
end
|
|
@@ -520,6 +549,10 @@ module InternetData
|
|
|
520
549
|
invalid_properties.push('invalid value for "is_relay", is_relay cannot be nil.')
|
|
521
550
|
end
|
|
522
551
|
|
|
552
|
+
if @is_bot.nil?
|
|
553
|
+
invalid_properties.push('invalid value for "is_bot", is_bot cannot be nil.')
|
|
554
|
+
end
|
|
555
|
+
|
|
523
556
|
if @is_anycast.nil?
|
|
524
557
|
invalid_properties.push('invalid value for "is_anycast", is_anycast cannot be nil.')
|
|
525
558
|
end
|
|
@@ -591,6 +624,7 @@ module InternetData
|
|
|
591
624
|
return false if @is_bogon.nil?
|
|
592
625
|
return false if @is_tor.nil?
|
|
593
626
|
return false if @is_relay.nil?
|
|
627
|
+
return false if @is_bot.nil?
|
|
594
628
|
return false if @is_anycast.nil?
|
|
595
629
|
return false if @is_carrier.nil?
|
|
596
630
|
return false if @is_satellite.nil?
|
|
@@ -649,6 +683,16 @@ module InternetData
|
|
|
649
683
|
@is_relay = is_relay
|
|
650
684
|
end
|
|
651
685
|
|
|
686
|
+
# Custom attribute writer method with validation
|
|
687
|
+
# @param [Object] is_bot Value to be assigned
|
|
688
|
+
def is_bot=(is_bot)
|
|
689
|
+
if is_bot.nil?
|
|
690
|
+
fail ArgumentError, 'is_bot cannot be nil'
|
|
691
|
+
end
|
|
692
|
+
|
|
693
|
+
@is_bot = is_bot
|
|
694
|
+
end
|
|
695
|
+
|
|
652
696
|
# Custom attribute writer method with validation
|
|
653
697
|
# @param [Object] is_anycast Value to be assigned
|
|
654
698
|
def is_anycast=(is_anycast)
|
|
@@ -815,6 +859,7 @@ module InternetData
|
|
|
815
859
|
is_pubproxy == o.is_pubproxy &&
|
|
816
860
|
is_hosting == o.is_hosting &&
|
|
817
861
|
is_cdn == o.is_cdn &&
|
|
862
|
+
is_bot == o.is_bot &&
|
|
818
863
|
is_anycast == o.is_anycast &&
|
|
819
864
|
is_carrier == o.is_carrier &&
|
|
820
865
|
is_satellite == o.is_satellite &&
|
|
@@ -832,6 +877,7 @@ module InternetData
|
|
|
832
877
|
pubproxy == o.pubproxy &&
|
|
833
878
|
hosting == o.hosting &&
|
|
834
879
|
cdn == o.cdn &&
|
|
880
|
+
bot == o.bot &&
|
|
835
881
|
carrier == o.carrier &&
|
|
836
882
|
satellite == o.satellite &&
|
|
837
883
|
ssh == o.ssh &&
|
|
@@ -847,6 +893,7 @@ module InternetData
|
|
|
847
893
|
whois == o.whois &&
|
|
848
894
|
rwhois == o.rwhois &&
|
|
849
895
|
hosted_domains == o.hosted_domains &&
|
|
896
|
+
user_agent == o.user_agent &&
|
|
850
897
|
trial_expired == o.trial_expired &&
|
|
851
898
|
cap_reached == o.cap_reached
|
|
852
899
|
end
|
|
@@ -860,7 +907,7 @@ module InternetData
|
|
|
860
907
|
# Calculates hash code according to all attributes.
|
|
861
908
|
# @return [Integer] Hash code
|
|
862
909
|
def hash
|
|
863
|
-
[ip, is_bogon, is_vpn, is_tor, is_relay, is_resproxy, is_dcproxy, is_mobproxy, is_pubproxy, is_hosting, is_cdn, is_anycast, is_carrier, is_satellite, is_ssh, is_smtp, is_web, is_dns_resolver, is_bittorrent, vpn, tor, relay, resproxy, dcproxy, mobproxy, pubproxy, hosting, cdn, carrier, satellite, ssh, smtp, web, dns_resolver, bittorrent, location, asn, company, hostname, abuse, whois, rwhois, hosted_domains, trial_expired, cap_reached].hash
|
|
910
|
+
[ip, is_bogon, is_vpn, is_tor, is_relay, is_resproxy, is_dcproxy, is_mobproxy, is_pubproxy, is_hosting, is_cdn, is_bot, is_anycast, is_carrier, is_satellite, is_ssh, is_smtp, is_web, is_dns_resolver, is_bittorrent, vpn, tor, relay, resproxy, dcproxy, mobproxy, pubproxy, hosting, cdn, bot, carrier, satellite, ssh, smtp, web, dns_resolver, bittorrent, location, asn, company, hostname, abuse, whois, rwhois, hosted_domains, user_agent, trial_expired, cap_reached].hash
|
|
864
911
|
end
|
|
865
912
|
|
|
866
913
|
# Builds the object from hash
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -0,0 +1,243 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#InternetData API
|
|
3
|
+
|
|
4
|
+
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
|
+
Contact: support@internetdata.io
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.25.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module InternetData
|
|
17
|
+
class UserAgentVerdict < ApiModelBase
|
|
18
|
+
# The agent the user agent names, such as `Googlebot` or `Chrome`; `Unknown` where it names none.
|
|
19
|
+
attr_accessor :agent
|
|
20
|
+
|
|
21
|
+
# `browser`, `inapp`, `automation`, `bot`, `ai-bot`, `http-client` or `unknown`: what kind of client the user agent says it is.
|
|
22
|
+
attr_accessor :kind
|
|
23
|
+
|
|
24
|
+
# `verified`: the agent's operator vouches for this address as it. `spoofed`: the operator of a bot that publishes its addresses, or whose registered space it uses, does not vouch for this one, or this address posed as the bot before. `unverifiable`: a bot no published list or registered space can confirm. `not_bot`: a browser, an app or a script.
|
|
25
|
+
attr_accessor :verdict
|
|
26
|
+
|
|
27
|
+
class EnumAttributeValidator
|
|
28
|
+
attr_reader :datatype
|
|
29
|
+
attr_reader :allowable_values
|
|
30
|
+
|
|
31
|
+
def initialize(datatype, allowable_values)
|
|
32
|
+
@allowable_values = allowable_values.map do |value|
|
|
33
|
+
case datatype.to_s
|
|
34
|
+
when /Integer/i
|
|
35
|
+
value.to_i
|
|
36
|
+
when /Float/i
|
|
37
|
+
value.to_f
|
|
38
|
+
else
|
|
39
|
+
value
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
def valid?(value)
|
|
45
|
+
!value || allowable_values.include?(value)
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
50
|
+
def self.attribute_map
|
|
51
|
+
{
|
|
52
|
+
:'agent' => :'agent',
|
|
53
|
+
:'kind' => :'kind',
|
|
54
|
+
:'verdict' => :'verdict'
|
|
55
|
+
}
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
# Returns attribute mapping this model knows about
|
|
59
|
+
def self.acceptable_attribute_map
|
|
60
|
+
attribute_map
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
# Returns all the JSON keys this model knows about
|
|
64
|
+
def self.acceptable_attributes
|
|
65
|
+
acceptable_attribute_map.values
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
# Attribute type mapping.
|
|
69
|
+
def self.openapi_types
|
|
70
|
+
{
|
|
71
|
+
:'agent' => :'String',
|
|
72
|
+
:'kind' => :'String',
|
|
73
|
+
:'verdict' => :'String'
|
|
74
|
+
}
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
# List of attributes with nullable: true
|
|
78
|
+
def self.openapi_nullable
|
|
79
|
+
Set.new([
|
|
80
|
+
])
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
# Initializes the object
|
|
84
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
85
|
+
def initialize(attributes = {})
|
|
86
|
+
if (!attributes.is_a?(Hash))
|
|
87
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `InternetData::UserAgentVerdict` initialize method"
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
91
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
92
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
93
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
94
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `InternetData::UserAgentVerdict`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
95
|
+
end
|
|
96
|
+
h[k.to_sym] = v
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
if attributes.key?(:'agent')
|
|
100
|
+
self.agent = attributes[:'agent']
|
|
101
|
+
else
|
|
102
|
+
self.agent = nil
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
if attributes.key?(:'kind')
|
|
106
|
+
self.kind = attributes[:'kind']
|
|
107
|
+
else
|
|
108
|
+
self.kind = nil
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
if attributes.key?(:'verdict')
|
|
112
|
+
self.verdict = attributes[:'verdict']
|
|
113
|
+
else
|
|
114
|
+
self.verdict = nil
|
|
115
|
+
end
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
119
|
+
# @return Array for valid properties with the reasons
|
|
120
|
+
def list_invalid_properties
|
|
121
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
122
|
+
invalid_properties = Array.new
|
|
123
|
+
if @agent.nil?
|
|
124
|
+
invalid_properties.push('invalid value for "agent", agent cannot be nil.')
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
if @kind.nil?
|
|
128
|
+
invalid_properties.push('invalid value for "kind", kind cannot be nil.')
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
if @verdict.nil?
|
|
132
|
+
invalid_properties.push('invalid value for "verdict", verdict cannot be nil.')
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
invalid_properties
|
|
136
|
+
end
|
|
137
|
+
|
|
138
|
+
# Check to see if the all the properties in the model are valid
|
|
139
|
+
# @return true if the model is valid
|
|
140
|
+
def valid?
|
|
141
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
142
|
+
return false if @agent.nil?
|
|
143
|
+
return false if @kind.nil?
|
|
144
|
+
return false if @verdict.nil?
|
|
145
|
+
verdict_validator = EnumAttributeValidator.new('String', ["verified", "spoofed", "unverifiable", "not_bot"])
|
|
146
|
+
return false unless verdict_validator.valid?(@verdict)
|
|
147
|
+
true
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
# Custom attribute writer method with validation
|
|
151
|
+
# @param [Object] agent Value to be assigned
|
|
152
|
+
def agent=(agent)
|
|
153
|
+
if agent.nil?
|
|
154
|
+
fail ArgumentError, 'agent cannot be nil'
|
|
155
|
+
end
|
|
156
|
+
|
|
157
|
+
@agent = agent
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
# Custom attribute writer method with validation
|
|
161
|
+
# @param [Object] kind Value to be assigned
|
|
162
|
+
def kind=(kind)
|
|
163
|
+
if kind.nil?
|
|
164
|
+
fail ArgumentError, 'kind cannot be nil'
|
|
165
|
+
end
|
|
166
|
+
|
|
167
|
+
@kind = kind
|
|
168
|
+
end
|
|
169
|
+
|
|
170
|
+
# Custom attribute writer method checking allowed values (enum).
|
|
171
|
+
# @param [Object] verdict Object to be assigned
|
|
172
|
+
def verdict=(verdict)
|
|
173
|
+
validator = EnumAttributeValidator.new('String', ["verified", "spoofed", "unverifiable", "not_bot"])
|
|
174
|
+
unless validator.valid?(verdict)
|
|
175
|
+
fail ArgumentError, "invalid value for \"verdict\", must be one of #{validator.allowable_values}."
|
|
176
|
+
end
|
|
177
|
+
@verdict = verdict
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
# Checks equality by comparing each attribute.
|
|
181
|
+
# @param [Object] Object to be compared
|
|
182
|
+
def ==(o)
|
|
183
|
+
return true if self.equal?(o)
|
|
184
|
+
self.class == o.class &&
|
|
185
|
+
agent == o.agent &&
|
|
186
|
+
kind == o.kind &&
|
|
187
|
+
verdict == o.verdict
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
# @see the `==` method
|
|
191
|
+
# @param [Object] Object to be compared
|
|
192
|
+
def eql?(o)
|
|
193
|
+
self == o
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
# Calculates hash code according to all attributes.
|
|
197
|
+
# @return [Integer] Hash code
|
|
198
|
+
def hash
|
|
199
|
+
[agent, kind, verdict].hash
|
|
200
|
+
end
|
|
201
|
+
|
|
202
|
+
# Builds the object from hash
|
|
203
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
204
|
+
# @return [Object] Returns the model itself
|
|
205
|
+
def self.build_from_hash(attributes)
|
|
206
|
+
return nil unless attributes.is_a?(Hash)
|
|
207
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
208
|
+
transformed_hash = {}
|
|
209
|
+
openapi_types.each_pair do |key, type|
|
|
210
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
211
|
+
transformed_hash["#{key}"] = nil
|
|
212
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
213
|
+
# check to ensure the input is an array given that the attribute
|
|
214
|
+
# is documented as an array but the input is not
|
|
215
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
216
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
217
|
+
end
|
|
218
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
219
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
220
|
+
end
|
|
221
|
+
end
|
|
222
|
+
new(transformed_hash)
|
|
223
|
+
end
|
|
224
|
+
|
|
225
|
+
# Returns the object in the form of hash
|
|
226
|
+
# @return [Hash] Returns the object in the form of hash
|
|
227
|
+
def to_hash
|
|
228
|
+
hash = {}
|
|
229
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
230
|
+
value = self.send(attr)
|
|
231
|
+
if value.nil?
|
|
232
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
233
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
hash[param] = _to_hash(value)
|
|
237
|
+
end
|
|
238
|
+
hash
|
|
239
|
+
end
|
|
240
|
+
|
|
241
|
+
end
|
|
242
|
+
|
|
243
|
+
end
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The InternetData API: look up what every database InternetData publishes says about an IP address, an AS or a domain, download the databases your organization is licensed for, and manage the account behind them. See https://docs.internetdata.io for guides and https://github.com/internetdata for the official client libraries.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2026.11.
|
|
6
|
+
The version of the OpenAPI document: 2026.11.21
|
|
7
7
|
Contact: support@internetdata.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.25.0
|
data/lib/internetdata/result.rb
CHANGED
|
@@ -68,14 +68,14 @@ module InternetData
|
|
|
68
68
|
include Answer
|
|
69
69
|
|
|
70
70
|
FLAGS = %w[
|
|
71
|
-
is_vpn is_tor is_relay is_resproxy is_dcproxy is_mobproxy is_pubproxy is_hosting is_cdn
|
|
72
|
-
is_carrier is_satellite is_ssh is_smtp is_web is_dns_resolver is_bittorrent
|
|
71
|
+
is_vpn is_tor is_relay is_resproxy is_dcproxy is_mobproxy is_pubproxy is_hosting is_cdn is_bot
|
|
72
|
+
is_anycast is_carrier is_satellite is_ssh is_smtp is_web is_dns_resolver is_bittorrent
|
|
73
73
|
].freeze
|
|
74
74
|
|
|
75
75
|
# The detail object behind each flag that has one; `is_anycast` has none.
|
|
76
76
|
DETAILS = %w[
|
|
77
|
-
vpn tor relay resproxy dcproxy mobproxy pubproxy hosting cdn carrier satellite ssh smtp
|
|
78
|
-
bittorrent
|
|
77
|
+
vpn tor relay resproxy dcproxy mobproxy pubproxy hosting cdn bot carrier satellite ssh smtp
|
|
78
|
+
dns_resolver bittorrent
|
|
79
79
|
].freeze
|
|
80
80
|
|
|
81
81
|
# The details that are a list of rows rather than one object.
|
|
@@ -198,6 +198,18 @@ module InternetData
|
|
|
198
198
|
@raw['is_cdn'] == true
|
|
199
199
|
end
|
|
200
200
|
|
|
201
|
+
# Whether an automated client uses the address (Bot IP): a search engine's or
|
|
202
|
+
# an AI company's crawler, an uptime monitor, an internet scanner or a
|
|
203
|
+
# webhook sender. Every answer; `bot` says whose.
|
|
204
|
+
def is_bot
|
|
205
|
+
@raw['is_bot']
|
|
206
|
+
end
|
|
207
|
+
|
|
208
|
+
# `is_bot` with an absent member read as false.
|
|
209
|
+
def bot?
|
|
210
|
+
@raw['is_bot'] == true
|
|
211
|
+
end
|
|
212
|
+
|
|
201
213
|
# Whether the address is announced from many places at once (Anycast IP).
|
|
202
214
|
# Every answer.
|
|
203
215
|
def is_anycast
|
|
@@ -329,6 +341,14 @@ module InternetData
|
|
|
329
341
|
@raw['cdn']
|
|
330
342
|
end
|
|
331
343
|
|
|
344
|
+
# Detail for `is_bot`: whose bot uses the address (`provider`,
|
|
345
|
+
# `provider_name`), its bots as their user agents name them (`agents`), what
|
|
346
|
+
# they do (`categories`) and whether the operator vouches for the address
|
|
347
|
+
# (`verified`, `identity`, `verified_by`). Paid plans and the trial.
|
|
348
|
+
def bot
|
|
349
|
+
@raw['bot']
|
|
350
|
+
end
|
|
351
|
+
|
|
332
352
|
# Detail for `is_carrier`. Paid plans and the trial.
|
|
333
353
|
def carrier
|
|
334
354
|
@raw['carrier']
|
|
@@ -357,8 +357,9 @@ module InternetData
|
|
|
357
357
|
# is `{}` under a false flag. test/database_test.rb holds this to
|
|
358
358
|
# spec/openapi.yaml.
|
|
359
359
|
REQUIRED = {
|
|
360
|
-
'LookupResponse' => %i[ip is_bogon is_tor is_relay is_anycast is_carrier is_satellite is_ssh
|
|
361
|
-
is_web is_dns_resolver is_bittorrent tor relay location asn company hostname
|
|
360
|
+
'LookupResponse' => %i[ip is_bogon is_tor is_relay is_bot is_anycast is_carrier is_satellite is_ssh
|
|
361
|
+
is_smtp is_web is_dns_resolver is_bittorrent tor relay location asn company hostname
|
|
362
|
+
abuse],
|
|
362
363
|
'ClassDetail' => [],
|
|
363
364
|
'ProxyDetail' => [],
|
|
364
365
|
'PubproxyDetail' => [],
|
|
@@ -370,9 +371,11 @@ module InternetData
|
|
|
370
371
|
cert_subject_o cert_issuer_dn cert_browser_trusted tls_version first_seen last_seen],
|
|
371
372
|
'DnsResolverDetail' => [],
|
|
372
373
|
'BitTorrentDetail' => [],
|
|
374
|
+
'BotDetail' => [],
|
|
375
|
+
'UserAgentVerdict' => %i[agent kind verdict],
|
|
373
376
|
'Location' => %i[continent continent_name country country_name timezone currency_code currency_name
|
|
374
377
|
currency_symbol flag_emoji flag_unicode],
|
|
375
|
-
'Asn' => %i[asn name domain type prefix],
|
|
378
|
+
'Asn' => %i[asn name domain type prefix country rpki_status],
|
|
376
379
|
'Company' => %i[name domain],
|
|
377
380
|
'AbuseContact' => %i[email],
|
|
378
381
|
'Whois' => %i[id name org country status source domain abuse_email asn],
|
|
@@ -390,6 +393,12 @@ module InternetData
|
|
|
390
393
|
'DomainIpRanges' => %i[domain redirects_to total ipv4 ranges],
|
|
391
394
|
'DomainIpRange' => %i[range name country],
|
|
392
395
|
'DisposableDetail' => [],
|
|
396
|
+
'DomainHost' => %i[ip asn],
|
|
397
|
+
'CohostedDomains' => %i[ip total domains],
|
|
398
|
+
'DomainWeb' => %i[url title description last_seen links],
|
|
399
|
+
'DomainWebLinks' => %i[total hosts],
|
|
400
|
+
'DomainRedirects' => %i[total domains],
|
|
401
|
+
'DomainBacklinks' => %i[total domains],
|
|
393
402
|
'BatchLookupError' => %i[status error],
|
|
394
403
|
'Entitlement' => %i[org_id apikey plan usage],
|
|
395
404
|
'EntitlementApikey' => %i[id expires allowed_cidrs],
|
data/lib/internetdata/version.rb
CHANGED