data_for_seo/entity/domain_analytics/whois_overview.rs
1use serde::{Deserialize, Serialize};
2
3/// Result object for the Whois `overview` endpoint.
4/// See <https://docs.dataforseo.com/v3/domain_analytics/whois/overview/live/>.
5#[derive(Debug, Default, Serialize, Deserialize, Clone)]
6pub struct DomainAnalyticsApiWhoisOverview {
7 /// Total number of domains matching the request across all pages.
8 pub total_count: Option<i64>,
9 /// Number of domain records returned in this response.
10 pub items_count: Option<i64>,
11 /// Offset applied to the returned results.
12 pub offset: Option<i32>,
13 /// Pagination token to fetch the next batch of results.
14 pub offset_token: Option<String>,
15 /// The returned Whois records.
16 pub items: Option<Vec<DomainAnalyticsApiWhoisItem>>,
17}
18
19/// Whois record for a single domain enriched with ranking and backlink stats.
20#[derive(Debug, Default, Serialize, Deserialize, Clone)]
21pub struct DomainAnalyticsApiWhoisItem {
22 /// Result element type, e.g. `domain_whois_overview`.
23 #[serde(rename = "type")]
24 pub item_type: Option<String>,
25 /// Domain name the record describes.
26 pub domain: Option<String>,
27 /// Domain registration date (UTC).
28 pub created_datetime: Option<String>,
29 /// Date the domain's Whois record was last changed (UTC).
30 pub changed_datetime: Option<String>,
31 /// Date the domain registration expires (UTC).
32 pub expiration_datetime: Option<String>,
33 /// Date DataForSEO last updated this record (UTC).
34 pub updated_datetime: Option<String>,
35 /// Date the domain was first seen in the DataForSEO database (UTC).
36 pub first_seen: Option<String>,
37 /// EPP status codes currently set on the domain.
38 pub epp_status_codes: Option<Vec<String>>,
39 /// Top-level domain of the domain name.
40 pub tld: Option<String>,
41 /// Whether the domain is currently registered.
42 pub registered: Option<bool>,
43 /// Name of the domain's registrar.
44 pub registrar: Option<String>,
45 /// Organic and paid SERP metrics for the domain.
46 pub metrics: Option<DomainAnalyticsApiWhoisMetrics>,
47 /// Backlink profile summary for the domain.
48 pub backlinks_info: Option<DomainAnalyticsApiWhoisBacklinksInfo>,
49}
50
51/// Organic and paid SERP metrics attached to a Whois record.
52#[derive(Debug, Default, Serialize, Deserialize, Clone)]
53pub struct DomainAnalyticsApiWhoisMetrics {
54 /// Metrics for keywords the domain ranks for organically.
55 pub organic: Option<DomainAnalyticsApiWhoisMetricsInfo>,
56 /// Metrics for keywords the domain ranks for through paid ads.
57 pub paid: Option<DomainAnalyticsApiWhoisMetricsInfo>,
58}
59
60/// Keyword-position distribution and traffic estimates for a domain.
61#[derive(Debug, Default, Serialize, Deserialize, Clone)]
62pub struct DomainAnalyticsApiWhoisMetricsInfo {
63 /// Number of keywords ranking in position 1.
64 pub pos_1: Option<i64>,
65 /// Number of keywords ranking in positions 2-3.
66 pub pos_2_3: Option<i64>,
67 /// Number of keywords ranking in positions 4-10.
68 pub pos_4_10: Option<i64>,
69 /// Number of keywords ranking in positions 11-20.
70 pub pos_11_20: Option<i64>,
71 /// Number of keywords ranking in positions 21-30.
72 pub pos_21_30: Option<i64>,
73 /// Number of keywords ranking in positions 31-40.
74 pub pos_31_40: Option<i64>,
75 /// Number of keywords ranking in positions 41-50.
76 pub pos_41_50: Option<i64>,
77 /// Number of keywords ranking in positions 51-60.
78 pub pos_51_60: Option<i64>,
79 /// Number of keywords ranking in positions 61-70.
80 pub pos_61_70: Option<i64>,
81 /// Number of keywords ranking in positions 71-80.
82 pub pos_71_80: Option<i64>,
83 /// Number of keywords ranking in positions 81-90.
84 pub pos_81_90: Option<i64>,
85 /// Number of keywords ranking in positions 91-100.
86 pub pos_91_100: Option<i64>,
87 /// Estimated monthly traffic volume derived from ranking position and CTR.
88 pub etv: Option<f64>,
89 /// Total number of ranking keywords.
90 pub count: Option<i64>,
91 /// Estimated monthly cost (USD) of the equivalent paid traffic.
92 pub estimated_paid_traffic_cost: Option<f64>,
93}
94
95/// Backlink summary attached to a Whois record.
96#[derive(Debug, Default, Serialize, Deserialize, Clone)]
97pub struct DomainAnalyticsApiWhoisBacklinksInfo {
98 /// Number of referring domains pointing to the target.
99 pub referring_domains: Option<i64>,
100 /// Number of referring root domains pointing to the target.
101 pub referring_main_domains: Option<i64>,
102 /// Number of referring pages pointing to the target.
103 pub referring_pages: Option<i64>,
104 /// Number of dofollow backlinks pointing to the target.
105 pub dofollow: Option<i64>,
106 /// Total number of backlinks pointing to the target.
107 pub backlinks: Option<i64>,
108 /// Date the backlink metrics were last updated (UTC).
109 pub time_update: Option<String>,
110}