realtime_configs
Creates, updates, deletes, gets or lists a realtime_configs resource.
Overview​
| Name | realtime_configs |
| Type | Resource |
| Id | supabase.config.realtime_configs |
Fields​
The following fields are returned by SELECT queries:
- get
Gets project's realtime configuration
| Name | Datatype | Description |
|---|---|---|
connection_pool | integer | Sets connection pool size for Realtime Authorization |
max_bytes_per_second | integer | Sets maximum number of bytes per second rate per channel limit |
max_channels_per_client | integer | Sets maximum number of channels per client rate limit |
max_concurrent_users | integer | Sets maximum number of concurrent users rate limit |
max_events_per_second | integer | Sets maximum number of events per second rate per channel limit |
max_joins_per_second | integer | Sets maximum number of joins per second rate limit |
max_payload_size_in_kb | integer | Sets maximum number of payload size in KB rate limit |
max_presence_events_per_second | integer | Sets maximum number of presence events per second rate limit |
postgres_changes_pool | integer | Sets connection pool size used to create Postgres Changes subscriptions |
presence_enabled | boolean | Whether to enable presence |
private_only | boolean | Whether to only allow private channels |
suspend | boolean | Disables the Realtime service for this project when true. Set to false to re-enable it. |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | ref | ||
update | update | ref | ||
shutdown | exec | ref |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
ref | string | Supabase project reference (the Project ID shown in the dashboard under Settings -> General; 20 lowercase letters). Resolved from the SUPABASE_PROJECT_ID environment variable when it is set (x-stackQL-envVar); otherwise it must be supplied on every project-scoped query as WHERE ref = '<ref>'. A WHERE value always takes precedence over the environment. (x-stackQL-envVar: SUPABASE_PROJECT_ID) |
SELECT examples​
- get
Gets project's realtime configuration
SELECT
connection_pool,
max_bytes_per_second,
max_channels_per_client,
max_concurrent_users,
max_events_per_second,
max_joins_per_second,
max_payload_size_in_kb,
max_presence_events_per_second,
postgres_changes_pool,
presence_enabled,
private_only,
suspend
FROM supabase.config.realtime_configs
WHERE ref = '{{ ref }}' -- required unless SUPABASE_PROJECT_ID is set
;
UPDATE examples​
- update
No description available.
UPDATE supabase.config.realtime_configs
SET
private_only = {{ private_only }},
connection_pool = {{ connection_pool }},
postgres_changes_pool = {{ postgres_changes_pool }},
max_concurrent_users = {{ max_concurrent_users }},
max_events_per_second = {{ max_events_per_second }},
max_bytes_per_second = {{ max_bytes_per_second }},
max_channels_per_client = {{ max_channels_per_client }},
max_joins_per_second = {{ max_joins_per_second }},
max_presence_events_per_second = {{ max_presence_events_per_second }},
max_payload_size_in_kb = {{ max_payload_size_in_kb }},
suspend = {{ suspend }},
presence_enabled = {{ presence_enabled }}
WHERE
ref = '{{ ref }}' --required unless SUPABASE_PROJECT_ID is set;
Lifecycle Methods​
EXEC variables use wire (API) names.
- shutdown
Realtime connections shutdown successfully
EXEC supabase.config.realtime_configs.shutdown
@ref='{{ ref }}' --required unless SUPABASE_PROJECT_ID is set
;