Layer 231
WalletTonConnectCloseSession
Close a TON Connect session between the user's wallet and a d App, optionally delivering an encrypted disconnect event to the d App.
method
wallet.tonConnectCloseSession#d63f61ce flags:# session_id:long body:flags.0?bytes = Bool;
Parameters
| Name | Type | Description |
|---|---|---|
| SessionId | long | ID of the TON Connect session to close |
| Body | flags.0?bytes | Encrypted disconnect event to deliver to the d App |
Returns
BoolGogram Example
// encryptedDisconnect: the TON Connect "disconnect" event, encrypted on-device for the dApp. ok, err := client.WalletTonConnectCloseSession(sessionID, encryptedDisconnect) if err != nil { log.Fatal(err) } fmt.Println("session closed:", ok)