- let example_payload = r#"{\"notificationIdentityPublicKeys\":{\"curve25519\":\"DYmV8VdkjwG/VtC8C53morogNJhpTPT/4jzW0/cxzQo\",\"ed25519\":\"D0BV2Y7Qm36VUtjwyQTJJWYAycN7aMSJmhEsRJpW2mk\"},\"primaryIdentityPublicKeys\":{\"curve25519\":\"Y4ZIqzpE1nv83kKGfvFP6rifya0itRg2hifqYtsISnk\",\"ed25519\":\"cSlL+VLLJDgtKSPlIwoCZg0h0EmHlQoJC08uV/O+jvg\"}}"#;
+ let keys = keys.unwrap_or_else(|| &DEFAULT_CLIENT_KEYS);
+ let example_payload =
+ serde_json::to_string(&keys).expect("Failed to serialize example payload");
// The ed25519 value from the olm payload
- let device_id = r#"cSlL+VLLJDgtKSPlIwoCZg0h0EmHlQoJC08uV/O+jvg"#;
+ let device_id = &keys.primary_identity_public_keys.ed25519;
let mut client_registration = Registration::new();