Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

eth_accounts

Get currently connected accounts without triggering authentication. Returns an empty array if no accounts are connected.

Authentication Required: No

Request

await jaw.provider.request({
  method: 'eth_accounts',
});

Parameters

None

Response

Returns an array of connected account addresses. Returns an empty array if not authenticated.

Type: 0x${string}[]

Example (Connected)

["0x1234567890123456789012345678901234567890"]

Example (Not Connected)

[]

Behavior

  • Returns empty array if not authenticated
  • Returns cached accounts if already connected
  • Does not trigger authentication popup

Example

import { JAW } from '@jaw.id/core';
 
const jaw = JAW.create({
  apiKey: 'your-api-key',
});
 
const accounts = await jaw.provider.request({
  method: 'eth_accounts',
});

Related Methods