get_request.rs 782 B

1234567891011121314151617181920212223242526272829
  1. use {
  2. crate::{api::ChainId, config::ConfigOptions},
  3. clap::Args,
  4. ethers::types::Address,
  5. };
  6. #[derive(Args, Clone, Debug)]
  7. #[command(next_help_heading = "Get Request Options")]
  8. #[group(id = "GetRequest")]
  9. pub struct GetRequestOptions {
  10. #[command(flatten)]
  11. pub config: ConfigOptions,
  12. /// Retrieve a randomness request to this provider
  13. #[arg(long = "chain-id")]
  14. #[arg(env = "FORTUNA_CHAIN_ID")]
  15. pub chain_id: ChainId,
  16. /// Retrieve a randomness request to this provider
  17. #[arg(long = "provider")]
  18. #[arg(env = "FORTUNA_PROVIDER")]
  19. pub provider: Address,
  20. /// The sequence number of the request to retrieve
  21. #[arg(long = "sequence")]
  22. #[arg(env = "FORTUNA_SEQUENCE")]
  23. #[arg(default_value = "0")]
  24. pub sequence: u64,
  25. }