Cargo Features

Ruma has no features set by default.

[dependencies]
ruma = { version = "0.12.0", features = ["api", "canonical-json", "client", "events", "server-util", "signatures", "state-res", "client-ext-client-api", "client-hyper", "client-hyper-native-tls", "client-reqwest", "client-reqwest-native-tls", "client-reqwest-native-tls-alpn", "client-reqwest-native-tls-vendored", "client-reqwest-rustls-manual-roots", "client-reqwest-rustls-webpki-roots", "client-reqwest-rustls-native-roots", "appservice-api-c", "appservice-api-s", "appservice-api", "client-api-c", "client-api-s", "client-api", "federation-api-c", "federation-api-s", "federation-api", "identity-service-api-c", "identity-service-api-s", "identity-service-api", "push-gateway-api-c", "push-gateway-api-s", "push-gateway-api", "js", "rand", "markdown", "html", "html-matrix", "full", "compat", "compat-arbitrary-length-ids", "compat-server-signing-key-version", "compat-user-id", "compat-empty-string-null", "compat-null", "compat-optional", "compat-unset-avatar", "compat-get-3pids", "compat-upload-signatures", "compat-signature-id", "compat-tag-info", "compat-encrypted-stickers", "ring-compat", "unstable-extensible-events", "unstable-msc1767", "unstable-msc2409", "unstable-msc2448", "unstable-msc2654", "unstable-msc2666", "unstable-msc2747", "unstable-msc2867", "unstable-msc2870", "unstable-msc2965", "unstable-msc2967", "unstable-msc3061", "unstable-msc3202", "unstable-msc3245", "unstable-msc3245-v1-compat", "unstable-msc3246", "unstable-msc3266", "unstable-msc3381", "unstable-msc3401", "unstable-msc3488", "unstable-msc3489", "unstable-msc3551", "unstable-msc3552", "unstable-msc3553", "unstable-msc3554", "unstable-msc3575", "unstable-msc3618", "unstable-msc3723", "unstable-msc3814", "unstable-msc3843", "unstable-msc3927", "unstable-msc3930", "unstable-msc3931", "unstable-msc3932", "unstable-msc3954", "unstable-msc3955", "unstable-msc3956", "unstable-msc3983", "unstable-msc4075", "unstable-msc4095", "unstable-msc4108", "unstable-msc4121", "unstable-msc4125", "unstable-msc4140", "unstable-msc4151", "unstable-msc4171", "unstable-msc4186", "unstable-pdu", "unstable-unspecified"] }
api appservice-api-c? appservice-api-s? client-api-c? client-api-s? federation-api-c? federation-api-s? full? identity-service-api-c? identity-service-api-s? push-gateway-api-c? push-gateway-api-s?

Enables api of ruma-common

Affects ruma::api

canonical-json signatures?

Enables canonical-json of ruma-common and optional ruma-events

client client-ext-client-api? client-hyper? client-hyper-native-tls? client-reqwest? client-reqwest-native-tls? client-reqwest-native-tls-alpn? client-reqwest-native-tls-vendored? client-reqwest-rustls-manual-roots? client-reqwest-rustls-native-roots? client-reqwest-rustls-webpki-roots? full?

Enables ruma-client

events appservice-api-c? appservice-api-s? client-api-c? client-api-s? full?

Enables ruma-events

server-util

Enables ruma-server-util

signatures federation-api-c? federation-api-s? full? = canonical-json

Enables ruma-signatures

state-res full?

Enables ruma-state-res

client-ext-client-api full? = client

ruma-client feature flags

Enables client-api of optional ruma-client

client-hyper = client

Enables hyper of optional ruma-client

ruma-client:

HTTP clients

client-hyper-native-tls = client

Enables hyper-native-tls of optional ruma-client

client-reqwest = client

Enables reqwest of optional ruma-client

client-reqwest-native-tls = client

Enables reqwest-native-tls of optional ruma-client

client-reqwest-native-tls-alpn = client

Enables reqwest-native-tls-alpn of optional ruma-client

client-reqwest-native-tls-vendored = client

Enables reqwest-native-tls-vendored of optional ruma-client

client-reqwest-rustls-manual-roots = client

Enables reqwest-rustls-manual-roots of optional ruma-client

client-reqwest-rustls-webpki-roots = client

Enables reqwest-rustls-webpki-roots of optional ruma-client

client-reqwest-rustls-native-roots = client

