---
url: >-
  https://game-engine-io.github.io/enginex-frontend-sdk/reference/api/@getenginex/sdk/interfaces/ResponseHookContext.md
---
[Reference](../../../index.md) / [@getenginex/sdk](../index.md) / ResponseHookContext

# ResponseHookContext

Context of a received response, for [EnginexClientHooks.onResponse](EnginexClientHooks.md#onresponse).

## Extends

* [`RequestHookContext`](RequestHookContext.md)

## Properties

### attempt

> **attempt**: `number`

Attempt number: `1` on the first call, `2` on the retry after a renewed 401. In
`onError`, it may be `0` when the call failed before any network attempt (e.g.
`CONFIGURATION_ERROR` while resolving `baseUrl`/`tenantHost`/`fetch`).

#### Inherited from

[`RequestHookContext`](RequestHookContext.md).[`attempt`](RequestHookContext.md#attempt)

***

### body?

> `optional` **body?**: [`RequestBodySummary`](RequestBodySummary.md)

Body summary, only on multipart requests (e.g. `kyc.uploadDocument`): the name of each field and,
for files, type and size — never the original name or the content of the file, nor the value of
text fields. Absent on the other requests (JSON body or no body), whose body never reaches the hooks.

#### Inherited from

[`RequestHookContext`](RequestHookContext.md).[`body`](RequestHookContext.md#body)

***

### durationMs

> **durationMs**: `number`

Duration of the attempt, in milliseconds.

***

### method

> **method**: [`HttpMethod`](../type-aliases/HttpMethod.md)

HTTP method.

#### Inherited from

[`RequestHookContext`](RequestHookContext.md).[`method`](RequestHookContext.md#method)

***

### path

> **path**: `string`

Path after `/api/v1`, without a query string, e.g. `/auth/login`.

#### Inherited from

[`RequestHookContext`](RequestHookContext.md).[`path`](RequestHookContext.md#path)

***

### requestId?

> `optional` **requestId?**: `string`

The response's `X-Request-ID`, when there is one.

***

### status

> **status**: `number`

HTTP status of the response.

***

### url

> **url**: `string`

Request URL without the query string: `baseUrl` + `/api/v1` + `path`, e.g.
`https://gateway.operator.com/api/v1/auth/login`. With `baseUrl: ''` (same-origin, the default) it is
relative, e.g. `/api/v1/auth/login`.

#### Inherited from

[`RequestHookContext`](RequestHookContext.md).[`url`](RequestHookContext.md#url)
