struct
#include <include/mtx/requests.hpp>
CreateRoom Request payload for the POST /_matrix/client/r0/createRoom
endpoint.
Public variables
- std::string name
- If this is included, an
m.room.name
event will be sent into the room to indicate the name of the room. - std::string topic
- If this is included, an
m.room.topic
event will be sent into the room to indicate the topic for the room. - std::string room_alias_name
- The desired room alias local part. e.g
#foo:example.com
. - std::vector<std::string> invite
- A list of user IDs to invite to the room.
- bool is_direct
- This flag makes the server set the is_direct flag on the
m.room.member
events sent to the users ininvite
andinvite_3pid
. - Preset preset
- Convenience parameter for setting various default state events.
-
common::
RoomVisibility visibility - Whether or not the room will be visible by non members.
-
std::vector<events::
collections:: StrippedEvents> initial_state - A list of state events to set in the new room. This allows the user to override the default state events set in the new room. The expected format of the state events are an object with type, state_key and content keys set.
- std::string room_version
- The room version to set for the room. If not provided, the homeserver is to use its configured default. If provided, the homeserver will return a 400 error with the errcode M_UNSUPPORTED_ROOM_VERSION if it does not support the room version.
-
std::optional<events::
state:: Create> creation_content - Extra keys, such as m.federate, to be added to the content of the m.room.create event. The server will overwrite the following keys: creator, room_version. Future versions of the specification may allow the server to overwrite other keys.