---
title: "Block - Main Group - realtime · RUAL Documentation"
description: "29 RUAL blueprint blocks in the realtime main group, sorted into 5 groups. Open a group to find a block and read its pins, canvas example and version history."
canonical: https://docs.rual.nl/block-types/realtime
language: en
---

# realtime

29 blocks in 5 groups. Open a block for its pins, an example and how it behaves.

## expiring sets

- [touch expiring set `condition` `v15.0.2` Adds a member to an expiring set for `ttl_ms`, or renews it: staff on shift while their heartbeats keep arriving, a job claimed while its worker reports progress.](https://docs.rual.nl/block-types/realtime/liveset_touch)

- [on expiring set change `execute_function` `v15.0.2` Runs when a member joins or leaves an expiring set whose name starts with the prefix in `event`: a device coming online in `devices:`, a member of staff whose shift heartbeats stopped in `shifts:`. Once per change, across the cluster.](https://docs.rual.nl/block-types/realtime/trigger_liveset_change)

- [expiring set members `array` `v15.0.2` The members of an expiring set, with their data and since when: the devices online at a site, the staff on shift at a depot.](https://docs.rual.nl/block-types/realtime/liveset_members)

- [add to expiring set `condition` `v15.0.2` Adds a member to an expiring set, held by the running socket (until it closes, then for `linger_ms`) or for `ttl_ms`: a device that stays online while its connection does, a worker that stays in a pool while it is connected.](https://docs.rual.nl/block-types/realtime/liveset_add)

- [remove from expiring set `condition` `v15.0.2` Takes a member out of an expiring set now, or with `hold_only` drops only the running socket's hold: a device taken out of service, a worker leaving its pool.](https://docs.rual.nl/block-types/realtime/liveset_remove)

## notifications

- [send notification `condition` `v15.0.2` Sends a phone notification to users' registered devices or to given devices, through APNs and FCM.](https://docs.rual.nl/block-types/realtime/notification_send)

- [remove device `condition` `v15.0.2` Removes a device by its token, or clears a VoIP token from its device.](https://docs.rual.nl/block-types/realtime/notification_device_remove)

- [register device `condition` `v15.0.2` Registers a device's notification token for a user.](https://docs.rual.nl/block-types/realtime/notification_device_set)

- [devices `condition` `v15.0.2` A user's registered devices.](https://docs.rual.nl/block-types/realtime/notification_devices)

## realtime

- [disconnect `condition` `v15.0.2` Closes sockets: the run's, a session's or every socket of a user, after an optional last push.](https://docs.rual.nl/block-types/realtime/realtime_disconnect)

- [on socket disconnect `execute_function` `v15.0.2` Runs once per realtime socket when it closes, with the reason: client_closed, server_closed, kicked, token_revoked, write_queue_full, rate_limited, drained or node_lost. node_lost fires from another node for the sockets of a node that died.](https://docs.rual.nl/block-types/realtime/trigger_socket_disconnect)

- [rooms `object` `v15.0.2` A session's rooms, each with the seq it was joined at.](https://docs.rual.nl/block-types/realtime/realtime_rooms)

- [subscribe `condition` `v15.0.2` Adds rooms to a socket's session, a session or every session of a user, on any node.](https://docs.rual.nl/block-types/realtime/realtime_subscribe)

- [unsubscribe `condition` `v15.0.2` Removes rooms from a socket's session, a session or every session of a user, on any node.](https://docs.rual.nl/block-types/realtime/realtime_unsubscribe)

- [on socket method `execute_function` `v15.0.2` Answers a realtime socket method by name: the method in `event`, the function on On Method.](https://docs.rual.nl/block-types/realtime/on_startup_register_socket_method)

- [push `condition` `v15.0.2` Pushes a frame to every socket in the rooms, on every node.](https://docs.rual.nl/block-types/realtime/realtime_push)

- [on socket before `execute_function` `v15.0.2` Runs before every socket method of the entity; if it answers, the method does not run. Where the gates every method passes through go.](https://docs.rual.nl/block-types/realtime/trigger_socket_before)

- [on socket connect `execute_function` `v15.0.2` Runs when a realtime socket has upgraded, before its first frame. The function gets socket.](https://docs.rual.nl/block-types/realtime/trigger_socket_connect)

## socket

- [current socket `socketconnection` `v15.0.2` The realtime socket the running method or trigger came from.](https://docs.rual.nl/block-types/realtime/socket_current)

- [api request for the socket `condition` `v15.0.3` Sends a request to this core's own API on behalf of the socket of the run, in process: the route sees the socket's address, user agent and host.](https://docs.rual.nl/block-types/realtime/socket_api_request)

- [open session `condition` `v15.0.2` Authenticates the socket with an access token and creates or resumes its session.](https://docs.rual.nl/block-types/realtime/socket_session_open)

- [answer `condition` `v15.0.2` Answers the socket method that is running: `{method, payload, request_id}`, or the error code in `error`.](https://docs.rual.nl/block-types/realtime/socket_answer)

## voice

- [close room `condition` `v15.0.2` Ends a voice room: everyone is disconnected and the room's node placement is released.](https://docs.rual.nl/block-types/realtime/voice_room_close)

- [receive voice event `condition` `v15.0.2` Verifies an event a voice node posted and reads it: somebody joined, left, published a track, a room ended.](https://docs.rual.nl/block-types/realtime/voice_webhook_receive)

- [room participants `condition` `v15.0.2` Who is in a voice room now, as the node sees it.](https://docs.rual.nl/block-types/realtime/voice_room_participants)

- [send room data `condition` `v15.0.2` Sends a message on a voice room's data channel, from the server.](https://docs.rual.nl/block-types/realtime/voice_room_send_data)

- [remove participant `condition` `v15.0.2` Disconnects a participant from a voice room.](https://docs.rual.nl/block-types/realtime/voice_room_remove_participant)

- [update participant `condition` `v15.0.2` Changes a participant in the live room: mute, deafen, let speak, rename, new metadata. No reconnect.](https://docs.rual.nl/block-types/realtime/voice_room_update_participant)

- [voice token `condition` `v15.0.2` Lets one person into a voice or video room: a signed join token and the node to connect to.](https://docs.rual.nl/block-types/realtime/voice_token)

- [All block groups](https://docs.rual.nl/block-types): Back to the overview of every group.
