summaryrefslogblamecommitdiff
path: root/makima/src/daemon/cli/directive.rs
blob: 5ce88c589444b8f683af071231e6f92176523097 (plain) (tree)







































                                                                                                
//! Directive subcommand - directive orchestration commands.

use clap::Args;
use uuid::Uuid;

/// Common arguments for directive commands.
#[derive(Args, Debug, Clone)]
pub struct DirectiveArgs {
    /// API URL
    #[arg(long, env = "MAKIMA_API_URL", default_value = "https://api.makima.jp", global = true)]
    pub api_url: String,

    /// API key for authentication
    #[arg(long, env = "MAKIMA_API_KEY", global = true)]
    pub api_key: String,

    /// Directive ID
    #[arg(long, env = "MAKIMA_DIRECTIVE_ID", global = true)]
    pub directive_id: Uuid,
}

/// Arguments for chain command (get specific chain).
#[derive(Args, Debug)]
pub struct ChainArgs {
    #[command(flatten)]
    pub common: DirectiveArgs,

    /// Chain ID to retrieve
    pub chain_id: Uuid,
}

/// Arguments for update-status command.
#[derive(Args, Debug)]
pub struct UpdateStatusArgs {
    #[command(flatten)]
    pub common: DirectiveArgs,

    /// New status (draft, planning, active, paused, completed, archived, failed)
    pub status: String,
}