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

# RequestHookContext

Context of a request, for [EnginexClientHooks](EnginexClientHooks.md). It never includes headers, tokens, the body
(only the summary of a multipart body, in `body`) or the query string: just enough for
logging/observability with no risk of leaking secrets.

## Extended by

* [`ResponseHookContext`](ResponseHookContext.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`).

***

### 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.

***

### method

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

HTTP method.

***

### path

> **path**: `string`

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

***

### 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`.
