Skip to main content

sign_with_api_key

Function sign_with_api_key 

Source
pub fn sign_with_api_key(
    token: &str,
    wallet_name_or_id: &str,
    chain: &Chain,
    tx_bytes: &[u8],
    index: Option<u32>,
    vault_path: Option<&Path>,
) -> Result<SignResult, OwsLibError>
Expand description

Sign a transaction using an API token (agent mode).

  1. Look up key file by SHA256(token)
  2. Check expiry and wallet scope
  3. Load and evaluate policies
  4. HKDF(token) → decrypt mnemonic
  5. HD derive → sign