Package org.inthewaves.kotlinsignald.clientprotocol.v1.structures
Types
Accept a v2 group invitation. Note that you must have a profile name set to join groups.
A local account in signald
Link a new device to a local Signal account
add a new server to connect to. Returns the new server's UUID.
approve a request to join a group
Indicates the server rejected our credentials or a failed group update. Typically means the linked device was removed by the primary device, or that the account was re-registered. For group updates, this can indicate that we lack permissions.
Bans users from a group. This works even if the users aren't in the group. If they are currently in the group, they will also be removed.
A message containing a single boolean, usually as a response
Wraps all incoming messages sent to the client after a v1 subscribe request is issued
delete all account data signald has on disk, and optionally delete the account from the server as well. Note that this is not "unlink" and will delete the entire account, even from a linked device.
For requests that don't expect a response, representing {}.
An incoming message representing an error that can be sent by signald after a v1 subscribe request. This is not documented in the client protocol; however, as the signald socket can send it anyway, we add this here for type safety purposes.
After a linking URI has been requested, finish_link must be called with the session_id provided with the URI. it will return information about the new account once the linking process is completed by the other device and the new account is setup. Note that the account setup process can sometimes take some time, if rapid userfeedback is required after scanning, use wait_for_scan first, then finish setup with finish_link.
Generate a linking URI. Typically this is QR encoded and scanned by the primary device. Submit the returned session_id with a finish_link request.
get all known identity keys
Query the server for the latest state of a known group. If the account is not a member of the group, an UnknownGroupError is returned.
Query the server for group revision history. The history contains information about the changes between each revision and the user that made the change.
Get information about a known keys for a particular address
list all linked devices on a Signal account
Get all information available about a user
group access control settings. Options for each controlled action are: UNKNOWN, ANY, MEMBER, ADMINISTRATOR, UNSATISFIABLE and UNRECOGNIZED
Represents a group change made by a user. This can also represent request link invites. Only the fields relevant to the group change performed will be set. Note that in signald, group changes are currently only received from incoming messages from a message subscription.
The result of fetching a group's history along with paging data.
A generic type that is used when the group version is not known
Get information about a group from a signal.group link
Indicates the server rejected our group update. This can be due to errors such as trying to add a user that's already in the group.
a list of identity keys associated with a particular address
An incoming message representing an exception that can be sent by signald corresponding to one of the documented error types in the protocol.
an internal error in signald has occurred. typically these are things that "should never happen" such as issues saving to the local disk, but it is also the default error type and may catch some things that should have their own error type. If you find tht your code is depending on the exception list for any particular behavior, please file an issue so we can pull those errors out to a separate error type: https://gitlab.com/signald/signald/-/issues/new
Determine whether an account identifier is registered on the Signal service.
Join a group using the a signal.group URL. Note that you must have a profile name set to join groups.
represents a file attached to a message. When sending, only filename
is required.
information about a legacy group
Information about a Signal group
Responses to message requests from unknown users or groups
metadata about one of the links in a message
A quote is a reply to a previous message. ID is the sent time of the message being replied to
return all local accounts
prior attempt to indicate signald connectivity state. WebSocketConnectionState messages will be delivered at the same time as well as in other parts of the websocket lifecycle.
Information about a Signal user
react to a previous message
deny a request to join a group
begin the account registration process by requesting a phone number verification code. when the code is received, submit it with a verify request
A remote config (feature flag) entry.
Retrieves the remote config (feature flags) from the server.
delete a message previously sent
Remove a linked device from the Signal account. Only allowed when the local device id is 1
Request other devices on the account send us their group list, syncable config and contact list.
reset a session with a particular user
Resolve a partial JsonAddress with only a number or UUID to one with both. Anywhere that signald accepts a JsonAddress will except a partial, this is a convenience function for client authors, mostly because signald doesn't resolve all the partials it returns.
send a mobilecoin payment
Sends a sync message to the account's devices
a Signal server
set this device's name. This will show up on the mobile device on the same account under settings -> linked devices
Set the message expiration timer for a thread. Expiration must be specified in seconds, set to 0 to disable timer
A base class for requests. This class is only used for serializing requests to the signald socket; the type of the responseWrapperSerializer property represents the response JSON structure.
indicates signald received an http 500 status code from the server
Broadcast to subscribed clients when there is a state change from the storage service
receive incoming messages. After making a subscribe request, incoming messages will be sent to the client encoded as ClientMessageWrapper. Send an unsubscribe request or disconnect from the socket to stop receiving messages.
Responses from the subscribe / unsubscribe endpoint. The protocol describes these as empty responses, but race conditions can occur. This response can contain messages sent before the (un)subscribe acknowledgement message from signald.
Trust another user's safety number using either the QR code data or the safety number text
send a typing started or stopped message
Unbans users from a group.
See subscribe for more info
returned in response to use v1 groups, which are no longer supported
update information about a local contact
modify a group. Note that only one modification action may be performed at once
verify an account's phone number with a code after registering, completing the account creation process
An optional part of the linking process. Intended to be called after displaying the QR code, will return quickly after the user scans the QR code. finish_link must be called after wait_for_scan returns a non-error
indicates when the websocket connection state to the signal server has changed