Skip to content

Commit e03681c

Browse files
chore: reorder commands based on Openapi priority
1 parent 184afb4 commit e03681c

File tree

3 files changed

+105
-105
lines changed

3 files changed

+105
-105
lines changed

src/cli.rs

Lines changed: 67 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -26,52 +26,41 @@ pub enum Commands {
2626
command: token::TokenCommands,
2727
},
2828

29-
/// Company data and information
30-
Company {
31-
#[command(subcommand)]
32-
command: company::CompanyCommands,
33-
},
34-
35-
/// SMS messaging (v2)
36-
Sms {
37-
#[command(subcommand)]
38-
command: sms::SmsCommands,
39-
},
40-
4129
/// Electronic signature
4230
Esignature {
4331
#[command(subcommand)]
4432
command: esignature::EsignatureCommands,
4533
},
4634

47-
/// Risk reports and scoring
48-
Risk {
49-
#[command(subcommand)]
50-
command: risk::RiskCommands,
51-
},
52-
5335
/// AI language models
5436
Ai {
5537
#[command(subcommand)]
5638
command: ai::AiCommands,
5739
},
5840

41+
/// SMS messaging (v2)
42+
Sms {
43+
#[command(subcommand)]
44+
command: sms::SmsCommands,
45+
},
46+
5947
/// Trust verification services
6048
Trust {
6149
#[command(subcommand)]
6250
command: trust::TrustCommands,
6351
},
6452

