Перейти к содержанию

SignerClient > SSETransportDriver


class SSETransportDriver(val url: String, val auth: AuthorizationSession) : TransportDriver

Client-side HTTP(S) + SSE bidirectional transport

Used for communication with Spatium Signer Service. As soon as created, it immediately tries to connect to a provided url and start listening for incoming messages

  • SeeAlso TransportDriver



url signer service endpoint (HTTP(S))
auth authorization AuthorizationSession session to use

Note requests are attributed to accountId of an authorization session, thus storing data independently for each authorized user


SSETransportDriver [androidJvm]
constructor(url: String, auth: AuthorizationSession)


Name Summary
auth [androidJvm]
val auth: AuthorizationSession
url [androidJvm]
val url: String


Name Summary
connect [androidJvm]
suspend fun connect(timeout: UInt?)
Connect and start listening to events
disconnect [androidJvm]
fun disconnect()
Stop listening for messages and disconnect
off [androidJvm]
open override fun off(id: String, data: TransportData?)
on [androidJvm]
open override fun on(filter: TransportFilter, callback: TransportCallback): String
send [androidJvm]
open suspend override fun send(meta: TransportMeta, data: TransportData)