Enables reqwest-rustls-native-roots of optional ruma-client

appservice-api-c appservice-api? = api, events

Enables client of ruma-appservice-api

appservice-api-s appservice-api? = api, events

Enables server of ruma-appservice-api

appservice-api full? = appservice-api-c, appservice-api-s
client-api-c client-api? = api, events

Enables client of ruma-client-api

ruma-client-api:

OutgoingRequest and IncomingResponse implementations

client-api-s client-api? = api, events

Enables server of ruma-client-api

ruma-client-api:

IncomingRequest and OutgoingResponse implementations

client-api full? = client-api-c, client-api-s
federation-api-c federation-api? = api, signatures

Enables client of ruma-federation-api

federation-api-s federation-api? = api, signatures

Enables server of ruma-federation-api

federation-api full? = federation-api-c, federation-api-s
identity-service-api-c identity-service-api? = api

Enables client of ruma-identity-service-api

identity-service-api-s identity-service-api? = api

Enables server of ruma-identity-service-api

identity-service-api full? = identity-service-api-c, identity-service-api-s
push-gateway-api-c push-gateway-api? = api

Enables client of ruma-push-gateway-api

push-gateway-api-s push-gateway-api? = api

Enables server of ruma-push-gateway-api

push-gateway-api full? = push-gateway-api-c, push-gateway-api-s
js

Required for randomness, current system time in browser environments

Enables js of ruma-common

rand full?

Convenience features

Enables rand of ruma-common

markdown full?

Enables markdown of optional ruma-events

html full? html-matrix?

Enables ruma-html, html of optional ruma-events

html-matrix full? = html

Enables matrix of ruma-html

full = api, appservice-api, client, client-api, client-ext-client-api, events, federation-api, html, html-matrix, identity-service-api, markdown, push-gateway-api, rand, signatures, state-res

Everything except compat, js and unstable features

compat = compat-empty-string-null, compat-get-3pids, compat-null, compat-optional, compat-server-signing-key-version, compat-signature-id, compat-tag-info, compat-unset-avatar, compat-user-id

Enable all compatibility hacks. Deprecated.

compat-arbitrary-length-ids

Allow IDs to exceed 255 bytes.

Enables compat-arbitrary-length-ids of ruma-common

compat-server-signing-key-version compat?

Don't validate ServerSigningKeyVersion.

Enables compat-server-signing-key-version of ruma-common

compat-user-id compat?

Allow some user IDs that are invalid even with the specified historical user ID scheme.

Enables compat-user-id of ruma-common

compat-empty-string-null compat?

Allow some mandatory fields in requests / responses to be missing, defaulting them to an empty string in deserialization.

Enables compat-empty-string-null of optional ruma-client-api, ruma-common, optional ruma-events, and optional ruma-federation-api

compat-null compat?

Allow certain fields to be null for compatibility, treating that the same as the field being absent.

Enables compat-null of ruma-common

compat-optional compat?

Allow certain fields to be absent even though the spec marks them as mandatory. Deserialization will yield a default value like an empty string.

Enables compat-optional of ruma-common and optional ruma-events

compat-unset-avatar compat?

Unset avatars by sending an empty string, same as what Element Web does, c.f. https://github.com/matrix-org/matrix-spec/issues/378#issuecomment-1055831264

Enables compat-unset-avatar of optional ruma-client-api

compat-get-3pids compat?

Always serialize the threepids response field in get_3pids::v3::Response, even if its value is an empty list.

Enables compat-get-3pids of optional ruma-client-api

compat-upload-signatures

Accept message as an alias for error in upload_signatures::v3::Failure, since that's what Synapse sends.

Enables compat-upload-signatures of optional ruma-client-api

compat-signature-id compat?

Allow extra characters in signature IDs not allowed in the specification.

Enables compat-signature-id of optional ruma-signatures

compat-tag-info compat?

Allow TagInfo to contain a stringified floating-point value for the order field.

Enables compat-tag-info of optional ruma-events

compat-encrypted-stickers

Support encrypted stickers, as sent by several bridges. https://github.com/matrix-org/matrix-spec/issues/1667

Enables compat-encrypted-stickers of optional ruma-events

ring-compat

Specific compatibility for past ring public/private key documents.

Enables ring-compat of ruma-signatures

unstable-extensible-events = unstable-msc3246, unstable-msc3488, unstable-msc3553, unstable-msc3954, unstable-msc3955

