[{"name":"Matrix","comment":"\n\n\n# Matrix SDK\n\nThis first version forms a mere basis from which we will create iterative builds\nthat slowly improve the codebase.\n\nIt is generally quite unusual to regularly publish iterative beta versions on\nthe public registry, but it is also generally quite unusual to exclusively\nsupport a monolithic public registry. (:\n\n\n## Vault\n\n@docs Vault\n\n","unions":[],"aliases":[{"name":"Vault","comment":" The Vault type stores all relevant information about the Matrix API.\n\nIt currently supports no functionality and it will just stay here - for fun.\n\n","args":[],"type":"Types.Vault"}],"values":[],"binops":[]},{"name":"Matrix.Event","comment":"\n\n\n# Matrix Events\n\nThis module contains all the functions necessary to view and manipulate Matrix\nevents.\n\n\n## Event\n\n@docs Event, content, eventType, stateKey\n\n\n## Metadata\n\n@docs eventId, roomId, sender, originServerTs\n\n\n## Optional data\n\nOccasionally, the Event might bring some extra information. Given how this\ninformation isn't always applicable, it doesn't always exist.\n\n@docs previousContent, redactedBecause\n\n","unions":[],"aliases":[{"name":"Event","comment":" In Matrix, the primary form of communication is to send JSON values to one\nanother. These JSON values, together with their metadata, are bundled into Event\ntypes. They contain information like:\n\n  - Who sent the JSON value\n  - How they intend you to decode it\n  - When they sent it\n  - In what room they sent it\n\n","args":[],"type":"Types.Event"}],"values":[{"name":"content","comment":" Receive the body of an Event, as created by the user that sent it.\n","type":"Matrix.Event.Event -> Json.Encode.Value"},{"name":"eventId","comment":" Determine the globally unique identifier for an event.\n","type":"Matrix.Event.Event -> String.String"},{"name":"eventType","comment":" To give a hint what the event's [content](#content) might look like, users\ncan use this eventType value to hint at how the JSON might be decoded.\n\nStandard examples of event types are `m.room.message`, `m.room.member` and\n`me.noordstar.game.chess.move`.\n\n","type":"Matrix.Event.Event -> String.String"},{"name":"originServerTs","comment":" Determine the timestamp of at what time the event was originally received by\nthe original homeserver.\n\nGenerally, this timestamp offers a relatively accurate indicator of when a\nmessage was sent. However, this number isn't completely reliable! The timestamp\ncan be far in the past due to long network lag, and a (malicious) homeserver can\nspoof this number to make it seem like something was sent ridiculously far in\nthe past - or even in the future.\n\n","type":"Matrix.Event.Event -> Time.Posix"},{"name":"previousContent","comment":" Determine the previous `content` value for this event. This field is only a\n`Just value` if the event is a state event, and the Matrix Vault has permission\nto see the previous content.\n","type":"Matrix.Event.Event -> Maybe.Maybe Json.Encode.Value"},{"name":"redactedBecause","comment":" If the event has been redacted, the homeserver can display the event that\nredacted it here.\n","type":"Matrix.Event.Event -> Maybe.Maybe Matrix.Event.Event"},{"name":"roomId","comment":" Unique id assigned to the Matrix room. You can use this room id to reference\nor look up rooms.\n","type":"Matrix.Event.Event -> String.String"},{"name":"sender","comment":" Determine the fully-qualified ID of the user who sent an event.\n","type":"Matrix.Event.Event -> String.String"},{"name":"stateKey","comment":" Determine an event's state key.\n\nIt is present if, and only if, the event is a _state_ event. The key makes the\npiece of state unique in the room. Note that it is often `Just \"\"`. If it is not\npresent, its value is `Nothing`.\n\nState keys starting with an `@` are reserved for referencing user IDs, such as\nroom members. With the exception of a few events, state events set with a given\nuser'd ID as the state key can only be set by that user.\n\n","type":"Matrix.Event.Event -> Maybe.Maybe String.String"}],"binops":[]},{"name":"Matrix.Settings","comment":" The Matrix Vault has lots of configurable variables that you rarely want to\ninteract with. Usually, you configure these variables only when creating a new\nVault, or when a user explicitly changes one of their preferred settings.\n\n\n## Device name\n\nThe default device name that is being communicated with the Matrix API.\n\nThis is mostly useful for users who are logged in with multiple sessions. They\nwill see device names like \"Element for Android\" or \"Element on iOS\". For the\nElm SDK, they will by default see the Elm SDK with its version included. If you\nare writing a custom client, however, you are free to change this to something\nmore meaningful to the user.\n\n@docs getDeviceName, setDeviceName\n\n\n## Sync time\n\nWhenever the Matrix API has nothing new to report, the Elm SDK is kept on\nhold until something new happens. The `syncTime` indicates a timeout to how long\nthe Elm SDK tolerates being held on hold.\n\n  - ↗️ A high value is good because it significantly reduces traffic between the\n    user and the homeserver.\n  - ↘️ A low value is good because it reduces the risk of\n    the connection ending abruptly or unexpectedly.\n\nNowadays, most libraries use 30 seconds as the standard, as does the Elm SDK.\nThe value is in miliseconds, so it is set at 30,000.\n\n@docs getSyncTime, setSyncTime\n\n","unions":[],"aliases":[],"values":[{"name":"getDeviceName","comment":" Determine the device name.\n","type":"Types.Vault -> String.String"},{"name":"getSyncTime","comment":" Determine the sync timeout value.\n","type":"Types.Vault -> Basics.Int"},{"name":"setDeviceName","comment":" Override the device name.\n","type":"String.String -> Types.Vault -> Types.Vault"},{"name":"setSyncTime","comment":" Override the sync timeout value.\n","type":"Basics.Int -> Types.Vault -> Types.Vault"}],"binops":[]}]