# fetchUser

`function` in `seedcord` · v0.11.0

<https://docs.seedcord.org/packages/seedcord/0.11.0/functions/fetch-user>

Fetches a Discord user by ID with error handling.

```ts
async fetchUser(
    client: Client,
    userId: string
): Promise<User>
```

Fetches a Discord user by ID with error handling.

Parameters.

- `client` `Client` — The Discord client instance
- `userId` `string` — The Discord user ID

Returns `Promise<User>`.