unstable: by using any of these, you opt out of all semver guarantees Ruma otherwise provides!

unstable-msc1767

Enables unstable-msc1767 of optional ruma-events

unstable-msc2409

Enables unstable-msc2409 of optional ruma-appservice-api

unstable-msc2448

Enables unstable-msc2448 of optional ruma-client-api, optional ruma-events, and optional ruma-federation-api

unstable-msc2654

Enables unstable-msc2654 of optional ruma-client-api

unstable-msc2666

Enables unstable-msc2666 of optional ruma-client-api

unstable-msc2747

Enables unstable-msc2747 of optional ruma-events

unstable-msc2867

Enables unstable-msc2867 of optional ruma-events

unstable-msc2870

Enables unstable-msc2870 of ruma-common

unstable-msc2965

Enables unstable-msc2965 of optional ruma-client-api

unstable-msc2967

Enables unstable-msc2967 of optional ruma-client-api

unstable-msc3061

Enables unstable-msc3061 of optional ruma-events

unstable-msc3202

Enables unstable-msc3202 of optional ruma-appservice-api

unstable-msc3245

Enables unstable-msc3245 of optional ruma-events

unstable-msc3245-v1-compat

Support the m.room.message fallback fields from the first version of MSC3245, implemented in Element Web and documented at https://github.com/matrix-org/matrix-spec-proposals/blob/83f6c5b469c1d78f714e335dcaa25354b255ffa5/proposals/3245-voice-messages.md

Enables unstable-msc3245-v1-compat of optional ruma-events

unstable-msc3246 unstable-extensible-events?

Enables unstable-msc3246 of optional ruma-events

unstable-msc3266

Enables unstable-msc3266 of optional ruma-client-api

unstable-msc3381

Enables unstable-msc3381 of optional ruma-events

unstable-msc3401

Enables unstable-msc3401 of optional ruma-events

unstable-msc3488 unstable-extensible-events?

Enables unstable-msc3488 of optional ruma-client-api and optional ruma-events

unstable-msc3489

Enables unstable-msc3489 of optional ruma-events

unstable-msc3551

Enables unstable-msc3551 of optional ruma-events

unstable-msc3552

Enables unstable-msc3552 of optional ruma-events

unstable-msc3553 unstable-extensible-events?

Enables unstable-msc3553 of optional ruma-events

unstable-msc3554

Enables unstable-msc3554 of optional ruma-events

unstable-msc3575

Enables unstable-msc3575 of optional ruma-client-api

unstable-msc3618

Enables unstable-msc3618 of optional ruma-federation-api

unstable-msc3723

Enables unstable-msc3723 of optional ruma-federation-api

unstable-msc3814

Enables unstable-msc3814 of optional ruma-client-api

unstable-msc3843

Enables unstable-msc3843 of optional ruma-client-api and optional ruma-federation-api

unstable-msc3927

Enables unstable-msc3927 of optional ruma-events

unstable-msc3930

Enables unstable-msc3930 of ruma-common

unstable-msc3931

Enables unstable-msc3931 of ruma-common

unstable-msc3932

Enables unstable-msc3932 of ruma-common

unstable-msc3954 unstable-extensible-events?

Enables unstable-msc3954 of optional ruma-events

unstable-msc3955 unstable-extensible-events?

Enables unstable-msc3955 of optional ruma-events

unstable-msc3956

Enables unstable-msc3956 of optional ruma-events

unstable-msc3983

Enables unstable-msc3983 of optional ruma-client-api

unstable-msc4075

Enables unstable-msc4075 of optional ruma-events

unstable-msc4095

Enables unstable-msc4095 of optional ruma-events

unstable-msc4108

Enables unstable-msc4108 of optional ruma-client-api

unstable-msc4121

Enables unstable-msc4121 of optional ruma-client-api

unstable-msc4125

Enables unstable-msc4125 of optional ruma-federation-api

unstable-msc4140

Enables unstable-msc4140 of optional ruma-client-api

unstable-msc4151

Enables unstable-msc4151 of optional ruma-client-api

unstable-msc4171

Enables unstable-msc4171 of optional ruma-events

unstable-msc4186

Enables unstable-msc4186 of optional ruma-client-api

unstable-pdu

Enables unstable-pdu of optional ruma-events

unstable-unspecified

Enables unstable-unspecified of ruma-common and optional ruma-federation-api