---
title: "Problem"
description: "RFC 9457 Problem Details shape."
url: "https://next.elysiajs.com/reference/type-aliases/problem/"
---

# Problem

```ts
type Problem<Code, Extension> = object & Extension;
```

Defined in: elysia/dist/error.d.ts:145

RFC 9457 Problem Details shape.

## Type Declaration

| Name        | Type     | Description                                                                                                                                                                | Defined in                 |
| ----------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------- |
| `code?`     | `string` | Extension member carrying a stable machine-readable token. `type` may be widened to a URI by [HTTPError.typeBase](/reference/classes/httperror/#typebase), `code` never is | elysia/dist/error.d.ts:153 |
| `detail?`   | `string` | -                                                                                                                                                                          | elysia/dist/error.d.ts:156 |
| `instance?` | `string` | -                                                                                                                                                                          | elysia/dist/error.d.ts:157 |
| `status?`   | `Code`   | -                                                                                                                                                                          | elysia/dist/error.d.ts:155 |
| `title?`    | `string` | -                                                                                                                                                                          | elysia/dist/error.d.ts:154 |
| `type?`     | `string` | URI (or slug) identifying the problem type. **Default** `'about:blank'`                                                                                                    | elysia/dist/error.d.ts:146 |

## Type Parameters

| Type Parameter                                                                       | Default type                                                        |
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------- |
| `Code` *extends* `number` \| keyof [`StatusMap`](/reference/type-aliases/statusmap/) | `number` \| keyof [`StatusMap`](/reference/type-aliases/statusmap/) |
| `Extension` *extends* `Record`<`string`, `unknown`>                                  | `object`                                                            |

## See

<https://www.rfc-editor.org/info/rfc9457/>
