# Changelog for version 2.0.0

* API redesign, with different ownership requirements for many string function arguments
  - This is because `libolm` sometimes internally modifies supplied buffers, and sometimes doesn't. The changes in the API were made to better reflect this: to not require ownership where it isn't necessary, and to require ownership, where provided data is modified.
* `OlmMessage::from_type_and_ciphertext(…)` now returns `Result<Self, UnknownOlmMessageType>`, instead of `Result<Self, ()>`
* fixes bug in `PkMessage::new(…)`, where the arguments `mac` and `ephemeral_key` were flipped
* `usize` now implements the trait `From<OlmMessageType>`
* added intra-documentation links where adequate

### Internal changes

* use new internal `ByteBuf` type for safely encapsulating raw object buffers

### Contributors

Thank you to Jonas Platte for doing the `ByteBuf` changes, and to poljar for reviewing the new API.

---

Johannes Hayeß
