Skip to Content

SiwxSession

Defined in: siwx-server/src/types.ts:70 

Serializable session derived from a verified CAIP-122 message (see toSession). Returned as JSON by the verify and session endpoints of @tuwaio/siwx-server/next.

Properties

address

address: string

Defined in: siwx-server/src/types.ts:72 

The verified CAIP-10 blockchain address.


chainId

chainId: string

Defined in: siwx-server/src/types.ts:74 

The CAIP-2 chain ID the session is bound to.


domain

domain: string

Defined in: siwx-server/src/types.ts:76 

The domain that issued the session.


expirationTime?

optional expirationTime?: string

Defined in: siwx-server/src/types.ts:82 

ISO 8601 timestamp when the session expires, if set.


issuedAt

issuedAt: string

Defined in: siwx-server/src/types.ts:80 

ISO 8601 timestamp when the session was issued.


nonce

nonce: string

Defined in: siwx-server/src/types.ts:78 

The nonce of the signed message. It must be single-use: consume it in a SiwxNonceStore.


verificationMethod?

optional verificationMethod?: SiwxVerificationMethod

Defined in: siwx-server/src/types.ts:88 

How the signature was verified (see SiwxVerificationMethod). Set by createSiwxApiHandler; in your own handlers, pass result.method of verifySiwxPayload to toSession. siwxJwtSubject reads it: without it, the subject of an EVM session keeps its chain.

Last updated on