# Siwe.validateMessage

Validates [EIP-4361](https://eips.ethereum.org/EIPS/eip-4361) message.

## Imports

:::code-group
```ts [Named]
import { Siwe } from 'ox'
```

```ts [Entrypoint]
import * as Siwe from 'ox/Siwe'
```
:::

## Examples

```ts twoslash
import { Siwe } from 'ox'

Siwe.validateMessage({
  address: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e',
  domain: 'example.com',
  message: {
    address: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e',
    chainId: 1n,
    domain: 'example.com',
    nonce: 'foobarbaz',
    uri: 'https://example.com/path',
    version: '1'
  },
  nonce: 'foobarbaz'
})
// @log: true
```

## Definition

```ts
function validateMessage(
  value: validateMessage.Value,
): boolean
```

**Source:** [src/core/Siwe.ts](https://github.com/wevm/ox/blob/main/src/core/Siwe.ts#L513)

## Parameters

### value

* **Type:** `validateMessage.Value`

Values to use when validating EIP-4361 formatted message.

## Return Type

Whether the message is valid.

`boolean`
