diff --git a/crates/ruma-common/CHANGELOG.md b/crates/ruma-common/CHANGELOG.md
index 8815e9c2..fd537940 100644
--- a/crates/ruma-common/CHANGELOG.md
+++ b/crates/ruma-common/CHANGELOG.md
@@ -32,7 +32,7 @@ Breaking changes:
Improvements:
-* Add `MatrixVersion::V1_4`
+* Add `MatrixVersion::V1_4` and `MatrixVersion::V1_5`
* Stabilize default room server ACL push rule
* Stabilize `room_types` in `directory::Filter` and `room_type` in `directory::PublicRoomsChunk`
* Stabilize support for private read receipts
diff --git a/crates/ruma-common/src/api/metadata.rs b/crates/ruma-common/src/api/metadata.rs
index ccfec68b..4b122e65 100644
--- a/crates/ruma-common/src/api/metadata.rs
+++ b/crates/ruma-common/src/api/metadata.rs
@@ -500,6 +500,11 @@ pub enum MatrixVersion {
///
/// See .
V1_4,
+
+ /// Version 1.5 of the Matrix specification, released in Q4 2022.
+ ///
+ /// See .
+ V1_5,
}
impl TryFrom<&str> for MatrixVersion {
@@ -517,6 +522,7 @@ impl TryFrom<&str> for MatrixVersion {
"v1.2" => V1_2,
"v1.3" => V1_3,
"v1.4" => V1_4,
+ "v1.5" => V1_5,
_ => return Err(UnknownVersionError),
})
}
@@ -560,6 +566,7 @@ impl MatrixVersion {
MatrixVersion::V1_2 => (1, 2),
MatrixVersion::V1_3 => (1, 3),
MatrixVersion::V1_4 => (1, 4),
+ MatrixVersion::V1_5 => (1, 5),
}
}
@@ -571,6 +578,7 @@ impl MatrixVersion {
(1, 2) => Ok(MatrixVersion::V1_2),
(1, 3) => Ok(MatrixVersion::V1_3),
(1, 4) => Ok(MatrixVersion::V1_4),
+ (1, 5) => Ok(MatrixVersion::V1_5),
_ => Err(UnknownVersionError),
}
}
@@ -644,7 +652,9 @@ impl MatrixVersion {
//
MatrixVersion::V1_3
//
- | MatrixVersion::V1_4 => RoomVersionId::V9,
+ | MatrixVersion::V1_4
+ //
+ | MatrixVersion::V1_5 => RoomVersionId::V9,
}
}
}