65-
/// Geocoding and reverse geocoding
66-
Geocoding {
53+
/// Foreign currency exchange rates
54+
#[command(name = "exchange-rate")]
55+
ExchangeRate {
6756
#[command(subcommand)]
68-
command: geocoding::GeocodingCommands,
57+
command: exchange_rate::ExchangeRateCommands,
6958
},
7059

71-
/// Electronic invoicing
72-
Invoice {
60+
/// Risk reports and scoring
61+
Risk {
7362
#[command(subcommand)]
74-
command: invoice::InvoiceCommands,
63+
command: risk::RiskCommands,
7564
},
7665

7766
/// Automotive data (vehicles, insurance)
@@ -80,17 +69,17 @@ pub enum Commands {
8069
command: automotive::AutomotiveCommands,
8170
},
8271

83-
/// Official documents (Business Register, Revenue Agency, INPS)
84-
Docuengine {
72+
/// SDI electronic invoicing
73+
Sdi {
8574
#[command(subcommand)]
86-
command: docuengine::DocuengineCommands,
75+
command: sdi::SdiCommands,
8776
},
8877

89-
/// Chamber of Commerce documents
90-
#[command(name = "chamber-of-commerce")]
91-
ChamberOfCommerce {
78+
/// Document time stamping
79+
#[command(name = "time-stamping")]
80+
TimeStamping {
9281
#[command(subcommand)]
93-
command: chamber_of_commerce::ChamberOfCommerceCommands,
82+
command: time_stamping::TimeStampingCommands,
9483
},
9584

9685
/// Real estate valuation data
@@ -100,30 +89,35 @@ pub enum Commands {
10089
command: real_estate::RealEstateCommands,
10190
},
10291

103-
/// Zip codes, municipalities, provinces, regions
104-
#[command(name = "zip-codes")]
105-
ZipCodes {
92+
/// Italian cadastral data
93+
Cadastre {
10694
#[command(subcommand)]
107-
command: zip_codes::ZipCodesCommands,
95+
command: cadastre::CadastreCommands,
10896
},
10997

110-
/// Official documents (Chamber of Commerce, INPS, Tax Agency)
111-
Visengine {
98+
/// Italian certified email (PEC / Legalmail)
99+
#[command(name = "certified-email")]
100+
CertifiedEmail {
112101
#[command(subcommand)]
113-
command: visengine::VisengineCommands,
102+
command: certified_email::CertifiedEmailCommands,
114103
},
115104

116-
/// Italian cadastral data
117-
Cadastre {
105+
/// .it domain management
106+
Domains {
118107
#[command(subcommand)]
119-
command: cadastre::CadastreCommands,
108+
command: domains::DomainsCommands,
120109
},
121110

122-
/// Postal mail service
123-
#[command(name = "postal-service")]
124-
PostalService {
111+
/// Geocoding and reverse geocoding
112+
Geocoding {
125113
#[command(subcommand)]
126-
command: postal_service::PostalServiceCommands,
114+
command: geocoding::GeocodingCommands,
115+
},
116+
117+
/// Electronic invoicing
118+
Invoice {
119+
#[command(subcommand)]
120+
command: invoice::InvoiceCommands,
127121
},
128122

129123
/// Massive Registered Electronic Mail
@@ -133,50 +127,56 @@ pub enum Commands {
133127
command: massive_rem::MassiveRemCommands,
134128
},
135129

130+
/// Bills payment
131+
#[command(name = "paying-bills")]
132+
PayingBills {
133+
#[command(subcommand)]
134+
command: paying_bills::PayingBillsCommands,
135+
},
136+
136137
/// HTML to PDF conversion
137138
Pdf {
138139
#[command(subcommand)]
139140
command: pdf::PdfCommands,
140141
},
141142

142-
/// Document time stamping
143-
#[command(name = "time-stamping")]
144-
TimeStamping {
143+
/// Postal mail service
144+
#[command(name = "postal-service")]
145+
PostalService {
145146
#[command(subcommand)]
146-
command: time_stamping::TimeStampingCommands,
147+
command: postal_service::PostalServiceCommands,
147148
},
148149

149-
/// Italian certified email (PEC / Legalmail)
150-
#[command(name = "certified-email")]
151-
CertifiedEmail {
150+
/// Official documents (Chamber of Commerce, INPS, Tax Agency)
151+
Visengine {
152152
#[command(subcommand)]
153-
command: certified_email::CertifiedEmailCommands,
153+
command: visengine::VisengineCommands,
154154
},
155155

156-
/// Bills payment
157-
#[command(name = "paying-bills")]
158-
PayingBills {
156+
/// Zip codes, municipalities, provinces, regions
157+
#[command(name = "zip-codes")]
158+
ZipCodes {
159159
#[command(subcommand)]
160-
command: paying_bills::PayingBillsCommands,
160+
command: zip_codes::ZipCodesCommands,
161161
},
162162

163-
/// Foreign currency exchange rates
164-
#[command(name = "exchange-rate")]
165-
ExchangeRate {
163+
/// Company data and information
164+
Company {
166165
#[command(subcommand)]
167-
command: exchange_rate::ExchangeRateCommands,
166+
command: company::CompanyCommands,
168167
},
169168

170-
/// .it domain management
171-
Domains {
169+
/// Chamber of Commerce documents
170+
#[command(name = "chamber-of-commerce")]
171+
ChamberOfCommerce {
172172
#[command(subcommand)]
173-
command: domains::DomainsCommands,
173+
command: chamber_of_commerce::ChamberOfCommerceCommands,
174174
},
175175

176-
/// SDI electronic invoicing
177-
Sdi {
176+
/// Official documents (Business Register, Revenue Agency, INPS)
177+
Docuengine {
178178
#[command(subcommand)]
179-
command: sdi::SdiCommands,
179+
command: docuengine::DocuengineCommands,
180180
},
181181

182182
/// Show configuration status and readiness

src/commands/mod.rs

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
pub mod token;
2-
pub mod company;
3-
pub mod sms;
42
pub mod esignature;
5-
pub mod risk;
63
pub mod ai;
4+
pub mod sms;
75
pub mod trust;
8-
pub mod geocoding;
9-
pub mod invoice;
6+
pub mod exchange_rate;
7+
pub mod risk;
108
pub mod automotive;
11-
pub mod docuengine;
12-
pub mod chamber_of_commerce;
9+
pub mod sdi;
10+
pub mod time_stamping;
1311
pub mod real_estate;
14-
pub mod zip_codes;
15-
pub mod visengine;
1612
pub mod cadastre;
17-
pub mod postal_service;
18-
pub mod massive_rem;
19-
pub mod pdf;
20-
pub mod time_stamping;
2113
pub mod certified_email;
22-
pub mod paying_bills;
23-
pub mod exchange_rate;
2414
pub mod domains;
25-
pub mod sdi;
15+
pub mod geocoding;
16+
pub mod invoice;
2617
pub mod info;
18+
pub mod massive_rem;
19+
pub mod paying_bills;
20+
pub mod pdf;
21+
pub mod postal_service;
22+
pub mod company;
23+
pub mod chamber_of_commerce;
24+
pub mod docuengine;
25+
pub mod visengine;
26+
pub mod zip_codes;

src/main.rs

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -31,42 +31,42 @@ async fn main() -> Result<()> {
3131
let client = ApiClient::new(config)?;
3232

3333
match &cli.command {
34-
Commands::Company { command } => commands::company::execute(command, &client).await,
35-
Commands::Sms { command } => commands::sms::execute(command, &client).await,
3634
Commands::Esignature { command } => commands::esignature::execute(command, &client).await,
37-
Commands::Risk { command } => commands::risk::execute(command, &client).await,
3835
Commands::Ai { command } => commands::ai::execute(command, &client).await,
36+
Commands::Sms { command } => commands::sms::execute(command, &client).await,
3937
Commands::Trust { command } => commands::trust::execute(command, &client).await,
40-
Commands::Geocoding { command } => commands::geocoding::execute(command, &client).await,
41-
Commands::Invoice { command } => commands::invoice::execute(command, &client).await,
42-
Commands::Automotive { command } => commands::automotive::execute(command, &client).await,
43-
Commands::Docuengine { command } => commands::docuengine::execute(command, &client).await,
44-
Commands::ChamberOfCommerce { command } => {
45-
commands::chamber_of_commerce::execute(command, &client).await
46-
}
47-
Commands::RealEstate { command } => commands::real_estate::execute(command, &client).await,
48-
Commands::ZipCodes { command } => commands::zip_codes::execute(command, &client).await,
49-
Commands::Visengine { command } => commands::visengine::execute(command, &client).await,
50-
Commands::Cadastre { command } => commands::cadastre::execute(command, &client).await,
51-
Commands::PostalService { command } => {
52-
commands::postal_service::execute(command, &client).await
38+
Commands::ExchangeRate { command } => {
39+
commands::exchange_rate::execute(command, &client).await
5340
}
54-
Commands::MassiveRem { command } => commands::massive_rem::execute(command, &client).await,
55-
Commands::Pdf { command } => commands::pdf::execute(command, &client).await,
41+
Commands::Risk { command } => commands::risk::execute(command, &client).await,
42+
Commands::Automotive { command } => commands::automotive::execute(command, &client).await,
43+
Commands::Sdi { command } => commands::sdi::execute(command, &client).await,
5644
Commands::TimeStamping { command } => {
5745
commands::time_stamping::execute(command, &client).await
5846
}
47+
Commands::RealEstate { command } => commands::real_estate::execute(command, &client).await,
48+
Commands::Cadastre { command } => commands::cadastre::execute(command, &client).await,
5949
Commands::CertifiedEmail { command } => {
6050
commands::certified_email::execute(command, &client).await
6151
}
52+
Commands::Domains { command } => commands::domains::execute(command, &client).await,
53+
Commands::Geocoding { command } => commands::geocoding::execute(command, &client).await,
54+
Commands::Invoice { command } => commands::invoice::execute(command, &client).await,
55+
Commands::MassiveRem { command } => commands::massive_rem::execute(command, &client).await,
6256
Commands::PayingBills { command } => {
6357
commands::paying_bills::execute(command, &client).await
6458
}
65-
Commands::ExchangeRate { command } => {
66-
commands::exchange_rate::execute(command, &client).await
59+
Commands::Pdf { command } => commands::pdf::execute(command, &client).await,
60+
Commands::PostalService { command } => {
61+
commands::postal_service::execute(command, &client).await
6762
}
68-
Commands::Domains { command } => commands::domains::execute(command, &client).await,
69-
Commands::Sdi { command } => commands::sdi::execute(command, &client).await,
63+
Commands::Visengine { command } => commands::visengine::execute(command, &client).await,
64+
Commands::ZipCodes { command } => commands::zip_codes::execute(command, &client).await,
65+
Commands::Company { command } => commands::company::execute(command, &client).await,
66+
Commands::ChamberOfCommerce { command } => {
67+
commands::chamber_of_commerce::execute(command, &client).await
68+
}
69+
Commands::Docuengine { command } => commands::docuengine::execute(command, &client).await,
7070
Commands::Info | Commands::Token { .. } => unreachable!(),
7171
}
7272
}

0 commit comments

Comments
 (0)