| mx_register | R Documentation |
Creates a new user via POST /_matrix/client/v3/register using
the m.login.dummy auth flow. Most homeservers only accept this
when open registration is enabled (or a registration token is
supplied). On success returns a ready-to-use mx_session —
registration also logs the new user in.
mx_register(
server,
username,
password,
device_id = NULL,
initial_device_display_name = NULL,
inhibit_login = FALSE
)
server |
Character. Homeserver base URL. |
username |
Character. Desired localpart (e.g. "alice"). |
password |
Character. Account password. |
device_id |
Character or NULL. Device id to assign; a server- generated one is used if NULL. |
initial_device_display_name |
Character or NULL. Human-readable label for the device. |
inhibit_login |
Logical. When TRUE, the server creates the
account but does not return a session; the call returns a list
with the new |
An mx_session object on login, or a list with
user_id when inhibit_login = TRUE.
## Not run:
s <- mx_register("https://matrix.example", "alice", "hunter2")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.