Skip to content

Documentation / @frak-labs/react-sdk / useSiweAuthenticate

Function: useSiweAuthenticate()

useSiweAuthenticate(args?): UseMutationResult<{ message: string; signature: `0x${string}`; }, FrakRpcError<undefined>, { metadata?: ModalRpcMetadata; siwe?: Partial<SiweAuthenticationParams>; }, unknown>

Defined in: react/src/hook/useSiweAuthenticate.ts:45

Hook that return a mutation helping to send perform a SIWE authentication

It's a `tanstack` wrapper around the `siweAuthenticate()` action

Parameters

args?

UseSiweAuthenticateParams = {}

Optional config object with mutations for customizing the underlying `useMutation()`

Returns

UseMutationResult<{ message: string; signature: `0x${string}`; }, FrakRpcError<undefined>, { metadata?: ModalRpcMetadata; siwe?: Partial<SiweAuthenticationParams>; }, unknown>

The mutation hook wrapping the siweAuthenticate() action The mutate and mutateAsync argument is of type `SiweAuthenticateModalParams` The data result is a `SiweAuthenticateReturnType`

See