Manage custom items
You can store additional information associated with a room as key-value pairs in a room
object. Custom key-value items are saved as an object and can be updated or deleted as long as the room status remains Open
. You can add information related to customer service, refund, or inquiry as custom items to improve user experience.
Add custom items
After a room has been created, users can add custom items to roomParams
as an object. By default, customItems
is an empty object.
Update and delete custom items
You can update or delete custom items that are added to a room. To update a custom item, call the room.UpdateCustomItems()
method. A new item with a new key will be added to the list of custom items. If a newly created custom item has the same key as the existing custom item, the value of the new item will replace the value of the existing item.
You can delete custom items by passing the list of keys to the existing custom items as a parameter to the room.DeleteCustomItems()
method.