Skip to main content

odin_room_create_ex

enum OdinError odin_room_create_ex(struct OdinConnectionPool *connection_pool,
const char *uri,
const char *token,
const char *room_name,
const unsigned char *user_data,
uint32_t user_data_length,
const float position[3],
struct OdinCipher *cipher,
struct OdinRoom **out_room);

Overview

Creates a new ODIN room with advanced parameters. In addition to the parameters required by the basic variant, this function accepts an optional room name, initial user data, 3D coordinates, and an optional ODIN cipher plugin.

Parameters

NameTypeDescription
connection_poolstruct OdinConnectionPool *The connection pool used manager the connection.
uriconst char *The URL of the ODIN gateway or server.
tokenconst char *A valid signed JWT token.
room_nameconst char *(Optional) Specific room name to join if token has multiple.
user_dataconst unsigned char *(Optional) Initial user data.
user_data_lengthuint32_tLength of user data.
positionconst float[3](Optional) Initial 3D position [x, y, z].
cipherstruct OdinCipher *(Optional) Cipher module for E2E encryption.
out_roomstruct OdinRoom **Pointer to receive the handle of the newly created room.

Return Value

TypeDescription
OdinErrorODIN_ERROR_SUCCESS on success.