diff --git a/crates/bitwarden/src/tool/generators/username_forwarders/simplelogin.rs b/crates/bitwarden/src/tool/generators/username_forwarders/simplelogin.rs index 3c09fc691..6c4f9dab4 100644 --- a/crates/bitwarden/src/tool/generators/username_forwarders/simplelogin.rs +++ b/crates/bitwarden/src/tool/generators/username_forwarders/simplelogin.rs @@ -31,7 +31,7 @@ async fn generate_with_api_url( let response = http .post(format!("{api_url}/api/alias/random/new{query}")) .header(CONTENT_TYPE, "application/json") - .bearer_auth(api_key) + .header("Authentication", api_key) .json(&Request { note }) .send() .await?; @@ -65,7 +65,7 @@ mod tests { .and(matchers::method("POST")) .and(matchers::query_param("hostname", "example.com")) .and(matchers::header("Content-Type", "application/json")) - .and(matchers::header("Authorization", "Bearer MY_TOKEN")) + .and(matchers::header("Authentication", "MY_TOKEN")) .and(matchers::body_json(json!({ "note": "Website: example.com. Generated by Bitwarden." }))) @@ -78,7 +78,7 @@ mod tests { .and(matchers::method("POST")) .and(matchers::query_param("hostname", "example.com")) .and(matchers::header("Content-Type", "application/json")) - .and(matchers::header("Authorization", "Bearer MY_FAKE_TOKEN")) + .and(matchers::header("Authentication", "MY_FAKE_TOKEN")) .and(matchers::body_json(json!({ "note": "Website: example.com. Generated by Bitwarden." })))