use clap::Subcommand;
use crate::clients::ClientKind;
#[derive(Debug, Subcommand)]
pub enum ClientOp {
List {
#[arg(long)]
json: bool,
},
#[command(alias = "create", alias = "add")]
Setup {
#[arg(value_enum)]
client: ClientKind,
#[arg(long, hide_env_values = true, conflicts_with = "token_stdin")]
token: Option<String>,
#[arg(long, conflicts_with = "token")]
token_stdin: bool,
#[arg(long = "server", alias = "base-url", value_name = "URL")]
base_url: Option<String>,
#[arg(long, default_value_t = 24)]
ttl_hours: i64,
},
Show {
#[arg(value_enum)]
client: ClientKind,
#[arg(long)]
json: bool,
},
#[command(alias = "delete", alias = "revoke")]
Remove {
#[arg(value_enum)]
client: ClientKind,
#[arg(long)]
revoke_supplied: bool,
#[arg(long)]
force: bool,
},
Doctor {
#[arg(value_enum)]
client: ClientKind,
},
}