Instantiate the pipe with an options object using new instead of passing the class reference. This lets you override the error HTTP status code, restrict UUID versions, or configure other pipe-specific behavior. When using new, the pipe is not resolved through DI — it cannot inject services.
Class reference (ParseIntPipe without new) — NestJS resolves it through the DI container.
Instance (new ParseIntPipe({...})) — you control options but lose DI injection inside the pipe.
Use class reference when the pipe has no options and may need injected services.
Use instance when you need to pass specific options like errorHttpStatusCode or version.
ParseFilePipe, ParseArrayPipe, ParseUUIDPipe, and ParseEnumPipe all accept option objects.