# `OCSF.HttpRequest`
[🔗](https://github.com/docjerem/ocsf/blob/v0.1.0/lib/ocsf/objects/http_request.ex#L1)

OCSF HTTP Request object.

Represents an HTTP request associated with an OCSF event. Used to
capture request-level context such as the URL, user agent, and HTTP
method.

Corresponds to the OCSF
[HTTP Request](https://schema.ocsf.io/1.8.0/objects/http_request) object.

## Fields

- `:url` -- request URL. Classified as `:network`.
- `:user_agent` -- user agent string. Classified as `:network`.
- `:http_method` -- HTTP method (e.g. `"GET"`, `"POST"`). Classified as `:taxonomic`.

## PII classification

See `OCSF.Classification` for data class definitions. Call
`__ocsf_fields__/0` to inspect this module's field classifications.

See `OCSF.NetworkEndpoint` for network endpoint information.

# `t`

```elixir
@type t() :: %OCSF.HttpRequest{
  http_method: String.t() | nil,
  url: String.t() | nil,
  user_agent: String.t() | nil
}
```

# `__ocsf_fields__`

```elixir
@spec __ocsf_fields__() :: keyword()
```

Return field classification metadata for PII policy enforcement.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
