Crate wicrs_server

Source

Re-exports§

pub use pgp;

Modules§

api
Public API for performing user actions, should be used for creating API implementations like the HTTP API or similar.
channel
Message storage and retreival for channels.
config
Various objects for storing configuration.
error
Errors
graphql_model
GraphQL model definition.
httpapi
Definition of the HTTP API.
hub
Hubs, permission management, channel management and member management.
permission
Permissions are defined here.
server
Server implementation.
signing
websocket
Definition of the WebSocket API.

Macros§

check_permission
Checks that a hub member has a given permission and returns an error if it doesn’t.

Constants§

MAX_DESCRIPTION_SIZE
Maximum size of a description in bytes. Clients should be able to accept larger and smaller values.
MAX_NAME_SIZE
Maximum size of a username in bytes. Clients should be able to accept larger and smaller values.
MAX_STATUS_SIZE
Maximum size of a user status in bytes. Clients should be able to accept larger and smaller values.
MESSAGE_MAX_SIZE
Maximum size of a message in bytes. Clients should be able to accept larger and smaller values.
TANTIVY_COMMIT_THRESHOLD
How long to wait before commiting new messages to the tantivy search engine in milliseconds, this takes a lot of time, which is why it should be done only periodically.

Functions§

check_name_validity
Wraps is_valid_name to return a Result<()>.
is_valid_name
Checks if a name is valid (not too long and only allowed characters).
new_id
Generates a new random ID.
start
Starts WICRS Server in the current directory loading the configuration from config.json.

Type Aliases§

ID
Type used to represent IDs of non user objects throughout wicrs.